Package com.zfabrik.components.provider.util

## Class AbstractComponentDescriptor

- java.lang.Object
- - com.zfabrik.components.provider.util.AbstractComponentDescriptor

- All Implemented Interfaces:
    `IComponentDescriptor`, `java.io.Serializable`
  Direct Known Subclasses:
    `FSCRDBComponent`

      public abstract class AbstractComponentDescriptor
      extends java.lang.Object
      implements IComponentDescriptor, java.io.Serializable

  Abstract implementation of a component descriptor. Useful in component repository implementations This implementation supports the switch board development mode feature. That is, in development mode, component properties may be overwritten by system properties following the naming scheme:

  `< component name >/ < property name > = < new value >`

  This implementation furthermore supports processing of properties for `IComponentDescriptorProcessor` implementations, such as the built-in JEXL3 support.
  See Also:
    Serialized Form

- - ### Field Summary

    - ### Fields inherited from interface com.zfabrik.components.IComponentDescriptor

      `ANY_COMPONENT_TYPE, COMPONENT_CLZ, COMPONENT_DESCRIPTOR_STYLE_PLAIN, COMPONENT_NAME, COMPONENT_TYPE, DEPENDENCIES, EXTENSION_POINTS, LINK_COMPONENT_TYPE, LINK_TARGET_COMPONENT, REVISION_INFO`

  - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `AbstractComponentDescriptor()` | Default constructor
    `AbstractComponentDescriptor​(AbstractComponentDescriptor a)` | Copy constructor

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `boolean` | `equals​(java.lang.Object obj)` |
    `java.lang.String` | `getName()` | Gets the name of the component.
    `java.util.Properties` | `getProperties()` | Get the properties of this component.
    `java.lang.String` | `getProperty​(java.lang.String name)` | Just a short hand for `getProperties().getProperty(String)`
    `java.util.Properties` | `getRawProperties()` | Get the raw properties of this component.
    `long` | `getRevision()` | Get the revision of the component.
    `java.lang.String` | `getType()` | Gets the type of the component.
    `int` | `hashCode()` |
    `static java.util.Properties` | `processProperties​(java.util.Properties raw)` | This method uses the to process properties to their target representation using none or some resolvable expression processing facility.
    `static java.util.Properties` | `processProperties​(java.util.Properties raw, java.util.function.Function<java.lang.String,​IComponentDescriptorProcessor> getProcessor)` | Processing with custom retrieval of processors.
    `void` | `setName​(java.lang.String name)` |
    `void` | `setProperties​(java.util.Properties properties)` |
    `void` | `setRevision​(long revision)` |

    - ### Methods inherited from class java.lang.Object

      `clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### AbstractComponentDescriptor

          public AbstractComponentDescriptor()

      Default constructor

    - #### AbstractComponentDescriptor

          public AbstractComponentDescriptor​(AbstractComponentDescriptor a)

      Copy constructor

  - ### Method Detail

    - #### setProperties

          public void setProperties​(java.util.Properties properties)

    - #### getRawProperties

          public java.util.Properties getRawProperties()

      Description copied from interface: `IComponentDescriptor`
      Get the raw properties of this component. Note that unlike `IComponentDescriptor.getProperties()` the result of this method is data as defined in persistent component configuration-
      Specified by:
        `getRawProperties` in interface `IComponentDescriptor`

    - #### setName

          public void setName​(java.lang.String name)

    - #### setRevision

          public void setRevision​(long revision)

    - #### getName

          public java.lang.String getName()

      Description copied from interface: `IComponentDescriptor`
      Gets the name of the component.
      Specified by:
        `getName` in interface `IComponentDescriptor`

    - #### getProperties

          public java.util.Properties getProperties()

      Description copied from interface: `IComponentDescriptor`
      Get the properties of this component. Note that these differ from the original configuration in these may be processed by some expression language evaluator.
      Specified by:
        `getProperties` in interface `IComponentDescriptor`

    - #### processProperties

          public static java.util.Properties processProperties​(java.util.Properties raw)

      This method uses the to process properties to their target representation using none or some resolvable expression processing facility.

    - #### processProperties

          public static java.util.Properties processProperties​(java.util.Properties raw,
                                                               java.util.function.Function<java.lang.String,​IComponentDescriptorProcessor> getProcessor)

      Processing with custom retrieval of processors. See also `IComponentDescriptor`.

    - #### getRevision

          public long getRevision()

      Description copied from interface: `IComponentDescriptor`
      Get the revision of the component. Minimum revision is zero. Revisions may not necessarily be strictly increasing, as components may be provided by different repositories over time.
      Specified by:
        `getRevision` in interface `IComponentDescriptor`

    - #### getType

          public java.lang.String getType()

      Description copied from interface: `IComponentDescriptor`
      Gets the type of the component. A short-hand for `getProperty(COMPONENT_TYPE)`.
      Specified by:
        `getType` in interface `IComponentDescriptor`

    - #### getProperty

          public java.lang.String getProperty​(java.lang.String name)

      Description copied from interface: `IComponentDescriptor`
      Just a short hand for `getProperties().getProperty(String)`
      Specified by:
        `getProperty` in interface `IComponentDescriptor`

    - #### hashCode

          public int hashCode()

      Overrides:
        `hashCode` in class `java.lang.Object`

    - #### equals

          public boolean equals​(java.lang.Object obj)

      Overrides:
        `equals` in class `java.lang.Object`