org.opends.server.admin
Class PropertyDefinition.AbstractBuilder<T,D extends PropertyDefinition<T>>

java.lang.Object
  extended by org.opends.server.admin.PropertyDefinition.AbstractBuilder<T,D>
Type Parameters:
T - The data-type of values of the property.
D - The type of property definition constructed by this builder.
Direct Known Subclasses:
ACIPropertyDefinition.Builder, AggregationPropertyDefinition.Builder, AttributeTypePropertyDefinition.Builder, BooleanPropertyDefinition.Builder, ClassPropertyDefinition.Builder, DNPropertyDefinition.Builder, DurationPropertyDefinition.Builder, EnumPropertyDefinition.Builder, IntegerPropertyDefinition.Builder, IPAddressMaskPropertyDefinition.Builder, IPAddressPropertyDefinition.Builder, SizePropertyDefinition.Builder, StringPropertyDefinition.Builder
Enclosing class:
PropertyDefinition<T>

protected abstract static class PropertyDefinition.AbstractBuilder<T,D extends PropertyDefinition<T>>
extends java.lang.Object

An interface for incrementally constructing property definitions.


Constructor Summary
protected PropertyDefinition.AbstractBuilder(AbstractManagedObjectDefinition<?,?> d, java.lang.String propertyName)
          Create a property definition builder.
 
Method Summary
protected abstract  D buildInstance(AbstractManagedObjectDefinition<?,?> d, java.lang.String propertyName, java.util.EnumSet<PropertyOption> options, AdministratorAction adminAction, DefaultBehaviorProvider<T> defaultBehavior)
          Build a property definition based on the properties of this builder.
 D getInstance()
          Construct a property definition based on the properties of this builder.
 void setAdministratorAction(AdministratorAction adminAction)
          Set the administrator action.
 void setDefaultBehaviorProvider(DefaultBehaviorProvider<T> defaultBehavior)
          Set the default behavior provider.
 void setOption(PropertyOption option)
          Add a property definition option.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PropertyDefinition.AbstractBuilder

protected PropertyDefinition.AbstractBuilder(AbstractManagedObjectDefinition<?,?> d,
                                             java.lang.String propertyName)
Create a property definition builder.

Parameters:
d - The managed object definition associated with this property definition.
propertyName - The property name.
Method Detail

getInstance

public final D getInstance()
Construct a property definition based on the properties of this builder.

Returns:
The new property definition.

setAdministratorAction

public final void setAdministratorAction(AdministratorAction adminAction)
Set the administrator action.

Parameters:
adminAction - The administrator action.

setDefaultBehaviorProvider

public final void setDefaultBehaviorProvider(DefaultBehaviorProvider<T> defaultBehavior)
Set the default behavior provider.

Parameters:
defaultBehavior - The default behavior provider.

setOption

public final void setOption(PropertyOption option)
Add a property definition option.

Parameters:
option - The property option.

buildInstance

protected abstract D buildInstance(AbstractManagedObjectDefinition<?,?> d,
                                   java.lang.String propertyName,
                                   java.util.EnumSet<PropertyOption> options,
                                   AdministratorAction adminAction,
                                   DefaultBehaviorProvider<T> defaultBehavior)
Build a property definition based on the properties of this builder.

Parameters:
d - The managed object definition associated with this property definition.
propertyName - The property name.
options - Options applicable to this definition.
adminAction - The administrator action.
defaultBehavior - The default behavior provider.
Returns:
The new property definition.