|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectbe.SIRAPRISE.util.IntersectableMap<K,V>
be.SIRAPRISE.util.IntersectableLinkedHashMap<java.lang.String,TypeDeclaration>
be.SIRAPRISE.client.Heading
public class Heading
A Heading maps attribute names onto typenames.
Nested Class Summary |
---|
Nested classes/interfaces inherited from interface java.util.Map |
---|
java.util.Map.Entry<K,V> |
Constructor Summary | |
---|---|
Heading()
|
Method Summary | |
---|---|
void |
add(java.lang.String attributeName,
Heading heading)
Adds a relation-typed attribute to the heading. |
void |
add(java.lang.String attributeName,
java.lang.String typeName)
Adds a scalar attribute to the heading. |
void |
add(java.lang.String attributeName,
TypeDeclaration typeDeclaration)
Adds an attribute declaration to the heading. |
java.util.Set<java.lang.String> |
getAttributeNames()
Gets The set of attribute names |
Heading |
getHeading(java.lang.String attributeName)
Gets the heading object defining the relation type of the named attribute, which must be relation-typed |
java.lang.String |
getTypeName(java.lang.String attributeName)
Gets the typename of the named attribute. |
boolean |
isStrictUnionCompatibleWith(Heading other)
Checks if the heading of another Relvar is exactly the same as this one : The set of attribute names in the other heading is equal to the set of attribute names in this heading The Type associated with each attribute name is the same in both headings |
java.lang.String |
print()
Gets the heading specification in textual format HEADING(ATTRIBUTENAME(TYPENAME)RELATIONTYPEDATTRIBUTENAME(RELATION(HEADING(...)))) |
java.lang.String |
printXML()
Gets the heading specification in XML style |
Heading |
subHeadingExcluding(java.util.Set<java.lang.String> attributeNames)
Gets a Heading that includes only the attribute definitions from this Heading whose attribute names do not appear in the given set |
Heading |
subHeadingIncluding(java.util.Set<java.lang.String> attributeNames)
Gets a Heading that includes only the attribute definitions from this Heading whose attribute names appear in the given set |
void |
toStream1_0(java.io.DataOutputStream outputStream)
Writes the heading to an outputstream in the V1.0 format |
Methods inherited from class be.SIRAPRISE.util.IntersectableMap |
---|
clear, clone, containsKey, containsValue, entrySet, equals, get, hashCode, intersect, intersect, isEmpty, keySet, minus, minus, put, putAll, remove, size, toString, union, union, values |
Methods inherited from class java.lang.Object |
---|
getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public Heading()
Method Detail |
---|
public final void add(java.lang.String attributeName, Heading heading) throws DuplicateException
attributeName
- The name of a relation-typed attribute to be added to the heading.heading
- The relation heading defining the relation type of the attribute
DuplicateException
- If the attributeName is already present in the headingpublic final void add(java.lang.String attributeName, java.lang.String typeName) throws DuplicateException
attributeName
- The name of the attribute to be added to the heading.typeName
- The name of the attribute's type.
DuplicateException
- If the attributeName is already present in the headingpublic final void add(java.lang.String attributeName, TypeDeclaration typeDeclaration) throws DuplicateException
attributeName
- The name of the attribute to be added to the heading.typeDeclaration
- The type declaration of the attribute.
DuplicateException
- If the attributeName is already present in the headingpublic final java.util.Set<java.lang.String> getAttributeNames()
public final Heading getHeading(java.lang.String attributeName) throws NotFoundException, TypeIsScalarException
attributeName
- The name of a relation-typed attribute whose heading is to be obtained
NotFoundException
TypeIsScalarException
public final java.lang.String getTypeName(java.lang.String attributeName) throws NotFoundException
attributeName
- The name of the attribute whose type name is to be obtained
NotFoundException
public final boolean isStrictUnionCompatibleWith(Heading other)
other
- the Heading of another Relvar
public final java.lang.String print()
public final java.lang.String printXML()
public final Heading subHeadingExcluding(java.util.Set<java.lang.String> attributeNames)
attributeNames
- The names of the attributes that are not to appear in the subHeading
public final Heading subHeadingIncluding(java.util.Set<java.lang.String> attributeNames)
attributeNames
- The names of the attributes that are to appear in the subHeading
public final void toStream1_0(java.io.DataOutputStream outputStream) throws java.io.IOException
outputStream
- the outputstream to write the heading to
java.io.IOException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |