protected AttachedFileDataType[] getAttachedFileDataTypes(String narrativeTypeCode) {

        int size = 0;
        for (NarrativeContract narrative : pdDoc.getDevelopmentProposal().getNarratives()) {
            if (narrative.getNarrativeType() != null
                    && narrative.getNarrativeType().getCode().equals(narrativeTypeCode)) {
                size++;
            }
        }
        AttachedFileDataType[] attachedFileDataTypes = new AttachedFileDataType[size];
        int attachments = 0;
        for (NarrativeContract narrative : pdDoc.getDevelopmentProposal().getNarratives()) {
            if (narrative.getNarrativeType() != null
                    && narrative.getNarrativeType().getCode().equals(narrativeTypeCode)) {
                attachedFileDataTypes[attachments] = getAttachedFileType(narrative);
                attachments++;
            }
        }
        return attachedFileDataTypes;
    }
protected AttachedFileDataType [ ] getAttachedFileDataTypes ( String narrativeTypeCode ) { int size = 0 ; for ( NarrativeContract narrative : pdDoc . getDevelopmentProposal ( ) . getNarratives ( ) ) { if ( narrative . getNarrativeType ( ) != null && narrative . getNarrativeType ( ) . getCode ( ) . equals ( narrativeTypeCode ) ) { size ++ ; } } AttachedFileDataType [ ] attachedFileDataTypes = new AttachedFileDataType [ size ] ; int attachments = 0 ; for ( NarrativeContract narrative : pdDoc . getDevelopmentProposal ( ) . getNarratives ( ) ) { if ( narrative . getNarrativeType ( ) != null && narrative . getNarrativeType ( ) . getCode ( ) . equals ( narrativeTypeCode ) ) { attachedFileDataTypes [ attachments ] = getAttachedFileType ( narrative ) ; attachments ++ ; } } return attachedFileDataTypes ; }
This method is used to get List of Other attachments from NarrativeAttachment

@return AttachedFileDataType[] based on the narrative type code.