org.modeshape.graph.query.validate
Interface Schemata.Table

All Known Subinterfaces:
Schemata.View
Enclosing interface:
Schemata

public static interface Schemata.Table

Information about a queryable table.


Method Summary
 Schemata.Column getColumn(String name)
          Get the information for a column with the supplied name within this table.
 List<Schemata.Column> getColumns()
          Get the queryable columns in this table.
 Map<String,Schemata.Column> getColumnsByName()
          Get the queryable columns in this table.
 Schemata.Key getKey(Iterable<Schemata.Column> columns)
          Obtain this table's key that contains exactly those columns listed.
 Schemata.Key getKey(Schemata.Column... columns)
          Obtain this table's key that contains exactly those columns listed.
 Collection<Schemata.Key> getKeys()
          Get the collection of keys for this table.
 SelectorName getName()
          Get the name for this table.
 boolean hasKey(Iterable<Schemata.Column> columns)
          Determine whether this table has a key that contains exactly those columns listed.
 boolean hasKey(Schemata.Column... columns)
          Determine whether this table has a key that contains exactly those columns listed.
 

Method Detail

getName

SelectorName getName()
Get the name for this table.

Returns:
the table name; never null

getColumn

Schemata.Column getColumn(String name)
Get the information for a column with the supplied name within this table.

The resulting column definition is immutable.

Parameters:
name - the column name; may not be null
Returns:
the column information, or null if there is no such column

getColumnsByName

Map<String,Schemata.Column> getColumnsByName()
Get the queryable columns in this table.

Returns:
the immutable map of immutable column objects by their name; never null

getColumns

List<Schemata.Column> getColumns()
Get the queryable columns in this table.

Returns:
the immutable, ordered list of immutable column objects; never null

getKeys

Collection<Schemata.Key> getKeys()
Get the collection of keys for this table.

Returns:
the immutable collection of immutable keys; never null, but possibly empty

hasKey

boolean hasKey(Schemata.Column... columns)
Determine whether this table has a key that contains exactly those columns listed.

Parameters:
columns - the columns for the key
Returns:
true if this table contains a key using exactly the supplied columns, or false otherwise

hasKey

boolean hasKey(Iterable<Schemata.Column> columns)
Determine whether this table has a key that contains exactly those columns listed.

Parameters:
columns - the columns for the key
Returns:
true if this table contains a key using exactly the supplied columns, or false otherwise

getKey

Schemata.Key getKey(Schemata.Column... columns)
Obtain this table's key that contains exactly those columns listed.

The resulting key definition is immutable.

Parameters:
columns - the columns for the key
Returns:
the key that uses exactly the supplied columns, or null if there is no such key

getKey

Schemata.Key getKey(Iterable<Schemata.Column> columns)
Obtain this table's key that contains exactly those columns listed.

The resulting key definition is immutable.

Parameters:
columns - the columns for the key
Returns:
the key that uses exactly the supplied columns, or null if there is no such key


Copyright © 2008-2010 JBoss, a division of Red Hat. All Rights Reserved.