public static void readPropertiesToListeners ( InputStream source , Encoding encoding , PropertiesParsingListener ... listeners ) throws IOException , SyntaxErrorException { BufferedReader _reader = new BufferedReader ( createReaderForInputStream ( source , encoding ) ) ; LineByLinePropertyParser _parser = new LineByLinePropertyParser ( ) ; for ( PropertiesParsingListener _listener : listeners ) { _parser . addListener ( _listener ) ; } for ( String _line = _reader . readLine ( ) ; _line != null ; ) { _parser . parseLine ( _line ) ; _line = _reader . readLine ( ) ; } _reader . close ( ) ; }
Read a file of properties and notifies all the listeners for each property .