Examples of PropertyMap


Examples of org.gatein.pc.api.state.PropertyMap

      }
      else
      {
         if (persistLocally)
         {
            PropertyMap newState = new SimplePropertyMap();
            getPropertiesFromMetaData(originalPortletContext, newState);
            try
            {
               PortletState sstate = new PortletState(portletId, newState);
               Serializable marshalledState = stateConverter.marshall(stateType, sstate);
View Full Code Here

Examples of org.gatein.pc.api.state.PropertyMap

         }
      }

      // Get the missing or read only properties from the referenced portlet properties
      // and add them to the actual state
      PropertyMap refPreferencesInfo = super.getProperties(portletContext, keys);
      for (Map.Entry<String, List<String>> entry : refPreferencesInfo.entrySet())
      {
         String key = entry.getKey();
         List<String> value = entry.getValue();
         props.setProperty(key, new ArrayList<String>(value));
      }
View Full Code Here

Examples of org.gatein.pc.api.state.PropertyMap

         );

         List<Property> props = properties.value;
         if (props != null)
         {
            PropertyMap result = new SimplePropertyMap(props.size());

            for (Property prop : props)
            {
               String name = prop.getName().toString();
               String value = prop.getStringValue();
               List<String> list = new ArrayList<String>();
               list.add(value);
               result.put(name, list); // todo: is that all?!?
            }

            return result;
         }
         else
View Full Code Here

Examples of org.jboss.portal.portlet.state.PropertyMap

         //
         dos.writeInt(MAGIC_VALUE);
         dos.write(VERSION_ID);
         dos.writeUTF(state.getPortletId());
         PropertyMap map = state.getProperties();
         dos.writeInt(map.size());
         for (Map.Entry<String, List<String>> entry : map.entrySet())
         {
            String key = entry.getKey();
            List<String> value = entry.getValue();
            String[] strings = value.toArray(new String[value.size()]);
            dos.writeUTF(key);
View Full Code Here

Examples of org.metagrid.gatekeeper.node.property.PropertyMap

    public void testGenericProperties()
    throws Exception
        {
        //
        // Create our PropertyMap (null node).
        final PropertyMap properties = new SimplePropertyMap(null);
        //
        // Create our reader.
        final XMLPropertiesReader reader = new XMLPropertiesReaderImpl(
            new XMLPropertyReaderImpl()
            );
        //
        // Parse the test XML.
        reader.read(
            new StringResource(
                  "<properties xmlns='urn:metagrid'>"
                + "  <property type='urn:metagrid/property/type/frog'>property.frog</property>"
                + "  <property type='urn:metagrid/property/type/toad'>property.toad</property>"
                + "</properties>"
                ).reader(),
            properties
            );
        //
        // Check the property values.
        assertEquals(
            "property.frog",
            properties.get(
                new URI(
                    "urn:metagrid/property/type/frog"
                    )
                ).value()
            );
        assertEquals(
            "property.toad",
            properties.get(
                new URI(
                    "urn:metagrid/property/type/toad"
                    )
                ).value()
            );
View Full Code Here

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

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

      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

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

      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

Examples of org.rhq.core.domain.configuration.PropertyMap

*/
public abstract class AbstractPropertyMapAdapter implements PropertyAdapter<PropertyMap, PropertyDefinitionMap>
{
    public PropertyMap convertToProperty(MetaValue metaValue, PropertyDefinitionMap propDefMap)
    {
        PropertyMap propMap = new PropertyMap(propDefMap.getName());
        populatePropertyFromMetaValue(propMap, metaValue, propDefMap);
        return propMap;
    }
View Full Code Here

Examples of org.rhq.core.domain.configuration.PropertyMap

*/
public class PropertyMapToTableValueAdapter extends AbstractPropertyMapAdapter implements PropertyAdapter<PropertyMap, PropertyDefinitionMap>
{
    public PropertyMap convertToProperty(MetaValue metaValue, PropertyDefinitionMap propertyDefinition)
    {
        PropertyMap property = new PropertyMap();
        populatePropertyFromMetaValue(property, metaValue, propertyDefinition);
        return property;
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.