Information Class
addon/utils/information.js:7
Class for loading metadata about models.
Item Index
Methods
createEnum
-
dictionary
Returns friezed object without prototype with own properties of parameter.
Returns:
enumCaptions
-
dictionary
Returns object without null values.
Parameters:
-
dictionary
Object
Returns:
firstLoadOfflineObjects
-
dexieDB
-
odataPath
-
functionName
-
modelName
-
count
-
top
-
skip
-
idPath
Load and save offline objects provided by odata function or returns objects count. Tables with objects to load must be empty.
Parameters:
-
dexieDB
ObjectDexie DB (example: dexieService.dexie('DB name', store)).
-
odataPath
StringOdata Url (example: 'http://localhost:35904/odata').
-
functionName
StringOdata function name.
-
modelName
StringModel name for objects.
-
count
BoolFlag indicates that function returns objects or objects count.
-
top
IntegerAmount of objects to load.
-
skip
IntegerAmount of objects to skip from result.
-
idPath
StringPath to string id in JSON ('guid' by default).
Returns:
getType
-
modelName
-
attributePath
Returns the type of the specified attribute path.
Returns:
The type of the specified attribute path.
inverseEnum
-
dictionary
Returns friezed inversed object without prototype.
Parameters:
-
dictionary
Object
Returns:
isAttribute
-
modelName
-
attributePath
Checks if the specified attribute path is an attribute.
Returns:
True if the specified attribute path is an attribute.
isDetail
-
modelName
-
attributePath
Checks if the specified attribute path is a detail field.
Returns:
True if the specified attribute path is a detail field.
isExist
-
modelName
-
attributePath
Checks if the specified attribute path is exist.
Returns:
True if the specified attribute path is exist.
isKey
-
modelName
-
attributePath
Checks if the specified attribute path is a key (i.e. it is an id or belongsTo relationship).
Returns:
True if the specified attribute path is a key.
isMaster
-
modelName
-
attributePath
Checks if the specified attribute path is a master field.
Returns:
True if the specified attribute path is a master field.
isOrdered
-
modelName
-
attributePath
Checks if the specified attribute path is a ordered field.
Returns:
True if the specified attribute path is a detail field.