- All Implemented Interfaces:
DataListener
- Enclosing class:
- DataTable
This class represents the schema of the table which specifies the
attributes belonging to the table.
-
Field Summary
Fields
map of attributes keyed by name
collection of primary keys
-
Constructor Summary
Constructors
-
Method Summary
void
Add a new attribute to the schema
Get the collection of all attributes in this schema
boolean
Determine if the specified key is a primary key
Get all of the keys for the schema.
Get the collection of primary keys
void
Update the schema from the data adaptor.
protected void
Validate that the primary keys are defined for this schema.
void
Write the schema out to the data adaptor.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Field Details
-
attributeTable
map of attributes keyed by name
-
primaryKeys
collection of primary keys
-
Constructor Details
-
Schema
public Schema()
Empty Constructor
-
-
Method Details
-
keys
Get all of the keys for the schema.
-
-
attributes
Get the collection of all attributes in this schema
- Returns:
- the collection of all attributes in this schema
-
-
primaryKeys
Get the collection of primary keys
- Returns:
- The collection of primary keys
-
isPrimaryKey
public boolean isPrimaryKey(String key)
Determine if the specified key is a primary key
- Parameters:
key
- The key to test for being a primary key
- Returns:
- true if the key is a primary key and false if it isn't a
primary key
-
dataLabel
Get the data label.
- Specified by:
dataLabel
in interface DataListener
- Returns:
- a tag that identifies the receiver's type
-
-