org.apache.tuscany.sca.assembly
Interface AbstractProperty

All Superinterfaces:
Base, IntentAttachPoint
All Known Subinterfaces:
ComponentProperty, Property

public interface AbstractProperty
extends Base, IntentAttachPoint

A property allows for the configuration of an implementation with externally set data values. An implementation can have zero or more properties. Each property has a data type, which may be either simple or complex. An implementation may also define a default value for a property.


Method Summary
 java.lang.String getName()
          Returns the property name.
 java.lang.Object getValue()
          Returns the default value of the property.
 javax.xml.namespace.QName getXSDElement()
          Returns the element defining the data type of this property.
 javax.xml.namespace.QName getXSDType()
          Returns the data type of this property.
 boolean isMany()
          Returns true if the property allows multiple values.
 boolean isMustSupply()
          Returns true if a value must be supplied for the property.
 void setMany(boolean many)
          Sets whether or not the property allows multiple values.
 void setMustSupply(boolean mustSupply)
          Sets whether a value must be supplied for the property.
 void setName(java.lang.String name)
          Sets the property name.
 void setValue(java.lang.Object defaultValue)
          Sets the default value of the property.
 void setXSDElement(javax.xml.namespace.QName element)
          Sets the element defining the data type of this property.
 void setXSDType(javax.xml.namespace.QName type)
          Sets the data type of this property.
 
Methods inherited from interface org.apache.tuscany.sca.assembly.Base
getExtensions, isUnresolved, setUnresolved
 
Methods inherited from interface org.apache.tuscany.sca.policy.IntentAttachPoint
getRequiredIntents
 

Method Detail

getName

java.lang.String getName()
Returns the property name.

Returns:
the property name

setName

void setName(java.lang.String name)
Sets the property name.

Parameters:
name - the property name

getValue

java.lang.Object getValue()
Returns the default value of the property.

Returns:
the default value of ths property

setValue

void setValue(java.lang.Object defaultValue)
Sets the default value of the property.

Parameters:
defaultValue - the default value of ths property

isMany

boolean isMany()
Returns true if the property allows multiple values.

Returns:
true if the property allows multiple values

setMany

void setMany(boolean many)
Sets whether or not the property allows multiple values.

Parameters:
many - true if the property should allow multiple values

isMustSupply

boolean isMustSupply()
Returns true if a value must be supplied for the property.

Returns:
true is a value must be supplied for the property

setMustSupply

void setMustSupply(boolean mustSupply)
Sets whether a value must be supplied for the property.

Parameters:
mustSupply - set to true to require that a value be supplied for uses of this property

getXSDType

javax.xml.namespace.QName getXSDType()
Returns the data type of this property. This is the qualified name of an XML schema type.

Returns:
the type of this property

setXSDType

void setXSDType(javax.xml.namespace.QName type)
Sets the data type of this property. This is the qualified name of an XML schema type.

Parameters:
type - the type of this property

getXSDElement

javax.xml.namespace.QName getXSDElement()
Returns the element defining the data type of this property. This is the qualified name of an XML schema element.

Returns:
the element defining the type of this property

setXSDElement

void setXSDElement(javax.xml.namespace.QName element)
Sets the element defining the data type of this property. This is the qualified name of an XML schema element.

Parameters:
type - the element defining the type of this property