de.grogra.xl.impl.property
Class CompiletimeModel.PropertyImpl

java.lang.Object
  extended by de.grogra.xl.impl.property.CompiletimeModel.PropertyImpl
All Implemented Interfaces:
CompiletimeModel.Property
Direct Known Subclasses:
PropertyCompiletime.GraphProperty
Enclosing class:
CompiletimeModel

public abstract class CompiletimeModel.PropertyImpl
extends java.lang.Object
implements CompiletimeModel.Property


Constructor Summary
CompiletimeModel.PropertyImpl(java.lang.Class<?> type, java.lang.String id)
           
CompiletimeModel.PropertyImpl(Type<?> type, java.lang.String id)
           
 
Method Summary
 CompiletimeModel.Property getComponentProperty()
          Returns the component property.
protected abstract  CompiletimeModel.PropertyImpl getComponentProperty(java.lang.String id)
           
 CompiletimeModel getModel()
          Returns this property's compile-time model.
 java.lang.String getRuntimeName()
          Defines the name of the corresponding RuntimeModel.Property.
 CompiletimeModel.Property getSubProperty(java.lang.String name)
          Returns a subproperty.
protected abstract  CompiletimeModel.PropertyImpl getSubProperty(java.lang.String name, java.lang.String id)
           
 Type<?> getType()
          Returns this property's type.
 CompiletimeModel.Property getTypeCastProperty(Type<?> type)
          Returns a type-cast property.
protected abstract  CompiletimeModel.PropertyImpl getTypeCastProperty(Type<?> type, java.lang.String id)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface de.grogra.xl.property.CompiletimeModel.Property
getRuntimeType
 

Constructor Detail

CompiletimeModel.PropertyImpl

public CompiletimeModel.PropertyImpl(java.lang.Class<?> type,
                                     java.lang.String id)

CompiletimeModel.PropertyImpl

public CompiletimeModel.PropertyImpl(Type<?> type,
                                     java.lang.String id)
Method Detail

getComponentProperty

public CompiletimeModel.Property getComponentProperty()
Description copied from interface: CompiletimeModel.Property
Returns the component property. If this property has an array type, then a component property may exist and is returned by this method, otherwise null is returned.

Specified by:
getComponentProperty in interface CompiletimeModel.Property
Returns:
the component property, if any

getComponentProperty

protected abstract CompiletimeModel.PropertyImpl getComponentProperty(java.lang.String id)

getModel

public CompiletimeModel getModel()
Description copied from interface: CompiletimeModel.Property
Returns this property's compile-time model. This is the model which has declared this property.

Specified by:
getModel in interface CompiletimeModel.Property
Returns:
this property's model

getRuntimeName

public java.lang.String getRuntimeName()
Description copied from interface: CompiletimeModel.Property
Defines the name of the corresponding RuntimeModel.Property. This name is used during run-time in invocations of RuntimeModel.propertyForName(String, ClassLoader) in order to obtain the RuntimeModel.Property which corresponds to this compile-time property.

Specified by:
getRuntimeName in interface CompiletimeModel.Property
Returns:
the name of the corresponding run-time property

getSubProperty

public CompiletimeModel.Property getSubProperty(java.lang.String name)
Description copied from interface: CompiletimeModel.Property
Returns a subproperty. If this property has a subproperty named name, then this subproperty is returned, otherwise null.

Specified by:
getSubProperty in interface CompiletimeModel.Property
Parameters:
name - the name of the subproperty
Returns:
the subproperty, if any

getSubProperty

protected abstract CompiletimeModel.PropertyImpl getSubProperty(java.lang.String name,
                                                                java.lang.String id)

getType

public Type<?> getType()
Description copied from interface: CompiletimeModel.Property
Returns this property's type.

Specified by:
getType in interface CompiletimeModel.Property
Returns:
this property's type

getTypeCastProperty

public CompiletimeModel.Property getTypeCastProperty(Type<?> type)
Description copied from interface: CompiletimeModel.Property
Returns a type-cast property. type has to be a reference type which is assignable to the type of this property. The method returns the corresponding type-cast property.

Specified by:
getTypeCastProperty in interface CompiletimeModel.Property
Parameters:
type - the type of the type-cast property
Returns:
the type-cast property

getTypeCastProperty

protected abstract CompiletimeModel.PropertyImpl getTypeCastProperty(Type<?> type,
                                                                     java.lang.String id)