attribute.js 909 B

1234567891011121314151617181920212223242526
  1. var PKCS12AttrSet_1;
  2. import { __decorate } from "tslib";
  3. import { AsnProp, AsnPropTypes, AsnArray, AsnType, AsnTypeTypes } from "@peculiar/asn1-schema";
  4. export class PKCS12Attribute {
  5. constructor(params = {}) {
  6. this.attrId = "";
  7. this.attrValues = [];
  8. Object.assign(params);
  9. }
  10. }
  11. __decorate([
  12. AsnProp({ type: AsnPropTypes.ObjectIdentifier })
  13. ], PKCS12Attribute.prototype, "attrId", void 0);
  14. __decorate([
  15. AsnProp({ type: AsnPropTypes.Any, repeated: "set" })
  16. ], PKCS12Attribute.prototype, "attrValues", void 0);
  17. let PKCS12AttrSet = PKCS12AttrSet_1 = class PKCS12AttrSet extends AsnArray {
  18. constructor(items) {
  19. super(items);
  20. Object.setPrototypeOf(this, PKCS12AttrSet_1.prototype);
  21. }
  22. };
  23. PKCS12AttrSet = PKCS12AttrSet_1 = __decorate([
  24. AsnType({ type: AsnTypeTypes.Sequence, itemType: PKCS12Attribute })
  25. ], PKCS12AttrSet);
  26. export { PKCS12AttrSet };