Skip to content
asn1jsasn1jsasn1jsv4.1.0

ObjectIdentifier

  • BaseBlock<LocalObjectIdentifierValueBlock, LocalObjectIdentifierValueBlockJson>

new ObjectIdentifier(parameters?): ObjectIdentifier

ObjectIdentifierParams = {}

ObjectIdentifier

BaseBlock.constructor

blockLength: number

BaseBlock.blockLength


error: string

BaseBlock.error


idBlock: LocalIdentificationBlock

BaseBlock.idBlock


lenBlock: LocalLengthBlock

BaseBlock.lenBlock


name: string

BaseBlock.name


optional: boolean

BaseBlock.optional


optional primitiveSchema?: BaseBlock<ValueBlock, LocalBaseBlockJson>

BaseBlock.primitiveSchema


valueBeforeDecodeView: Uint8Array

3.0.0

BaseBlock.valueBeforeDecodeView


valueBlock: LocalObjectIdentifierValueBlock

BaseBlock.valueBlock


warnings: string[]

BaseBlock.warnings


static NAME: string = "OBJECT IDENTIFIER"

Name of the block

BaseBlock.NAME

get strict(): boolean

Whether value assignment and encoding throw on invalid OIDs. Defaults to false. Changing this flag does not validate or alter the value; the next assignment or encoding checks it.

boolean

set strict(value): void

boolean

void


get valueBeforeDecode(): ArrayBuffer

ArrayBuffer

set valueBeforeDecode(value): void

ArrayBuffer

void

BaseBlock.valueBeforeDecode

fromBER(inputBuffer, inputOffset, inputLength, context?): number

Replaces decoded value state and refreshes diagnostics using the prepared length block.

Uint8Array

number

number

FromBerContext

number

BaseBlock.fromBER


getValue(): string

Gets string representation of Object Identifier

string

3.0.0


isEqual(other): other is ObjectIdentifier

Determines whether two object instances are equal

unknown

Object to compare with the current object

other is ObjectIdentifier

BaseBlock.isEqual


setValue(value): void

Sets Object Identifier value from a complete decimal string. Invalid input clears the value and sets error and valueBlock.error. Throws when strict is enabled; a successful assignment clears previous value errors.

string

String value

void

3.0.0


toBER(sizeOnly?, writer?): ArrayBuffer

Encodes the value and copies value errors to this block’s diagnostics. In strict mode, invalid values throw, including for sizeOnly and nested encoding. Discard an externally supplied writer if encoding throws; writes are not rolled back.

boolean

ViewWriter

ArrayBuffer

BaseBlock.toBER


toJSON(): ObjectIdentifierJson

Returns a JSON representation of an object

ObjectIdentifierJson

JSON object

BaseBlock.toJSON


toString(encoding?): string

Returns a string representation of an object.

StringEncoding = "ascii"

string

BaseBlock.toString


static blockName(): string

Aux function, need to get a block name. Need to have it here for inheritance

string

Returns name of the block

BaseBlock.blockName