Oracle Application Development Framework Model and Business Components Java API Reference 10.1.3.1.0
B28969-01


oracle.binding.metaimpl
Class BaseAttributeDefinition

java.lang.Object
  extended byoracle.binding.metaimpl.BaseValueObjectDefinition
      extended byoracle.binding.metaimpl.BaseAttributeDefinition

All Implemented Interfaces:
AttributeDefinition, Definition, NamedDefinition, VariableDefinition

public class BaseAttributeDefinition
extends BaseValueObjectDefinition
implements AttributeDefinition

A class for holding metadata of attributes.


Field Summary

 

Fields inherited from interface oracle.binding.meta.Definition
TYPE_ACCESSOR, TYPE_ATTRIBUTE, TYPE_DATACONTROL, TYPE_DEFINITION, TYPE_DEFINITIONCONTEXT, TYPE_METHODRETURN, TYPE_NAMED, TYPE_OPERATION, TYPE_PARAMETER, TYPE_STRUCTURE, TYPE_VARIABLE

 

Constructor Summary
BaseAttributeDefinition(java.lang.String id, StructureDefinition parent, java.lang.String javaType, boolean isReadOnly, boolean isKey)
          Constructor.

 

Method Summary
 int getDefinitionType()
          Retrieves the type of this definition.
 java.lang.Object getProperty(java.lang.String propertyName)
          Retrieves the value of the given property.
 java.lang.String getSourceTypeString()
          Returns the actual java type of the attribute in the data source.
 boolean isKey()
          Finds out whether this attribute is the primary key of the row.
 boolean isReadOnly()
          Finds out whether this attribute is read-only or is updateable.
 void setReadOnly(boolean isReadOnly)
          Specify whether this attribute is read-only or is updateable.
 void setSourceTypeString(java.lang.String sourceTypeString)
          Set the java type of this attribute in the data source.

 

Methods inherited from class oracle.binding.metaimpl.BaseValueObjectDefinition
getDataControlDefinition, getDefinitionParent, getFullName, getJavaTypeString, getName, getProperties

 

Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

 

Methods inherited from interface oracle.binding.meta.VariableDefinition
getDataControlDefinition, getJavaTypeString

 

Methods inherited from interface oracle.binding.meta.NamedDefinition
getDefinitionParent, getFullName, getName, getProperties

 

Constructor Detail

BaseAttributeDefinition

public BaseAttributeDefinition(java.lang.String id,
                               StructureDefinition parent,
                               java.lang.String javaType,
                               boolean isReadOnly,
                               boolean isKey)
Constructor.
Parameters:
id - Identifier, or name, of the attribute.
parent - Metadata of the parent structure.
javaType - Fully-qualified Java class name of the attribute type.
isReadOnly - Whether the attribute is read-only.
isKey - Whether the attribute is the primary key of a row.

Method Detail

isReadOnly

public boolean isReadOnly()
Finds out whether this attribute is read-only or is updateable.
Specified by:
isReadOnly in interface AttributeDefinition
Returns:
True if this attribute is read-only, false otherwise.

setReadOnly

public void setReadOnly(boolean isReadOnly)
Specify whether this attribute is read-only or is updateable.

setSourceTypeString

public void setSourceTypeString(java.lang.String sourceTypeString)
Set the java type of this attribute in the data source.
Parameters:
sourceTypeString - A String representing the java type.

isKey

public boolean isKey()
Finds out whether this attribute is the primary key of the row.
Specified by:
isKey in interface AttributeDefinition
Returns:
True if this attribute is the primary key, false otherwise.

getSourceTypeString

public java.lang.String getSourceTypeString()
Returns the actual java type of the attribute in the data source. This may be different from the java type returned by getJavaTypeString if the data control is returning an attribute as a different datatype as what it is in its data source. For example, if the source type is a java.lang.String representing some number, the java type of the attribute could be java.lang.Integer.
Specified by:
getSourceTypeString in interface AttributeDefinition
Returns:
The java type of the attribute in the data source.

getProperty

public java.lang.Object getProperty(java.lang.String propertyName)
Retrieves the value of the given property. This class does not provide any properties.
Specified by:
getProperty in interface NamedDefinition
Overrides:
getProperty in class BaseValueObjectDefinition
Parameters:
propertyName - Name of property whose value should be returned.
Returns:
Value of the property whose name is given.

getDefinitionType

public int getDefinitionType()
Description copied from interface: Definition
Retrieves the type of this definition. It can be one of the TYPE_* constants defined in this class. This is useful to find out the actual type of the Definition without doing an instanceof operations.
Specified by:
getDefinitionType in interface Definition
Overrides:
getDefinitionType in class BaseValueObjectDefinition
Returns:
Always return TYPE_PRIMITIVE.

Oracle Application Development Framework Model and Business Components Java API Reference 10.1.3.1.0
B28969-01


Copyright © 1997, 2006, Oracle. All rights reserved.