vSphere Client SDK API Documentation : version 5.5.0.1300321

com.vmware.vise.usersession
Class UserSession

java.lang.Object
  extended by com.vmware.vise.usersession.UserSession

@data
public class UserSession
extends Object

User session details for the logged in user.

The current UserSession can be retrieved through the UserSessionService


Field Summary
 String clientId
          Id used to uniquely identify a client session.
 String locale
          Locale for the session.
 String samlTokenXml
          The XML value of the SAML Token representing the current user.
 ServerInfo[] serversInfo
          List of all the servers in the current session.
 String userName
          Name of the user who owns the session.
 
Constructor Summary
UserSession()
           
 
Method Summary
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

userName

public volatile String userName
Name of the user who owns the session.


locale

public volatile String locale
Locale for the session.


serversInfo

public volatile ServerInfo[] serversInfo
List of all the servers in the current session.

See Also:
ServerInfo

clientId

public volatile String clientId
Id used to uniquely identify a client session.

You can use it for instance to keep track of session specific resources and clean them up when you are notified of the session ending in your ClientSessionEndListener. Note that the HttpSession id cannot be used in place of clientId because the same client session can involve multiple Http sessions.

clientId is only set by the framework when UserSession is accessed in one of two ways:

  1. Within a Java service method for which your corresponding Flex proxy class extends BaseProxy, as shown in the SDK samples.
  2. Or within a DataProviderAdapter or PropertyProviderAdapter (in which case the proxy is the one from Data Access Manager).

See Also:
ClientSessionEndListener

samlTokenXml

public volatile String samlTokenXml
The XML value of the SAML Token representing the current user. A plug-in can use that information to check the user's authentication if necessary. See the vSphere Single Sign-On documentation.

samlTokenXml can be null if for some reason the UserSession didn't use a proper SSO authentication, but this should not happen in production mode.

Constructor Detail

UserSession

public UserSession()

vSphere Client SDK API Documentation : version 5.5.0.1300321

Copyright @ 2012 VMware, Inc. All rights reserved.