Adds a listener to an event type.
When an event of the type pType fires, the callback pListener will be called. This function
returns a unique string id that may be used in removeEventListenerById to allow simple
listener removal.
It is possible to add an object that will be included in the callback to avoid creating too many closures.
The id of the inserted callback (actually an UUID).
Adds a listener to an event type.
When an event of the type pType fires, the callback pListener will be called. This function
returns a unique string id that may be used in removeEventListenerById to allow simple
listener removal.
The id of the inserted callback (actually an UUID).
Asynchronously gets the information about the specified part instance ids and their genealogy.
Returns a promise.
Please note that in case of multiple promises running at the same time on the same IdCardGetterInterface, the first promises will be signalled as cancelled, the last as ok, but all calls to getPartInstanceInfos after awaiting will return the same value.
If pFilteringContext is modified during the execution, then the call is cancelled (see cancel).
A promise. The promise is resolved with the reason (success, cancelled, disposed, bad input). In case of success, the promise contains the requested Array
part instance ids to fetch metadata from.Asynchronously gets the information about the specified part instance id and its genealogy.
Returns a promise.
Please note that in case of multiple promises running at the same time on the same IdCardGetterInterface, the first promises will be signalled as cancelled, the last as ok, but all calls to getPartInstanceInfos after awaiting will return the same value.
If pFilteringContext is modified during the execution, then the call is cancelled (see cancel).
A promise. The promise is resolved with the reason (success, cancelled, disposed, bad input). In case of success, the promise contains the requested Array
part instance id to fetch metadata from.Cancels the computation of the metadata retrieving process (if any).
A IdCardCancelled signal is emitted if the IdCardGetterInterface is retrieving data.
true if the DocumentIdConverterInterface was running, else false.
Gets rid of this object.
After this call, this object can no longer be used.
If the object is an InfiniteObjectDispatcherInterface, then the ObjectDisposed signal is emitted.
Further uses of the object (with the exception of isDisposed and getInfiniteObjectType) will log a message with LL_UsingDisposedObject.
Tells the type of the given interface.
The type of the given interface.
Each call to retrieveIdCard is assigned a request id.
This call tels the id of the last call to retrieveIdCard.
The id of the last call to retrieveIdCard.
Gets the result of the metadata request.
The metadata content is returned if the IdCardGetterInterface has finished computing. Use addEventListener on the event IdCardReady to know when the IdCardGetterInterface is ready.
DO NOT modify this data in place, this results in undefined behavior.
part instance ids and their genealogy (the size of the array is the number of
part instance ids requested (see [retrieveIdCard](IdCardGetterInterface.html#retrieveIdCard))), or
undefined if the IdCardGetterInterface is computing or if the IdCardGetterInterface is in error or cancelled.
Tells if the EventDispatcher has such a callback registered for the given event type.
true if such a listener is installed for the given type of event.
Tells if the IdCardGetterInterface has been cancelled.
This is generally the case after calling cancel when the IdCardGetterInterface is retrieving data.
true if the IdCardGetterInterface is cancelled.
Tells if this object has been gotten rid off.
true if dispose has been called on this object.
Tells if the IdCardGetterInterface is updating.
This is the case after calling retrieveIdCard.
true if the IdCardGetterInterface is updating.
Removes a listener from an event type.
If no such listener is found, then the function returns false and does nothing. You must use the exact parameters that were used in addEventListener to actually remove the listener.
true if the callback was removed else false.
The listener function that gets removed.
The listener object that was used when addEventListener was called.
Removes a listener from an event type.
If no such listener is found, then the function returns false and does nothing. You must use the exact parameters that were used in addEventListener to actually remove the listener.
true if the callback was removed else false.
The listener function that gets removed.
Removes a listener by its id.
If no such listener is found, then the function returns false and does nothing. You must use the return value of addEventListener to actually remove the listener.
true if the callback was removed else false.
Gets the information about the specified part instance ids and their genealogy.
The IdCardReady signal is fired when the
part instance ids metadata result is ready.
Returns true if the metadata procedure retrieval is started. If not, just call getLastError to
get the reason why the procedure failed. For instance, pPartInstanceIds is considered as invalid input if it is empty
or at least one element is out of range [1 : 2^31-1].
If pFilteringContext is modified during the execution, then the call is cancelled (see cancel).
true if the retrieval procedure has begun.
part instance ids to fetch metadata from.Gets the information about the specified part instance id and its genealogy.
The event IdCardGetterInterfaceSignal.IdCardReady is fired when the
part instance id metadata result is ready.
If pFilteringContext is modified during the execution, then the call is cancelled (see cancel).
Returns true if the metadata procedure retrieval is started. If not, just call getLastError to
get the reason why the procedure failed. For instance, pPartInstanceIds is considered as invalid input if it is empty
or at least one element is out of range [1 - 2^31-1].
true if the retrieval procedure has begun.
part instance id to fetch metadata from.
The IdCardGetterInterface interface is used to retrieve information about a
part instance(and not ageometric instance id), such as the metadata of thepart, link, the list ofpart instanceancestors, attached document, ....The
metadata documentsand general information can be retrieved by knowing thepart instanceto retrieve. If such a document is requested after a picking, then the givengeometric instance idmust be converted to apart instance id.The IdCardGetterInterface interfaces are created through the createIdCardGetter method.
The list of signals the IdCardGetterInterface may trigger is available in the [IdCardGetterInterfaceSignal](../enums/IdCardGetterInterfaceSignal.html) enumeration.
The metadata retrieval procedure is triggered through the retrieveIdCard methods. The result is not available right away, but the event IdCardReady is triggered when the result of the IdCardGetterInterface is available. The result is available through the [getPartInstanceInfos]] function.
Warning : there may be cases when the getPartInstanceInfos is not available such as when the IdCardGetterInterface is updating, i.e. when isRunning returns true, or when the IdCardGetterInterface has been cancelled, i.e. when isCancelled returns true.
An IdCardGetterInterface may be interrupted (cancelled) when the IdCardGetterInterface is updating and cancel is called. In such cases, the IdCardCancelled signal is fired, and shortly after, IdCardReady signal is fired, but getPartInstanceInfos will return undefined. Just call retrieveIdCard with another (or the same)
part instance idsto trigger a new retrieval.If you call multiple times retrieveIdCard before receiving the IdCardReady, only one IdCardReady will be sent with the content of the last call to retrieveIdCard.
The developer may process the results of an id card retrieval with the following code :
or with async calls :
Please make sure the destination browser supports promises before using async calls.
See