Copyright @ 2002 SAP. All Rights Reserved.

com.sap.tc.complib
Class EntityReference

java.lang.Object
  |
  +--com.sap.tc.complib.xml.Initializable
        |
        +--com.sap.tc.complib.impl.ImportedEntityImpl
              |
              +--com.sap.tc.complib.EntityReference
All Implemented Interfaces:
Identifiable, ImportedEntity

public final class EntityReference
extends com.sap.tc.complib.impl.ImportedEntityImpl

Reference to an entity. Used to define lists of to be imported entities in public parts.


Fields inherited from class com.sap.tc.complib.xml.Initializable
_apiVersion, _attributes, _extensions, _initialized, _schemaVersion, buffer, clearBuffer, INIT, isEmpty, recoverMode, recoverTagName, RECOVERY_MODE, ROOT, state
 
Constructor Summary
EntityReference()
          Creates a new empty instance
EntityReference(java.lang.String name, java.lang.String publicPart, DCReference component)
          Creates a new instance with given name and reference to a certain public part of a given development component.
 
Method Summary
protected  boolean endTag(java.lang.String name)
           
 boolean equals(java.lang.Object obj)
          Determines whether the given object is "equal to" this one.
 DCReference getComponent()
          Returns the component of the referenced entity
 java.lang.String getName()
          Returns the name of the referenced entity
 java.lang.String getPackageName()
          Returns the name of the package the referenced entity belongs to
 java.lang.String getPublicPart()
          Returns the public part of the referenced entity
 java.lang.String getSubType()
          Returns the subtype of the references entity
 java.lang.String getType()
          Returns the type of the referenced entity
 int hashCode()
           
 void serialize(XMLWriter writer)
          Serializes the reference to the given XMLWriter.
 void serialize(XMLWriter writer, java.lang.String schemaVersion)
           
 void setComponent(DCReference component)
          Sets the component of the referenced entity
 void setName(java.lang.String name)
          Sets the name of the referenced entity
 void setPackageName(java.lang.String packageName)
          Sets the name of the package the referenced entity belongs to
 void setPublicPart(java.lang.String publicPart)
          Sets the public part of the referenced entity
 void setSubType(java.lang.String subtype)
          Sets the subtype of the referenced entity
 void setType(java.lang.String type)
          Sets the type of the referenced entity
protected  void startTag(java.lang.String name, org.xml.sax.Attributes attributes)
           
protected  void tagValue(char[] chars, int start, int length)
          tag value event wrapper. since SAX splits consecutive lines of character input in multiple events, this method collect the parts. use one of the getter methods below (getString, getBoolean...) to access the content of a tag.
 void validate()
          Verifies that the component reference is valid (according to the DTD).
 
Methods inherited from class com.sap.tc.complib.impl.ImportedEntityImpl
getUniqueKey
 
Methods inherited from class com.sap.tc.complib.xml.Initializable
_getAPIVersion, _getSchemaVersion, _isInitialized, _isSchemaAllowed, _isSchemaAllowed, _setSchemaVersion, checkMandatoryAttribute, checkMandatoryAttributeNotEmpty, checkPropertyNotEmptyOrNull, checkPropertyNotEmptyOrNull, checkPropertyNotEmptyOrNull, checkPropertyNotNull, doSerialize, dropTagValue, endDocument, getAttributes, getAttributes, getBooleanValue, getBooleanValue, getDoubleValue, getFloatValue, getIllegalAttributeMessage, getIntegerValue, getLongValue, getMissingTagMessage, getStringValue, getStringValue, isEmptyTag, removeAttribute, resolveEntity, setAttribute, startDocument
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EntityReference

public EntityReference()
Creates a new empty instance

EntityReference

public EntityReference(java.lang.String name,
                       java.lang.String publicPart,
                       DCReference component)
Creates a new instance with given name and reference to a certain public part of a given development component.
Method Detail

endTag

protected boolean endTag(java.lang.String name)
                  throws org.xml.sax.SAXException
Overrides:
endTag in class com.sap.tc.complib.impl.ImportedEntityImpl

equals

public boolean equals(java.lang.Object obj)
Description copied from class: com.sap.tc.complib.impl.ImportedEntityImpl
Determines whether the given object is "equal to" this one. Compares component, public part, name, vendor, package, type and subtype (if defined).
Overrides:
equals in class com.sap.tc.complib.impl.ImportedEntityImpl

getComponent

public DCReference getComponent()
Description copied from class: com.sap.tc.complib.impl.ImportedEntityImpl
Returns the component of the referenced entity
Overrides:
getComponent in class com.sap.tc.complib.impl.ImportedEntityImpl

