Cross Point


IUser Interface Reference

Inheritance diagram for IUser:

IXMLBase IEventBase List of all members.

Detailed Description

This interface represents a user object in the reader.

This object is used in the IUserDatabase interface, it encapsulates user information. This simplifies passing user information to and from the user database.

When this reader contains firmware newer then 1.63 and a filesystem of 16 or 17, the user groups, time schemes and validation period features are enabled. For more information regarding user groups and time schemes see IUserGroup and/or ITimeScheme.

Validation periods is a feature that a card is only valid between two specific dates. The card does not have access before the start date and has no access after the end date has passed. This feature is especially useful for visitor cards, or cards for hotel rooms, where a card is only allowed access on a certain day.


Public Member Functions

HRESULT UserDatabase ([out, retval] IUserDatabase **ppintfUserDatabase)
 Returns the userdatabase this user belongs to.

HRESULT Name ([out, retval] BSTR *pbstrName)
 Returns the name of this user.

HRESULT Name ([in] BSTR bstrName)
 Sets the name of this user.

HRESULT CardNumber ([out, retval] BSTR *pbstrCardNumber)
 Gets the card number of this user.

HRESULT CardNumber ([in] BSTR bstrCardNumber)
 Sets the new card number for this user.

HRESULT FacilityCode ([out, retval] BSTR *pbstrFacility)
 Returns the current facility code for this user.

HRESULT FacilityCode ([in] BSTR bstrFacility)
 Sets the facility code for this user.

HRESULT CardType ([out, retval] ECardType *peType)
 Returns the type of the card this user uses.

HRESULT CardType ([in] ECardType eType)
 Sets the type of the card this user uses.

HRESULT CardTypeDescription ([out, retval] BSTR *pbstrCardTypeDescription)
 Returns a description of the current cardtype of this user.

HRESULT Level ([out, retval] EUserLevel *peLevel)
 Returns the user level of this user.

HRESULT Level ([in] EUserLevel eLevel)
 Sets the level of this user.

HRESULT LevelDescription ([out, retval] BSTR *pbstrLevelDescription)
 Returns a description of the level of this user.

HRESULT ValidatePinCode ([in] long PinCode,[out, retval] VARIANT_BOOL *pfValid)
 Validate if a pincode matches with the pincode of this user.

HRESULT SetPinCode ([in] long OldPinCode,[in] long NewPinCode,[out, retval] VARIANT_BOOL *pfSucceeded)
 Sets a new pincode for this user.

HRESULT Save ([in, defaultvalue(0xffff)] VARIANT_BOOL fDisableRFID,[out, retval] VARIANT_BOOL *pfSucceeded)
 Stores the user data in the reader.

HRESULT HasValidPeriod ([out, retval] VARIANT_BOOL *pfValidPeriod)
 Returns true if this user has a validation period.

HRESULT StartDate ([out, retval] DATE *pdtStartDate)
 Returns the start of the valid period of this user.

HRESULT EndDate ([out, retval] DATE *pdtEndDate)
 Returns the end of the valid period of this user.

HRESULT SetValidPeriod ([in, defaultvalue(0)] DATE dtStartDate,[in, defaultvalue(0)] DATE dtEndDate)
 Set the valid period for this user.

HRESULT UserGroup ([out, retval] IUserGroup **ppintfUserGroup)
 Returns this user's user group.

HRESULT UserGroup ([in] IUserGroup *pintfUserGroup)
 Set the user group of this user.

HRESULT UserGroupID ([out, retval] long *plID)
 Returns the ID of the user group of this user.

HRESULT UserGroupID ([in] long lID)
 Set the new user group ID of this user.

HRESULT NumberOfPinAttemptsLeft ([out, retval] short *psAttempts)
 Returns the number of pin attempts left for this user.

HRESULT _ID64 ([out, retval] unsigned __int64 *piID)
 Returns the user ID as a 64 bit value.


Member Function Documentation

IUser::UserDatabase [out, retval] IUserDatabase **  ppintfUserDatabase  ) 
 

Returns the userdatabase this user belongs to.

Parameters:
ppintfUserDatabase Receives the user database object.
Precondition:
ppintfUserDatabase is not NULL.
Note:
This is a read-only property when used in scripting languages.
See also:
IUserDatabase

IUser::Name [out, retval] BSTR *  pbstrName  ) 
 

Returns the name of this user.

