public class MobileResourceManager
extends java.lang.Object
MobileResourceManager
class is for administrative uses. It
is thread-safe and it provides an array of administrative APIs that can be
used to manage users, groups, applications, etc. This class is a replacement
of the ResourceManager
class, which has been deprecated as the
APIs in ResourceManager
are not thread-safe.Constructor and Description |
---|
MobileResourceManager(java.lang.String adminUser,
java.lang.String adminPwd,
java.lang.String adminURL)
Initialize a MobileResourcManager object.
|
Modifier and Type | Method and Description |
---|---|
void |
addUsersToGroup(java.lang.String groupName,
java.util.Vector users)
Add users to the given user group.
|
void |
addUserToGroup(java.lang.String groupName,
java.lang.String userName)
Add one user to the given user group.
|
boolean |
clearPassword(java.lang.String userName)
Set password as null for an existing Mobile Server user to make user external.
|
void |
closeConnection()
End the Mobile Server administrative session.
|
void |
commitTransaction()
Commit the admin tasks in the current active session.
|
boolean |
createExternalUser(java.lang.String userName,
java.lang.String fullName,
java.lang.String privilege)
Create a Mobile Server user whose identification will be authenticated externally.
|
boolean |
createGroup(java.lang.String groupName)
Create a new Mobile Server user group.
|
boolean |
createUser(java.lang.String userName,
java.lang.String password,
java.lang.String fullName,
java.lang.String privilege)
Create a new Mobile Server user.
|
void |
dropApplication(java.lang.String virtualPath)
Drop the named existing application.
|
void |
dropGroup(java.lang.String groupName)
Remove the named user group.
|
void |
dropUser(java.lang.String userName)
Remove a Mobile Server user.
|
java.lang.String |
getApplicationClasspath(java.lang.String vp)
Return the classpath of an application.
|
java.lang.String |
getApplicationDefaultPage(java.lang.String vp)
Return the default page of an application.
|
java.lang.String |
getApplicationDescription(java.lang.String virtualPath)
Return the description of an existing application.
|
java.lang.String |
getApplicationIcon(java.lang.String vp)
Return the icon of an applicaiton.
|
java.lang.String |
getApplicationName(java.lang.String virtualPath)
Return the name of an existing application.
|
java.lang.String |
getApplicationPublication(java.lang.String vp)
Return the publication associated with an application.
|
java.sql.Timestamp |
getApplicationPublishedTime(java.lang.String virtualPath)
Return the time an application was published.
|
java.lang.String |
getApplicationRepositoryDirectory(java.lang.String vp)
Return the repository directory of an application.
|
java.util.Enumeration |
getApplicationUsers(java.lang.String virtualPath)
Return an enumeration of the users associated with an application.
|
int |
getDBConnections(java.lang.String virtualPath)
Return the number of database connections for an existing application.
|
boolean |
getDBConnectionSharing(java.lang.String virtualPath)
Return the database connection sharing setting for an application.
|
java.lang.String |
getDBUser(java.lang.String virtualPath)
Return the database username for an existing application.
|
java.lang.String |
getDSN(java.lang.String vp)
Return the DSN of an application.
|
java.lang.String |
getFullName(java.lang.String userName)
Return the fullname information of an existing Mobile Server user.
|
boolean |
getGroupAccess(java.lang.String virtualPath,
java.lang.String groupName)
Return application access for the user group.
|
boolean |
getGroupRoleAccess(java.lang.String virtualPath,
java.lang.String groupName,
java.lang.String role)
Return the group access with certain role for an application.
|
boolean |
getGroupUserAccess(java.lang.String virtualPath,
java.lang.String groupName,
java.lang.String userName)
This will check if an user belongs to a group and if that group has access
to an application.
|
java.lang.String |
getPrivilege(java.lang.String userName)
Return the privilege of an existing Mobile Server user.
|
java.lang.String |
getPublication(java.lang.String virtualPath)
Return the name of the Consolidator publication associated with an application.
|
java.lang.String |
getPublicationItemName(java.lang.String snapshot,
java.lang.String appVP)
This is a link between MobileResourceManager API and Consolidator API.
|
java.lang.String |
getSnapshotTemplate(java.lang.String snapshot,
java.lang.String appVP)
Return the snapshot template string.
|
java.lang.String |
getTemplateVariable(java.lang.String virtualPath,
java.lang.String userName,
java.lang.String varName)
Return the value of an application snapshot template variable for one user.
|
java.util.Hashtable |
getTemplateVariables(java.lang.String virtualPath,
java.lang.String userName)
Return the values of all the application snapshots template variables for one user.
|
boolean |
getUserAccess(java.lang.String virtualPath,
java.lang.String userName)
Return application access for the user at the user level.
|
java.util.Vector |
getUserGroupList(java.lang.String userName)
Return a vector of id of the groups that an user has access.
|
java.util.Vector |
getUserGroupNameList(java.lang.String userName)
Return a vector of groups names that a user has access to.
|
java.util.Vector |
getUserPublications(java.lang.String userName,
java.lang.String platform)
Return a vector of publications associated with a user.
|
boolean |
getUserRoleAccess(java.lang.String virtualPath,
java.lang.String userName,
java.lang.String role)
Return the user access for an application with certain role.
|
boolean |
hasAccess(java.lang.String virtualPath,
java.lang.String userName)
Return application access for the user at the user level.
|
void |
isAPI(boolean flag)
Mobile Server can have a dependency on servlet.jar.
|
boolean |
isServerSuspended()
* Return the status of Mobile Server - suspended (single user) or
* running in regular mode
|
java.util.Vector |
listApplications(java.lang.String appnamePattern)
List all the Mobile Server applications that match the namePattern.
|
java.util.Vector |
listApplicationsByVP(java.lang.String vpPattern)
List applications whose virtual path matches the supplied virtual path pattern.
|
java.util.Vector |
listGroupRoles(java.lang.String virtualPath,
java.lang.String groupName)
List the roles a group has for an application.
|
java.util.Vector |
listGroups(java.lang.String namePattern)
List groups whose name matches the pattern.
|
java.util.Vector |
listRoles(java.lang.String virtualPath)
List the roles that are associated with an existing application.
|
java.util.Vector |
listSnapshots(java.lang.String virtualPath)
List the snapshots associated with an existing application.
|
java.util.Vector |
listTemplateVariables(java.lang.String virtualPath)
Lists the name of the all the snapshot template variables for an application on one platform.
|
java.util.Vector |
listUserApplicationNames(java.lang.String userName)
List all the applicatons that the user have access to.
|
java.util.Vector |
listUserApplications(java.lang.String userName)
List all the applicatons that the user have access to.
|
java.util.Vector |
listUserRoles(java.lang.String virtualPath,
java.lang.String userName)
List the roles a user has for an applicaiton.
|
java.util.Vector |
listUsers(java.lang.String namePattern)
Find users whose username matches the name pattern.
|
java.util.Vector |
listUsersInGroup(java.lang.String groupName)
Return all the users in a user group.
|
void |
mobileDisableUser(java.lang.String userName)
Remove the entry for this user from Mobile Server.
|
boolean |
mobileEnableUser(java.lang.String userName,
java.lang.String privilege)
Mobile Enable an IAS user residing in OID.
|
void |
publishApplication(java.io.File jarFile,
java.lang.String username,
java.lang.String password,
java.lang.String url,
boolean isPublicApplication,
boolean overwrite)
Publish an application jar file.
|
void |
removeUserFromGroup(java.lang.String groupName,
java.lang.String userName)
Removed a user from the given user group.
|
void |
removeUsersFromGroup(java.lang.String groupName,
java.util.Vector users)
Remove users from the given user group.
|
void |
resumeServer()
* Resume Mobile Server and put it in back in Multi user mode
|
void |
rollbackTransaction()
Rollback the admin tasks in the current active session.
|
void |
setApplicationClasspath(java.lang.String vp,
java.lang.String cp)
Set the classpath of an application.
|
void |
setApplicationDefaultPage(java.lang.String vp,
java.lang.String defaultPage)
Set the default page of an application.
|
void |
setApplicationDescription(java.lang.String virtualPath,
java.lang.String description)
Set the description for an existing application.
|
void |
setApplicationIcon(java.lang.String vp,
java.lang.String icon)
Set the icon of an application.
|
void |
setApplicationName(java.lang.String virtualPath,
java.lang.String appname)
Rename an existing application.
|
void |
setApplicationPublication(java.lang.String vp,
java.lang.String pubName)
Associate the Consolidator publication of an application.
|
void |
setApplicationPublishedTime(java.lang.String virtualPath)
Set application publish time with the current time.
|
void |
setDBConnections(java.lang.String virtualPath,
int connections)
Set the number of database connections for an existing application.
|
void |
setDBConnectionSharing(java.lang.String virtualPath,
boolean sharing)
Enable/disable the database connection sharing for an existing application.
|
void |
setDBUser(java.lang.String virtualPath,
java.lang.String dbUser,
java.lang.String dbPwd)
Set the Database User property of an existing application.
|
void |
setFullName(java.lang.String userName,
java.lang.String fullname)
Set the full name information for an existing Mobile Server user.
|
void |
setGroupAccess(java.lang.String virtualPath,
java.lang.String groupName,
boolean access)
Set application access for a group.
|
void |
setGroupRoleAccess(java.lang.String virtualPath,
java.lang.String groupName,
java.lang.String role,
boolean access)
Set Group access with a role.
|
void |
setGroupRoleAccess(java.lang.String virtualPath,
java.lang.String groupName,
java.util.Vector roles,
boolean access)
Grant or revoke application role for the group.
|
void |
setGroupUserAccess(java.lang.String virtualPath,
java.lang.String groupName,
java.lang.String userName,
boolean access)
This method assigns finer grain user access to the application in a group level.
|
boolean |
setPassword(java.lang.String userName,
java.lang.String newpwd)
Set password for an existing Mobile Server user.
|
void |
setPrivilege(java.lang.String userName,
java.lang.String privilege)
Set the privilege for an existing Mobile Server user.
|
void |
setTemplateVariable(java.lang.String virtualPath,
java.lang.String userName,
java.lang.String name,
java.lang.String value)
Set a snapshot template variable value for a particular user.
|
void |
setTemplateVariables(java.lang.String virtualPath,
java.lang.String userName,
java.util.Hashtable nameValuePairs)
Set snapshot template variables for a particular user.
|
void |
setUserAccess(java.lang.String virtualPath,
java.lang.String userName,
boolean access)
Sets application access for the user.
|
void |
setUserCompleteRefresh(java.lang.String userName,
java.lang.String platform)
Set complete refresh on the given platform next time the user do a sync.
|
void |
setUserRoleAccess(java.lang.String virtualPath,
java.lang.String userName,
java.lang.String role,
boolean access)
Grant or revoke application role for the user.
|
void |
setUserRoleAccess(java.lang.String virtualPath,
java.lang.String userName,
java.util.Vector roles,
boolean access)
Grant or revoke application role for the user.
|
void |
setUsersAccess(java.lang.String virtualPath,
java.lang.String[] userName)
Set access of an application for an array of users.
|
void |
suspendServer(oracle.lite.web.WTGUser user)
* Suspend Mobile Server and put it in Single user mode.
|
int |
validateExternalUser(java.lang.String user,
java.lang.String displayName) |
int |
validateUser(java.lang.String user,
java.lang.String pwd,
java.lang.String displayName) |
public MobileResourceManager(java.lang.String adminUser, java.lang.String adminPwd, java.lang.String adminURL) throws ResException
adminUser
- the username of the MobileAdmin schema.adminPwd
- the password of the MobileAdmin schema.adminURL
- the jdbc url of the database which contains the MobileAdmin schema.ResException
MobileResourceManager(Connection conn)
public void addUsersToGroup(java.lang.String groupName, java.util.Vector users) throws ResException
groupName
- the name of an existing user group. No action will be
taken if the group does not exist.users
- a vector of existing user names that will be added to the group.ResException
public void addUserToGroup(java.lang.String groupName, java.lang.String userName) throws ResException
groupName
- the name of an existing user group. This method does
nothing if the group does not exist.userName
- the name of an existing user.ResException
public boolean clearPassword(java.lang.String userName) throws ResException
userName
- the username of an existing Mobile Server user. No action will
be taken if the user does not exist.ResException
public void closeConnection()
public void commitTransaction()
public boolean createExternalUser(java.lang.String userName, java.lang.String fullName, java.lang.String privilege) throws ResException
userName
- name of the new Mobile Server user Please note that it should
not be the same of an existing user or group.fullName
- user's real nameprivilege
- the Mobile Server user privilege. The value can be one of the
following:
"O" for publishing an application.
"U" for connecting to Mobile Server as an user.
"A" for administrating the Mobile Server.
"M" for Member user.
NULL stands for none privilege.ResException
public boolean createGroup(java.lang.String groupName)
groupName
- the name of the new Mobile Server user group. It should not
have the same name as an existing user or group.public boolean createUser(java.lang.String userName, java.lang.String password, java.lang.String fullName, java.lang.String privilege) throws ResException
userName
- the name of the new Mobile Server user. Please note that it
should not be the name of an existing user or group.password
- the clear text password for the new Mobile Server user.fullName
- user's real nameprivilege
- the Mobile Server user privilege. The value can be one of the
following:
"O" for publishing an application.
"U" for connecting to Mobile Server as an user.
"A" for administrating the Mobile Server.
"M" for Member user.
NULL stands for none privilege.ResException
public void dropApplication(java.lang.String virtualPath)
virtualPath
- the virtual path of an existing application. Please
note that the virtual path is the unique identifier of an application.public void dropGroup(java.lang.String groupName)
groupName
- the name of a Mobile Server user group.public void dropUser(java.lang.String userName) throws ResException
userName
- the username of the userResException
public java.lang.String getApplicationClasspath(java.lang.String vp)
vp
- the virtual path of the application.public java.lang.String getApplicationDefaultPage(java.lang.String vp)
vp
- the virtual path of the application.public java.lang.String getApplicationDescription(java.lang.String virtualPath)
virtualPath
- the virtual path of an existing application. Please
note that the virtual path is the unique identifier of an application.public java.lang.String getApplicationIcon(java.lang.String vp)
vp
- the virtual path of the application.public java.lang.String getApplicationName(java.lang.String virtualPath)
virtualPath
- the virtual path of an existing application. Please
note that virtual path is the unique identifier of an application.public java.lang.String getApplicationPublication(java.lang.String vp) throws ResException
vp
- the virtual path of the application.ResException
public java.sql.Timestamp getApplicationPublishedTime(java.lang.String virtualPath)
virtualPath
- the virtual path of an existing application
Please note that the virtual path is the unique identifier of an application.public java.lang.String getApplicationRepositoryDirectory(java.lang.String vp)
vp
- the virtual path of the application.public java.util.Enumeration getApplicationUsers(java.lang.String virtualPath)
virtualPath
- the virtual path of the application.public int getDBConnections(java.lang.String virtualPath)
virtualPath
- the virtual path of an existing application.
Please note that the virtual path is the unique identifier of an application.public boolean getDBConnectionSharing(java.lang.String virtualPath)
virtualPath
- the virtual path of an existing application.
Please note that the virtual path is the unique identifier of an application.public java.lang.String getDBUser(java.lang.String virtualPath)
virtualPath
- the virtual path of an existing application.
Please note that the virtual path is the unique identifier of an application.public java.lang.String getDSN(java.lang.String vp)
vp
- the virtual path of the application.public java.lang.String getFullName(java.lang.String userName) throws ResException
userName
- the username of an existing Mobile Server user.ResException
public boolean getGroupAccess(java.lang.String virtualPath, java.lang.String groupName)
virtualPath
- the virtual path for an existing Mobile Server application.groupName
- the name of the User group.public boolean getGroupRoleAccess(java.lang.String virtualPath, java.lang.String groupName, java.lang.String role)
virtualPath
- the virtual path for an existing Mobile Server application.groupName
- the name of the group.role
- a role that is associated with this application.public boolean getGroupUserAccess(java.lang.String virtualPath, java.lang.String groupName, java.lang.String userName)
virtualPath
- the virtual path of an existing application.groupName
- the name of an existing group that has access to this applicationuserName
- the name of an existing user(String, String, String, boolean)
public java.lang.String getPrivilege(java.lang.String userName)
userName
- the username of an existing Mobile Server user.(String, String)
public java.lang.String getPublication(java.lang.String virtualPath)
virtualPath
- the virtual path of an existing application.public java.lang.String getPublicationItemName(java.lang.String snapshot, java.lang.String appVP)
snapshot
- the name of an existing snapshot.appVP
- the virtual path of the application that this Publication Item belongs to.public java.lang.String getSnapshotTemplate(java.lang.String snapshot, java.lang.String appVP)
snapshot
- the name of the snapshot.public java.lang.String getTemplateVariable(java.lang.String virtualPath, java.lang.String userName, java.lang.String varName)
virtualPath
- the virtual path of an application.userName
- the username of the user.varName
- the name of the variable.getTemplateVariables(String, String)
public java.util.Hashtable getTemplateVariables(java.lang.String virtualPath, java.lang.String userName)
virtualPath
- the virtual path of the application.userName
- the username of the user.public boolean getUserAccess(java.lang.String virtualPath, java.lang.String userName)
virtualPath
- the virtual path for an existing Mobile Server application.userName
- the username of the user.public java.util.Vector getUserGroupList(java.lang.String userName) throws ResException
userName
- the username of the user.ResException
public java.util.Vector getUserGroupNameList(java.lang.String userName) throws ResException
userName
- the username of the user.ResException
public java.util.Vector getUserPublications(java.lang.String userName, java.lang.String platform) throws java.lang.Exception
userName
- the name of the user.platform
- the platform associated.java.lang.Exception
public boolean getUserRoleAccess(java.lang.String virtualPath, java.lang.String userName, java.lang.String role)
virtualPath
- the virtual path for an existing Mobile Server application.userName
- the username of the user.role
- a role that is associated with this application.public boolean hasAccess(java.lang.String virtualPath, java.lang.String userName)
virtualPath
- virtual for an existing Mobile Server application.userName
- the name of the user.public void isAPI(boolean flag)
flag
- true to set up the dependency; false to break itpublic boolean isServerSuspended()
public java.util.Vector listApplications(java.lang.String appnamePattern)
appnamePattern
- the pattern that matches the application name.public java.util.Vector listApplicationsByVP(java.lang.String vpPattern)
vpPattern
- the virtual path pattern (SQL). NULL will match for all.public java.util.Vector listGroupRoles(java.lang.String virtualPath, java.lang.String groupName)
virtualPath
- the name of an existing application.groupName
- the name of an existing group.public java.util.Vector listGroups(java.lang.String namePattern)
namePattern
- name search pattern (SQL). NULL will search for all.public java.util.Vector listRoles(java.lang.String virtualPath)
virtualPath
- the virtual path of an existing application.
Please note that the virtual path is the unique identifier of an application.public java.util.Vector listSnapshots(java.lang.String virtualPath)
virtualPath
- the virtual path of an existing application.
Please note that the virtual path is the unique identifier of an application.public java.util.Vector listTemplateVariables(java.lang.String virtualPath) throws ResException
virtualPath
- the virtual path of an existing application.ResException
public java.util.Vector listUserApplicationNames(java.lang.String userName)
userName
- the userName.public java.util.Vector listUserApplications(java.lang.String userName)
userName
- the userName.public java.util.Vector listUserRoles(java.lang.String virtualPath, java.lang.String userName)
virtualPath
- the name of an existing application.userName
- the name of an existing user.public java.util.Vector listUsers(java.lang.String namePattern)
namePattern
- the name search pattern (SQL). NULL will search for all.public java.util.Vector listUsersInGroup(java.lang.String groupName)
groupName
- name of an existing user group.public void mobileDisableUser(java.lang.String userName) throws ResException
userName
- the username of the usernameResException
public boolean mobileEnableUser(java.lang.String userName, java.lang.String privilege) throws ResException
userName
- name of the IAS user. Please note that it should not be
the name of an existing user or group.privilege
- the Mobile Server user privilege. The value can be one of the
following:
"O" for publishing an application,
"U" for connecting to Mobile Server
"A" for administrating Mobile Server.
NULL stands for none privilege.ResException
public void publishApplication(java.io.File jarFile, java.lang.String username, java.lang.String password, java.lang.String url, boolean isPublicApplication, boolean overwrite) throws ResException
jarFile
- the Mobile Server application jar file created by Mobile Server Packaging
Wizard.username
- the Mobile Server user that have the publishing priviliege.password
- the Mobile Server user's password.url
- the url for the application's directory on the Mobile Server.isPublicApplication
- is this application accessible to all user.overwrite
- if set to true, an existing definition for this application
is overwritten on the server.ResException
- when failed to publish the application.public void removeUserFromGroup(java.lang.String groupName, java.lang.String userName)
groupName
- the name of the user group.userName
- the username of the user.public void removeUsersFromGroup(java.lang.String groupName, java.util.Vector users)
groupName
- the name of the user group. This method does nothing
if the groupName does not exist.users
- a vector of users names (String) that will be removed.public void resumeServer()
public void rollbackTransaction()
public void setApplicationClasspath(java.lang.String vp, java.lang.String cp)
vp
- the virtual path of the application.cp
- the classpath of the application.public void setApplicationDefaultPage(java.lang.String vp, java.lang.String defaultPage)
vp
- the virtual path of the application.defaultPage
- the name of the default page.public void setApplicationDescription(java.lang.String virtualPath, java.lang.String description)
virtualPath
- the virtual path of an existing application.
Please note that virtual path is the unique identifier of an application.description
- the new description for an existing application.public void setApplicationIcon(java.lang.String vp, java.lang.String icon)
vp
- the virtual path of the application.icon
- the icon of an applicaiton.public void setApplicationName(java.lang.String virtualPath, java.lang.String appname)
virtualPath
- the virtual path of an existing application. Please
note that virtual path is the unique identifier of an application.appname
- the new name for this application.public void setApplicationPublication(java.lang.String vp, java.lang.String pubName) throws ResException
vp
- the virtual path of the application.pubName
- the Consolidator publication of an application.ResException
public void setApplicationPublishedTime(java.lang.String virtualPath) throws ResException
virtualPath
- the virtual path of an existing application.
Please note that the virtual path is the unique identifier of an application.ResException
public void setDBConnections(java.lang.String virtualPath, int connections)
virtualPath
- the virtual path of an existing application. Please
note that virtual path is the unique identifier of an application.connections
- the number of database connection for an existing application.
This can not be negative.public void setDBConnectionSharing(java.lang.String virtualPath, boolean sharing)
virtualPath
- the virtual path of an existing application.
Please note that the virtual path is the unique identifier of an application.sharing
- true if allow database connection sharing; false other wise.public void setDBUser(java.lang.String virtualPath, java.lang.String dbUser, java.lang.String dbPwd)
virtualPath
- the virtual path of an existing application.
Please note that the virtual path is the unique identifier of an application.dbUser
- the database user name for the application.dbPwd
- the database user password (in clear text).public void setFullName(java.lang.String userName, java.lang.String fullname) throws ResException
userName
- an existing Mobile Server user. No action will be taken if the
user already exists.fullname
- the full name information for this Mobile Server user.ResException
public void setGroupAccess(java.lang.String virtualPath, java.lang.String groupName, boolean access)
virtualPath
- the application virtual path.groupName
- the name of the User Group.access
- true to grant and false to revoke the access.public void setGroupRoleAccess(java.lang.String virtualPath, java.lang.String groupName, java.lang.String role, boolean access)
virtualPath
- the application virtual path.groupName
- a group that has access to the application.role
- the application role.access
- TRUE to grant access; FALSE to revoke access for the name role.public void setGroupRoleAccess(java.lang.String virtualPath, java.lang.String groupName, java.util.Vector roles, boolean access)
virtualPath
- the application virtual path.groupName
- a group that has access to the application.roles
- a vector of existing application roles (strings).access
- TRUE to grant access and FALSE to revoke access for the name role.public void setGroupUserAccess(java.lang.String virtualPath, java.lang.String groupName, java.lang.String userName, boolean access)
virtualPath
- the application virtual path.groupName
- the group that has access to the application.userName
- the username of the user.access
- TRUE to grant access and FALSE to revoke access for the name role.setUserAccess(String, String, boolean)
,
setGroupAccess(String, String, boolean)
public boolean setPassword(java.lang.String userName, java.lang.String newpwd) throws ResException
userName
- the username of an existing Mobile Server user. No action will
will taken if the user does not exist.newpwd
- this Mobile Server user's new password in clear text.ResException
public void setPrivilege(java.lang.String userName, java.lang.String privilege)
userName
- the username of an existing Mobile Server user. No action will
be taken if the user does not exist.privilege
- the Mobile Server user privilege. The value can be one of the
following:
"O" for publishing an application,
"U" for connecting to Mobile Server
"A" for administrating Mobile Server.
NULL stands for none privilege.public void setTemplateVariable(java.lang.String virtualPath, java.lang.String userName, java.lang.String name, java.lang.String value)
virtualPath
- the virtual path of an application.userName
- the username of an existing Mobile Server user.name
- the name of the template variable.value
- the value of the template variable.public void setTemplateVariables(java.lang.String virtualPath, java.lang.String userName, java.util.Hashtable nameValuePairs)
virtualPath
- the virtual path of an application.userName
- the username of an existing Mobile Server user.nameValuePairs
- a hashtable containing the name/value pairs
that cover all the template variable of the snapshot. Please note
that it does not include the leading ":". Also, the name is case-insensitive.public void setUserAccess(java.lang.String virtualPath, java.lang.String userName, boolean access) throws ResException
virtualPath
- the application virtual path.userName
- the username of the user.access
- true grant and false to revoke the access.ResException
public void setUserCompleteRefresh(java.lang.String userName, java.lang.String platform) throws ResException
userName
- the username of an existing user.platform
- a valid platform String.ResException
setUserCompleteRefresh(String, int)
public void setUserRoleAccess(java.lang.String virtualPath, java.lang.String userName, java.lang.String role, boolean access) throws ResException
virtualPath
- the application virtual path.userName
- a user that has access to the application.role
- the application role.access
- true to grant access; false to revoke access for the name role.ResException
public void setUserRoleAccess(java.lang.String virtualPath, java.lang.String userName, java.util.Vector roles, boolean access)
virtualPath
- application virtual pathuserName
- a user that has access to the application.roles
- all the roles for this application for this user.access
- true to grant access; false to revoke access for the name role.public void setUsersAccess(java.lang.String virtualPath, java.lang.String[] userName)
virtualPath
- the virtual path of the application.userName
- an array of usernames.public void suspendServer(oracle.lite.web.WTGUser user)
user
- userName
* @deprecatedpublic int validateExternalUser(java.lang.String user, java.lang.String displayName)
public int validateUser(java.lang.String user, java.lang.String pwd, java.lang.String displayName)