All Packages Class Hierarchy This Package Previous Next Index
Class com.ibm.as400.access.User
java.lang.Object
|
+----com.ibm.as400.access.User
- public class User
- extends Object
- implements Serializable
The User class represents an AS/400 user.
The default User constructor only provides a default virtual user. To retrieve the information of a real user on AS400,
the methods setSystem(), setName() and loadUserInformation() should be explicitly invoked. Here
is an example:
// Constructs a AS400 system object.
AS400 system = new AS400();
// Create a user
User user = new User();
...
user.setSystem(system);
user.setName("Fred");
user.loadUserInformation();
...
System.out.println(user.getJobDescription());
-
User()
- Constructs a User object.
-
User(AS400, String)
- Constructs a User object.
-
addPropertyChangeListener(PropertyChangeListener)
- Adds a listener to be notified when the value of any bound
property is changed.
-
addVetoableChangeListener(VetoableChangeListener)
- Adds a listener to be notified when the value of any constrained
property is changed.
-
getAccountingCode()
- Returns the accounting code that is associated with this user.
-
getAssistanceLevel()
- Returns the user interface that the user will use.
-
getAttentionKeyHandlingProgram()
- Returns the full path of the attention-key-handling program for this user.
-
getCCSID()
- Returns the character code set identifier to be used by the system for this user.
-
getCountryID()
- Returns the country identifier used by the system for this user.
-
getCurrentLibraryName()
- Returns the name of the user's current library.
-
getDaysUntilPasswordExpire()
- Returns the number of days until the password will expire.
-
getDescription()
- Returns the descriptive text for the user profile.
-
getDisplaySignOnInformation()
- Returns the value that indicates whether the sign-on information display is shown when
the user signs on.
-
getGroupAuthority()
- Returns the authority the user's group profile has to the objects the user creates.
-
getGroupAuthorityType()
- Returns the type of authority the user's group profile has to the objects the
user creates.
-
getGroupIDNumber()
- Returns the group identifier number for the user profile.
-
getGroupProfileName()
- Returns the name of the group profile.
-
getHighestSchedulingPriority()
-
Returns the highest scheduling priority the user is allowed to have
for each job submitted to the system.
-
getHomeDirectory()
- Returns the home directory for this user profile.
-
getInitialMenu()
- Returns the full path of the initial menu for the user.
-
getInitialProgram()
- Returns the full path of the initial program for the user.
-
getJobDescription()
- Returns the full path of the job description used for jobs that start through
subsystem work station entries.
-
getLanguageID()
- Returns the language identifier used by the system for this user.
-
getLimitCapabilities()
- Returns the value indicating whether the user has limited capabilities.
-
getLimitDeviceSessions()
- Returns the value indicating whether the user is limited to one device session.
-
getLocaleJobAttributes()
- Returns the job attributes that are taken from the user's locale path name.
-
getLocalePathName()
- Returns the locale path name that is assigned to the user profile when a job is
started.
-
getMaximumStorageAllowed()
- Returns the maximum amount of auxiliary storage (in kilobytes) that can be
assigned to store permanent objects owner by the user.
-
getMessageQueue()
- Returns the full path of the message queue that is used by this user.
-
getMessageQueueDeliveryMethod()
- Returns the message queue delivery method which indicates how the messages
are delivered to the message queue used by the user.
-
getMessageQueueSeverity()
- Returns the lowest severity that a message can have and still
be delivered to a user in break or notify mode.
-
getName()
- Returns the name of the user.
-
getObjectAuditingValue()
- Returns the current user's object auditing value.
-
getOutputQueue()
- Returns the full path of the output queue used by this user.
-
getOwner()
-
Returns the value indicating who is to own objects created by those user.
-
getPasswordExpirationInterval()
-
Returns the number of days (from 1 through 366) the user's password can
remain active before it must be changed.
-
getPasswordExpireDate()
- Returns the date the user's password expires.
-
getPasswordLastChangedDate()
- Returns the date the user's password was last changed.
-
getPreviousSignedOnDate()
- Returns the date and time the user last signed on.
-
getPrintDevice()
-
Returns the printer used to print for this user.
-
getSignedOnAttemptsNotValid()
-
Returns the number of the sign-on attempts that were not valid since the
last successful sign-on.
-
getSortSequenceTable()
- Returns the full path of the sort sequence table used for string comparisons.
-
getSpecialAuthority()
- Returns the special authority of the user.
-
getSpecialEnvironment()
- Returns the special environment the user operates in after signing on.
-
getStatus()
- Returns the status of the user profile.
-
getStorageUsed()
-
Returns the amount of auxiliary storage (in kilobytes) occupied by this user's owned
objects.
-
getSupplementalGroups()
- Returns the array of supplemental groups for the user profile.
-
getSupplementalGroupsNumber()
- Returns the number of supplemental groups returned in the array.
-
getSystem()
- Returns the AS/400 system.
-
getUserActionAuditLevel()
- Returns the action audit values for this user.
-
getUserClassName()
- Returns the class for the user.
-
getUserIDNumber()
- Returns the user identifier number for the user profile.
-
getUserProfileName()
- Returns the name of the user profile for which the information is returned.
-
isGroupHasMember()
- Indicates whether the user is a group that has members.
-
isNoPassword()
- Indicates whether *NONE is specified for the password in the user profile.
-
isPasswordSetExpire()
- Indicates whether the user's password is set to expire,
requiring the user to change the pasword when signing on.
-
isWithDigitalCertificates()
- Indicates whether there are digital certificates associated with this user.
-
loadUserInformation()
- Loads the user information.
-
removePropertyChangeListener(PropertyChangeListener)
- Removes a property change listener.
-
removeVetoableChangeListener(VetoableChangeListener)
- Removes a vetoable change listener.
-
setName(String)
- Set the user profile name.
-
setSystem(AS400)
- Set the AS/400 system.
-
toString()
- Return the name of the user.
User
public User()
- Constructs a User object.
User
public User(AS400 system,
String userProfileName) throws AS400Exception, AS400SecurityException, ConnectionDroppedException, ErrorCompletingRequestException, InterruptedException, ObjectDoesNotExistException, IOException, UnsupportedEncodingException
- Constructs a User object.
- Parameters:
- system - The AS/400 system in which the user information resides.
- userProfileName - The user profile name.
- Throws: AS400Exception
- If the AS/400 system returns an error message.
- Throws: AS400SecurityException
- If a security or authority error occurs.
- Throws: ConnectionDroppedException
- If the connection is dropped unexpectedly.
- Throws: ErrorCompletingRequestException
- If an error occurs before the request is completed.
- Throws: InterruptedException
- If this thread is interrupted.
- Throws: IOException
- If an error occurs while communicating with the AS/400.
- Throws: ObjectDoesNotExistException
- If the AS/400 object does not exist.
- Throws: UnsupportedEncodingException
- If the character encoding is not supported.
addPropertyChangeListener
public void addPropertyChangeListener(PropertyChangeListener listener)
- Adds a listener to be notified when the value of any bound
property is changed. The propertyChange() method will be called.
- Parameters:
- listener - The property change listener.
addVetoableChangeListener
public void addVetoableChangeListener(VetoableChangeListener listener)
- Adds a listener to be notified when the value of any constrained
property is changed. The vetoableChange() method will be called.
- Parameters:
- listener - The vetoable change listener.
getAccountingCode
public String getAccountingCode()
- Returns the accounting code that is associated with this user.
- Returns:
- The accounting code that is associated with this user. If the user
does not have an accounting code, this field is blank.
getAssistanceLevel
public String getAssistanceLevel()
- Returns the user interface that the user will use.
- Returns:
- The user interface that the user will use. The possible values are:
- *SYSVAL - The system value QASTLVL determines which user interface the user is using.
- *BASIC - The Operational Assistance user interface.
- *INTERMED - The system user interface.
- *ADVANCED - The expert system user interface.
getAttentionKeyHandlingProgram
public String getAttentionKeyHandlingProgram()
- Returns the full path of the attention-key-handling program for this user.
- Returns:
- The full path of the attention-key-handling program for this user. The special values
that may be used: *SYSVAL, *NONE, or *ASSIST.
getCCSID
public int getCCSID()
- Returns the character code set identifier to be used by the system for this user.
- Returns:
- The character code set identifier to be used by the system for this user.
It can be the following special values:
- -2 - The system value QCCSID is used to determine the user's character code set identifier.
getCountryID
public String getCountryID()
- Returns the country identifier used by the system for this user.
- Returns:
- The country identifier used by the system for this user.
It can be the following special values:
- *SYSVAL - The system value QCNTRYID is used to determine the user's country identifier.
getCurrentLibraryName
public String getCurrentLibraryName()
- Returns the name of the user's current library.
- Returns:
- The name of the user's current library.
It can be the following special values:
- *CRTDFT - The user does not have have a current library.
getDaysUntilPasswordExpire
public int getDaysUntilPasswordExpire()
- Returns the number of days until the password will expire. 0 indicates that
the password is expired.
- Returns:
- The number of days until the password will expire.
getDescription
public String getDescription()
- Returns the descriptive text for the user profile.
- Returns:
- The descriptive text for the user profile.
getDisplaySignOnInformation
public String getDisplaySignOnInformation()
- Returns the value that indicates whether the sign-on information display is shown when
the user signs on.
- Returns:
- The value that indicates whether the sign-on information display is shown when
the user signs on. The possible values are:
- *SYSVAL - The system value QDSPSGNINF determines if the sign-on
information display is shown when the user signs on.
- *YES - The sign-on information display is shown when the user signs
on.
- *NO - The sign-on information display is not shown when the user
signs on.
getGroupAuthority
public String getGroupAuthority()
- Returns the authority the user's group profile has to the objects the user creates.
- Returns:
- The authority the user's group profile has to the objects the user creates.
The possible values are:
- *NONE - The group profile has no authority to the object the user creates. If the user does not have a group profile, the field contains this value.
- *ALL - The group profile has all authority to the object the user creates.
- *CHANGE - The group profile has change authority to the object the user creates.
- *USE - The group profile has use authority to the object the user creates.
- *EXCLUDE - The group profile has exclude authority to the object the user creates.
getGroupAuthorityType
public String getGroupAuthorityType()
- Returns the type of authority the user's group profile has to the objects the
user creates.
- Returns:
- The type of authority the user's group profile has to objects the user
creates. The possible values are:
- *PRIVATE - The group profile has a private authority to the objects
the user creates. If the user does not have a group profile,
return this value.
- *PGP - The group profile will be the primary group for objects the user
creates.
getGroupIDNumber
public int getGroupIDNumber()
- Returns the group identifier number for the user profile.
- Returns:
- The group identifier number for the user profile. The possible values are:
- 0 - Same as *NONE. The user does not have a group identifier.
- 1 through 4294967294 which is a valid group identifier.
getGroupProfileName
public String getGroupProfileName()
- Returns the name of the group profile. If the user does not have a group profile,
this method will return *NONE.
- Returns:
- The name of the group profile.
getHighestSchedulingPriority
public int getHighestSchedulingPriority() throws NumberFormatException
- Returns the highest scheduling priority the user is allowed to have
for each job submitted to the system.
- Returns:
- The highest scheduling priority the user is allowed. It is a number
from 0 through 9, with 0 being the highest priority.
getHomeDirectory
public String getHomeDirectory()
- Returns the home directory for this user profile. This is the user's initial working directory.
- Returns:
- The home directory for this user profile.
getInitialMenu
public String getInitialMenu()
- Returns the full path of the initial menu for the user. For example the possible return value is "*LIBL/MAIN".
- Returns:
- The full path of the initial menu for the user.
getInitialProgram
public String getInitialProgram()
- Returns the full path of the initial program for the user.
- Returns:
- The full path of the initial program for the user.
getJobDescription
public String getJobDescription()
- Returns the full path of the job description used for jobs that start through
subsystem work station entries.
- Returns:
- The full path of the job description used for jobs.
getLanguageID
public String getLanguageID()
- Returns the language identifier used by the system for this user.
- Returns:
- The language identifier used by the system for this user. It can be the
following special values:
- *SYSVAL - The system value QLANGID is used to determine
the user's language identifier.
getLimitCapabilities
public String getLimitCapabilities()
- Returns the value indicating whether the user has limited capabilities.
- Returns:
- The value indicating whether the user has limited capabilities.
The possible values are:
- *PARTIAL - The user can not change his initial program or
current library.
- *YES - The user can not change his initial menu, initial
program, or current library. The user can not run
commands from the command line.
- *NO - The user is not limited.
getLimitDeviceSessions
public String getLimitDeviceSessions()
- Returns the value indicating whether the user is limited to one device session.
- Returns:
- The value indicating whether the user is limited to one device session.
The possible values are:
- *SYSVAL - The system value QLMTDEVSSN determines if the user
is limited to one device sessins.
- *YES - The user is limited to one device sessions.
- *NO - The user is not limited to one device sessions.
getLocaleJobAttributes
public String[] getLocaleJobAttributes()
- Returns the job attributes that are taken from the user's locale path name.
- Returns:
- The job attributes that are taken from the user's locale path name.
The possible values are :
- *NONE - No job attributes are used from the locale path name at the time a job is started for this user profile.
- *SYSVAL - The job attributes assigned from the locale path name are dtermined by the system value QSETJOBATR at the time a job is started for this user profile.
- *CCSID - The coded character set identifier is set from the locale path name at the time a job is started for this user profile.
- *DATFMT - The date format is set from the locale path name at the time a job is started for this user profile.
- *DATSEP - The date separator is set from the locale path name at the time a job is started for this user profile.
- *SRTSEQ - The sort sequence is set from the locale path name at the time a job is started for this user profile
- *TIMSEP - The time separator is set from the locale path name at the time a job is started for this user profile
- *DECFMT - The decimal format is set from the locale path name at the time a job is started for this user profile
getLocalePathName
public String getLocalePathName()
- Returns the locale path name that is assigned to the user profile when a job is
started.
- Returns:
- The locale path name that is assigned to the user profile when a job is
started. The possible values are :
- *C - The C locale path name is assigned.
- *NONE - No locale path name is assigned.
- *POSIX - The POSIX locale path name is assigned.
- *SYSVAL - The QLOCALE system value is used to determine the locale path name.
getMaximumStorageAllowed
public int getMaximumStorageAllowed()
- Returns the maximum amount of auxiliary storage (in kilobytes) that can be
assigned to store permanent objects owner by the user. The value -1 is for *NOMAX.
- Returns:
- The maximum amount of auxiliary storage allowed.
getMessageQueue
public String getMessageQueue()
- Returns the full path of the message queue that is used by this user. The default message queue name is the same as the user profile name. For example, the return value of the user "QAUTPROF" is "QAUTPROF".
- Returns:
- The full path of the message queue that is used by this user.
getMessageQueueDeliveryMethod
public String getMessageQueueDeliveryMethod()
- Returns the message queue delivery method which indicates how the messages
are delivered to the message queue used by the user.
- Returns:
- The message queue delivery method. The possible values are:
- *BREAK - The job to which the message queue is assigned is interrupted
when a message arrives on the message queue.
- *DFT - Messages requiring replies are answered with their default reply.
- *HOLD - The messages are held in the message queue until they are requested
by the user or program.
- *NOTIFY - The job to which the message queue is assigned is notified
when a message arrives on the message queue.
getMessageQueueSeverity
public int getMessageQueueSeverity()
- Returns the lowest severity that a message can have and still
be delivered to a user in break or notify mode. The value ranges from 0 through 99.
- Returns:
- The lowest severity that a message can have and still be delivered to a user
in break or notify mode.
getName
public String getName()
- Returns the name of the user.
- Returns:
- The name of the user.
getObjectAuditingValue
public String getObjectAuditingValue()
- Returns the current user's object auditing value.
- Returns:
- The current user's object auditing value.
getOutputQueue
public String getOutputQueue()
- Returns the full path of the output queue used by this user.
- Returns:
- The full path of the output queue used by this user.
getOwner
public String getOwner()
- Returns the value indicating who is to own objects created by those user.
- Returns:
- The value indicating who is to own objects created by those user. The possible values are:
- *USRPRF - The user owns any objects the user creates. If the
user does not have a group profile, returns this value.
- *GRPPRF - Yhe user's profile owns any objects the user creates.
getPasswordExpireDate
public Date getPasswordExpireDate()
- Returns the date the user's password expires.
- Returns:
- The date the user's password expires.
getPasswordExpirationInterval
public int getPasswordExpirationInterval()
- Returns the number of days (from 1 through 366) the user's password can
remain active before it must be changed.
- Returns:
- The password expiration interval. It can be the following special values:
- 0 - The system value QPWDEXPITV is used to determine the user's password
expiration interval.
- -1 - The user's password does not expire(*NOMAX).
getPasswordLastChangedDate
public Date getPasswordLastChangedDate()
- Returns the date the user's password was last changed.
- Returns:
- The date the user's password was last changed.
getPreviousSignedOnDate
public Date getPreviousSignedOnDate()
- Returns the date and time the user last signed on.
- Returns:
- The date and time the user last signed on.
getPrintDevice
public String getPrintDevice()
- Returns the printer used to print for this user.
- Returns:
- The printer used to print for this user.
getSignedOnAttemptsNotValid
public int getSignedOnAttemptsNotValid()
- Returns the number of the sign-on attempts that were not valid since the
last successful sign-on.
- Returns:
- The number of the sign-on attempts that were not valid since the
last successful sign-on.
getSortSequenceTable
public String getSortSequenceTable()
- Returns the full path of the sort sequence table used for string comparisons.
- Returns:
- The full path of the sort sequence table used for string comparisons.
getSpecialAuthority
public String[] getSpecialAuthority()
- Returns the special authority of the user.
- Returns:
- The special authority of the user.
Possible values are :
- *ALLOBJ - All object. Indicates the user has all object special authority.
- *SECADM - Security administrator. Indicates the user has security administrator special authority.
- *JOBCTL - Job control. Indicates the user has job control special authority.
- *SPLCTL - Spool control. Indicates the user has spool control special authority.
- *SAVSYS - Save system. Indicates the user has save system special authority.
- *SERVICE - Service. Indicates the user has service special authority.
- *AUDIT - Audit. Indicates the user has audit special authority.
- *IOSYSCFG - Input/output system configuration. Indicates the user has input/output system configuration special authority.
getSpecialEnvironment
public String getSpecialEnvironment()
- Returns the special environment the user operates in after signing on.
- Returns:
- The special environment the user operates in after signing on.
The possible values are:
- *SYSVAL - The system value QSPCENV is used to determine
the user's special environment.
- *NONE - The user operates in the OS/400 environment.
- *S36 - The user operates in the System/400 S/36 environment.
getStatus
public String getStatus()
- Returns the status of the user profile.
- Returns:
- The status of the user profile. The possible values are:
- *ENABLED - The user profile is enabled;therefore, the user is able to
sign on.
- *DISABLED - The user profile is disabled;therefore, the user can not
sign on.
getStorageUsed
public int getStorageUsed()
- Returns the amount of auxiliary storage (in kilobytes) occupied by this user's owned
objects.
- Returns:
- The amount of auxiliary storage (in kilobytes) occupied by this user's owned
objects.
getSupplementalGroups
public String[] getSupplementalGroups()
- Returns the array of supplemental groups for the user profile.
- Returns:
- The array of supplemental groups for the user profile.
getSupplementalGroupsNumber
public int getSupplementalGroupsNumber()
- Returns the number of supplemental groups returned in the array.
- Returns:
- The number of supplemental groups returned in the array.
getSystem
public AS400 getSystem()
- Returns the AS/400 system.
- Returns:
- The AS/400 object.
getUserActionAuditLevel
public String[] getUserActionAuditLevel()
- Returns the action audit values for this user.
- Returns:
- The action audit values for this user.
The possible values are :
- *CMD - The user has the *CMD audit value specified in the user profile.
- *CREATE - The user has the *CREATE audit value specified in the user profile.
- *DELETE - The user has the *DELETE audit value specified in the user profile.
- *JOBDTA - The user has the *JOBDTA audit value specified in the user profile.
- *OBJMGT - The user has the *OBJMGT audit value specified in the user profile.
- *OFCSRV - The user has the *OFCSRV audit value specified in the user profile.
- *OPTICAL - The user has the *OPTICAL audit value specified in the user profile.
- *PGMADP - The user has the *PGMADP audit value specified in the user profile.
- *SAVRST - The user has the *SAVRST audit value specified in the user profile.
- *SECURITY - The user has the *SECURITY audit value specified in the user profile.
- *SERVICE - The user has the *SERVICE audit value specified in the user profile.
- *SPLFDTA - The user has the *SPLFDTA audit value specified in the user profile.
- *SYSMGT - The user has the *SYSMGT audit value specified in the user profile.
getUserClassName
public String getUserClassName()
- Returns the class for the user.
- Returns:
- The class for the user. The possible values are:
- *SECOFR - The user has a class of security officer.
- *SECADM - The user has a class of security administrator.
- *PGMR - The user has a class of programmer.
- *SYSOPR - The user has a class of system operator.
- *USER - The user has a class of end user.
getUserIDNumber
public int getUserIDNumber()
- Returns the user identifier number for the user profile.
- Returns:
- The user identifier number for the user profile.
getUserProfileName
public String getUserProfileName()
- Returns the name of the user profile for which the information is returned.
- Returns:
- The name of the user profile for which the information is returned.
isGroupHasMember
public boolean isGroupHasMember()
- Indicates whether the user is a group that has members.
- Returns:
- true if the user is a group that has members; false otherwise.
isNoPassword
public boolean isNoPassword()
- Indicates whether *NONE is specified for the password in the user profile.
- Returns:
- true if *NONE is specified for the password in the user profile; false otherwise.
isPasswordSetExpire
public boolean isPasswordSetExpire()
- Indicates whether the user's password is set to expire,
requiring the user to change the pasword when signing on.
- Returns:
- true if the user's password is set to expire; false otherwise.
isWithDigitalCertificates
public boolean isWithDigitalCertificates()
- Indicates whether there are digital certificates associated with this user.
- Returns:
- true if there are digital certificates associated with this user; false otherwise.
loadUserInformation
public void loadUserInformation() throws AS400Exception, AS400SecurityException, ConnectionDroppedException, ErrorCompletingRequestException, InterruptedException, ObjectDoesNotExistException, IOException, PropertyVetoException, UnsupportedEncodingException
- Loads the user information. If you have called setName() or setSystem() or both,
you should also call this method to reload the user information.
- Parameters:
- system - The AS/400 system in which the user information resides.
- userProfileName - The user profile name.
- Throws: AS400Exception
- If the AS/400 system returns an error message.
- Throws: AS400SecurityException
- If a security or authority error occurs.
- Throws: ConnectionDroppedException
- If the connection is dropped unexpectedly.
- Throws: ErrorCompletingRequestException
- If an error occurs before the request is completed.
- Throws: InterruptedException
- If this thread is interrupted.
- Throws: IOException
- If an error occurs while communicating with the AS/400.
- Throws: ObjectDoesNotExistException
- If the AS/400 object does not exist.
- Throws: PropertyVetoException
- If the change is vetoed.
- Throws: UnsupportedEncodingException
- If the character encoding is not supported.
removePropertyChangeListener
public void removePropertyChangeListener(PropertyChangeListener listener)
- Removes a property change listener.
- Parameters:
- listener - The property change listener.
- See Also:
- addPropertyChangeListener
removeVetoableChangeListener
public void removeVetoableChangeListener(VetoableChangeListener listener)
- Removes a vetoable change listener.
- Parameters:
- listener - The vetoable change listener.
- See Also:
- addVetoableChangeListener
setName
public void setName(String userProfileName)
- Set the user profile name. The AS/400 system should have been set before
calling this method.
- Parameters:
- userProfileName - The user profile name.
setSystem
public void setSystem(AS400 system) throws Exception
- Set the AS/400 system.
- Parameters:
- system - The AS/400 system.
- Throws: Exception
- If an exception occurred.
toString
public String toString()
- Return the name of the user.
- Returns:
- The name of the user.
- Overrides:
- toString in class Object
All Packages Class Hierarchy This Package Previous Next Index