com.sap.mdm.session
Class UserSessionContext

java.lang.Object
  extended bycom.sap.mdm.session.AbstractSessionContext
      extended bycom.sap.mdm.session.ServerSessionContext
          extended bycom.sap.mdm.session.RepositorySessionContext
              extended bycom.sap.mdm.session.UserSessionContext
All Implemented Interfaces:
MdmSessionContext, Serializable

public class UserSessionContext
extends RepositorySessionContext

This class represents the context of the user session. The context includes: all elements of RepositorySessionContext plus region name

See Also:
ServerSessionContext, RepositorySessionContext, Serialized Form

Field Summary
 
Fields inherited from class com.sap.mdm.session.ServerSessionContext
DEFAUL_USER_NAME, DEFAULT_USER_NAME
 
Constructor Summary
UserSessionContext()
          C'tor
UserSessionContext(RepositorySessionContext ctx)
          Constructor
UserSessionContext(RepositorySessionContext ctx, String regionName)
          Constructor
UserSessionContext(String serverName, RepositoryIdentifier repository, String userName)
          Constructor
UserSessionContext(String serverName, RepositoryIdentifier repository, String regionName, String userName)
          Constructor
UserSessionContext(String serverName, String serverUserName, RepositoryIdentifier repository, String userName)
          Constructor
UserSessionContext(String serverName, String serverUserName, RepositoryIdentifier repository, String regionName, String userName)
          Constructor
UserSessionContext(String serverName, String repositoryName, String userName)
          Constructor
UserSessionContext(String serverName, String repositoryName, String regionName, String userName)
          Constructor
UserSessionContext(UserSessionContext ctx)
          Copy Constructor
 
Method Summary
 boolean equals(Object obj)
           
 RegionProperties getRegion()
          Get region
 String getRegionCode()
          Deprecated. instead of this method use getRegion().getRegionCode()
 Locale getRegionLocale()
          Get region Locale
 String getRegionName()
          Get region name
 int hashCode()
           
 void setRegionLocale(Locale regionLocale)
          Set region Locale.
 void setRegionName(String regionName)
          Set region name
 String toString()
           
 
Methods inherited from class com.sap.mdm.session.RepositorySessionContext
getRepository, getRepositoryName, getUnicodeNormalizationType, getUserName, setUnicodeNormalizationType, setUserName
 
Methods inherited from class com.sap.mdm.session.ServerSessionContext
getFullyQualifiedServerName, getServerName, getServerUserName, setServerUserName, setSocketFactory
 
Methods inherited from class com.sap.mdm.session.AbstractSessionContext
getApplicationId, getApplicationName, getConnectionType, getContextIdentifier, getSocketFactory, isTrustedConnection, isWebServiceContext, readFromString, setApplicationId, setApplicationName, setConnectionType, setContextIdentifier, setHashCode, setTrustedConnection, writeToString
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

UserSessionContext

public UserSessionContext(String serverName,
                          String serverUserName,
                          RepositoryIdentifier repository,
                          String regionName,
                          String userName)
Constructor


UserSessionContext

public UserSessionContext(String serverName,
                          RepositoryIdentifier repository,
                          String regionName,
                          String userName)
Constructor


UserSessionContext

public UserSessionContext(String serverName,
                          String repositoryName,
                          String regionName,
                          String userName)
Constructor


UserSessionContext

public UserSessionContext(String serverName,
                          String repositoryName,
                          String userName)
Constructor


UserSessionContext

public UserSessionContext(String serverName,
                          RepositoryIdentifier repository,
                          String userName)
Constructor


UserSessionContext

public UserSessionContext(String serverName,
                          String serverUserName,
                          RepositoryIdentifier repository,
                          String userName)
Constructor


UserSessionContext

public UserSessionContext(RepositorySessionContext ctx)
Constructor


UserSessionContext

public UserSessionContext(UserSessionContext ctx)
Copy Constructor


UserSessionContext

public UserSessionContext(RepositorySessionContext ctx,
                          String regionName)
Constructor


UserSessionContext

public UserSessionContext()
C'tor

Method Detail

getRegionName

public String getRegionName()
Get region name

Returns:
a region name

setRegionName

public void setRegionName(String regionName)
Set region name

Parameters:
regionName - the region name

getRegionLocale

public Locale getRegionLocale()
Get region Locale

Returns:
a region Locale

setRegionLocale

public void setRegionLocale(Locale regionLocale)
Set region Locale. The value of locale will be used for resolving the region properties instead of region name. If the repository does not contain any matching region then the first existing region will be used.

Parameters:
regionLocale - the region locale

getRegion

public RegionProperties getRegion()
                           throws IllegalArgumentException
Get region

Returns:
a region properties.
Throws:
IllegalArgumentException - if repository does not contain region correspondent to the specified region name

getRegionCode

public String getRegionCode()
                     throws IllegalArgumentException
Deprecated. instead of this method use getRegion().getRegionCode()

Get region code

Returns:
the region code
Throws:
IllegalArgumentException - if repository does not contain region correspondent to the specified region name

hashCode

public int hashCode()
Overrides:
hashCode in class RepositorySessionContext

equals

public boolean equals(Object obj)
Overrides:
equals in class RepositorySessionContext

toString

public String toString()
Overrides:
toString in class RepositorySessionContext
See Also:
Object.toString()


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.