it.unimo.dbgroup.momis.odli3
Class GlobalInterface

java.lang.Object
  extended byit.unimo.dbgroup.momis.odli3.MomisObject
      extended byit.unimo.dbgroup.momis.odli3.TypeContainer
          extended byit.unimo.dbgroup.momis.odli3.Interface
              extended byit.unimo.dbgroup.momis.odli3.GlobalInterface
All Implemented Interfaces:
OntologyAnnotableElement, java.io.Serializable, TypeInterface

public class GlobalInterface
extends Interface

This class describes a "Global interface".

See Also:
Serialized Form

Field Summary
private  GlobalJoinAttribute _globalJoinAttribute
          The join information for this global class
private  boolean _isFused
          If this Global Interface has been "fused" by TUNIM
private  java.util.Set _localInterfaces
          Local Interfaces.
private  Interface _mostGeneralLocalInterface
           
 
Fields inherited from class it.unimo.dbgroup.momis.odli3.Interface
COMPARE_ON_NAME
 
Fields inherited from class it.unimo.dbgroup.momis.odli3.TypeContainer
_constants, _interfaces, _sources, _structs, _thesRelations
 
Fields inherited from class it.unimo.dbgroup.momis.odli3.MomisObject
mod_GenericODLParser, mod_GlobalSchema, mod_QueryManger, mod_SIDes_ARM, mod_SIDes_ARTEMIS, mod_SIDes_EXTM, mod_SIDes_JoinMap, mod_SIDes_main, mod_SIDes_SAM, mod_SIDes_SIM, mod_SIDes_SIM2, mod_SIDes_SLIM, mod_SIDes_TREdit, mod_SIDes_TUNIM
 
Constructor Summary
GlobalInterface()
           
 
Method Summary
 void addIntBody(GlobalIntBody intBody)
          Allowing only a specific kind of IntBody.
 void addIntBody(IntBody intBody)
          Deprecated.  
 void addLocalInterface(Interface v)
          Add a _localInterfaces element
 GlobalJoinAttribute getGlobalJoinAttribute()
          Getter for the _globalJoinAttribute field
 boolean getIsFused()
          Getter for the _isFused field
 java.util.Collection getLocalInterfaces()
          Getter for the _localInterfaces field
 Interface getMostGeneralLocalInterface()
          getter of _mostGeneralLocalInterface param
 java.lang.String getNameFromMapping(Schema schema)
          this method retrieves the name of this global interface from the mapping.
 boolean hasLocalInterface(Interface intf)
          Asks if has at least one element
 boolean hasLocalInterfaces()
          Asks if has at least one element
 void loadFromXML(org.xml.sax.Attributes attrib)
          Load the object from an xml tag.
private  java.lang.String resolveGlobalAttrDuplicateNames(GlobalSource gSource, java.lang.String nameToControl)
          method that relolve duplicates global interface names into the same globalSource.
 void setGlobalJoinAttribute(GlobalJoinAttribute v)
          Setter for the _globalJoinAttribute field
 void setIsFused(boolean v)
          Setter for the _isFused field
 void setMostGeneralLocalInterface(Schema schema)
          this method retrieves the name of this global attribute from the mapping.
 
Methods inherited from class it.unimo.dbgroup.momis.odli3.Interface
addExtent, addForeignKey, addKey, addToInheritanceMap, aggiornaAttributes, control, controlForeignKeys, getAttribute, getAttributes, getAttributesIncludingParents_sortByAttributeDottedName, getAttributesIncludingParents, getAttributeVectorsIncludingParents, getDottedName, getExtentName, getFlagPersistent, getFlagView, getForeignKeys, getKey, getKeys, getName, getOntologyAnnotation, getParents, getSource, getXmlType, setExtentName, setFlagPersistent, setFlagView, setForeignKeys, setInheritanceMap, setName, setOntologyAnnotation, setSource, setSourceTo, toOdl, toOlcd, toOlcdSimB, toString
 
