Package org.omnaest.utils.propertyfile.content

Examples of org.omnaest.utils.propertyfile.content.PropertyMap


        {
          propertyFile.setFileEncoding( fileEncoding );
        }
        propertyFile.setUseJavaStyleUnicodeEscaping( useJavaStyleUnicodeEscaping );
        propertyFile.load();
        PropertyMap propertyMap = propertyFile.getPropertyFileContent().getPropertyMap();
       
        //
        boolean contentChanged = false;
        for ( String propertyKey : propertyKeyToValueMap.keySet() )
        {
          //
          String value = propertyKeyToValueMap.get( propertyKey );
         
          //
          if ( StringUtils.isNotEmpty( value ) )
          {
            //
            String[] values = value.split( Pattern.quote( FileGroupToPropertiesAdapter.MULTILINE_VALUES_SEPARATOR ) );
           
            //
            Property property = propertyMap.containsKey( propertyKey ) ? property = propertyMap.get( propertyKey )
                                                                      : new Property();
           
            //
            property.setKey( propertyKey );
            property.clearValues();
            property.addAllValues( Arrays.asList( values ) );
           
            //
            propertyMap.put( property );
           
            //
            contentChanged = true;
          }
          else if ( propertyMap.containsKey( propertyKey ) && deletePropertiesWithBlankValue )
          {
            //
            propertyMap.remove( propertyKey );
           
            //
            contentChanged = true;
          }
        }
View Full Code Here


      PropertyFile propertyFile = this.resolveAndLoadPropertyFile( groupToken );
      if ( propertyFile != null )
      {
        //
        PropertyFileContent propertyFileContent = propertyFile.getPropertyFileContent();
        PropertyMap propertyMap = propertyFileContent.getPropertyMap();
       
        //
        Property property = propertyMap.get( propertyKey );
        if ( property != null )
        {
          //
          retval = new PropertyFileAndProperty();
          retval.setProperty( property );
View Full Code Here

      PropertyFile propertyFile = this.resolveAndLoadPropertyFile( groupToken );
      if ( propertyFile != null )
      {
        //
        PropertyFileContent propertyFileContent = propertyFile.getPropertyFileContent();
        PropertyMap propertyMap = propertyFileContent.getPropertyMap();
       
        //
        retset.addAll( propertyMap.keySet() );
      }
    }
   
    //
    return retset;
View Full Code Here

TOP

Related Classes of org.omnaest.utils.propertyfile.content.PropertyMap

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.