|
SAP CC 1.0
API 4.2 (Core) |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.highdeal.admin.hci.InstanceMap
public class InstanceMap
This class represents an instance map.
The instance map is a named set of InstanceInfo
describing all the instances working for the same cluster.
| XML Schema Fragment |
<xs:element name="instanceMap">
<xs:complexType>
<xs:sequence>
<xs:element ref="instanceInfo" minOccurs="0" maxOccurs="unbounded"/>
</xs:sequence>
<xs:attribute name="name" type="xs:string"/>
<xs:attribute name="lastModificationDate" type="xs:dateTime" use="required"/>
</xs:complexType>
</xs:element> |
| Field Summary | |
|---|---|
static java.lang.String |
TAG_NAME
|
| Constructor Summary | |
|---|---|
InstanceMap()
Initializes a new InstanceMap instance without any InstanceInfo. |
|
InstanceMap(java.lang.String name,
java.util.Date lastModificationDate,
java.util.List<InstanceInfo> instanceInfos)
Builds a new InstanceMap instance from a list of InstanceInfo. |
|
| Method Summary | |
|---|---|
void |
addCharacterData(java.lang.String cData)
Adds character data to the content element. |
void |
addChild(java.lang.String tagName,
XMLMarshallable child)
Adds a child to the objects, the child represents
the marshallable object to be added into the content tree. |
void |
assertIsCompatible(com.highdeal.util.Version.Edition edition)
Checks if this instance map is compatible with the specified edition. |
void |
checkValidity()
Throws an InvalidInstanceMapException if the map is malformed or invalid. |
InstanceMap |
clone()
Returns a copy of this instance map. |
int |
getBackupCount()
Returns the backup count of this map. |
InstanceInfo |
getBillingAssistant()
Returns the InstanceInfo of the billing assistant. |
InstanceInfo |
getBulkLoader()
Returns the InstanceInfos of all the declared chargers sorted by instance id. |
int |
getChargerCount()
Returns the guider count of this map. |
java.util.List<InstanceInfo> |
getChargers()
Returns the InstanceInfos of all the declared chargers sorted by instance id. |
java.util.List<InstanceInfo> |
getEZTaxers()
Returns the InstanceInfos of all the declared EZTaxers sorted by instance id. |
int |
getGuiderCount()
Returns the guider count of this map. |
java.util.List<InstanceInfo> |
getGuiders()
Returns the InstanceInfos of all the declared guiders sorted by instance id. |
InstanceInfo |
getInfo(InstanceId instanceId)
Returns the InstanceInfo with the given ID. |
int |
getInstanceCount()
Returns the instance count of this map. |
java.util.List<InstanceInfo> |
getInstances()
Returns the InstanceInfos of all the declared instances sorted by instance id. |
java.util.Date |
getLastModificationDate()
Returns the instance map last modification date stored the database. |
java.lang.String |
getName()
Returns the name of the instance map called cluster name too. |
short[][] |
getPartitionMap()
This method returns an array (new short[ratingInstanceCount][2]) which give for each ratingInstance ID the related partition ID range. |
InstanceInfo |
getPrimaryBackup()
Returns the InstanceInfo of the primary backup. |
int |
getRaterCount()
Returns the rater count of this map (backup excluded). |
java.util.List<InstanceInfo> |
getRaters()
Returns the InstanceInfos of all the declared raters sorted by instance id. |
InstanceInfo |
getSecondaryBackup()
Returns the InstanceInfo of secondary backup. |
InstanceInfo |
getUpdater()
Returns the InstanceInfo of the updater. |
void |
marshal(XMLOutputter output)
Gives an XML representation of this object, and of its children. |
void |
setAttributes(XMLAttributes atts)
Sets the attributes of the XML representation of the tag beeing processed. |
java.lang.String |
toString()
Returns a printable form of the instance map in XML. |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String TAG_NAME
| Constructor Detail |
|---|
public InstanceMap()
InstanceMap instance without any InstanceInfo. This instance map
must be initialized using the fact it is an XMLMarshallable.
public InstanceMap(java.lang.String name,
java.util.Date lastModificationDate,
java.util.List<InstanceInfo> instanceInfos)
InstanceMap instance from a list of InstanceInfo.
name - the name of the cluster that can be null.lastModificationDate - the last time this instance map has been modified.instanceInfos - a list of valid InstanceInfo (one per instance).
java.lang.IllegalArgumentException - if name is not set| Method Detail |
|---|
public java.lang.String getName()
public int getInstanceCount()
InstanceInfos of this instance map.public int getRaterCount()
InstanceInfos of type InstanceType.rater.public int getGuiderCount()
InstanceInfos of type InstanceType.guider.public int getChargerCount()
InstanceInfos of type InstanceType.guider.public int getBackupCount()
InstanceInfos of type InstanceType.backup.public InstanceInfo getInfo(InstanceId instanceId)
InstanceInfo with the given ID.
instanceId - the instance id of the expected InstanceInfo.
public java.util.Date getLastModificationDate()
public java.util.List<InstanceInfo> getInstances()
InstanceInfos of all the declared instances sorted by instance id.
public java.util.List<InstanceInfo> getRaters()
InstanceInfos of all the declared raters sorted by instance id.
InstanceType.rater. It is empty
if the no rater is declared.public java.util.List<InstanceInfo> getGuiders()
InstanceInfos of all the declared guiders sorted by instance id.
InstanceType.guider. It is empty
if the no guider is declared.public java.util.List<InstanceInfo> getChargers()
InstanceInfos of all the declared chargers sorted by instance id.
InstanceType.charger. It is empty
if the no guider is declared.public InstanceInfo getBulkLoader()
InstanceInfos of all the declared chargers sorted by instance id.
InstanceType.charger. It is empty
if the no guider is declared.public java.util.List<InstanceInfo> getEZTaxers()
InstanceInfos of all the declared EZTaxers sorted by instance id.
InstanceType.eztaxer. It is empty
if the no guider is declared.public InstanceInfo getPrimaryBackup()
InstanceInfo of the primary backup.
InstanceType.backup and 1 as instance number.
if exists, null otherwise.public InstanceInfo getSecondaryBackup()
InstanceInfo of secondary backup.
InstanceType.backup and 2 as instance number.
if exists, null otherwise.public InstanceInfo getUpdater()
InstanceInfo of the updater.
InstanceType.updater
if exists, null otherwise.public InstanceInfo getBillingAssistant()
InstanceInfo of the billing assistant.
InstanceType.billingAssistant
if exists, null otherwise.public short[][] getPartitionMap()
public void assertIsCompatible(com.highdeal.util.Version.Edition edition)
throws InvalidInstanceException
edition - the edition to check. Cannot be null.
InvalidInstanceException - if the instance map is not compatible.
com.highdeal.util.NullArgumentException - if ed is null.public void setAttributes(XMLAttributes atts)
XMLMarshallable
setAttributes in interface XMLMarshallableatts - the XML attributes of the current tag.
public void addChild(java.lang.String tagName,
XMLMarshallable child)
XMLMarshallablechild represents
the marshallable object to be added into the content tree.
addChild in interface XMLMarshallabletagName - the name of tag for the child.child - the child to be added.public void addCharacterData(java.lang.String cData)
XMLMarshallable
addCharacterData in interface XMLMarshallablecData - the character data to be added.public void marshal(XMLOutputter output)
XMLMarshallable
marshal in interface XMLMarshallableoutput - the XML output to marshall the object into.
public void checkValidity()
throws InvalidInstanceException
An instance map is valid if all its InstanceInfos are valid.
InvalidInstanceExceptionpublic java.lang.String toString()
toString in class java.lang.Objectpublic InstanceMap clone()
To Modify the clone won't modify the original.
clone in class java.lang.Object
|
SAP CC 1.0
API 4.2 (Core) |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
SAP Convergent Charging 1.0 (build R4.2.1.35.0.0)
CONVERGENT CHARGING 4.2
(c) Copyright 2009 SAP AG. All rights reserved.