Parameters:
pbstrName Receives the current name of this user.
Precondition:
pbstrName is not NULL.

IUser::Name [in] BSTR  bstrName  ) 
 

Sets the name of this user.

Parameters:
bstrName The new user name.

IUser::CardNumber [out, retval] BSTR *  pbstrCardNumber  ) 
 

Gets the card number of this user.

Parameters:
pbstrCardNumber Receives the card number of this user.
Precondition:
pbstrCardNumber is not NULL.
See also:
FacilityCode

IUser::CardNumber [in] BSTR  bstrCardNumber  ) 
 

Sets the new card number for this user.

Parameters:
bstrCardNumber The new card number for this user.
See also:
FacilityCode

IUser::FacilityCode [out, retval] BSTR *  pbstrFacilityCode  ) 
 

Returns the current facility code for this user.

Parameters:
pbstrFacilityCode Receives the facility code of this user.
Precondition:
pbstrFacilityCode is not NULL.
See also:
CardNumber

IUser::FacilityCode [in] BSTR  bstrFacilityCode  ) 
 

Sets the facility code for this user.

Parameters:
bstrFacilityCode The new facility code for this user.
See also:
CardNumber

IUser::CardType [out, retval] ECardType peType  ) 
 

Returns the type of the card this user uses.

Parameters:
peType Receives the current cardtype for this user.
Precondition:
peType is not NULL.
See also:
ECardType, CardTypeDescription

IUser::CardType [in] ECardType  eType  ) 
 

Sets the type of the card this user uses.

Parameters:
eType The new cardtype for this user.
See also:
ECardType, CardTypeDescription

IUser::CardTypeDescription [out, retval] BSTR *  pbstrCardTypeDescription  ) 
 

Returns a description of the current cardtype of this user.

When the current card type of the user is for instance ctCrossPoint, this property will return the string "Cross Point" on a english windows system. The description is loaded from the resource dll of the current selected windows language (if found), so when a Dutch windows version is installed, a dutch description will be returned.

Parameters:
pbstrCardTypeDescription Receives the description.
Precondition:
pbstrCardTypeDescription is not NULL.
Note:
This is a read-only property when used in scripting languages.
See also:
CardType, ECardType

IUser::Level [out, retval] EUserLevel peLevel  ) 
 

Returns the user level of this user.

Parameters:
peLevel Receives the current user level of this user.
Precondition:
peLevel is not NULL.
See also:
EUserLevel, LevelDescription

IUser::Level [in] EUserLevel  eLevel  ) 
 

Sets the level of this user.

Parameters:
eLevel The new user level for this user.
See also:
EUserLevel, LevelDescription

IUser::LevelDescription [out, retval] BSTR *  pbstrLevelDescription  ) 
 

Returns a description of the level of this user.

When the current level of a user is for instance ulInstallerProgrammer, this method will return the string "Installer programmer" on a english windows system. The description is loaded from a resource dll (only if the correct language dll can be found). Note that when for instance a Dutch windows version is installed, a dutch description will be returned.

Parameters:
pbstrLevelDescription Receives the level description.
Note:
This is a read-only property when used in scripting languages.
See also:
EUserLevel, Level

IUser::ValidatePinCode [in] long  lPinCode,
[out, retval] VARIANT_BOOL *  pfValid
 

Validate if a pincode matches with the pincode of this user.

Returns true if lPinCode matches the current pincode of this user.

Parameters:
lPinCode The pincode that should be checked.
pfValid Set to true if lPinCode is valid for this user.
Precondition:
pfValid is not NULL.
See also:
SetPinCode

IUser::SetPinCode [in] long  lOldPinCode,
[in] long  lNewPinCode,
[out, retval] VARIANT_BOOL *  pfSucceeded
 

Sets a new pincode for this user.

The PinCode may only be changed if the old pincode of this user is also passed to this method and if it matches the current pincode of this user.

Parameters:
lOldPinCode The old pin-code for this user (use -1 when setting the pincode for a new user).
lNewPinCode The new pin-code for this user.
pfSucceeded Set to true when the password has been successfully changed (False when the supplied lOldPinCode is invalid).
Precondition:
pfSucceeded is not NULL.
See also:
ValidatePinCode

IUser::Save [in, defaultvalue(0xffff)] VARIANT_BOOL  fDisableRFID,
[out, retval] VARIANT_BOOL *  pfSucceeded
 

Stores the user data in the reader.

