Creates a new EntityManagerFactory connected to the given destination
Optional
options: string | { The destination to connect with, or an options object
Private
Optional
[CONNECTED]Indicates if there is currently no exclusive operation executed
true
If no exclusive lock is hold
Apply additional configurations to this EntityManagerFactory
The additional configuration options
Optional
staleness?: numberThe maximum staleness of objects that are acceptable while reading cached
data, 0
to always bypass the browser cache
Optional
tokenThe tokenStorage which should be used by this emf
Optional
tokenThe tokenStorage factory implementation which should be used for token storage
Connects this EntityManager to the given destination
The host or the app name to connect with
Optional
secure: booleantrue
To use a secure connection
Optional
basePath: stringThe base path of the api
Connects this EntityManager to the given destination
The host or the app name to connect with
Optional
port: numberThe port to connect to
Optional
secure: booleantrue
To use a secure connection
Optional
basePath: stringThe base path of the api
Create a new application-managed EntityManager.
a new entityManager
Optional
useSharedTokenStorage: booleanThe token storage to persist the authorization token, or
true
To use the shared token storage of the emf.
false
To use a instance based storage.
Waits on the previously requested operation and calls the doneCallback if the operation is fulfilled
A promise which completes successfully, when the previously requested operation completes
Optional
doneCallback: ((this: EntityManagerFactory) => any)The callback which will be invoked when the previously operations on this object is completed.
Optional
failCallback: ((error: Error) => any)When the lock can't be released caused by a none recoverable error
Protected
withProtected
Try to aquire an exclusive lock and executes the given callback.
A promise
If the lock can't be aquired
The exclusive operation to execute
Optional
critical: boolean = falseIndicates if the operation is critical. If the operation is critical and the operation fails, then the lock will not be released
Generated using TypeDoc
This base class provides an lock interface to execute exclusive operations