Interface AggregateObject

All Superinterfaces:
DataObject, PropertyHandler
All Known Implementing Classes:
AggregateObjectImpl

public interface AggregateObject extends DataObject
An AggregateObject represents an collection of attribute value pairs.

A detailed description can be found in the AggregateClass.

Author:
Rainer Maximini
See Also:
  • Field Details

  • Method Details

    • getAggregateClass

      AggregateClass getAggregateClass()
    • getAttributeValue

      DataObject getAttributeValue(String name)
      The method returns the value for a specific Attribute, which can be a subclass of DataObject. If the given AggregateObject doesn't contain the attribute, null will be returned.
      Parameters:
      name - the name of the requested attribute
      Returns:
      the DataObject value of the requested attribute name.
    • resolveAttributeClass

      DataClass resolveAttributeClass(AttributePath path) throws ProCAKENoSuchAttributeException
      Throws:
      ProCAKENoSuchAttributeException
    • resolveAttributeValue

      DataObject resolveAttributeValue(AttributePath path) throws ProCAKENoSuchAttributeException
      Throws:
      ProCAKENoSuchAttributeException
    • setAttributeValue

      void setAttributeValue(String name, DataObject value) throws ProCAKEInvalidTypeException, ProCAKENoSuchAttributeException
      Sets a value for the given attribute. Values can be removed by setting null.
      Parameters:
      name - An existing attribute name for the AggregateObject.
      value - A new DataObject object that matches to the specified type, a VoidObject object, or null.
      Throws:
      ProCAKEInvalidTypeException - if the types of the given value and the attribute doesn't match
      ProCAKENoSuchAttributeException - if the AggregateObject doesn't contain a attribute with this name
    • getAttributeMap

      Map<String,DataObject> getAttributeMap()
      Returns an unmodifiable map of all attributes and values of this aggregate.
      Returns:
      an unmodifiable map of all attributes and values
    • isEmpty

      boolean isEmpty()
      Checks, if the aggregate object contains any values.
      Returns:
    • hasAttributeValue

      boolean hasAttributeValue(String string)
      Checks if the aggregate object contains an attribute with the given name whose value is not null
      Parameters:
      string - the name of the attribute
      Returns:
    • getAttributeNames

      Collection<String> getAttributeNames()
      Returns a collection of all attribute names.
      Returns:
      a collection of all attribute names
    • size

      int size()
      Returns the size of the underlying map of attributes.
      Returns:
      the number of attributes