Files
NapCatQQ/.pnpm-store/v3/files/a5/174b46f07e26f6f4b846b7df494bc17aa2a1223c601ce7439ec9f930494bf102e354efa8f899433e38749a0f728bc0b64a1720f01f63b44a47de1984add958
TanTan e311ca3275
Build NapCat Artifacts / Windows Loader Test (push) Canceled after 0s
Build NapCat Artifacts / Type Check & Test (push) Canceled after 0s
Build NapCat Artifacts / Build NapCat.Framework (push) Canceled after 0s
Build NapCat Artifacts / Build NapCat.Shell (push) Canceled after 0s
docs: 仓库链接指向本镜像仓库
2026-11-13 09:25:58 +08:00

37 lines
1.4 KiB
Plaintext

import { AsnPropTypes, AsnTypeTypes } from "./enums";
import { IAsnConverter, IEmptyConstructor } from "./types";
export type AsnItemType<T = unknown> = AsnPropTypes | IEmptyConstructor<T>;
export interface IAsn1TypeOptions {
type: AsnTypeTypes;
itemType?: AsnItemType;
}
export type AsnRepeatTypeString = "sequence" | "set";
export type AsnRepeatType = AsnRepeatTypeString;
export interface IAsn1PropOptions {
type: AsnItemType;
optional?: boolean;
defaultValue?: unknown;
context?: number;
implicit?: boolean;
converter?: IAsnConverter;
repeated?: AsnRepeatType;
/**
* If true, the raw ASN.1 encoded bytes of the property will be stored in a separate property
* with 'Raw' suffix.
*/
raw?: boolean;
}
export type AsnTypeDecorator = (target: IEmptyConstructor) => void;
export declare const AsnType: (options: IAsn1TypeOptions) => AsnTypeDecorator;
export declare const AsnChoiceType: () => AsnTypeDecorator;
export interface IAsn1SetOptions {
itemType: AsnItemType;
}
export declare const AsnSetType: (options: IAsn1SetOptions) => AsnTypeDecorator;
export interface IAsn1SequenceOptions {
itemType?: AsnItemType;
}
export declare const AsnSequenceType: (options: IAsn1SequenceOptions) => AsnTypeDecorator;
export type AsnPropDecorator = (target: object, propertyKey: string) => void;
export declare const AsnProp: (options: IAsn1PropOptions) => AsnPropDecorator;