projects/m2-core/src/lib/core/utils/object.utils.ts
Methods |
|
| Static addMissingProperties | |||||||||
addMissingProperties(from: T, to: T)
|
|||||||||
Type parameters :
|
|||||||||
|
Add "from" object's properties to "to" object if "to" doesn't have them yet
Parameters :
Returns :
void
|
| Static clear | ||||||
clear(obj: Object)
|
||||||
|
Parameters :
Returns :
void
|
| Static cloneDeep | ||||||
cloneDeep(srcObj: T)
|
||||||
Type parameters :
|
||||||
|
Warning! It's intended that object has constructor that can be safely called without parameters
Parameters :
Returns :
T
|
| Static copyProperties | ||||||||||||||||
copyProperties(from: T, to: T, propertyConfig)
|
||||||||||||||||
Type parameters :
|
||||||||||||||||
|
Copies properties from the first object to the second and returns the second object.
Parameters :
Returns :
T
|
| Static deleteMissingProperties | |||||||||
deleteMissingProperties(source: T, target: T)
|
|||||||||
Type parameters :
|
|||||||||
|
Deletes properties from "target" object that are missed in "source" object
Parameters :
Returns :
void
|
| Static isNullOrEmpty | ||||||
isNullOrEmpty(obj: Object)
|
||||||
|
Parameters :
Returns :
boolean
|
| Static stringify | ||||||||||||
stringify(value: any, omitCircular)
|
||||||||||||
|
Parameters :
Returns :
string
|
| Static validateIsJustCreated | ||||||
validateIsJustCreated(entity: E)
|
||||||
Type parameters :
|
||||||
|
Parameters :
Returns :
boolean
|