private void createStringMappings ( MtasTokenIdFactory mtasTokenIdFactory , Level level , String stringValue , int offsetStart , int offsetEnd , int position ) throws IOException { // System.out.println("createStringMappings string "); String [ ] stringValues = MtasPennTreebankReader . createStrings ( stringValue , Pattern . quote ( STRING_SPLITTER ) ) ; if ( stringValues . length > 0 && ! stringValues [ 0 ] . trim ( ) . isEmpty ( ) ) { MtasToken token = new MtasTokenString ( mtasTokenIdFactory . createTokenId ( ) , "t" , filterString ( stringValues [ 0 ] . trim ( ) ) , position ) ; token . setOffset ( offsetStart , offsetEnd ) ; tokenCollection . add ( token ) ; level . tokens . add ( token ) ; } if ( stringValues . length > 1 && ! stringValues [ 1 ] . trim ( ) . isEmpty ( ) ) { MtasToken token = new MtasTokenString ( mtasTokenIdFactory . createTokenId ( ) , "lemma" , filterString ( stringValues [ 1 ] . trim ( ) ) , position ) ; token . setOffset ( offsetStart , offsetEnd ) ; tokenCollection . add ( token ) ; level . tokens . add ( token ) ; } }
Creates the string mappings .