JSlim  


com.gtcgroup.jslim
Class ServiceTypeVO

java.lang.Object
  extended bycom.gtcgroup.jslim.DocumentPathSuperVO
      extended bycom.gtcgroup.jslim.ServicesSuperVO
          extended bycom.gtcgroup.jslim.ServiceTypeVO

final class ServiceTypeVO
extends ServicesSuperVO

This immutable class maintinas a collection of ServiceKeyVO objects which together represent a service type as defined in the descriptor document. For example, if three JMS queue services are documented, a single ServiceTypeVO collects all of the <Element>s for the three services.

Copyright (c) 1999 - 2004 by Global Technology Consulting Group, Inc. at gtcGroup.com.
Use is authorized, provided the source is acknowledged by inclusion of this copyright notice.

Since:
v. 1.0
Author:
MDT (MarvinToll@gtcGroup.com)

Field Summary
private  java.util.LinkedHashMap lhmServiceKeyVOs
          A collection of ServiceKeyVO objects.
 
Constructor Summary
(package private) ServiceTypeVO(int intServiceType)
          Constructor.
private ServiceTypeVO(java.util.LinkedHashMap lhmServiceKeyVOs, int intServiceType)
          Constructor (for internal use only).
 
Method Summary
(package private)  boolean containsServiceKeyVO(java.lang.String strServiceKey)
          Returns whether or not a particular ServiceKeyVO is available.
 boolean equals(java.lang.Object o)
           
(package private)  int getDocumentPath()
          Returns the path representation of the descriptor document.
(package private)  java.lang.String getElementKey()
          Returns the element key representation read from a descriptor document.
(package private)  java.lang.String getElementText()
          Return the element text read from a descriptor document.
(package private)  int getServiceCount()
          Returns the number of ServiceKeyVO objects representing a service type defined in a descriptor document.
(package private)  java.lang.String getServiceKey()
          Returns the service key representation read from a descriptor document.
(package private)  ServiceKeyVO getServiceKeyVO(java.lang.String strServiceKey)
          Returns a ServiceKeyVO representing a service type defined in a descriptor document.
(package private)  java.util.LinkedHashMap getServiceKeyVOs()
          Returns the collection of all ServiceKeyVOs each of which represents a service type defined in a descriptor document.
(package private)  int getServiceType()
          Returns the service type representation read from a descriptor document.
 int hashCode()
           
(package private)  ServiceTypeVO updateServiceTypeVO(org.w3c.dom.Element eleService, boolean blnOverWriteValue, int intDocumentPath)
          Returns a new ServiceTypeVO with an updated collection.
(package private)  ServiceTypeVO updateServiceTypeVO(org.w3c.dom.Element eleService, int intDocumentPath)
          Returns a new ServiceTypeVO with an updated collection.
(package private)  ServiceTypeVO updateServiceTypeVO(ServiceKeyVO serviceKeyVO)
          Returns a new ServiceTypeVO with an updated collection.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

lhmServiceKeyVOs

private final java.util.LinkedHashMap lhmServiceKeyVOs
A collection of ServiceKeyVO objects.

Constructor Detail

ServiceTypeVO

ServiceTypeVO(int intServiceType)
Constructor.

Parameters:
intServiceType - Represents the service type read from a descriptor document.

ServiceTypeVO

private ServiceTypeVO(java.util.LinkedHashMap lhmServiceKeyVOs,
                      int intServiceType)
Constructor (for internal use only).

Parameters:
lhmServiceKeyVOs - A collection of ServiceKeyVO objects.
intServiceType - Represents the service type read from a descriptor document.
Method Detail

containsServiceKeyVO

final boolean containsServiceKeyVO(java.lang.String strServiceKey)
Returns whether or not a particular ServiceKeyVO is available.

Parameters:
strServiceKey - Represents the service key read from a descriptor document.
Returns:
Returns whether or not a ServiceKeyVO is available.

getServiceKeyVOs

final java.util.LinkedHashMap getServiceKeyVOs()
Returns the collection of all ServiceKeyVOs each of which represents a service type defined in a descriptor document.

Returns:
The collection of all ServiceKeyVOs.

getServiceKeyVO

final ServiceKeyVO getServiceKeyVO(java.lang.String strServiceKey)
                            throws JSlimException
Returns a ServiceKeyVO representing a service type defined in a descriptor document.

Parameters:
strServiceKey - Represents the service key read from a descriptor document.
Returns:
A ServiceKeyVO.
Throws:
JSlimException - if an exception encountered.

getServiceCount

final int getServiceCount()
Returns the number of ServiceKeyVO objects representing a service type defined in a descriptor document.

Returns:
Returns the number of ServiceKeyVO objects.

updateServiceTypeVO

final ServiceTypeVO updateServiceTypeVO(ServiceKeyVO serviceKeyVO)
Returns a new ServiceTypeVO with an updated collection.

Parameters:
serviceKeyVO - A portion of a descriptor document representing one service.
Returns:
A new ServiceTypeVO with updated collection.

updateServiceTypeVO

final ServiceTypeVO updateServiceTypeVO(org.w3c.dom.Element eleService,
                                        int intDocumentPath)
                                 throws JSlimException
Returns a new ServiceTypeVO with an updated collection. Text values will not be over written if there is a duplicate value key within a service.

Parameters:
eleService - A portion of a descriptor document representing one service.
intDocumentPath - Represents the path of a descriptor document.
Returns:
A new ServiceTypeVO with an updated collection.
Throws:
JSlimException - if an exception encountered.

updateServiceTypeVO

final ServiceTypeVO updateServiceTypeVO(org.w3c.dom.Element eleService,
                                        boolean blnOverWriteValue,
                                        int intDocumentPath)
                                 throws JSlimException
Returns a new ServiceTypeVO with an updated collection.

Parameters:
eleService - A portion of a descriptor document representing one service.
blnOverWriteValue - Indicates current text values may be over written.
intDocumentPath - Represents the path of a descriptor document.
Returns:
A new ServiceTypeVO with an updated collection.
Throws:
JSlimException - if an exception encountered.

equals

public boolean equals(java.lang.Object o)
Overrides:
equals in class ServicesSuperVO

hashCode

public int hashCode()
Overrides:
hashCode in class ServicesSuperVO

getServiceType

final int getServiceType()
Returns the service type representation read from a descriptor document.

Returns:
The service type representation.

getServiceKey

final java.lang.String getServiceKey()
Returns the service key representation read from a descriptor document.

Returns:
The service key representation.

getElementKey

final java.lang.String getElementKey()
Returns the element key representation read from a descriptor document.

Returns:
The element key representation.

getElementText

final java.lang.String getElementText()
Return the element text read from a descriptor document.

Returns:
The element text read from a descriptor document.

getDocumentPath

final int getDocumentPath()
Returns the path representation of the descriptor document.

Returns:
The path representation of the descriptor document.

JSlim  


Copyright (c) 1999 - 2004 by Global Technology Consulting Group, Inc. at gtcGroup.com.
Use is authorized, provided the source is acknowledged by inclusion of this copyright notice.