src/core/user-profile/common/smart-user-profile.ts
Copyright © 2006-2026 by Consultingwerk Ltd. ("CW") - * www.consultingwerk.com and other contributors as listed * below. All Rights Reserved. * * Software is distributed on an "AS IS", WITHOUT WARRANTY OF ANY * KIND, either express or implied. * * Contributors: * *
Methods |
|
Accessors |
constructor(initialValues: T, profileType: string, profileName: string, profileKey: string)
|
| Public clearChangedKeys |
clearChangedKeys()
|
|
Clears the tracked changed keys. Called after successful persistence.
Returns :
void
|
| Public getChangedKeys |
getChangedKeys()
|
|
Gets the keys that have been changed since the profile was created or last cleared.
Returns :
unknown[]
Array of changed keys |
| Public getChangedValues |
getChangedValues()
|
|
Gets only the changed values from this profile.
Returns :
Partial<T>
Object containing only the changed key-value pairs |
| Public hasValue | ||||||
hasValue(key: unknown)
|
||||||
|
Indicates if this user profile contains a value for the given key
Parameters :
Returns :
boolean
boolean |
| Public setValue | |||||||||
setValue(key: unknown, value: T)
|
|||||||||
|
Updates a value of the user's profile locally
Parameters :
Returns :
void
|
| Public toObject |
toObject()
|
|
A simple object representation of this User Profile
Returns :
T
T |
| userProfleKey |
getuserProfleKey()
|
|
The User Profile Key
Returns :
string
|
| userProfileType |
getuserProfileType()
|
|
The User Profile Type
Returns :
string
|
| userProfileName |
getuserProfileName()
|
|
The User Profile name
Returns :
string
|