question: private void element ( String segment ) { int index = segment . indexOf ( ':' ) ; String prefix = null ; if ( index > 0 ) { prefix = segment . substring ( 0 , index ) ; segment = segment . substring ( index + 1 ) ; } String element = style . getElement ( segment ) ; prefixes . add ( prefix ) ; names . add ( element ) ; }
target:  This will insert the path segment provided. A path segment is represented by an optional namespace prefix and an XML element name. If there is no prefix then a null is entered this will ensure that the names and segments are kept aligned by index.