dke.smwp.fragmentation
Class DerivedFragmentClass
java.lang.Object
|
+--dke.smwp.fragmentation.FragmentClass
|
+--dke.smwp.fragmentation.DerivedFragmentClass
- public class DerivedFragmentClass
- extends FragmentClass
derived fragment class
- Version:
- 1.0
- Author:
- Werner Enser
Field Summary |
protected java.lang.String |
_joinPredicate
sql statement defining join clause between fragmentation base class
and derivation base class |
Fields inherited from class dke.smwp.fragmentation.FragmentClass |
_columns, _derivBase, _derivBaseClass, _fc_alias_name, _fc_long_name, _fc_root_name, _fc_short_name, _foreignKeys, _fragBase, _fragBaseClass, _fragRelation, _parameters, _primaryKeys |
Method Summary |
FragmentClass |
create(java.lang.String name,
FragmentClass fragmentBaseClass,
FragmentClass derivationBaseClass,
java.lang.String joinPredicate)
creates derived fragment class based upon fragmentation base class and
derivation base class;
name is used as root name for the created fragment class;
using a different value as the root name of its fragment base class will
cause errors. |
java.lang.String[] |
getJoinAttributesForFragmentClass(java.lang.String aliasName)
parse join predicate (SQL statements) and retrieve attribute names
of derivation base class (which are used as join attributes);
e.g. following join predicate (where aliasName2 ^= alias Name of
derivation base class
aliasName1.attribute1 = aliasName2.attribute2 AND
aliasName1.attribute3 = aliasName2.attribute4
==> retrieve attribute2 and
attribute4 for aliasName2 |
java.lang.String |
getJoinPredicate()
gets join predicate;
sql statement used to join fragmentation base class
with derivation base class; |
Methods inherited from class dke.smwp.fragmentation.FragmentClass |
addColumn, addForeignKey, addParameter, addParameter, addPrimaryKey, columnNamesToString, columnNamesToString, dropXMLPublishStmt, getAliasName, getColumns, getDerivBaseClass, getDerivBaseClassLongName, getDerivBaseClassShortName, getFCElementLocalname, getForeignKeys, getFragBaseClass, getFragmentationRelation, getFragmentBaseClassLongName, getFragmentBaseClassShortName, getFragmentPredicate, getLongName, getNewestParameter, getParameters, getPrimaryKeys, getRootName, getShortName, getTupleElementLocalname, getTuplePredicate, parameterNamesToString, parameterNamesToString, setAliasName, setLongName, setRootName, setXMLPublishStmt, showFragmentClass, toString |
Methods inherited from class java.lang.Object |
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, wait, wait, wait |
_joinPredicate
protected java.lang.String _joinPredicate
- sql statement defining join clause between fragmentation base class
and derivation base class
DerivedFragmentClass
public DerivedFragmentClass()
- default constructor
create
public FragmentClass create(java.lang.String name,
FragmentClass fragmentBaseClass,
FragmentClass derivationBaseClass,
java.lang.String joinPredicate)
throws SMWPException
- creates derived fragment class based upon fragmentation base class and
derivation base class;
name
is used as root name for the created fragment class;
using a different value as the root name of its fragment base class will
cause errors.
- Parameters:
name
- value for fragment class root namefragmentBaseClass
- fragmentation base class; may be unfragmentedderivationBaseClass
- derivation base class; must contain exactly
one parameterjoinPredicate
- sql join statement to join fragmentation base
class with derivation base class - used to
initialize generated fragment class- Returns:
- FragmentClass object which has been generated
- Throws:
SMWPException
- writing meta-data failed,
creating/initializing fragment class relation failed,
creating/initializing fragmentation relation failed,
derivationBaseClass introduces more than one
parameter
getJoinPredicate
public java.lang.String getJoinPredicate()
- gets join predicate;
sql statement used to join fragmentation base class
with derivation base class;
getJoinAttributesForFragmentClass
public java.lang.String[] getJoinAttributesForFragmentClass(java.lang.String aliasName)
- parse join predicate (SQL statements) and retrieve attribute names
of derivation base class (which are used as join attributes);
e.g. following join predicate (where aliasName2 ^= alias Name of
derivation base class
aliasName1.attribute1 = aliasName2.attribute2 AND
aliasName1.attribute3 = aliasName2.attribute4
==> retrieve attribute2
and
attribute4
for aliasName2
- Parameters:
aliasName
- alias name for fragment class- Returns:
- Array of String containing column names