Class ComplexPropertyContainer


  • public class ComplexPropertyContainer
    extends java.lang.Object
    Object representation for arrays content This Class could be used to define directly a property with more than one field (structure) and also schemas
    • Field Detail

      • properties

        private final java.util.List<AbstractField> properties
    • Constructor Detail

      • ComplexPropertyContainer

        public ComplexPropertyContainer()
        Complex Property type constructor (namespaceURI is given)
    • Method Detail

      • getFirstEquivalentProperty

        protected AbstractField getFirstEquivalentProperty​(java.lang.String localName,
                                                           java.lang.Class<? extends AbstractField> type)
        Give the first property found in this container with type and localname expected
        Parameters:
        localName - the localname of property wanted
        type - the property type of property wanted
        Returns:
        the property wanted
      • addProperty

        public void addProperty​(AbstractField obj)
        Add a property to the current structure
        Parameters:
        obj - the property to add
      • getAllProperties

        public java.util.List<AbstractField> getAllProperties()
        Return all children associated to this property
        Returns:
        All Properties contained in this container
      • getPropertiesByLocalName

        public java.util.List<AbstractField> getPropertiesByLocalName​(java.lang.String localName)
        Return all properties with this specified localName.
        Parameters:
        localName - the local name wanted
        Returns:
        All properties with local name which match with localName given, or null if there are none.
      • isSameProperty

        public boolean isSameProperty​(AbstractField prop1,
                                      AbstractField prop2)
        Check if two properties are equal.
        Parameters:
        prop1 - First property
        prop2 - Second property
        Returns:
        True if these properties are equal.
      • containsProperty

        public boolean containsProperty​(AbstractField property)
        Check if a XMPFieldObject is in the complex property
        Parameters:
        property - The property to check
        Returns:
        True if property is present in this container
      • removeProperty

        public void removeProperty​(AbstractField property)
        Remove a property
        Parameters:
        property - The property to remove
      • removePropertiesByName

        public void removePropertiesByName​(java.lang.String localName)
        Remove all properties with a specified LocalName.
        Parameters:
        localName - The name for which to remove all.