The user will only be saved when the data of this user is changed. When saving a lot of users after each other, it is faster to disable the RFID interface before saving the first user, and re-enable it after the last user has been saved (and setting the fDisableRFID flag to false). See IProximityReader::EnableRFID for more information.

If a new user is saved (one that is not known in the userdatabase), the IUserDatabase will fire an OnProcessInfo event of processtype ptUserdatabaseChange with a sub process type of sptItemAdded. The new user will be passed in the Info argument. The new user object is also added to the user database internal collection of users. So calling the collection returned by IUserDatabase::Users will also contain the new user.

If an existing user is modified, the same event is fire, but the sub process type will then be set to sptItemModified.

Parameters:
fDisableRFID When set to true (default), the RFID interface will be disabled while saving this user and re-enabled after the saving process. This ensures that a user presenting a card cannot interfere.
pfSucceeded Will be set to true upon success.
See also:
IUserDatabase::CollectUsers, IUserDatabase::Users

IUser::HasValidPeriod [out, retval] VARIANT_BOOL *  pfValidPeriod  ) 
 

Returns true if this user has a validation period.

Parameters:
pfValidPeriod Receives true if this user has a validation period.
Precondition:
pfValidPeriod is not NULL.
See also:
SetValidPeriod, StartDate, EndDate

IUser::StartDate [out, retval] DATE *  pdtStartDate  ) 
 

Returns the start of the valid period of this user.

The user will not be granted access before the start date returned by this property. When the startdate is set to 0, the user will always have access (until the end-date occurs).

Parameters:
pdtStartDate Receives the current start date for this user.
Precondition:
pdtStartDate is not NULL.
See also:
SetValidPeriod

IUser::EndDate [out, retval] DATE *  pdtEndDate  ) 
 

Returns the end of the valid period of this user.

The user will not be granted access after the end date returned by this property. When the enddate is set to 0, the user will be have always access (after the start-date).

Parameters:
pdtEndDate Receives the current end date for this user.
Precondition:
pdtEndDate is not NULL.
See also:
SetValidPeriod

IUser::SetValidPeriod [in, defaultvalue(0)] DATE  dtStartDate,
[in, defaultvalue(0)] DATE  dtEndDate
 

Set the valid period for this user.

Parameters:
dtStartDate The start date. When this date is set to 0, the user will have access directly (until the end date).
dtEndDate The end date. Set to 0 for inifite.
See also:
StartDate, EndDate

IUser::UserGroup [out, retval] IUserGroup **  ppintfUserGroup  ) 
 

Returns this user's user group.

The user group is only returned if user groups are supported by the current firmware and filesystem of this reader, else an error is returned.

Parameters:
ppintfUserGroup Receives the user group object.
Precondition:
ppintfUserGroup is not NULL.
See also:
UserGroupID, IUserGroup

IUser::UserGroup [in] IUserGroup pintfUserGroup  ) 
 

Set the user group of this user.

If user groups are not supported by the current firmware and filesystem of this reader, an error is returned.

Parameters:
pintfUserGroup The new user group for this user.
See also:
UserGroupID, IUserGroup

IUser::UserGroupID [out, retval] long *  plID  ) 
 

Returns the ID of the user group of this user.

If user groups are not supported by the current firmware and filesystem of this reader, an error is returned.

Parameters:
plID Receives the ID of the user group of this user.
Precondition:
plID is not NULL.
See also:
UserGroupID, IUserGroup

IUser::UserGroupID [in] long  lID  ) 
 

Set the new user group ID of this user.

If user groups are not supported by the current firmware and filesystem of this reader, an error is returned.

Parameters:
lID The ID of the new user group for this user.
See also:
UserGroupID, IUserGroup

IUser::NumberOfPinAttemptsLeft [out, retval] short *  psAttempts  ) 
 

Returns the number of pin attempts left for this user.

When this value is 0, the user is blocked. The pin code should then be reset before the user can use it's ID card again.

Parameters:
psAttempts Receives the number of pin attempts left.
Precondition:
psAttempts is not NULL.
See also:
SetPinCode

IUser::_ID64 [out, retval] unsigned __int64 *  piID  ) 
 

Returns the user ID as a 64 bit value.

Parameters:
piID Receives the ID.
Precondition:
piID is not NULL.


© Copyright 2001 - 2006 Cross Point. Generated on Mon Mar 12 16:29:52 2007 Cross Point