com.ibm.tws.objects.plan
Class WindowsUserInPlan

java.lang.Object
  extended bycom.ibm.tws.objects.plan.WindowsUserInPlan
All Implemented Interfaces:
java.io.Serializable, TWSHeader, TWSObject

public class WindowsUserInPlan
extends java.lang.Object
implements TWSObject, TWSHeader

This class maintains information about Windows users. Since it has no header, it wraps directly a WindowsUserInPlanKey object, which in turn references a WorkstationInPlanKey as part of the Windows user key.

The following syntax validation constraints must be met on WindowsUserInPlan objects:

name The name of an existing Windows User.
workstationKey Reference to an existing workstation
password Not longer than 31 bytes
Null if current password must not be changed

See Also:
Serialized Form

Field Summary
static java.lang.String COPYRIGHT
          Copyright.
 
Constructor Summary
WindowsUserInPlan()
          Creates an empty WindowsUser.
WindowsUserInPlan(Identifier windowsUserId)
          Creates a WindowsUser with the specified identifier.
WindowsUserInPlan(Identifier windowsUserId, WindowsUserInPlanKey windowsUserKey)
          Creates a WindowsUser with the specified Identifier and key.
WindowsUserInPlan(WindowsUserInPlanKey windowsUserKey)
          Creates a WindowsUser with the specified key.
 
Method Summary
 boolean equals(java.lang.Object object)
          Returns true if all fields of this WindowsUser object are equal to those of the given one.
 Identifier getId()
          Returns the windows user Identifier.
 WindowsUserInPlanKey getKey()
          Returns the WindowsUserInPlanKey wrapped by this WindowsUserInPlan object.
 LockData getLockData()
          Return the LockData of the object.
 ModifyData getModifyData()
          Return the ModifyData of the object.
 java.lang.String getName()
          Returns the windows user name.
 TWSHeader getObjectHeader()
          Return the object header.
 TWSKey getObjectKey()
          Returns the object key.
 byte[] getPassword()
          Returns the windows user password.
 Identifier getWorkstationId()
          Returns the Identifier of the workstation referenced by this windows user.
 WorkstationInPlanKey getWorkstationKey()
          Gets the Workstation Key
 int hashCode()
          Returns a hash code for this WindowsUserInPlan object.
 boolean isPasswordEncrypted()
          Returns true if the current windows user password is encrypted.
 void setId(Identifier identifier)
          Sets the windows user Identifier.
 void setKey(WindowsUserInPlanKey windowsUserKey)
          Sets the WindowsUserKey to be wrapped by this WindowsUser object.
 void setName(java.lang.String value)
          Sets the windows user name.
 void setPassword(byte[] value)
          Sets the windows user password.
 void setPassword(byte[] value, boolean isEncrypted)
          Sets the windows user password.
 void setWorkstationId(Identifier identifier)
          Sets the Identifier of the workstation referenced by this windows user.
 void setWorkstationKey(WorkstationInPlanKey key)
          Sets the workstation key.
 java.lang.String toString()
          Returns a string representation of this WindowsUserInPlan.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

COPYRIGHT

public static final java.lang.String COPYRIGHT
Copyright.

Constructor Detail

WindowsUserInPlan

public WindowsUserInPlan()
Creates an empty WindowsUser.


WindowsUserInPlan

public WindowsUserInPlan(Identifier windowsUserId)
Creates a WindowsUser with the specified identifier.

Parameters:
windowsUserId - The windows Use Identifier

WindowsUserInPlan

public WindowsUserInPlan(WindowsUserInPlanKey windowsUserKey)
Creates a WindowsUser with the specified key.

Parameters:
windowsUserKey - The windows user key.

WindowsUserInPlan

public WindowsUserInPlan(Identifier windowsUserId,
                         WindowsUserInPlanKey windowsUserKey)
Creates a WindowsUser with the specified Identifier and key.

Parameters:
windowsUserId - The windows user Identifier.
windowsUserKey - The windows user key.
Method Detail

getId

public Identifier getId()
Returns the windows user Identifier.

Specified by:
getId in interface TWSObject
Returns:
The windows user Identifier.

getObjectKey

public TWSKey getObjectKey()
Returns the object key.

Specified by:
getObjectKey in interface TWSObject
Returns:
The object key.
See Also:
TWSHeader.getObjectKey()

getKey

public WindowsUserInPlanKey getKey()
Returns the WindowsUserInPlanKey wrapped by this WindowsUserInPlan object.

Returns:
The WindowsUserInPlanKey wrapped by this WindowsUserInPlan object.

getName

public java.lang.String getName()
Returns the windows user name.

Specified by:
getName in interface TWSObject
Returns:
The windows user name.

getPassword

public byte[] getPassword()
Returns the windows user password.

Returns:
the windows user password.

isPasswordEncrypted

public boolean isPasswordEncrypted()
Returns true if the current windows user password is encrypted.

Returns:
True if the current windows user password is encrypted.

getWorkstationId

public Identifier getWorkstationId()
Returns the Identifier of the workstation referenced by this windows user.

Returns:
The Identifier of the workstation referenced by this windows user.

setId

public void setId(Identifier identifier)
Sets the windows user Identifier.

Parameters:
identifier - The wndows user Identifier.

setKey

public void setKey(WindowsUserInPlanKey windowsUserKey)
Sets the WindowsUserKey to be wrapped by this WindowsUser object.

Parameters:
windowsUserKey - The WindowsUserKey to be wrapped by this WindowsUser object.

setName

public void setName(java.lang.String value)
Sets the windows user name.

Parameters:
value - The windows user name.

setPassword

public void setPassword(byte[] value)
Sets the windows user password.

Parameters:
value - The windows user password (not encrypted).

setPassword

public void setPassword(byte[] value,
                        boolean isEncrypted)
Sets the windows user password. For internal use only.

Parameters:
value - The windows user password.
isEncrypted - True if the specified password is encrypted.

setWorkstationId

public void setWorkstationId(Identifier identifier)
Sets the Identifier of the workstation referenced by this windows user.

Parameters:
identifier - The identifier of the workstation referenced by this windows user.

equals

public boolean equals(java.lang.Object object)
Returns true if all fields of this WindowsUser object are equal to those of the given one.

Parameters:
object - The object to be compared with this one.
Returns:
True if this object equals to the given one.

hashCode

public int hashCode()
Returns a hash code for this WindowsUserInPlan object.

Returns:
The object's hash code.

toString

public java.lang.String toString()
Returns a string representation of this WindowsUserInPlan.

Returns:
A text string including all WindowsUserInPlan fields.

getObjectHeader

public TWSHeader getObjectHeader()
Return the object header. In this case it is the object itself.

Specified by:
getObjectHeader in interface TWSObject
Returns:
the object header
See Also:
TWSObject.getObjectHeader()

getModifyData

public ModifyData getModifyData()
Return the ModifyData of the object. For plan object it is always null.

Specified by:
getModifyData in interface TWSObject
Returns:
The ModifyData of the object.
See Also:
TWSObject.getModifyData()

getLockData

public LockData getLockData()
Return the LockData of the object. For plan object it is always null.

Specified by:
getLockData in interface TWSObject
Returns:
The LockData of the object.
See Also:
TWSObject.getLockData()

getWorkstationKey

public WorkstationInPlanKey getWorkstationKey()
Gets the Workstation Key

Returns:
the workstation key

setWorkstationKey

public void setWorkstationKey(WorkstationInPlanKey key)
Sets the workstation key.

Parameters:
key - the key that must be set.


Copyright © 2005 IBM All Rights Reserved.