getName

public java.lang.String getName()
Description copied from class: com.sap.tc.complib.impl.ImportedEntityImpl
Returns the name of the referenced entity
Overrides:
getName in class com.sap.tc.complib.impl.ImportedEntityImpl

getPackageName

public java.lang.String getPackageName()
Description copied from class: com.sap.tc.complib.impl.ImportedEntityImpl
Returns the name of the package the referenced entity belongs to
Overrides:
getPackageName in class com.sap.tc.complib.impl.ImportedEntityImpl

getPublicPart

public java.lang.String getPublicPart()
Description copied from class: com.sap.tc.complib.impl.ImportedEntityImpl
Returns the public part of the referenced entity
Overrides:
getPublicPart in class com.sap.tc.complib.impl.ImportedEntityImpl

getSubType

public java.lang.String getSubType()
Description copied from class: com.sap.tc.complib.impl.ImportedEntityImpl
Returns the subtype of the references entity
Overrides:
getSubType in class com.sap.tc.complib.impl.ImportedEntityImpl

getType

public java.lang.String getType()
Description copied from class: com.sap.tc.complib.impl.ImportedEntityImpl
Returns the type of the referenced entity
Overrides:
getType in class com.sap.tc.complib.impl.ImportedEntityImpl

hashCode

public int hashCode()
Overrides:
hashCode in class com.sap.tc.complib.impl.ImportedEntityImpl

serialize

public void serialize(XMLWriter writer,
                      java.lang.String schemaVersion)
               throws ValidationException
Overrides:
serialize in class com.sap.tc.complib.impl.ImportedEntityImpl

serialize

public void serialize(XMLWriter writer)
               throws ValidationException
Description copied from interface: ImportedEntity
Serializes the reference to the given XMLWriter.
Overrides:
serialize in class com.sap.tc.complib.impl.ImportedEntityImpl
Following copied from interface: com.sap.tc.complib.ImportedEntity
Parameters:
writer - the XMLWriter to use for serialization.

setComponent

public void setComponent(DCReference component)
Description copied from class: com.sap.tc.complib.impl.ImportedEntityImpl
Sets the component of the referenced entity
Overrides:
setComponent in class com.sap.tc.complib.impl.ImportedEntityImpl

setName

public void setName(java.lang.String name)
Description copied from class: com.sap.tc.complib.impl.ImportedEntityImpl
Sets the name of the referenced entity
Overrides:
setName in class com.sap.tc.complib.impl.ImportedEntityImpl

setPackageName

public void setPackageName(java.lang.String packageName)
Description copied from class: com.sap.tc.complib.impl.ImportedEntityImpl
Sets the name of the package the referenced entity belongs to
Overrides:
setPackageName in class com.sap.tc.complib.impl.ImportedEntityImpl

setPublicPart

public void setPublicPart(java.lang.String publicPart)
Description copied from class: com.sap.tc.complib.impl.ImportedEntityImpl
Sets the public part of the referenced entity
Overrides:
setPublicPart in class com.sap.tc.complib.impl.ImportedEntityImpl

setSubType

public void setSubType(java.lang.String subtype)
Description copied from class: com.sap.tc.complib.impl.ImportedEntityImpl
Sets the subtype of the referenced entity
Overrides:
setSubType in class com.sap.tc.complib.impl.ImportedEntityImpl

setType

public void setType(java.lang.String type)
Description copied from class: com.sap.tc.complib.impl.ImportedEntityImpl
Sets the type of the referenced entity
Overrides:
setType in class com.sap.tc.complib.impl.ImportedEntityImpl

startTag

protected void startTag(java.lang.String name,
                        org.xml.sax.Attributes attributes)
                 throws org.xml.sax.SAXException
Overrides:
startTag in class com.sap.tc.complib.impl.ImportedEntityImpl

tagValue

protected void tagValue(char[] chars,
                        int start,
                        int length)
Description copied from class: Initializable
tag value event wrapper. since SAX splits consecutive lines of character input in multiple events, this method collect the parts. use one of the getter methods below (getString, getBoolean...) to access the content of a tag.
Overrides:
tagValue in class com.sap.tc.complib.impl.ImportedEntityImpl

validate

public void validate()
              throws ValidationException
Description copied from class: com.sap.tc.complib.impl.ImportedEntityImpl
Verifies that the component reference is valid (according to the DTD).
Overrides:
validate in class com.sap.tc.complib.impl.ImportedEntityImpl
Following copied from class: com.sap.tc.complib.impl.ImportedEntityImpl
Throws:
ValidationException - if the object is not valid.

Copyright @ 2002 SAP. All Rights Reserved.