UNPKG

react-native-scanbot-sdk

Version:

Scanbot Document and Barcode Scanner SDK React Native Plugin for Android and iOS

67 lines (60 loc) 2.35 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.RefCountedObjectProfile = void 0; var _JsonSerializationTypes = require("../utils/json/JsonSerializationTypes"); var _utils = require("../utils/utils"); /// Auto-generated with ScanbotSDKCodegenV3. Modifications will be overwritten. /// Generated from core/schemas/ObjectPoolTypes.yaml /** Profile info of a reference-counted stored object. */ class RefCountedObjectProfile extends _utils.PartiallyConstructible { /** Unique ID of the object. */ /** Timestamp (milliseconds since the UNIX epoch), at which the object was first created. */ /** Number of strong references associated with the object. The strong reference count increases when a new instance of a platform ImageRef class is created from the object's unique ID and decreases when the ImageRef instance is destroyed. Default is 0 */ strongReferences = 0; /** Number of serialized references to the object. The serialized reference count increases when an ImageRef is written to JSON or a Parcel on Android and decrease when the respective JSON or Parcel is deserialized. Default is 0 */ serializedReferences = 0; /** @param source {@displayType `DeepPartial<RefCountedObjectProfile>`} */ constructor(source = {}) { super(); if (source.uniqueId !== undefined) { this.uniqueId = source.uniqueId; } else { throw new Error('uniqueId must be present in constructor argument'); } if (source.timestampCreated !== undefined) { this.timestampCreated = source.timestampCreated; } else { throw new Error('timestampCreated must be present in constructor argument'); } if (source.strongReferences !== undefined) { this.strongReferences = source.strongReferences; } if (source.serializedReferences !== undefined) { this.serializedReferences = source.serializedReferences; } } serialize(config = new _JsonSerializationTypes.ToJsonConfiguration()) { return { uniqueId: this.uniqueId, timestampCreated: this.timestampCreated, strongReferences: this.strongReferences, serializedReferences: this.serializedReferences }; } } exports.RefCountedObjectProfile = RefCountedObjectProfile; //# sourceMappingURL=ObjectPoolTypes.js.map