com.sap.mdm.valuetypes
Class MultiregionValue

java.lang.Object
  extended bycom.sap.mdm.valuetypes.AbstractMdmValue
      extended bycom.sap.mdm.valuetypes.MultiregionValue
All Implemented Interfaces:
Cloneable, Comparable, MdmValue

public class MultiregionValue
extends AbstractMdmValue

This class is common representation of multi-regional value.


Nested Class Summary
 
Nested classes inherited from class com.sap.mdm.valuetypes.MdmValue
MdmValue.Type
 
Constructor Summary
MultiregionValue()
          Constructor
 
Method Summary
 Object clone()
          Clone MdmValue object
 int compareTo(MdmValue otherValue)
          Compares two MdmValue.
 boolean containsRegion(String regionCode)
          Determines if the specified region layer exist.
 boolean equals(Object obj)
           
 String[] getRegionCodes()
          Get region codes for all values of multi-regional string class
 int getType()
          Get type of MdmValue instance.
 MdmValue getValue(String regionCode)
          Returns value for the specified region code
 int hashCode()
           
 boolean isMultiregion()
          Specify if MdmValue is multi-region instance
 boolean isNull()
          Specify if MdmValue is NULL
 boolean isNull(String regionCode)
          Check if the value for specified region code is NullValue.
 void setValue(String regionCode, MdmValue value)
          Sets a new value for the specified region code
 String toString()
           
 
Methods inherited from class com.sap.mdm.valuetypes.AbstractMdmValue
compareTo, isMultivalue
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

MultiregionValue

public MultiregionValue()
Constructor

Method Detail

getRegionCodes

public String[] getRegionCodes()
Get region codes for all values of multi-regional string class

Returns:
array of region codes

isNull

public boolean isNull(String regionCode)
               throws IllegalArgumentException
Check if the value for specified region code is NullValue.

Parameters:
regionCode - region code
Returns:
true if value is instance of NullValue, false> otherwise
Throws:
IllegalArgumentException

containsRegion

public boolean containsRegion(String regionCode)
Determines if the specified region layer exist.

Parameters:
regionCode - the region code
Returns:
true if the region layer exist, otherwise, false

getValue

public MdmValue getValue(String regionCode)
                  throws IllegalArgumentException
Returns value for the specified region code

Parameters:
regionCode - region code
Returns:
instance of MdmValue
Throws:
IllegalArgumentException

setValue

public void setValue(String regionCode,
                     MdmValue value)
              throws IllegalArgumentException
Sets a new value for the specified region code

Parameters:
regionCode - region code
value - a new value
Throws:
IllegalArgumentException

clone

public Object clone()
Description copied from interface: MdmValue
Clone MdmValue object

Specified by:
clone in interface MdmValue
Specified by:
clone in class AbstractMdmValue

getType

public int getType()
Description copied from interface: MdmValue
Get type of MdmValue instance. For MdmMultiValue instance this type specify type of multi-value elements Constants for MdmValue types are specified in this interface

Specified by:
getType in interface MdmValue
Specified by:
getType in class AbstractMdmValue

isMultiregion

public boolean isMultiregion()
Description copied from interface: MdmValue
Specify if MdmValue is multi-region instance

Specified by:
isMultiregion in interface MdmValue
Overrides:
isMultiregion in class AbstractMdmValue

isNull

public boolean isNull()
Description copied from interface: MdmValue
Specify if MdmValue is NULL

Specified by:
isNull in interface MdmValue
Overrides:
isNull in class AbstractMdmValue

equals

public boolean equals(Object obj)
Overrides:
equals in class AbstractMdmValue
See Also:
Object.equals(java.lang.Object)

hashCode

public int hashCode()
See Also:
Object.hashCode()

toString

public String toString()
See Also:
Object.toString()

compareTo

public int compareTo(MdmValue otherValue)
Description copied from class: AbstractMdmValue
Compares two MdmValue.

Specified by:
compareTo in class AbstractMdmValue
Parameters:
otherValue - the MdmValue to be compared.
Returns:
the value 0 if the argument is a MdmValue is equal to this MdmValue; the value is less than 0 if this MdmValue is less than the argument MdmValue; the value is greater than 0 if this MdmValue is greater than the argument MdmValue;


Copyright 2004-2007 by SAP AG. All Rights Reserved.

SAP, R/3, mySAP, mySAP.com, xApps, xApp, SAP NetWeaver, and other SAP products and services mentioned herein as well as their respective logos are trademarks or registered trademarks of SAP AG in Germany and in several other countries all over the world. All other product and service names mentioned are the trademarks of their respective companies. Data contained in this document serves informational purposes only. National product specifications may vary.

These materials are subject to change without notice. These materials are provided by SAP AG and its affiliated companies (SAP Group) for informational purposes only, without representation or warranty of any kind, and SAP Group shall not be liable for errors or omissions with respect to the materials. The only warranties for SAP Group products and services are those that are set forth in the express warranty statements accompanying such products and services, if any. Nothing herein should be construed as constituting an additional warranty.