Package com.sas.services

# Class AbstractServiceAttributeFactory

java.lang.Object
com.sas.services.AbstractServiceAttributeFactory

All Implemented Interfaces:
  `ServiceAttributeFactoryInterface`

public abstract class AbstractServiceAttributeFactory extends Object implements ServiceAttributeFactoryInterface
Abstract implementation of a factory used to manufacture a service attribute. A service attribute is used in the context of the Discovery service as an optional qualifier used to discover a service.

A service may employ service attributes to distinguish itself from other services that satisfy the same service types. This permits a client to seek not only a service satisfying particular service type(s), but also optionally specified service attributes.

Since:
  1.0
See Also:
  - `ServiceAttributeFactoryInterface`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `AbstractServiceAttributeFactory()`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `final ServiceAttributeInterface`
  `getServiceAttribute(ServiceConfigurationInterface serviceConfiguration)`
  Gets the service attribute from the provided service configuration.
  `abstract ServiceAttributeInterface`
  `getServiceAttribute(Map nameValueMap)`
  Abstract method used to get a service attribute with its fields initialized with values obtained from the specified map.

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

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

- ## Constructor Details

  - ### AbstractServiceAttributeFactory

    public AbstractServiceAttributeFactory()

- ## Method Details

  - ### getServiceAttribute

    public final ServiceAttributeInterface getServiceAttribute(ServiceConfigurationInterface serviceConfiguration) throws InitializationException
    Gets the service attribute from the provided service configuration.
    Specified by:
      `getServiceAttribute` in interface `ServiceAttributeFactoryInterface`
    Parameters:
      `serviceConfiguration` - Service configuration containing the service attribute.
    Returns:
      Service attribute.
    Throws:
      `InitializationException` - if unable to get the service attribute.

  - ### getServiceAttribute

    public abstract ServiceAttributeInterface getServiceAttribute(Map nameValueMap) throws InitializationException
    Abstract method used to get a service attribute with its fields initialized with values obtained from the specified map.
    Parameters:
      `nameValueMap` - A `Map` of name value pairs where the key is the name of the attribute's field.
    Returns:
      Service attribute created based upon values specified in the map.
    Throws:
      `InitializationException` - if unable to get a service attribute based upon values specified in the map.