code: private void parseLine( List<String> names, String line )
      {
          int commentPos = line.indexOf( '#' );
          if( commentPos >= 0 )
          {
              line = line.substring( 0, commentPos );
          }
          line = line.trim();
          if( !line.isEmpty() && !names.contains( line ) )
          {
              names.add( line );
          }
      }
docs: Parses a single line of a META-INF/services resources. If the line contains a class name, the
  name is added to the given list.
  
  @param names list of class names
  @param line line to be parsed