Methods inherited from class it.unimo.dbgroup.momis.odli3.TypeContainer
addConstant, addConstants, addDefined, addDefineds, addEnum, addEnums, addExtRule, addIntBodies, addIntBodyForceNewName, addInterface, addInterfaces, addModule, addModules, addRule, addRules, addSource, addSources, addStruct, addStructs, addThesRelation, addThesRelations, addThesRelationWithControl, addThesRelationWithControlIgnoreWeaker, addThesRelationWithControlIgnoreWeaker, addTypes, addTypesToSolve, addTypeToSolve, addUnion, addUnions, cloneAllThesRelations, delAllThesRelations, delRule, delRuleByName, delThesRelation, delThesRelationsForProducer, getConstant, getConstants, getDefined, getDefineds, getEnum, getEnums, getExtRule, getIntBodies, getIntBodiesAsCollection, getIntBodiesOrderByName, getIntBody, getInterface, getInterface, getInterfaces, getInterfacesAsCollection, getInterfacesOrderByName, getModule, getModules, getParent, getRule, getRuleByName, getRules, getSchema, getSource, getSources, getSourcesAsCollection, getSourcesOrderByName, getStruct, getStructs, getThesRelations, getTopParent, getTypesToSolve, getUnion, getUnions, retrieveAttribute, retrieveInterface, retrieveSource, setParent, solveUnsolved, solveUnsolvedForeignKeys
 
Methods inherited from class it.unimo.dbgroup.momis.odli3.MomisObject
getAdditionalInfo, getAdditionalInfos, getGenericProducerDescription, getProducerDescription, getProducerId, putAdditionalInfo, setProducerId
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

_localInterfaces

private java.util.Set _localInterfaces
Local Interfaces. The cluster of local interface for this global Interface are stored in this Vector


_isFused

private boolean _isFused
If this Global Interface has been "fused" by TUNIM


_globalJoinAttribute

private GlobalJoinAttribute _globalJoinAttribute
The join information for this global class


_mostGeneralLocalInterface

private Interface _mostGeneralLocalInterface
Constructor Detail

GlobalInterface

public GlobalInterface()
Method Detail

addIntBody

public void addIntBody(GlobalIntBody intBody)
                throws OdlException
Allowing only a specific kind of IntBody.

Throws:
OdlException

addIntBody

public void addIntBody(IntBody intBody)
                throws OdlException
Deprecated.  

Method overriding

Overrides:
addIntBody in class TypeContainer
Throws:
OdlException

getLocalInterfaces

public java.util.Collection getLocalInterfaces()
Getter for the _localInterfaces field


addLocalInterface

public void addLocalInterface(Interface v)
Add a _localInterfaces element


hasLocalInterfaces

public boolean hasLocalInterfaces()
Asks if has at least one element


hasLocalInterface

public boolean hasLocalInterface(Interface intf)
Asks if has at least one element


getIsFused

public boolean getIsFused()
Getter for the _isFused field


setIsFused

public void setIsFused(boolean v)
Setter for the _isFused field


loadFromXML

public void loadFromXML(org.xml.sax.Attributes attrib)
                 throws java.lang.Exception
Load the object from an xml tag.

Overrides:
loadFromXML in class Interface
Throws:
java.lang.Exception

setMostGeneralLocalInterface

public void setMostGeneralLocalInterface(Schema schema)
this method retrieves the name of this global attribute from the mapping. It retrieves the name of the most general attribute involved into mapping


getMostGeneralLocalInterface

public Interface getMostGeneralLocalInterface()
getter of _mostGeneralLocalInterface param

Returns:
Interface

getGlobalJoinAttribute

public GlobalJoinAttribute getGlobalJoinAttribute()
Getter for the _globalJoinAttribute field


setGlobalJoinAttribute

public void setGlobalJoinAttribute(GlobalJoinAttribute v)
Setter for the _globalJoinAttribute field


getNameFromMapping

public java.lang.String getNameFromMapping(Schema schema)
this method retrieves the name of this global interface from the mapping. It retrieves the name of the most general interface involved into mapping

Returns:
String: the name selected

resolveGlobalAttrDuplicateNames

private java.lang.String resolveGlobalAttrDuplicateNames(GlobalSource gSource,
                                                         java.lang.String nameToControl)
method that relolve duplicates global interface names into the same globalSource. If there is a dublicate, the second name is renamed into oldName_n

Returns:
String: the name resolved


Universita' di Modena e Reggio Emilia