com.ibm.as400.access

Class User

  • java.lang.Object
    • com.ibm.as400.access.User
  • All Implemented Interfaces:
    java.io.Serializable
    Direct Known Subclasses:
    UserGroup


    public class User
    extends java.lang.Object
    implements java.io.Serializable
    Represents a user profile object on the system.

    Note: User attribute information is cached internally in the User object, after the first retrieval. To force an update of the cached information, call refresh().

    Note: Calling any of the attribute getters for the first time (for a given User instance) will result in an implicit call to refresh(). If any exceptions are thrown by the implicit refresh(), they are logged under trace category Trace.ERROR and ignored. However, if an exception occurs during an explicit call to refresh(), it will be thrown to the caller.

    Implementation note: This class internally calls the Retrieve User Information (QSYRUSRI) API for the methods that retrieve user profile information. In order to use those methods, the caller must have *READ authority to the user profile object. This class internally calls the Change User Profile (CHGUSRPRF) command for the methods that change user profile information. In order to use those methods, the caller must have security administrator (*SECADM) special authority, and object management (*OBJMGT) and use (*USE) authorities to the user profile being changed.

    See Also:
    DirectoryEntry, UserList, UserGroup, Serialized Form
    • Constructor Summary

      Constructors 
      Constructor and Description
      User()
      Constructs a User object.
      User(AS400 system, java.lang.String name)
      Constructs a User object.
    • Method Summary

      Methods 
      Modifier and Type Method and Description
      void addPropertyChangeListener(java.beans.PropertyChangeListener listener)
      Adds a PropertyChangeListener.
      void addVetoableChangeListener(java.beans.VetoableChangeListener listener)
      Adds a VetoableChangeListener.
      boolean exists()
      Determines if this user profile exists on the system.
      java.lang.String getAccountingCode()
      Retrieves the accounting code that is associated with this user.
      java.lang.String getAssistanceLevel()
      Retrieves the user interface that the user will use.
      java.lang.String getAttentionKeyHandlingProgram()
      Retrieves the attention key handling program for this user.
      int getCCSID()
      Retrieves the character code set ID to be used by the system for this user.
      java.lang.String getCHRIDControl()
      Retrieves the character identifier control for the user.
      java.lang.String getCountryID()
      Retrieves the country or region ID used by the system for this user.
      java.lang.String getCurrentLibraryName()
      Retrieves the name of the user's current library.
      int getDaysUntilPasswordExpire()
      Retrieves the number of days until the password will expire.
      java.lang.String getDescription()
      Retrieves the descriptive text for the user profile.
      java.lang.String getDetailInSTRAUTCOL() 
      DirectoryEntry getDirectoryEntry()
      Retrieves the system distribution directory entry for the user profile, if one exists.
      java.lang.String getDisplaySignOnInformation()
      Retrieves whether the sign-on information display is shown when the user signs on.
      java.lang.String[] getDLOObjectTypesInSTRAUTCOL() 
      java.lang.String[] getFileSystemObjectTypesInSTRAUTCOL() 
      java.lang.String getGroupAuthority()
      Retrieves the authority the user's group profile has to objects the user creates.
      java.lang.String getGroupAuthorityType()
      Retrieves the type of authority the user's group has to objects the user creates.
      long getGroupID()
      Retrieves the group ID number for the user profile.
      int getGroupIDNumber()
      Deprecated. 
      This method has been replaced by getGroupID() which returns a long.
      java.lang.String getGroupProfileName()
      Retrieves the name of the group profile.
      int getHighestSchedulingPriority()
      Retrieves the highest scheduling priority the user is allowed to have for each job submitted to the system.
      java.lang.String getHomeDirectory()
      Retrieves the home directory for this user profile.
      java.lang.String[] getIASPNames()
      Retrieves the list of independent auxiliary storage pool (IASP) names in use by this user.
      int getIASPStorageAllowed(java.lang.String iaspName)
      Retrieves the maximum amount of auxiliary storage in kilobytes that can be assigned to store permanent object owned by this user on the given independant ASP.
      int getIASPStorageUsed(java.lang.String iaspName)
      Retrieves the amount of auxiliary storage in kilobytes occupied by this user's owned objects on the given independent ASP.
      java.lang.String getInitialMenu()
      Retrieves the initial menu for the user.
      java.lang.String getInitialProgram()
      Retrieves the initial program for the user.
      java.lang.String getJobDescription()
      Retrieves the fully qualified integrated file system path name of the job description used for jobs that start through subsystem work station entries.
      java.lang.String getKeyboardBuffering()
      Retrieves the keyboard buffering value that is used when a job is initialized for this user.
      java.lang.String getLanguageID()
      Retrieves the language ID used by the system for this user.
      java.lang.String[] getLibNameInSTRAUTCOL() 
      java.lang.String getLimitCapabilities()
      Retrieves whether the user has limited capabilites.
      java.lang.String getLimitDeviceSessions()
      Retrieves whether the user is limited to one device session.
      java.lang.String[] getLocaleJobAttributes()
      Retrieves a list of the job attributes which are set from the user's locale path name.
      java.lang.String getLocalePathName()
      Retrieves the locale path name that is assigned to the user profile when a job is started.
      int getMaximumStorageAllowed()
      Retrieves the maximum amount of auxiliary storage (in kilobytes) that can be assigned to store permanant objects owned by the user.
      long getMaximumStorageAllowedInLong() 
      java.lang.String getMessageQueue()
      Retrieves the fully qualified integrated file system path name of the message queue that is used by this user.
      java.lang.String getMessageQueueDeliveryMethod()
      Retrieves how the messages are delivered to the message queue used by the user.
      int getMessageQueueSeverity()
      Retrieves the lowest severity that a message can have and still be delivered to a user in break or notify mode.
      java.lang.String getName()
      Returns the user profile name.
      java.lang.String getObjectAuditingValue()
      Retrieves the user's object auditing value.
      java.lang.String[] getObjectNamesInSTRAUTCOL() 
      UserObjectsOwnedList getObjectsOwned()
      Return an object representing the objects that this user owns.
      java.lang.String[] getObjectTypesInSTRAUTCOL() 
      java.lang.String[] getOmitLibNamesInSTRAUTCOL() 
      java.lang.String getOutputQueue()
      Retrieves the output queue used by this user.
      java.lang.String getOwner()
      Retrieves who is to own objects created by this user.
      java.lang.String getPasswordChangeBlock()
      Retrieves the time period during which a password is blocked from being changed following the prior successful password change operation.
      int getPasswordExpirationInterval()
      Retrieves the number of days the user's password can remain active before it must be changed.
      java.util.Date getPasswordExpireDate()
      Retrieves the date the user's password expires.
      java.util.Date getPasswordLastChangedDate()
      Retrieves the date the user's password was last changed.
      java.util.Date getPreviousSignedOnDate()
      Retrieves the date and time the user last signed on.
      java.lang.String getPrintDevice()
      Retrieves the printer used to print for this user.
      int getSignedOnAttemptsNotValid()
      Retrieves the number of sign-on attempts that were not valid since the last successful sign-on.
      java.lang.String getSortSequenceTable()
      Retrieves the name of the sort sequence table used for string comparisons.
      java.lang.String[] getSpecialAuthority()
      Retrieves a list of the special authorities the user has.
      java.lang.String getSpecialEnvironment()
      Retrieves the special environment the user operates in after signing on.
      java.lang.String getStatus()
      Retrieves the status of the user profile.
      int getStorageUsed()
      Retrieves the amount of auxiliary storage (in kilobytes) occupied by this user's owned objects.
      long getStorageUsedInLong()
      Retrieves the amount of auxiliary storage (in kilobytes) occupied by this user's owned objects.
      java.lang.String[] getSupplementalGroups()
      Retrieves the supplemental groups for the user profile.
      int getSupplementalGroupsNumber()
      Retrieves the number of supplemental groups for the user profile.
      AS400 getSystem()
      Returns the system object representing the system on which the user profile exists.
      java.lang.String[] getUserActionAuditLevel()
      Retrieves a list of action audit levels for the user.
      java.lang.String getUserClassName()
      Retrieves the user class name.
      java.lang.String getUserExpirationAction()
      Retrieves the action that will occur when the user profile has expired.
      java.util.Date getUserExpirationDate()
      Retrieves the date when the user profile expires and is automatically disabled.
      int getUserExpirationInterval()
      Retrieves the number of days before the user profile is automatically disabled.
      long getUserID()
      Retrieves the user ID (UID) number for the user profile.
      int getUserIDNumber()
      Deprecated. 
      This method has been replaced by getUserID() which returns a long.
      java.lang.String[] getUserOptions()
      Retrieves a list of options for users to customize their environment.
      java.lang.String getUserProfileName()
      Retrieves the name of the user profile for which the information is returned.
      boolean hasSpecialAuthority(java.lang.String authority)
      Retrieves if this user profile has been granted the specified authority, or belongs to a group profile that has been granted the specified authority.
      boolean isAuthCollectionActive() 
      boolean isAuthCollectionDeleted() 
      boolean isAuthCollectionRepositoryExist() 
      boolean isGroupHasMember()
      Retrieves whether this user is a group that has members.
      boolean isLocalPasswordManagement()
      Retrieves whether the password is managed locally.
      boolean isNoPassword()
      Retrieves whether *NONE is specified for the password in the user profile.
      boolean isPasswordSetExpire()
      Retrieves whether the user's password is set to expired, requiring the user to change the password when signing on.
      boolean isUserEntitlementRequired()
      Retrieves whether a user entitlement is required for this user profile.
      boolean isWithDigitalCertificates()
      Retrieves whether there are digital certificates associated with this user.
      void loadUserInformation()
      Refreshes the values for all attributes.
      void refresh()
      Refreshes all the attribute values for this User object by retrieving them from the system.
      void removePropertyChangeListener(java.beans.PropertyChangeListener listener)
      Removes the PropertyChangeListener.
      void removeVetoableChangeListener(java.beans.VetoableChangeListener listener)
      Removes the VetoableChangeListener.
      void setAccountingCode(java.lang.String accountingCode)
      Sets the accounting code that is associated with this user profile.
      void setAssistanceLevel(java.lang.String assistanceLevel)
      Sets which user interface to use.
      void setAttentionKeyHandlingProgram(java.lang.String attentionKeyHandlingProgram)
      Sets the program to be used as the Attention (ATTN) key handling program for this user.
      void setCCSID(int ccsid)
      Sets the character code set identifier (CCSID) to be used for this user.
      void setCCSID(java.lang.String ccsid)
      Sets the character code set identifier (CCSID) to be used for this user.
      void setCHRIDControl(java.lang.String chridControl)
      Sets the character identifier control (CHRIDCTL) for the job.
      void setCountryID(java.lang.String countryID)
      Sets the country or region identifier to be used for this user.
      void setCurrentLibraryName(java.lang.String currentLibraryName)
      Sets the name of the current library associated with the job being run.
      void setDescription(java.lang.String description)
      Sets the text that briefly describes the object.
      void setDisplaySignOnInformation(java.lang.String displaySignOnInformation)
      Sets whether the sign-on information display is shown.
      void setGroupAuthority(java.lang.String groupAuthority)
      Sets the specific authority given to the group profile for newly created objects.
      void setGroupAuthorityType(java.lang.String groupAuthorityType)
      Sets the type of authority to be granted to the group profile for newly-created objects.
      void setGroupID(long groupID)
      Sets the group ID number (gid number) for this user profile.
      void setGroupID(java.lang.String groupID)
      Sets the group ID number (gid number) for this user profile.
      void setGroupProfileName(java.lang.String groupProfileName)
      Sets the user's group profile name whose authority is used if no specific authority is given for the user.
      void setHighestSchedulingPriority(int highestSchedulingPriority)
      Sets the highest scheduling priority the user is allowed to have for each job submitted to the system.
      void setHomeDirectory(java.lang.String homeDirectory)
      Sets the path name of the home directory for this user profile.
      void setInitialMenu(java.lang.String initialMenu)
      Sets the initial menu displayed when the user signs on the system if the user's routing program is the command processor.
      void setInitialProgram(java.lang.String initialProgram)
      Sets, for an interactive job, the program called whenever a new routing step is started that has QCMD as the request processing program.
      void setJobDescription(java.lang.String jobDescription)
      Sets the fully qualified integrated file system path name of the job description used for jobs that start through subsystem work station entries.
      void setKeyboardBuffering(java.lang.String keyboardBuffering)
      Sets the keyboard buffering value to be used when a job is initialized for this user profile.
      void setLanguageID(java.lang.String languageID)
      Sets the language ID to be used for this user.
      void setLimitCapabilities(java.lang.String limitCapabilities)
      Sets the limit to which the user can control the program, menu, current library, and the ATTN key handling program values.
      void setLimitDeviceSessions(java.lang.String limitDeviceSessions)
      Sets if the number of device sessions allowed for a user is limited to 1.
      void setLocaleJobAttributes(java.lang.String[] localeJobAttributes)
      Sets which job attributes are to be taken from the locale specified for the Locale (LOCALE) parameter when the job is initiated.
      void setLocalePathName(java.lang.String localePathName)
      Sets the path name of the locale that is assigned to LANG environment variable for this user.
      void setLocalPasswordManagement(boolean localPasswordManagement)
      Sets whether the user profile password should be managed locally.
      void setMaximumStorageAllowed(int maximumStorageAllowed)
      Sets the maximum amount of auxiliary storage (in kilobytes) assigned to store permanant objects owned by this user profile (1 kilobyte equals 1024 bytes).
      void setMaximumStorageAllowed(java.lang.String maximumStorageAllowed)
      Sets the maximum amount of auxiliary storage (in kilobytes) assigned to store permanant objects owned by this user profile (1 kilobyte equals 1024 bytes).
      void setMessageQueue(java.lang.String messageQueue)
      Sets the message queue to which messages are sent.
      void setMessageQueueDeliveryMethod(java.lang.String messageQueueDeliveryMethod)
      Sets how the messages are sent to the message queue for this user are to be delivered.
      void setMessageQueueSeverity(int messageQueueSeverity)
      Sets the lowest severity code that a message can have and still be delivered to a user in break or notify mode.
      void setName(java.lang.String name)
      Sets the user profile name.
      void setObjectAuditingValue(java.lang.String objectAuditingValue)
      Sets the object auditing value for the user.
      void setOutputQueue(java.lang.String outputQueue)
      Sets the output queue to be used by this user profile.
      void setOwner(java.lang.String owner)
      Sets the user profile that is to be the owner of objects created by this user.
      void setPasswordChangeBlock(java.lang.String pwdChangeBlock)
      Sets the time period during which a password is blocked from being changed following the prior successful password change operation.
      void setPasswordExpirationInterval(int passwordExpirationInterval)
      Sets the password expiration interval (in days).
      void setPasswordExpirationInterval(java.lang.String passwordExpirationInterval)
      Sets the password expiration interval (in days).
      void setPasswordSetExpire(boolean passwordSetExpire)
      Sets whether the password for this user is set to expired.
      void setPrintDevice(java.lang.String printDevice)
      Sets the default printer device for this user.
      void setSortSequenceTable(java.lang.String sortSequenceTable)
      Sets the sort sequence table to be used for string comparisons for this profile.
      void setSpecialAuthority(java.lang.String[] specialAuthority)
      Sets the special authorities given to a user.
      void setSpecialEnvironment(java.lang.String specialEnvironment)
      Sets the special environment in which the user operates after signing on.
      void setStatus(java.lang.String status)
      Sets the status of the user profile.
      void setSupplementalGroups(java.lang.String[] supplementalGroups)
      Sets the user's supplemental group profiles.
      void setSystem(AS400 system)
      Sets the system object representing the system on which the user profile exists.
      void setUserActionAuditLevel(java.lang.String[] userActionAuditLevel)
      Sets the level of activity that is audited for this user profile.
      void setUserClassName(java.lang.String userClassName)
      Sets the type of user associated with this user profile: security officer, security administrator, programmer, system operator, or user.
      void setUserExpirationDate(java.util.Date expirationDate)
      Sets the date when the user profile expires and is automatically disabled.
      void setUserExpirationInterval(int expirationInterval)
      Sets the expiration interval (in days) before the user profile is automatically disabled.
      void setUserID(long userID)
      Sets the user ID number (uid number) for this user profile.
      void setUserOptions(java.lang.String[] userOptions)
      Sets the level of help information detail to be shown and the function of the Page Up and Page Down keys by default.
      java.lang.String toString()
      Sets the string representation of this User object.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • User

        public User()
        Constructs a User object.
      • User

        public User(AS400 system,
            java.lang.String name)
             throws AS400SecurityException,
                    ErrorCompletingRequestException,
                    java.lang.InterruptedException,
                    java.io.IOException,
                    ObjectDoesNotExistException
        Constructs a User object. Note that this constructor no longer throws any of the declared exceptions, but they remain for compatibility.
        Parameters:
        system - The system object representing the system on which the user profile exists.
        name - The user profile name.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        ObjectDoesNotExistException - If the object does not exist on the system.
    • Method Detail

      • addPropertyChangeListener

        public void addPropertyChangeListener(java.beans.PropertyChangeListener listener)
        Adds a PropertyChangeListener. The specified PropertyChangeListener's propertyChange() method will be called each time the value of any bound property is changed.
        Parameters:
        listener - The listener.
        See Also:
        removePropertyChangeListener(java.beans.PropertyChangeListener)
      • addVetoableChangeListener

        public void addVetoableChangeListener(java.beans.VetoableChangeListener listener)
        Adds a VetoableChangeListener. The specified VetoableChangeListener's vetoableChange() method will be called each time the value of any constrained property is changed.
        Parameters:
        listener - The listener.
        See Also:
        removeVetoableChangeListener(java.beans.VetoableChangeListener)
      • exists

        public boolean exists()
                       throws AS400SecurityException,
                              ErrorCompletingRequestException,
                              java.lang.InterruptedException,
                              java.io.IOException,
                              ObjectDoesNotExistException
        Determines if this user profile exists on the system. This method simply calls the CHKOBJ API and if no exception is thrown, the user profile exists; if a CPF9801 occurs then the user profile does not exist. Any other exceptions are still thrown.

        The value returned by this method is not cached. That is, every time exists() is called, a call to the system is made to determine if the user profile still exists.

        Returns:
        true if the profile exists, false if it does not.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        ObjectDoesNotExistException - If the object does not exist on the system.
      • getAccountingCode

        public java.lang.String getAccountingCode()
        Retrieves 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, an empty string ("") is returned.
        See Also:
        setAccountingCode(java.lang.String)
      • getAssistanceLevel

        public java.lang.String getAssistanceLevel()
        Retrieves the user interface that the user will use.
        Returns:
        The user interface that the user will use. Possible values are:
        • "*SYSVAL" - The system value QASTLVL determines which user interface the user is using.
        • "*BASIC" - The Operational Assistant user interface.
        • "*INTERMED" - The system user interface.
        • "*ADVANCED" - The expert system user interface.
      • getAttentionKeyHandlingProgram

        public java.lang.String getAttentionKeyHandlingProgram()
        Retrieves the attention key handling program for this user.
        Returns:
        The attention key handling program for this user. Possible values are:
        • "*SYSVAL" - The system value QATNPGM determines the user's attention key handling program.
        • NONE - No attention key handling program is used.
        • The fully qualified integrated file system path name of the attention key handling program.
        See Also:
        QSYSObjectPathName
      • getCCSID

        public int getCCSID()
        Retrieves the character code set ID to be used by the system for this user.
        Returns:
        The character code set ID to be used by the system for this user. Possible values are:
        • -2 - The system value QCCSID is used to determine the user's character code set ID.
        • A character code set ID.
      • getCHRIDControl

        public java.lang.String getCHRIDControl()
        Retrieves the character identifier control for the user.
        Returns:
        The character identifier control for this user. Possible values are:
        • "*SYSVAL" - The system value QCHRIDCTL will be used to determine the CHRID control for this user.
        • "*DEVD" - The *DEVD special value performs the same function as on the CHRID command parameter for display files, printer files, and panel groups.
        • "*JOBCCSID" - The *JOBCCSID special value performs the same function as on the CHRID command parameter for display files, printer files, and panel groups.
        See Also:
        setCHRIDControl(java.lang.String)
      • getCountryID

        public java.lang.String getCountryID()
        Retrieves the country or region ID used by the system for this user.
        Returns:
        The country or region ID used by the system for this user. Possible values are:
        • "*SYSVAL" - The system value QCNTRYID is used to determine the user's country or region ID.
        • A country or region ID.
        See Also:
        setCountryID(java.lang.String)
      • getCurrentLibraryName

        public java.lang.String getCurrentLibraryName()
        Retrieves the name of the user's current library.
        Returns:
        The name of the user's current library. Possible values are:
        • "*CRTDFT" - The user does not have a current library.
        • A library name.
        See Also:
        setCurrentLibraryName(java.lang.String)
      • getDaysUntilPasswordExpire

        public int getDaysUntilPasswordExpire()
        Retrieves the number of days until the password will expire.
        Returns:
        The number of days until the password will expire. Possible values are:
        • 0 - The password is expired.
        • 1-7 - The number of days until the password expires.
        • -1 - The password will not expire in the next 7 days.
      • getDescription

        public java.lang.String getDescription()
        Retrieves the descriptive text for the user profile. This value is pre-loaded into any User objects generated from a UserList object so that a call to the system is not required to retrieve this value. In the event that this User object was not constructed by a UserList, the description will need to be retrieved from the system via an implicit call to refresh().
        Returns:
        The descriptive text for the user profile.
        See Also:
        setDescription(java.lang.String)
      • getDisplaySignOnInformation

        public java.lang.String getDisplaySignOnInformation()
        Retrieves whether the sign-on information display is shown when the user signs on.
        Returns:
        Whether the sign-on information display is shown when the user signs on. 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.
        See Also:
        setDisplaySignOnInformation(java.lang.String)
      • getGroupAuthority

        public java.lang.String getGroupAuthority()
        Retrieves the authority the user's group profile has to objects the user creates.
        Returns:
        The authority the user's group profile has to objects the user creates. Possible values are:
        • NONE - The group profile has no authority to the objects the user creates, or the user does not have a group profile.
        • "*ALL" - The group profile has all authority to the objects the user creates.
        • "*CHANGE" - The group profile has change authority to the objects the user creates.
        • "*USE" - The group profile has use authority to the objects the user creates.
        • "*EXCLUDE" - The group profile has exclude authority to the objects the user creates.
        See Also:
        setGroupAuthority(java.lang.String)
      • getGroupAuthorityType

        public java.lang.String getGroupAuthorityType()
        Retrieves the type of authority the user's group has to objects the user creates.
        Returns:
        The type of authority the user's group has to objects the user creates. Possible values are:
        • "*PRIVATE" - The group profile has a private authority to the objects the user creates, or the user does not have a group profile.
        • "*PGP" - The group profile will be the primary group for objects the user creates.
        See Also:
        setGroupAuthorityType(java.lang.String)
      • getGroupID

        public long getGroupID()
        Retrieves the group ID number for the user profile. The group ID number is used to identify the user when it is a group and a member of the group is using the integrated file system.
        Returns:
        The group ID number for the user profile. Possible values are:
        • 0 - user does not have a group ID (*NONE).
        • A GID.
        See Also:
        setGroupID(long), setGroupID(String)
      • getGroupIDNumber

        public int getGroupIDNumber()
        Deprecated. This method has been replaced by getGroupID() which returns a long.
        Retrieves the group ID number for the user profile. The group ID number is used to identify the user when it is a group and a member of the group is using the integrated file system.
        Returns:
        The group ID number for the user profile. Possible values are:
        • 0 - user does not have a group ID (*NONE).
        • A GID.
      • getGroupProfileName

        public java.lang.String getGroupProfileName()
        Retrieves the name of the group profile.
        Returns:
        The name of the group profile. Possible values are:
        • NONE - The user does not have a group profile.
        • The group profile name.
        See Also:
        setGroupProfileName(java.lang.String)
      • getHighestSchedulingPriority

        public int getHighestSchedulingPriority()
        Retrieves 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 to have for each job submitted to the system. The priority is a value from 0 to 9, with 0 being the highest priority.
        See Also:
        setHighestSchedulingPriority(int)
      • getHomeDirectory

        public java.lang.String getHomeDirectory()
        Retrieves the home directory for this user profile. The home directory is the user's initial working directory. The working directory, associated with a process, is used in path name resolution in the directory file system for path names that do not begin with a slash (/).
        Returns:
        The home directory for this user profile.
        See Also:
        setHomeDirectory(java.lang.String)
      • getIASPStorageAllowed

        public int getIASPStorageAllowed(java.lang.String iaspName)
        Retrieves the maximum amount of auxiliary storage in kilobytes that can be assigned to store permanent object owned by this user on the given independant ASP.
        Parameters:
        iaspName -
        Returns:
        The maximum amount of auxiliary storage in kilobytes that can be assigned to store permanent object owned by this user on the given independant ASP. If the user does not have a maximum amount of allowed storage on the given independent ASP, -1 for *NOMAX is returned. If the system operating system is not release V5R1M0 or higher, or if the given IASP name is not listed for this user, -2 is returned.
        See Also:
        getIASPNames(), getIASPStorageUsed(java.lang.String)
      • getIASPStorageUsed

        public int getIASPStorageUsed(java.lang.String iaspName)
        Retrieves the amount of auxiliary storage in kilobytes occupied by this user's owned objects on the given independent ASP.
        Parameters:
        iaspName -
        Returns:
        The amount of auxiliary storage in kilobytes occupied by this user's owned objects on the given independent ASP. If the system operating system is not release V5R1M0 or higher, or if the given IASP name is not listed for this user, -2 is returned.
        See Also:
        getIASPNames(), getIASPStorageAllowed(java.lang.String)
      • getInitialMenu

        public java.lang.String getInitialMenu()
        Retrieves the initial menu for the user.
        Returns:
        The initial menu for the user. Possible values are:
        • "*SIGNOFF" - The user is limited to running the initial program specified in this profile.
        • The fully qualified integrated file system path name of the initial menu name.
        See Also:
        QSYSObjectPathName, setInitialMenu(java.lang.String)
      • getInitialProgram

        public java.lang.String getInitialProgram()
        Retrieves the initial program for the user.
        Returns:
        The initial program for the user. Possible values are:
        • NONE - The user does not have an initial program.
        • The fully qualified integrated file system path name of the initial program name.
        See Also:
        QSYSObjectPathName, setInitialProgram(java.lang.String)
      • getJobDescription

        public java.lang.String getJobDescription()
        Retrieves the fully qualified integrated file system path name of the job description used for jobs that start through subsystem work station entries.
        Returns:
        The fully qualified integrated file system path name of the job description used for jobs that start through subsystem work station entries.
        See Also:
        QSYSObjectPathName, setJobDescription(java.lang.String)
      • getKeyboardBuffering

        public java.lang.String getKeyboardBuffering()
        Retrieves the keyboard buffering value that is used when a job is initialized for this user.
        Returns:
        The keyboard buffering value that is used when a job is initialized for this user. Possible values are:
        • "*SYSVAL" - The system value QKBDBUF determines the keyboard buffering value for this user.
        • "*YES" - The type-ahead and attention-key buffering options are both on.
        • "*NO" - The type-ahead and attention-key buffering options are not on.
        • "*TYPEAHEAD" - The type-ahead option is on, but the attention-key buffering option is not.
        See Also:
        setKeyboardBuffering(java.lang.String)
      • getLanguageID

        public java.lang.String getLanguageID()
        Retrieves the language ID used by the system for this user.
        Returns:
        The language ID used by the system for this user. Possible values are:
        • "*SYSVAL" - The system value QLANGID will be used to determine the language ID.
        • The language ID.
        See Also:
        setLanguageID(java.lang.String)
      • getLimitCapabilities

        public java.lang.String getLimitCapabilities()
        Retrieves whether the user has limited capabilites.
        Returns:
        Whether the user has limited capabilites. Possible values are:
        • "*PARTIAL" - The user cannot change the initial program or current library.
        • "*YES" - The user cannot change the initial menu, initial program, or current library. The user cannot run commands from the command line.
        • "*NO" - The user is not limited.
        See Also:
        setLimitCapabilities(java.lang.String)
      • getLimitDeviceSessions

        public java.lang.String getLimitDeviceSessions()
        Retrieves whether the user is limited to one device session. Note: Values "0-9" are only valid when running to IBM i 6.1 or higher.
        Returns:
        Whether the user is limited to one device session. Possible values are:
        • "*SYSVAL" - The system value QLMTDEVSSN determines if the user is limited to one device session.
        • "*YES" - The user is limited to one session.
        • "*NO" - The user is not limited to one device session.
        • "0" - The user is not limited to a specific number of device session. The value has the same meaning as *NO.
        • "1" - The user is limited to a single device session. The value has the same meaning as *YES.
        • "2-9" - The user is limited to the specified number of device sessions.
        See Also:
        setLimitDeviceSessions(java.lang.String)
      • getLocaleJobAttributes

        public java.lang.String[] getLocaleJobAttributes()
        Retrieves a list of the job attributes which are set from the user's locale path name.
        Returns:
        A list of the job attributes which are set from the user's locale path name. Possible values for the elements of this array 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 determined 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.
        See Also:
        setLocaleJobAttributes(java.lang.String[])
      • getLocalePathName

        public java.lang.String getLocalePathName()
        Retrieves 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. 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.
        • A locale path name.
        See Also:
        setLocalePathName(java.lang.String)
      • getMaximumStorageAllowed

        public int getMaximumStorageAllowed()
        Retrieves the maximum amount of auxiliary storage (in kilobytes) that can be assigned to store permanant objects owned by the user.
        Returns:
        The maximum amount of auxiliary storage (in kilobytes) that can be assigned to store permanant objects owned by the user. Possible values are:
        • -1 - The user does not have a maximum amount of allowed storage (*NOMAX).
        • -2 - The maximum amount cannot be represent in an int value.
        • The maximum amount of auxiliary storage (in kilobytes).
        See Also:
        setMaximumStorageAllowed(int), setMaximumStorageAllowed(String)
      • getMaximumStorageAllowedInLong

        public long getMaximumStorageAllowedInLong()
      • getMessageQueue

        public java.lang.String getMessageQueue()
        Retrieves the fully qualified integrated file system path name of the message queue that is used by this user.
        Returns:
        The fully qualified integrated file system path name of the message queue that is used by this user.
        See Also:
        QSYSObjectPathName, setMessageQueue(java.lang.String)
      • getMessageQueueDeliveryMethod

        public java.lang.String getMessageQueueDeliveryMethod()
        Retrieves how the messages are delivered to the message queue used by the user.
        Returns:
        How the messages are delivered to the message queue used by the user. 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.
        See Also:
        setMessageQueueDeliveryMethod(java.lang.String)
      • getMessageQueueSeverity

        public int getMessageQueueSeverity()
        Retrieves the lowest severity that a message can have and still be delivered to a user in break or notify mode.
        Returns:
        The lowest severity that a message can have and still be delivered to a user in break or notify mode. The severity is a value in the range 0 through 99.
        See Also:
        setMessageQueueSeverity(int)
      • getName

        public java.lang.String getName()
        Returns the user profile name.
        Returns:
        The user profile name.
        See Also:
        setName(java.lang.String)
      • getObjectAuditingValue

        public java.lang.String getObjectAuditingValue()
        Retrieves the user's object auditing value.
        Returns:
        The user's object auditing value. Possible values are:
        • NONE - No additional object auditing is done for the user.
        • "*CHANGE" - Object changes are audited for the user if the object's auditing value is *USRPRF.
        • "*ALL" - Object read and change operations are audited for the user if the object's auditing value is *USRPRF.
        See Also:
        setObjectAuditingValue(java.lang.String)
      • getObjectsOwned

        public UserObjectsOwnedList getObjectsOwned()
        Return an object representing the objects that this user owns.
        Returns:
        UserObjectsOwnedList object constructed with default selection criteria.
      • getOutputQueue

        public java.lang.String getOutputQueue()
        Retrieves the output queue used by this user.
        Returns:
        The output queue used by this user. Possible values are:
        • "*WRKSTN" - The output queue assigned to the user's work station is used.
        • "*DEV" - An output queue with the same name as the device specified in the printer device parameter is used.
        • The fully qualified integrated file system path name of the output queue.
        See Also:
        QSYSObjectPathName, setOutputQueue(java.lang.String)
      • getOwner

        public java.lang.String getOwner()
        Retrieves who is to own objects created by this user.
        Returns:
        Who is to own objects created by this user. Possible values are:
        • "*USRPRF" - The user owns any objects the user creates. If the user does not have a group profile, the field contains this value.
        • "*GRPPRF" - The user's group profile owns any objects the user creates.
        See Also:
        setOwner(java.lang.String)
      • getPasswordExpireDate

        public java.util.Date getPasswordExpireDate()
        Retrieves the date the user's password expires.
        Returns:
        The date the user's password expires. Possible values are:
        • A date object containing the date the user's password expires.
        • null - The user's password will not expire (password expiration interval of *NOMAX) or the user's password is set to expired.
      • getPasswordChangeBlock

        public java.lang.String getPasswordChangeBlock()
        Retrieves the time period during which a password is blocked from being changed following the prior successful password change operation.

        Note: This method should not be used when running to IBM i 5.4 or earlier releases.

        Returns:
        The time period during which a password is blocked from being changed. Possible values are:
        • "*SYSVAL" - The system value QPWDCHGBLK is used to determine the block password change value.
        • NONE - The password can be changed at any time.
        • 1-99 - Indicates the number of hours a user must wait after the prior successful password change operation before they are able to change the password again.
        See Also:
        setPasswordChangeBlock(java.lang.String)
      • getPasswordExpirationInterval

        public int getPasswordExpirationInterval()
        Retrieves the number of days the user's password can remain active before it must be changed.
        Returns:
        The number of days the user's password can remain active before it must be changed. Possible values are:
        • 0 - The system value QPWDEXPITV is used to determine the user's password expiration interval.
        • -1 - The user's password does not expire (*NOMAX).
        • 1-366 - The number of days the user's password can remain active before it must be changed.
        See Also:
        setPasswordExpirationInterval(int), setPasswordExpirationInterval(String)
      • getPasswordLastChangedDate

        public java.util.Date getPasswordLastChangedDate()
        Retrieves the date the user's password was last changed.
        Returns:
        The date the user's password was last changed.
      • getPreviousSignedOnDate

        public java.util.Date getPreviousSignedOnDate()
        Retrieves the date and time the user last signed on.
        Returns:
        The date and time the user last signed on. Possible values are:
        • A date object containing the date and time the user last signed on.
        • null - The user has never signed on the system.
      • getPrintDevice

        public java.lang.String getPrintDevice()
        Retrieves the printer used to print for this user.
        Returns:
        The printer used to print for this user. Possible values are:
        • "*WRKSTN" - The printer assigned to the user's work station is used.
        • "*SYSVAL" - The default system printer specified in the system value QPRTDEV is used.
        • The print device.
        See Also:
        setPrintDevice(java.lang.String)
      • getSignedOnAttemptsNotValid

        public int getSignedOnAttemptsNotValid()
        Retrieves the number of sign-on attempts that were not valid since the last successful sign-on.
        Returns:
        The number of sign-on attempts that were not valid since the last successful sign-on.
      • getSortSequenceTable

        public java.lang.String getSortSequenceTable()
        Retrieves the name of the sort sequence table used for string comparisons.
        Returns:
        The name of the sort sequence table used for string comparisons. Possible values are:
        • "*HEX" - The hexadecimal values of the characters are used to determine the sort sequence.
        • "*LANGIDUNQ" - A unique-weight sort table associated with the language specified.
        • "*LANGIDSHR" - A shared-weight sort table associated with the language specified.
        • "*SYSVAL" - The system value QSRTSEQ.
        • The fully qualified integrated file system path name of the sort sequence table name.
        See Also:
        QSYSObjectPathName, setSortSequenceTable(java.lang.String)
      • getSpecialEnvironment

        public java.lang.String getSpecialEnvironment()
        Retrieves the special environment the user operates in after signing on.
        Returns:
        The special environment the user operates in after signing on. Possible values are:
        • "*SYSVAL" - The system value QSPCENV is used to determine the user's special environment.
        • NONE - The user operates in the IBM i system environment.
        • "*S36" - The user operates in the System/36 environment.
        See Also:
        setSpecialEnvironment(java.lang.String)
      • getStatus

        public java.lang.String getStatus()
        Retrieves the status of the user profile.
        Returns:
        The status of the user profile. Possible values are:
        • "*ENABLED" - The user profile is enabled; therefor, the user is able to sign on.
        • "*DISABLED" - The user profile is not enabled; therefor, the user cannot sign on.
        See Also:
        setStatus(java.lang.String)
      • getStorageUsed

        public int getStorageUsed()
        Retrieves 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.
      • getStorageUsedInLong

        public long getStorageUsedInLong()
        Retrieves 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 java.lang.String[] getSupplementalGroups()
        Retrieves the supplemental groups for the user profile.
        Returns:
        The array of supplemental groups for the user profile, or an array of length 0 if there are no supplemental groups.
        See Also:
        setSupplementalGroups(java.lang.String[])
      • getSupplementalGroupsNumber

        public int getSupplementalGroupsNumber()
        Retrieves the number of supplemental groups for the user profile.

        This method simply returns getSupplementalGroups().length.

        Returns:
        The number of supplemental groups for the user profile.
        See Also:
        getSupplementalGroups()
      • getSystem

        public AS400 getSystem()
        Returns the system object representing the system on which the user profile exists.
        Returns:
        The system object representing the system on which the user profile exists. If the system has not been set, null is returned.
        See Also:
        setSystem(com.ibm.as400.access.AS400)
      • getUserActionAuditLevel

        public java.lang.String[] getUserActionAuditLevel()
        Retrieves a list of action audit levels for the user.
        Returns:
        A list of action audit levels for the user. Possible values for the elements of this array 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.
        See Also:
        setUserActionAuditLevel(java.lang.String[])
      • getUserClassName

        public java.lang.String getUserClassName()
        Retrieves the user class name.
        Returns:
        The user class name. 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.
        See Also:
        setUserClassName(java.lang.String)
      • getUserExpirationAction

        public java.lang.String getUserExpirationAction()
        Retrieves the action that will occur when the user profile has expired.

        Note: This method should not be used when running to IBM i 6.1 or earlier releases.

        Returns:
        The action that will occur when the user profile has expired. Possible values include:
        • NONE - The user profile will not expire.
        • "*DISABLE" - The user profile will be disabled.
        • "*DELETE" - The user profile will be deleted. If the user profile cannot be deleted, it will be disabled.
      • getUserExpirationDate

        public java.util.Date getUserExpirationDate()
        Retrieves the date when the user profile expires and is automatically disabled.

        Note: This method should not be used when running to IBM i 6.1 or earlier releases.

        Returns:
        The date when the user profile expires. null is returned if the user profile does not have an expiration date.
        See Also:
        setUserExpirationDate(java.util.Date)
      • getUserExpirationInterval

        public int getUserExpirationInterval()
        Retrieves the number of days before the user profile is automatically disabled.

        Note: This method should not be used when running to IBM i 6.1 or earlier releases.

        Returns:
        The number of days until the user profile expires, starting from when the profile was created or last re-enabled. 0 is returned if the user profile does not have a user expiration interval.
        See Also:
        setUserExpirationInterval(int)
      • getUserID

        public long getUserID()
        Retrieves the user ID (UID) number for the user profile. The UID is used to identify the user when using the integrated file system.
        Returns:
        The user ID (UID) number for the user profile.
        See Also:
        setUserID(long)
      • getUserIDNumber

        public int getUserIDNumber()
        Deprecated. This method has been replaced by getUserID() which returns a long.
        Retrieves the user ID (UID) number for the user profile. The UID is used to identify the user when using the integrated file system.
        Returns:
        The user ID (UID) number for the user profile.
      • getUserOptions

        public java.lang.String[] getUserOptions()
        Retrieves a list of options for users to customize their environment.
        Returns:
        The list of options for users to customize their environment. Possible values include:
        • "*CLKWD" - The keywords are shown when a CL command is displayed.
        • "*EXPERT" - More detailed information is shown when the user is defining or changing the system using edit or display object authority. This is independent of the ASTLVL parameter that is available on the user profile and other commands.
        • "*HLPFULL" - UIM online help is to be displayed full screen instead of in a window.
        • "*STSMSG" - Status messages sent to the user are shown.
        • "*NOSTSMSG" - Status messages sent to the user are not shown.
        • "*ROLLKEY" - The opposite action from the system default for roll keys is taken.
        • "*PRTMSG" - A message is sent to the user when a spooled file is printed.
        See Also:
        setUserOptions(java.lang.String[])
      • getUserProfileName

        public java.lang.String getUserProfileName()
        Retrieves the name of the user profile for which the information is returned. Note this is the name that is returned by the system, not the name that was set into this User object by the constructor or by a call to setUser().
        Returns:
        The name of the user profile for which the information is returned.
      • isAuthCollectionActive

        public boolean isAuthCollectionActive()
      • isAuthCollectionRepositoryExist

        public boolean isAuthCollectionRepositoryExist()
      • isAuthCollectionDeleted

        public boolean isAuthCollectionDeleted()
      • getDetailInSTRAUTCOL

        public java.lang.String getDetailInSTRAUTCOL()
      • getLibNameInSTRAUTCOL

        public java.lang.String[] getLibNameInSTRAUTCOL()
      • getObjectNamesInSTRAUTCOL

        public java.lang.String[] getObjectNamesInSTRAUTCOL()
      • getObjectTypesInSTRAUTCOL

        public java.lang.String[] getObjectTypesInSTRAUTCOL()
      • getDLOObjectTypesInSTRAUTCOL

        public java.lang.String[] getDLOObjectTypesInSTRAUTCOL()
      • getFileSystemObjectTypesInSTRAUTCOL

        public java.lang.String[] getFileSystemObjectTypesInSTRAUTCOL()
      • getOmitLibNamesInSTRAUTCOL

        public java.lang.String[] getOmitLibNamesInSTRAUTCOL()
      • hasSpecialAuthority

        public boolean hasSpecialAuthority(java.lang.String authority)
        Retrieves if this user profile has been granted the specified authority, or belongs to a group profile that has been granted the specified authority.
        Parameters:
        authority - The authority to check. It must be one of the following special authority values:
        • *ALLOBJ - All object.
        • *SECADM - Security administrator.
        • *JOBCTL - Job control.
        • *SPLCTL - Spool control.
        • *SAVSYS - Save system.
        • *SERVICE - Service.
        • *AUDIT - Audit.
        • *IOSYSCFG - Input/output system configuration.
        Returns:
        true if this user has the authority or belongs to a group that has the authority; false if it does not have authority or an error occurs.
        See Also:
        getSpecialAuthority(), setSpecialAuthority(java.lang.String[])
      • isGroupHasMember

        public boolean isGroupHasMember()
        Retrieves whether this user is a group that has members.

        For User objects, this should always return false. For UserGroup objects, this should return true if the group profile has members.

        Returns:
        true if the user is a group that has members, false otherwise.
        See Also:
        UserGroup
      • isLocalPasswordManagement

        public boolean isLocalPasswordManagement()
        Retrieves whether the password is managed locally.
        Returns:
        true if the password is managed locally, false otherwise.
        See Also:
        setLocalPasswordManagement(boolean)
      • isNoPassword

        public boolean isNoPassword()
        Retrieves 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()
        Retrieves whether the user's password is set to expired, requiring the user to change the password when signing on.
        Returns:
        true if the password is set to expired, false otherwise.
        See Also:
        setPasswordSetExpire(boolean)
      • isUserEntitlementRequired

        public boolean isUserEntitlementRequired()
        Retrieves whether a user entitlement is required for this user profile. This property should be ignored on systems that do not have feature 5052 installed. Note: This method is valid only when running to IBM i 6.1 or higher.
        Returns:
        true if a user entitlement is required for this user profile; false otherwise.
      • isWithDigitalCertificates

        public boolean isWithDigitalCertificates()
        Retrieves whether there are digital certificates associated with this user.
        Returns:
        true if there are digital certificates associated with this user; false otherwise.
      • removePropertyChangeListener

        public void removePropertyChangeListener(java.beans.PropertyChangeListener listener)
        Removes the PropertyChangeListener. If the PropertyChangeListener is not on the list, nothing is done.
        Parameters:
        listener - The listener object.
      • removeVetoableChangeListener

        public void removeVetoableChangeListener(java.beans.VetoableChangeListener listener)
        Removes the VetoableChangeListener. If the VetoableChangeListener is not on the list, nothing is done.
        Parameters:
        listener - The listener object.
      • setAccountingCode

        public void setAccountingCode(java.lang.String accountingCode)
                               throws AS400SecurityException,
                                      ErrorCompletingRequestException,
                                      java.lang.InterruptedException,
                                      java.io.IOException
        Sets the accounting code that is associated with this user profile.
        Parameters:
        accountingCode - The accounting code that is associated with this user profile. Possible values are:
        • "*BLANK" - An accounting code of 15 blanks is assigned to this user profile.
        • An accounting code - A 15 character accounting code to be used by jobs that get their accounting code from this user profile. If less than 15 characters are specified, the string is padded on the right with blanks.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getAccountingCode()
      • setAssistanceLevel

        public void setAssistanceLevel(java.lang.String assistanceLevel)
                                throws AS400SecurityException,
                                       ErrorCompletingRequestException,
                                       java.lang.InterruptedException,
                                       java.io.IOException
        Sets which user interface to use.
        Parameters:
        assistanceLevel - The user interface to use. Possible values are:
        • "*SYSVAL" - The assistance level defined in the system value QASTLVL is used.
        • "*BASIC" - The Operational Assistant user interface is used.
        • "*INTERMED" - The system user interface is used.
        • "*ADVANCED" - The expert system user interface is used. To allow for more list entries, option keys and function keys are not displayed. If a command does not have an advanced (*ADVANCED) level, the intermediate (*INTERMED) level is used.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
      • setAttentionKeyHandlingProgram

        public void setAttentionKeyHandlingProgram(java.lang.String attentionKeyHandlingProgram)
                                            throws AS400SecurityException,
                                                   ErrorCompletingRequestException,
                                                   java.lang.InterruptedException,
                                                   java.io.IOException
        Sets the program to be used as the Attention (ATTN) key handling program for this user. The ATTN key handling program is called when the ATTN key is pressed during an interactive job. The program is active only when the user routes to the system-supplied QCMD processor. The ATTN key handling program is set on before the initial program (if any) is called and it is active for both program and menu. If the program changes the ATNPGM (by using the SETATNPGM command), the new program remains active only for the duration of the program. When contol returns and QCMD call the menu, the original ATTN key handling program becomes active again. If the SETATNPGM command is run from the menues or an application is called from the menues, the new ATTN key handling program that is specified overrides the original ATTN key handling program. If *YES or *PARTIAL is specified for the Limit capabilites (LMTCPB) parameter on the Create User Profile (CRTUSRPRF) or Change User Profile (CHGUSRPRF) command, the ATTN key handling program cannot be changed. The caller must have *USE authority to the specified program.
        Parameters:
        attentionKeyHandlingProgram - The program to be used as the Attention (ATTN) key handling program for this user. Possible values are:
        • "*SYSVAL" - The system value QATNPGM is used.
        • NONE - No ATTN key handling program is used by this user.
        • "*ASSIST" - The Operational Assistant ATTN key handling program, QEZMAIN, is used.
        • The fully qualified integrated file system path name of the attention key handling program.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        QSYSObjectPathName
      • setCCSID

        public void setCCSID(int ccsid)
                      throws AS400SecurityException,
                             ErrorCompletingRequestException,
                             java.lang.InterruptedException,
                             java.io.IOException
        Sets the character code set identifier (CCSID) to be used for this user.

        A CCSID is a 16-bit number identifying a specific set of encoding scheme identifiers, character set identifiers, code page identifiers, and additional coding-related information that uniquely identifies the coded graphic representation used.

        Note: If the value for CCSID is changed, the change does not affect job that are currently running.

        Parameters:
        ccsid - The character code set identifier (CCSID) to be used for this user. Possible values are:
        • -2 - The system value QCCSID is used to determine the user's character code set ID.
        • A character code set ID.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
      • setCCSID

        public void setCCSID(java.lang.String ccsid)
                      throws AS400SecurityException,
                             ErrorCompletingRequestException,
                             java.lang.InterruptedException,
                             java.io.IOException
        Sets the character code set identifier (CCSID) to be used for this user.

        A CCSID is a 16-bit number identifying a specific set of encoding scheme identifiers, character set identifiers, code page identifiers, and additional coding-related information that uniquely identifies the coded graphic representation used.

        Note: If the value for CCSID is changed, the change does not affect job that are currently running.

        Parameters:
        ccsid - The character code set identifier (CCSID) to be used for this user. Possible values are:
        • "*SYSVAL" - The system value QCCSID is used to determine the user's character code set ID.
        • "*HEX" - The CCSID 65535 is used.
        • A character code set ID.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
      • setCHRIDControl

        public void setCHRIDControl(java.lang.String chridControl)
                             throws AS400SecurityException,
                                    ErrorCompletingRequestException,
                                    java.lang.InterruptedException,
                                    java.io.IOException
        Sets the character identifier control (CHRIDCTL) for the job. This attribute controls the type of coded character set identifier (CCSID) conversion that occurs for display files, printer files and panel groups. The *CHRIDCTL special value must be specified for the Character identifier (CHRID) parameter an the create, change, or override commands for display files, printer files, and panel groups before this attribute will be used.
        Parameters:
        chridControl - The character identifier control (CHRIDCTL) for the job. Possible values are:
        • "*SYSVAL" - The system value QCHRIDCTL is used.
        • "*DEVD" - The *DEVD special value performs the same function as on the CHRID command parameter for display files, printer files, and panel groups.
        • "*JOBCCSID" - The *JOBCCSID special value performs the same function as on the CHRID command parameter for display files, printer files, and panel groups.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getCHRIDControl()
      • setCountryID

        public void setCountryID(java.lang.String countryID)
                          throws AS400SecurityException,
                                 ErrorCompletingRequestException,
                                 java.lang.InterruptedException,
                                 java.io.IOException
        Sets the country or region identifier to be used for this user.
        Parameters:
        countryID - The country or region identifier to be used for this user. Possible values are:
        • "*SYSVAL" - The system value QCNTRYID is used.
        • A country or region identifier.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getCountryID()
      • setCurrentLibraryName

        public void setCurrentLibraryName(java.lang.String currentLibraryName)
                                   throws AS400SecurityException,
                                          ErrorCompletingRequestException,
                                          java.lang.InterruptedException,
                                          java.io.IOException
        Sets the name of the current library associated with the job being run.

        Specifies the name of the library to be used as the current library for this user. If *PARTIAL or *YES is specified for the Limit capabilities (LMTCPB) parameter of the Create User Profile (CRTUSRPRF) or Change User Profile (CHGUSRPRF) command, the user cannot change the current library at sign-on or with the Change Profile (CHGPRF) command.

        The caller must have *USE authority to the specified library.

        Parameters:
        currentLibraryName - The name of the current library associated with the job being run. Possible values are:
        • "*CRTDFT" - The user has no current library. The library QGPL is used as the default current library.
        • A library name.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getCurrentLibraryName()
      • setDescription

        public void setDescription(java.lang.String description)
                            throws AS400SecurityException,
                                   ErrorCompletingRequestException,
                                   java.lang.InterruptedException,
                                   java.io.IOException
        Sets the text that briefly describes the object.
        Parameters:
        description - The text that briefly describes the object. Possible values are:
        • "*BLANK" - No text is specified.
        • No more than 50 characters of text.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getDescription()
      • setDisplaySignOnInformation

        public void setDisplaySignOnInformation(java.lang.String displaySignOnInformation)
                                         throws AS400SecurityException,
                                                ErrorCompletingRequestException,
                                                java.lang.InterruptedException,
                                                java.io.IOException
        Sets whether the sign-on information display is shown.
        Parameters:
        displaySignOnInformation - Whether the sign-on information display is shown. Possible values are:
        • "*SYSVAL" - The system value QDSPSGNINF is used to determine whether the sign-on information display is shown.
        • "*NO" - The sign-on information display is not shown.
        • "*YES" - The sign-on information display is shown.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getDisplaySignOnInformation()
      • setGroupAuthority

        public void setGroupAuthority(java.lang.String groupAuthority)
                               throws AS400SecurityException,
                                      ErrorCompletingRequestException,
                                      java.lang.InterruptedException,
                                      java.io.IOException
        Sets the specific authority given to the group profile for newly created objects. If *GRPPRF is specified for the Owner (OWNER) parameter, specification of this parameter is not allowed.
        Parameters:
        groupAuthority - The specific authority given to the group profile for newly created objects. Possible values are:
        • NONE - No group authority is given.
        • "*ALL" - The user can perform all operations execept those limited to the owner or controlled by authorization list management (*AUTLMGT) authority. The user can control the object's existence, specify the security for the object, change the object, and perform basic functions on the object. The user can also change ownership of the object.
        • "*CHANGE" - The user can perform all operations execept those limited to the owner or controlled by the object existence (*OBJEXIST) and object management (*OBJMGT) authorities. The user can change and perform basic functions on the object. *CHANGE authority provides object operational (*OBJOPR) authority and all data authority. If the object is an authorization list, the user cannot add, change, or remove users.
        • "*USE" - The user can perform basic operations on the object, such as running a program or reading a file. The user cannot change the object. User (*USE) authority provides object operational (*OBJOPR), read (*READ), and execute (*EXECUTE) authorities.
        • "*EXCLUDE" - The user cannot access the object.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getGroupAuthority()
      • setGroupAuthorityType

        public void setGroupAuthorityType(java.lang.String groupAuthorityType)
                                   throws AS400SecurityException,
                                          ErrorCompletingRequestException,
                                          java.lang.InterruptedException,
                                          java.io.IOException
        Sets the type of authority to be granted to the group profile for newly-created objects. If NONE is specified for the Group Authority (GRPAUT) parameter, specification of this parameter is ignored.
        Parameters:
        groupAuthorityType - The type of authority to be granted to the group profile for newly-created objects. Possible values are:
        • "*PRIVATE" - The group profile is granted private authority to newly-created objects, with the authority value determined by the GRPAUT parameter. If the authority value in the GRPAUT parameter is NONE, this value is ignored.
        • "*PGP" - The group profile is the primary group for newly-created objects, with the authority value determined by the GRPAUT parameter. If the authority value in the GRPAUT parameter is NONE, this value is ignored.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getGroupAuthorityType()
      • setGroupID

        public void setGroupID(long groupID)
                        throws AS400SecurityException,
                               ErrorCompletingRequestException,
                               java.lang.InterruptedException,
                               java.io.IOException
        Sets the group ID number (gid number) for this user profile. The gid number is used to identify the group profile when a member of the group is using the directory file system. The gid number for a user may not be changed if:
        • The user profile is the primary group of an object in a directory.
        • There are one or more active jobs for the user.
        Parameters:
        groupID - The group ID number (gid number) for this user profile. Possible values are:
        • 0 - The user does not have a gid number or an existing gid number is removed.

          Note: This value cannot be specified if the user is a group profile or the primary group of an object.

        • 1-4294967294 - The gid number to be assigned to the user profile. The gid number assigned must not already be assigned to another user profile.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getGroupID()
      • setGroupID

        public void setGroupID(java.lang.String groupID)
                        throws AS400SecurityException,
                               ErrorCompletingRequestException,
                               java.lang.InterruptedException,
                               java.io.IOException
        Sets the group ID number (gid number) for this user profile. The gid number is used to identify the group profile when a member of the group is using the directory file system. The gid number for a user may not be changed if:
        • The user profile is the primary group of an object in a directory.
        • There are one or more active jobs for the user.
        Parameters:
        groupID - The group ID number (gid number) for this user profile. Possible values are:
        • NONE - The user does not have a gid number or an existing gid number is removed.

          Note: This value cannot be specified if the user is a group profile or the primary group of an object.

        • "*GEN" - The gid number will be generated for the user. The system generates a gid number that is not already assigned to another user. The gid number generated is greater than 100.
        • 1-4294967294 - The gid number to be assigned to the user profile. The gid number assigned must not already be assigned to another user profile.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getGroupID()
      • setGroupProfileName

        public void setGroupProfileName(java.lang.String groupProfileName)
                                 throws AS400SecurityException,
                                        ErrorCompletingRequestException,
                                        java.lang.InterruptedException,
                                        java.io.IOException
        Sets the user's group profile name whose authority is used if no specific authority is given for the user. The caller must have object management (*OBJMGT) and change (*CHANGE) authority to the profile specified for the Group profile (GRPPRF) parameter. The required *OBJMGT authority cannot be given by a program adopt operation.
        Parameters:
        groupProfileName - The user's group profile name whose authority is used if no specific authority is given for the user. Possible values are:
        • NONE - The user profile has no group profile.
        • The name of the group profile used with this user profile.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getGroupProfileName()
      • setHighestSchedulingPriority

        public void setHighestSchedulingPriority(int highestSchedulingPriority)
                                          throws AS400SecurityException,
                                                 ErrorCompletingRequestException,
                                                 java.lang.InterruptedException,
                                                 java.io.IOException
        Sets the highest scheduling priority the user is allowed to have for each job submitted to the system. This value controls the job processing priority and output priority for any job running under this user profile; that is, values specified in the JOBPTY and OUTPTY parameters of any job command cannot exceed the PTYLMT value of the user profile under which the job is run. The scheduling priority can have a value ranging from 0 through 9, where 0 is the highest priority and 9 is the lowest priority.
        Parameters:
        highestSchedulingPriority - The highest scheduling priority the user is allowed to have for each job submitted to the system.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getHighestSchedulingPriority()
      • setHomeDirectory

        public void setHomeDirectory(java.lang.String homeDirectory)
                              throws AS400SecurityException,
                                     ErrorCompletingRequestException,
                                     java.lang.InterruptedException,
                                     java.io.IOException
        Sets the path name of the home directory for this user profile. The home directory is the user's initial working directory. The working directory, associated with a process, is used during path name resolution in the directory file system for path names that do not begin with a slash (/). If the home directory specified does not exist when the user signs on, the user's initial working directory is the root (/) directory.
        Parameters:
        homeDirectory - The path name of the home directory for this user profile. Possible values are:
        • "*USRPRF" - The home directory assigned to the user will be /home/USRPRF, where USRPRF is the name of the user profile.
        • The path name of the home directory to be assigned to this user.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getHomeDirectory()
      • setInitialMenu

        public void setInitialMenu(java.lang.String initialMenu)
                            throws AS400SecurityException,
                                   ErrorCompletingRequestException,
                                   java.lang.InterruptedException,
                                   java.io.IOException
        Sets the initial menu displayed when the user signs on the system if the user's routing program is the command processor. If *YES is specified for the Limit capabilities (LMTCPB) parameter, the user cannot change the menu either at sign-on or with the Change Profile (CHGPRF) command.

        A System/36 environment menu can be specified as the initial menu if either of the following conditions are true:

        • *S36 is specified for the Special environments (SPCENV) parameter.
        • *SYSVAL is specified on the SPCENV parameter and the system value, QSPCENV, is *S36.

        The caller must have *USE authority to the specified menu.

        Parameters:
        initialMenu - The initial menu displayed when the user signs on the system if the user's routing program is the command processor. Possible values are:
        • "*SIGNOFF" - The system signs off the user when the program completes. This is intended for users authorized only to run the program.
        • The fully qualified integrated file system path name of the initial menu.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        QSYSObjectPathName, getInitialMenu()
      • setInitialProgram

        public void setInitialProgram(java.lang.String initialProgram)
                               throws AS400SecurityException,
                                      ErrorCompletingRequestException,
                                      java.lang.InterruptedException,
                                      java.io.IOException
        Sets, for an interactive job, the program called whenever a new routing step is started that has QCMD as the request processing program. If *PARTIAL or *YES is specified for the Limit capabilities parameter, the program value cannot be changed at sign on or by using the Change Profile (CHGPRF) command. No parameters can be passed to the program.

        A System/36 environment procedure name can be specified as the initial program if the procedure is a member of the file QS36PRC (in the library list or specified library) and if either of the following conditions are true:

        • *36 is specified on the SPCENV parameter.
        • *SYSVAL is specified on the SPCENV parameter and the system value, QSPCENV is *S36.

        The caller must have *USE authority to the specified program.

        Parameters:
        initialProgram - The initial program for the user. Possible values are:
        • NONE - No program is called when the user signs on. If a menu name is specified in the Initial menu (INLMNU) parameter, that menu is displayed.
        • The fully qualified integrated file system path name of the initial program for the user.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        QSYSObjectPathName, getInitialProgram()
      • setJobDescription

        public void setJobDescription(java.lang.String jobDescription)
                               throws AS400SecurityException,
                                      ErrorCompletingRequestException,
                                      java.lang.InterruptedException,
                                      java.io.IOException
        Sets the fully qualified integrated file system path name of the job description used for jobs that start through subsystem work station entries. If the job description does not exist when the user profile is created or changed, a library qualifier must be specified, because the job description name is kept in the user profile. The caller must have *USE authority to the specified job description.
        Parameters:
        jobDescription - The fully qualified integrated file system path name of the job description used for jobs that start through subsystem work station entries.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        QSYSObjectPathName, getJobDescription()
      • setKeyboardBuffering

        public void setKeyboardBuffering(java.lang.String keyboardBuffering)
                                  throws AS400SecurityException,
                                         ErrorCompletingRequestException,
                                         java.lang.InterruptedException,
                                         java.io.IOException
        Sets the keyboard buffering value to be used when a job is initialized for this user profile. If the type-ahead feature is active, you can buffer your keyboard strokes. If the attention key buffering option is active, the attention key is buffered as any other key. If it is not active, the attention key is not buffered and is sent to the system even if the display station is input-inhibited. This value can alse be set by a user application.
        Parameters:
        keyboardBuffering - The keyboard buffering value to be used when a job is initialized for this user profile. Possible values are:
        • "*SYSVAL" - The system value, QKBDBUF, is used to determine the keyboard buffering value.
        • "*NO" - The type-ahead and attention-key buffering options are not active.
        • "*TYPEAHEAD" - The type-ahead option is active, but the attention key buffering option is not.
        • "*YES" - The type-ahead and attention key buffering options are active.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getKeyboardBuffering()
      • setLanguageID

        public void setLanguageID(java.lang.String languageID)
                           throws AS400SecurityException,
                                  ErrorCompletingRequestException,
                                  java.lang.InterruptedException,
                                  java.io.IOException
        Sets the language ID to be used for this user.
        Parameters:
        languageID - The language ID to be used for this user. Possible values are:
        • "*SYSVAL" - The system value QLANGID is used.
        • The language ID to be used.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getLanguageID()
      • setLimitCapabilities

        public void setLimitCapabilities(java.lang.String limitCapabilities)
                                  throws AS400SecurityException,
                                         ErrorCompletingRequestException,
                                         java.lang.InterruptedException,
                                         java.io.IOException
        Sets the limit to which the user can control the program, menu, current library, and the ATTN key handling program values. It alse determines whether the user can run commands from the command line. This parameter is ignored when the security level is 10.

        Note: When creating or changing other users' user profile, you cannot specify values on this parameter that grant greater capabilities to other users than your own user profile grants to you. For example, if *PARTIAL is specified for the Limit capabilities (LMTCPB) parameter in your user profile, you can specify *PARTIAL or *YES for anther user. You cannot specify *NO for another user.

        Parameters:
        limitCapabilities - The limit to which the user can control the program, menu, current library, and the ATTN key handling program values. Possible values are:
        • "*NO" - The program, menu, and current library values can be changed when the usre signs on the system. User may change the program, menu, current library, or ATTN key handling program values is the own user profiles with the Change Profile (CHGPRF) command. Commands can be run from a command line.
        • "*PARTIAL" - The program and current library cannot be changed on the sign-on display. The menu can be changed and comands can be run from a command line. A user can change the menu value with the Change profile (CHGPRF) command. The program, current library, and the ATTN key handling program cannot be changed using the CHGPRF command.
        • "*YES" - The program, menu, and current library values cannot be changed on the sign-on display. Commands cannot be run when issued from a command line or by selecting an option from a command grouping menu such as CMDADD, but can still be run from a command entry screen. The user cannot change the program, menu, current library, or the ATTN key program handling values by using the CHGPRF command.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getLimitCapabilities()
      • setLimitDeviceSessions

        public void setLimitDeviceSessions(java.lang.String limitDeviceSessions)
                                    throws AS400SecurityException,
                                           ErrorCompletingRequestException,
                                           java.lang.InterruptedException,
                                           java.io.IOException
        Sets if the number of device sessions allowed for a user is limited to 1. This does not limit SYSREQ and second sign-on. Note: Values "0-9" are only valid when running to IBM i 6.1 or higher.
        Parameters:
        limitDeviceSessions - If the number of device sessions allowed for a user is limited to 1. Possible values are:
        • "*SYSVAL" - The system value QLMTDEVSSN is used to determine whether the user is limited to a single device session.
        • "*NO" - The user is not limited to one device session.
        • "*YES" - The user is limited to one session.
        • "0" - The user is not limited to a specific number of device session. The value has the same meaning as *NO.
        • "1" - The user is limited to a single device session. The value has the same meaning as *YES.
        • "2-9" - The user is limited to the specified number of device sessions.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getLimitDeviceSessions()
      • setLocaleJobAttributes

        public void setLocaleJobAttributes(java.lang.String[] localeJobAttributes)
                                    throws AS400SecurityException,
                                           ErrorCompletingRequestException,
                                           java.lang.InterruptedException,
                                           java.io.IOException
        Sets which job attributes are to be taken from the locale specified for the Locale (LOCALE) parameter when the job is initiated.
        Parameters:
        localeJobAttributes - A list of attributes which are set from the locale path name at the time a job is started for this user. Possible values for the elements of this array are:
        • "*SYSVAL" - The system value, QSETJOBATR, is used to determine which job attributes are taken from the locale.
        • NONE - No job attributes are taken from the locale.
        • "*CCSID" - The coded character set identifier from the locale is used. The CCSID value from the locale overrides the user profile CCSID.
        • "*DATFMT" - The date format from the locale is used.
        • "*DATSEP" - The date separator from the locale is used.
        • "*DECFMT" - The decimal format from the locale is used.
        • "*SRTSEQ" - The sort sequence from the locale is used. The sort sequence from the locale overrides the user profile sort sequence.
        • "*TIMSEP" - The time separator from the locale is used.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getLocaleJobAttributes()
      • setLocalePathName

        public void setLocalePathName(java.lang.String localePathName)
                               throws AS400SecurityException,
                                      ErrorCompletingRequestException,
                                      java.lang.InterruptedException,
                                      java.io.IOException
        Sets the path name of the locale that is assigned to LANG environment variable for this user.
        Parameters:
        localePathName - The locale path name that is assigned to the user profile when a job is started. Possible values are:
        • "*SYSVAL" - The system value QLOCALE is used to determine the locale path name to be assigned for this user.
        • NONE - No locale path name is assigned for this user.
        • "*C" - The C locale path name is assigned for this user.
        • "*POSIX" - The POSIX locale path name is assigned for this user.
        • The path name of the locale to be assigned for this user.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getLocalePathName()
      • setLocalPasswordManagement

        public void setLocalPasswordManagement(boolean localPasswordManagement)
                                        throws AS400SecurityException,
                                               ErrorCompletingRequestException,
                                               java.lang.InterruptedException,
                                               java.io.IOException
        Sets whether the user profile password should be managed locally.
        Parameters:
        localPasswordManagement - true if the password will be managed on the local system, false otherwise.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        isLocalPasswordManagement()
      • setMaximumStorageAllowed

        public void setMaximumStorageAllowed(int maximumStorageAllowed)
                                      throws AS400SecurityException,
                                             ErrorCompletingRequestException,
                                             java.lang.InterruptedException,
                                             java.io.IOException
        Sets the maximum amount of auxiliary storage (in kilobytes) assigned to store permanant objects owned by this user profile (1 kilobyte equals 1024 bytes). If the maximum is exceeded, when an interactive user tries to create an object, an error message is displayed, and the object is not created. If the maximum is exceeded when an object is created in a batch job, an error message is sent to the job log (depending on the logging level of the job), and the object is not created.

        Storage is allocated in 4K increments. Therefore, if you specify MAXSTG (9), the profile is allocated 12K of storage.

        When planning maximum storage for user profiles, consider the following system actions:

        • A restore operation assigns the storage to the user doing the restore, and then transfers the object to the owner. For a large restore, specify MAXSTG(*NOMAX).
        • The user profile that creates a journal receiver is assigned the required storage as the receiver size grows. If new receivers are created using JRNRCV(*GEN), the storage continues to be assigned to the user profile that wons the active journal receiver. If a very active journal receiver is owned, specify MAXSTG(*NOMAX).
        • User profiles that transfer created objects to their group profile must have adequate storage in the user profiles to contain created objects before the objects are transferred to the group profile.
        • The owner of the library is assigned the storage for the descriptions of objects which are stored in a library, even when the objects are owned by another user profile. Examples of such objects are text and program references.
        Parameters:
        maximumStorageAllowed - The maximum amount of auxiliary storage (in kilobytes) assigned to store permanant objects owned by this user profile. Possible values are:
        • -1 - As much storage as is required is assigned to this profile (*NOMAX).
        • The maximum amount of storage for the user, in kilobytes (1 kilobyte equals 1024 bytes).
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getMaximumStorageAllowed()
      • setMaximumStorageAllowed

        public void setMaximumStorageAllowed(java.lang.String maximumStorageAllowed)
                                      throws AS400SecurityException,
                                             ErrorCompletingRequestException,
                                             java.lang.InterruptedException,
                                             java.io.IOException
        Sets the maximum amount of auxiliary storage (in kilobytes) assigned to store permanant objects owned by this user profile (1 kilobyte equals 1024 bytes). If the maximum is exceeded, when an interactive user tries to create an object, an error message is displayed, and the object is not created. If the maximum is exceeded when an object is created in a batch job, an error message is sent to the job log (depending on the logging level of the job), and the object is not created.

        Storage is allocated in 4K increments. Therefore, if you specify MAXSTG (9), the profile is allocated 12K of storage.

        When planning maximum storage for user profiles, consider the following system actions:

        • A restore operation assigns the storage to the user doing the restore, and then transfers the object to the owner. For a large restore, specify MAXSTG(*NOMAX).
        • The user profile that creates a journal receiver is assigned the required storage as the receiver size grows. If new receivers are created using JRNRCV(*GEN), the storage continues to be assigned to the user profile that wons the active journal receiver. If a very active journal receiver is owned, specify MAXSTG(*NOMAX).
        • User profiles that transfer created objects to their group profile must have adequate storage in the user profiles to contain created objects before the objects are transferred to the group profile.
        • The owner of the library is assigned the storage for the descriptions of objects which are stored in a library, even when the objects are owned by another user profile. Examples of such objects are text and program references.
        Parameters:
        maximumStorageAllowed - The maximum amount of auxiliary storage (in kilobytes) assigned to store permanant objects owned by this user profile. Possible values are:
        • "*NOMAX" - As much storage as is required is assigned to this profile.
        • The maximum amount of storage for the user, in kilobytes (1 kilobyte equals 1024 bytes).
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getMaximumStorageAllowed()
      • setMessageQueue

        public void setMessageQueue(java.lang.String messageQueue)
                             throws AS400SecurityException,
                                    ErrorCompletingRequestException,
                                    java.lang.InterruptedException,
                                    java.io.IOException
        Sets the message queue to which messages are sent.

        Note: The message queue is created, if it does not exist. The user profile specified for the User profile (USRPRF) parameter is the owner of the message queue.

        The caller must have *USE authority to the specified message queue.

        Parameters:
        messageQueue - The message queue to which messages are sent. Possible values are:
        • "*USRPRF" - A message queue with the same name as that specified for the USRPRF parameter is used as the message queue for this user. This message queue is located in the QUSERSYS library.
        • The fully qualified integrated file system path name of the message queue to be used with this profile.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        QSYSObjectPathName, getMessageQueue()
      • setMessageQueueDeliveryMethod

        public void setMessageQueueDeliveryMethod(java.lang.String messageQueueDeliveryMethod)
                                           throws AS400SecurityException,
                                                  ErrorCompletingRequestException,
                                                  java.lang.InterruptedException,
                                                  java.io.IOException
        Sets how the messages are sent to the message queue for this user are to be delivered.
        Parameters:
        messageQueueDeliveryMethod - How the messages are sent to the message queue for this user are to be delivered. Possible values are:
        • "*NOTIFY" - The job to which the message queue is assigned is notified when a message arrives on the message queue. For interactive jobs at a work station, the audible alarm is sounded (if the alarm feature is set) and the Message Waiting light is turned on. The delivery mode cannot be changed to *NOTIFY if the message queue is also being used by another job.
        • "*HOLD" - The messages are held in the message queue until they are requested by the user or program.
        • "*BREAK" - The job to which the message queue is assigned is interrupted when a message arrives at the message queue. If the job is an interactive job, the autdible alarm is sounded (if the alarm feature is set). The delivery mode cannot be changed to *BREAK if the message queue is also being used by another job.
        • "*DFT" - The default reply to the inquiry message is sent. If no default reply is specified in the message description of the inquiry message, the system default reply, *N, is used.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        setMessageQueueDeliveryMethod(java.lang.String)
      • setMessageQueueSeverity

        public void setMessageQueueSeverity(int messageQueueSeverity)
                                     throws AS400SecurityException,
                                            ErrorCompletingRequestException,
                                            java.lang.InterruptedException,
                                            java.io.IOException
        Sets the lowest severity code that a message can have and still be delivered to a user in break or notify mode. Messages arriving at the message queue whose severities are lower than the the severity code specified for this parameter do not interrupt the job or turn on the audible alarm or the message-waiting light; they are held in the queue until they are requested by using the Display Message (DSPMSG) command. If *BREAK or *NOTIFY is specidied for the Delivery (DLVRY) parameter, and is in effect when a message arrives at the queue, the message is delivered if the severity code associated with the message is equal or greater then the value specified here. Otherwiese, the message is held in the queue until it is requested.
        Parameters:
        messageQueueSeverity - A severity code ranging from 00 through 99.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getMessageQueueSeverity()
      • setName

        public void setName(java.lang.String name)
                     throws java.beans.PropertyVetoException
        Sets the user profile name. This does not change the name of the user profile on the system. Instead, it changes the user profile to which this User object references. This property cannot be changed if the object has established a connection to the system.
        Parameters:
        name - The user profile name.
        Throws:
        java.beans.PropertyVetoException - If any of the registered listeners vetos the property change.
        See Also:
        getName()
      • setObjectAuditingValue

        public void setObjectAuditingValue(java.lang.String objectAuditingValue)
                                    throws AS400SecurityException,
                                           ErrorCompletingRequestException,
                                           java.lang.InterruptedException,
                                           java.io.IOException
        Sets the object auditing value for the user. This value only takes effect if the object auditing (OBJAUD) value for the object being accessed has the value *USRPRF.

        Implementation note: The method internally calls the Change User Auditing (CHGUSRAUD) command and not the Change User Profile (CHGUSRPRF) command. The caller must have audit (*AUDIT) special authority. Changes take effect the next time a job is started for this user.

        Parameters:
        objectAuditingValue - The object auditing value for the user. Possible values are:
        • NONE - The auditing value for the object determines when auditing is performed.
        • "*CHANGE" - All changes accesses by this user on all objects with the *USRPRF audit value are logged.
        • "*ALL" - All change and read accesses by this use on all objects with the *USRPRF audit value are logged.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getObjectAuditingValue()
      • setOutputQueue

        public void setOutputQueue(java.lang.String outputQueue)
                            throws AS400SecurityException,
                                   ErrorCompletingRequestException,
                                   java.lang.InterruptedException,
                                   java.io.IOException
        Sets the output queue to be used by this user profile. The output queue must already exist when this command is run. The caller must have *USE authority to the specified output queue.
        Parameters:
        outputQueue - The output queue to be used by this user profile. Possible values are:
        • "*WRKSTN" - The output queue assigned to the user's work station is used.
        • "*DEV" - The output queue associated with the printer specified for the Print device (PRTDEV) parameter is used. The output queue has the same name as the printer. (The pringer file DEV parameter is determined by the CRTPRTF, CHGPRTF, or the OVRPRTF command).

          Note: This assumes the defaults are specified for the Output queue (OUTQ) parameter for the printer file, job description, user profile, and workstation.

        • The fully qualified integrated file system path name of the output queue to be used by this user profile.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        QSYSObjectPathName, getOutputQueue()
      • setOwner

        public void setOwner(java.lang.String owner)
                      throws AS400SecurityException,
                             ErrorCompletingRequestException,
                             java.lang.InterruptedException,
                             java.io.IOException
        Sets the user profile that is to be the owner of objects created by this user.
        Parameters:
        owner - The user profile that is to be the owner of objects created by this user. Possible values are:
        • "*USRPRF" - The user profile associated with the job is the owner of the object.
        • "*GRPPRF" - The group profile is made the owner of newly created objects and has all authority to the object. The user profile associated with the job does not have any specific authority to the object. If *GRPPRF is specified, a user profile name must be specified for the Group profile (GRPPRF) parameter, and the Group authority (GRPAUT) parameter cannot be specified.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getOwner()
      • setPasswordChangeBlock

        public void setPasswordChangeBlock(java.lang.String pwdChangeBlock)
                                    throws AS400SecurityException,
                                           ErrorCompletingRequestException,
                                           java.lang.InterruptedException,
                                           java.io.IOException
        Sets the time period during which a password is blocked from being changed following the prior successful password change operation.

        Note: This method should not be used when running to IBM i 5.4 or earlier releases.

        Parameters:
        pwdChangeBlock - The time period during which a password is blocked from being changed. Possible values are:
        • "*SYSVAL" - The system value QPWDCHGBLK is used to determine the block password change value.
        • NONE - The password can be changed at any time.
        • 1-99 - Indicates the number of hours a user must wait after the prior successful password change operation before they are able to change the password again.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getPasswordChangeBlock()
      • setPasswordExpirationInterval

        public void setPasswordExpirationInterval(int passwordExpirationInterval)
                                           throws AS400SecurityException,
                                                  ErrorCompletingRequestException,
                                                  java.lang.InterruptedException,
                                                  java.io.IOException
        Sets the password expiration interval (in days).
        Parameters:
        passwordExpirationInterval - The number of days the user's password can remain active before it must be changed. Possible values are:
        • 0 - The system value QPWDEXPITV is used to determine the password expiration interval (*SYSVAL).
        • -1 - The password does not expire (*NOMAX).
        • 1-366 - The number of days between the date when the password is changed and the date when the password expires.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getPasswordExpirationInterval()
      • setPasswordExpirationInterval

        public void setPasswordExpirationInterval(java.lang.String passwordExpirationInterval)
                                           throws AS400SecurityException,
                                                  ErrorCompletingRequestException,
                                                  java.lang.InterruptedException,
                                                  java.io.IOException
        Sets the password expiration interval (in days).
        Parameters:
        passwordExpirationInterval - The number of days the user's password can remain active before it must be changed. Possible values are:
        • "*SYSVAL" - The system value QPWDEXPITV is used to determine the password expiration interval.
        • "*NOMAX" - The password does not expire.
        • 1-366 - The number of days between the date when the password is changed and the date when the password expires.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getPasswordExpirationInterval()
      • setPasswordSetExpire

        public void setPasswordSetExpire(boolean passwordSetExpire)
                                  throws AS400SecurityException,
                                         ErrorCompletingRequestException,
                                         java.lang.InterruptedException,
                                         java.io.IOException
        Sets whether the password for this user is set to expired. If the password is set to expired, the user is required to change the password to sign on to the system. When the user attempts to sign on to the system, the sign-on information display is shown and the user has the option to change this password.
        Parameters:
        passwordSetExpire - true if the password set to expired, false otherwise.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        isPasswordSetExpire()
      • setPrintDevice

        public void setPrintDevice(java.lang.String printDevice)
                            throws AS400SecurityException,
                                   ErrorCompletingRequestException,
                                   java.lang.InterruptedException,
                                   java.io.IOException
        Sets the default printer device for this user. If the pringer file used to create printed output specifies to spool the data, the spooled file is placed on the device's output queue, which is named the same as the device.

        Note: This assumes the defaults are specified for the Output queue (OUTQ) parameter for the printer file, job description, user profile, and workstation.

        The caller must have *USE authority to the specified print device.

        Parameters:
        printDevice - The default printer device for this user. Possible values are:
        • "*WRKSTN" - The printer assigned to the user's work station is used.
        • "*SYSVAL" - The value specified in the system value QPRTDEV is used.
        • The name of a printer that is to be used to print the output for this user.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getPrintDevice()
      • setSortSequenceTable

        public void setSortSequenceTable(java.lang.String sortSequenceTable)
                                  throws AS400SecurityException,
                                         ErrorCompletingRequestException,
                                         java.lang.InterruptedException,
                                         java.io.IOException
        Sets the sort sequence table to be used for string comparisons for this profile.
        Parameters:
        sortSequenceTable - The sort sequence table to be used for string comparisons for this profile. Possible values are:
        • "*SYSVAL" - The system value QSRTSEQ is used.
        • "*HEX" - A sort sequence table is not used. The hexadecimal values of the characters are used to determine the sort sequence.
        • "*LANGIDUNQ" - A unique-weight sort table is used
        • "*LANGIDSHR" - A shared-weight sort table is used.
        • The fully qualified integrated file system path name of the sort sequence table to be used with this profile.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        QSYSObjectPathName, getSortSequenceTable()
      • setSpecialAuthority

        public void setSpecialAuthority(java.lang.String[] specialAuthority)
                                 throws AS400SecurityException,
                                        ErrorCompletingRequestException,
                                        java.lang.InterruptedException,
                                        java.io.IOException
        Sets the special authorities given to a user. Special authorities are required to perform certain functions on the system. Special authorities cannot be removed from many of the system-supplied user profiles, including QSECOFR and QSYS.

        The following special authorities are usually given:

        • Save system (*SAVSYS) special authority to users who need to operate the system.
        • Input/output system configuration (*IOSYSCFG) special authority to users who need to change system I/O configurations.
        • Job control (*JOBCTL) special authority is given to the user. The user is given the authority to change, display, hold, release, cancel, and clear all jobs that are running on the system or that are on a job queue or output queue that has OPRCTL (*YES) specified. The user also has the authority to load the system, to start writers, and to stop active subsystems.
        • Security administrator (*SECADM) special authority to users who need to create, change, or delete user profiles.
        • All object (*ALLOBJ) special authority to users who need to work with system resources.
        • Service (*SERVICE) special authority to users who need to perform service functions.
        • Spool control (*SPLCTL) special authority to users who need to perform all spool-related functions.
        • Audit (*AUDIT) special authority to users who need to perform auditing functions.

        Restrictions:

        • The user profile creating or changing another user profile must have all of the special authorities being given. All special authorities are needed to give all special authorities to another user profile.
        • A user must have *ALLOBJ and *SECADM special authorities to give a user *SECADM special authority when using the CHGUSRPRF command.
        • The user must have *ALLOBJ, *SECADM, and *AUDIT special authorities to give a user *AUDIT special authority when using the CHGUSRPRF command.
        Parameters:
        specialAuthority - The special authorities given to a user. Possible values for the elements of this array are:
        • "*USRCLS" - Special authorities are granted to this user based on the value specified on User class (USRCLS) parameter.
        • NONE - No special authorities are granted to this user.
        • SPECIAL_AUTHORITY_ALL_OBJECT - All object authority is given to the user. The user can access any system resource with or without private user authorizations.
        • SPECIAL_AUTHORITY_AUDIT - Audit authority is granted to this user. The user is given the authority to perform auditing functions. Auditing functions include turning auditing on or off for the system and controlling the level of auditing on an object or user.
        • SPECIAL_AUTHORITY_JOB_CONTROL - Job control authority is given to the user. The user has authority to change, display, hold, release, cancel, and clear all jobs that are running on the system or that are on a job queue or output queue that has OPRCTL (*YES) specified. The user also has the authority to start writers and to stop active subsystems.
        • SPECIAL_AUTHORITY_SAVE_SYSTEM - Save system authority is given to the user profile. This user has the authority to save, restore, and free storage for all objects on the system, with or without object management authority.
        • SPECIAL_AUTHORITY_IO_SYSTEM_CONFIGURATION - Input/output (I/O) system configuration authority is given to the user. The user has authority to change system I/O configurations.
        • SPECIAL_AUTHORITY_SECURITY_ADMINISTRATOR - Security administrator authority is given to the user. The user can create, change, or delete user profiles if authorized to the Create User Profile (CRTUSRPRF), Change User Profile (CHGUSRPRF), or Delete User Profile (DLTUSRPRF) commands and is authorized to the user profile. This authority does not allow giving special authorities that this user profile does not have. To give *SECADM special authority to another user, a user must have both *ALLOBJ and *SECADM special authorities.
        • SPECIAL_AUTHORITY_SERVICE - Service authority is given to this user. The user can perform service functions.
        • SPECIAL_AUTHORITY_SPOOL_CONTROL - Spool control authority is given to this user. The user can perform all spool functions.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getSpecialAuthority(), hasSpecialAuthority(java.lang.String)
      • setSpecialEnvironment

        public void setSpecialEnvironment(java.lang.String specialEnvironment)
                                   throws AS400SecurityException,
                                          ErrorCompletingRequestException,
                                          java.lang.InterruptedException,
                                          java.io.IOException
        Sets the special environment in which the user operates after signing on.
        Parameters:
        specialEnvironment - The special environment in which the user operates after signing on. Possible values are:
        • "*SYSVAL" - The system value, QSPCENV, is used to determine the system environment after the user signs on the system.
        • NONE - The user operates in the IBM i system environment after signing on the system.
        • "*S36" - The user operates in the System/36 environment after signing on the system.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getSpecialEnvironment()
      • setStatus

        public void setStatus(java.lang.String status)
                       throws AS400SecurityException,
                              ErrorCompletingRequestException,
                              java.lang.InterruptedException,
                              java.io.IOException
        Sets the status of the user profile.

        The system will disable a user profile if the number of failed sign-on attempts reaches the limit specified on the QMAXSIGN system value and option 2 or 3 has been specified on the QMAXSGNACN system value.

        Parameters:
        status - The status of the user profile. Possible values are:
        • "*ENABLED" - The user profile is valid for sign-on.
        • "*DISABLED" - The user profile is not valid for sign-on until an authorized user enables it again. Batch jobs can be submitted under a disabled user profile.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getStatus()
      • setSupplementalGroups

        public void setSupplementalGroups(java.lang.String[] supplementalGroups)
                                   throws AS400SecurityException,
                                          ErrorCompletingRequestException,
                                          java.lang.InterruptedException,
                                          java.io.IOException
        Sets the user's supplemental group profiles. The profiles specified here, along with the group profile specified for the Group profile (GRPPRF) parameter, are used to determine what authority the user has if no specific user authority is given for the job. If profiles are specified for this parameter, a group profile name must be specified on the GRPPRF parameter for this user profile (either on this command or on a previous Create User Profile (CRTUSRPRF) or Change User Profile (CHGUSRPRF) command. The current user of this command must have object management (*OBJMGT) and change (*CHANGE) authority to the profiles specified for this. The required *OBJMGT authority cannot be given by a program adopt operation.

        Notes:

        • When a group profile is specified, the user is automatically granted *CHANGE and *OBJMGT authority to the group profile.
        • The following IBM-supplied user profiles are not valid for this parameter:

          QAUTPROF, QCLUMGT, QCLUSTER, QCOLSRV, QDBSHR, QDBSHRDO, QDFTOWN, QDIRSRV, QDLFM, QDOC, QDSNX, QEJB, QFNC, QGATE, QIPP, QLPAUTO, QLPINSTALL, QMGTC, QMSF, QNETSPLF, QNFSANON, QNTP, QPEX, QPM400, QRJE, QSNADS, QSPL, QSPLJOB, QSRV, QSRVAGT, QSRVBAS, QSYS, QTCM, QTCP, QTFTP, QTSTRQS, QYCMCIMOM, QYPSJSVR

        Parameters:
        supplementalGroups - The user's supplemental group profiles. Possible values for the elements of this array are:
        • NONE - No supplemental group profiles are used with this user profile.
        • The group profile names to be used with this user profile and the group profile specified on the GRPPRF parameter to determine a job's eligibility for getting access to existing objects and special authority. A maximum of 15 group profile names may be specified.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getSupplementalGroups()
      • setSystem

        public void setSystem(AS400 system)
                       throws java.beans.PropertyVetoException
        Sets the system object representing the system on which the user profile exists. This property cannot be changed if the object has established a connection to the system.
        Parameters:
        system - The system object representing the system on which the user profile exists.
        Throws:
        java.beans.PropertyVetoException - If any of the registered listeners vetos the property change.
        See Also:
        getSystem()
      • setUserActionAuditLevel

        public void setUserActionAuditLevel(java.lang.String[] userActionAuditLevel)
                                     throws AS400SecurityException,
                                            ErrorCompletingRequestException,
                                            java.lang.InterruptedException,
                                            java.io.IOException
        Sets the level of activity that is audited for this user profile. Note: The system values QAUDLVL and QAUDLVL2 are used in conjunction with this parameter. Example: If QAUDLVL is set to *DELETE and AUDLVL is set to *CREATE, then both *DELETE and *CREATE would be audited for this user. The default value for the QAUDLVL and QAUDLVL2 system values is NONE.

        Implementation note: The method internally calls the Change User Auditing (CHGUSRAUD) command and not the Change User Profile (CHGUSRPRF) command. The caller must have audit (*AUDIT) special authority. Changes take effect the next time a job is started for this user.

        Parameters:
        userActionAuditLevel - The level of activity that is audited for this user profile. Possible values for the elements of this array are:
        • NONE - No auditing level is specified. The auditing level for this user is taken from system values QAUDLVL and QAUDLVL2.
        • "*CMD" - CL command strings, System/36 environment operator control commands, and System/36 enviromnent procedures are logged for this user.
        • "*CREATE" - Auditing entries are sent when objects are created by this user.
        • "*DELETE" - Auditing entries are sent when objects are deleteed by this user.
        • "*JOBDTA" - The following actions taken by this user that affect a job are audited:
          • Job start and stop data.
          • Hold, release, stop, continue, change, disconnect, end, end abnormal.
          • Program start request (PSR) is attached to a prestart job.
        • "*OBJMGT" - Object management changes made by this user, such as move or rename, are audited.
        • "*OFCSRV" - Office services changes made by this user, such as changes to the system directory and use of OfficeVision, are audited.
        • "*OPTICAL" - The following optical functions are audited:
          • Add or remove optical cartridge.
          • Change the authorization list used to secure an optical volume.
          • Open optical file or directory.
          • Create or delete optical directory.
          • Change or retrieve optical directory attributes.
          • Copy, move, or rename optical file.
          • Copy optical directory.
          • Back up optical volume.
          • Initialize or rename optical volume.
          • Convert backup optical volume to a primary volume.
          • Save or release help optical file.
          • Absolute read of an optical volume.
        • "*PGMADP" - Authority obtained through program adoption is audited for this user.
        • "*SAVRST" - Save and restore actions performed by this user are audited.
        • "*SECURITY" - Security changes made by this user are audited.
        • "*SERVICE" - User of the system service tools by this user is audited.
        • "*SPLFDTA" - Spooled file operations made by this user are audited.
        • "*SYSMGT" - Use of system management functions by this user are audited.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getUserActionAuditLevel()
      • setUserClassName

        public void setUserClassName(java.lang.String userClassName)
                              throws AS400SecurityException,
                                     ErrorCompletingRequestException,
                                     java.lang.InterruptedException,
                                     java.io.IOException
        Sets the type of user associated with this user profile: security officer, security administrator, programmer, system operator, or user. The user class controls the options that are shown on a menu. Special authorities are given only if *USRCLS is specified for the Special authority (SPCAUT) parameter. If SPCAUT(*USRCLS) is specified, the special authorities granted will differ depending on the QSECURITY value.
        Parameters:
        userClassName - The type of user associated with this user profile. Possible values are:
        • "*USER" - At QSECURITY level 10 or 20, the user has *ALLOBJ and *SAVSYS authority. At QSECURITY level 30 or above, the user has no special authorities.
        • "*SECOFR" - At all levels of security, the security officer is granted the following special authorities:
          • *ALLOBJ
          • *SAVSYS
          • *JOBCTL
          • *SERVICE
          • *SPLCTL
          • *SECADM
          • *AUDIT
          • *IOSYSCFG
        • "*SECADM" - At QSECURITY level 10 or 20, the security administrator has *ALLOBJ, *SAVSYS, *SECADM, and *JOBCTL special authorities. At QSECURITY level 30 or above, the user has *SECADM special authority.
        • "*PGMR" - At QSECURITY level 10 or 20, the programmer has *ALLOBJ, *SAVSYS, and *JOBCTL special authorities. At QSECURITY level 30 or above, the user has no special authorities.
        • "*SYSOPR" - At QSECURITY level 10 or 20, the system operator has *ALLOBJ, *SAVSYS, and *JOBCTL special authorities. At QSECURITY level 30 or above, the user has *SAVSYS and *JOBCTL special authorities.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getUserClassName()
      • setUserExpirationInterval

        public void setUserExpirationInterval(int expirationInterval)
                                       throws AS400SecurityException,
                                              ErrorCompletingRequestException,
                                              java.lang.InterruptedException,
                                              java.io.IOException,
                                              RequestNotSupportedException
        Sets the expiration interval (in days) before the user profile is automatically disabled. If the user profile does not have a user expiration date, or the user profile has expired and the Status parameter is set to *ENABLED, specifies the number of days between today and the new date when the user profile expires. If the user profile has not yet expired, the user expiration interval is changed, but the existing user expiration date is not changed.

        Note: This method should not be used when running to IBM i 6.1 or earlier releases.

        Parameters:
        expirationInterval - The number of days from today until the user profile is automatically disabled. Valid values range from 1 through 366. To specify that the user profile has no expiration interval, call setUserExpirationDate(null).
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        RequestNotSupportedException - If the request is not supported.
        See Also:
        getUserExpirationInterval(), setUserExpirationDate(java.util.Date)
      • setUserID

        public void setUserID(long userID)
                       throws AS400SecurityException,
                              ErrorCompletingRequestException,
                              java.lang.InterruptedException,
                              java.io.IOException
        Sets the user ID number (uid number) for this user profile. The uid number is used to identify the user when the user is using the directory file system. The uid number for a user cannot be changed if there are one or more active jobs for the user.
        Parameters:
        userID - The uid number to be assigned to the user profile. A value from 1 to 4294967294 can be entered. The uid number assigned must not already be assigned to another user profile.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getUserID()
      • setUserOptions

        public void setUserOptions(java.lang.String[] userOptions)
                            throws AS400SecurityException,
                                   ErrorCompletingRequestException,
                                   java.lang.InterruptedException,
                                   java.io.IOException
        Sets the level of help information detail to be shown and the function of the Page Up and Page Down keys by default. The system shows several displays that are suitable for the inexperienced user. More experienced users must perform an extra action to see detailed information. When values are specified for this parameter, the system presents detailed information without further action by the experienced user.
        Parameters:
        userOptions - The level of help information detail to be shown and the function of the Page Up and Page Down keys by default. Possible values include:
        • NONE - Detailed information is not shown.
        • "*CLKWD" - Parameter keywords are shown instead of the possible parameter values when a control language (CL) command is prompted.
        • "*EXPERT" - More detailed information is shown when the user is performing display and edit options to define or change the system (such as edit or display object authority).
        • "*ROLLKEY" - The actions of the Page Up and Page Down keys are reversed.
        • "*NOSTSMSG" - Status messages are not displayed when sent to the user.
        • "*STSMSG" - Status messages are displayed when sent to the user.
        • "*HLPFULL" - Help text is shown on a full display rather than in a window.
        • "*PRTMSG" - A message is sent to this user's message queue when a spooled file for this user is printed or held by the printer writer.
        Throws:
        AS400SecurityException - If a security or authority error occurs.
        ErrorCompletingRequestException - If an error occurs before the request is completed.
        java.lang.InterruptedException - If this thread is interrupted.
        java.io.IOException - If an error occurs while communicating with the system.
        See Also:
        getUserOptions()
      • toString

        public java.lang.String toString()
        Sets the string representation of this User object.
        Overrides:
        toString in class java.lang.Object
        Returns:
        The user profile name.