Class: AlgorithmIdentifier

Core.PDFNet. AlgorithmIdentifier


new AlgorithmIdentifier()

This class represents an algorithm identifier, as defined by ITU and used in X.509.

Extends

Methods


<static> createFromDigestAlgorithm(digest_algorithm_type)

Constructs an AlgorithmIdentifier from a DigestAlgorithm enum.
Parameters:
Name Type Description
digest_algorithm_type number
PDFNet.DigestAlgorithm.Type = {
	e_SHA1 : 0
	e_SHA256 : 1
	e_SHA384 : 2
	e_SHA512 : 3
	e_RIPEMD160 : 4
	e_unknown_digest_algorithm : 5
}
The enumeration value corresponding to your desired digest algorithm.
Returns:
A promise that resolves to an object of type: "PDFNet.AlgorithmIdentifier"
Type
Promise.<Core.PDFNet.AlgorithmIdentifier>

<static> createFromDigestAlgorithmAndParams(digest_algorithm_type, params)

Constructs an AlgorithmIdentifier from a DigestAlgorithm enum and an AlgorithmParams object.
Parameters:
Name Type Description
digest_algorithm_type number
PDFNet.DigestAlgorithm.Type = {
	e_SHA1 : 0
	e_SHA256 : 1
	e_SHA384 : 2
	e_SHA512 : 3
	e_RIPEMD160 : 4
	e_unknown_digest_algorithm : 5
}
The enumeration value corresponding to your desired digest algorithm.
params Core.PDFNet.AlgorithmParams The AlgorithmParams object to use.
Returns:
A promise that resolves to an object of type: "PDFNet.AlgorithmIdentifier"
Type
Promise.<Core.PDFNet.AlgorithmIdentifier>

<static> createFromObjectIdentifier(oid)

Constructs an AlgorithmIdentifier from an ObjectIdentifier.
Parameters:
Name Type Description
oid Core.PDFNet.ObjectIdentifier The ObjectIdentifier object to use.
Returns:
A promise that resolves to an object of type: "PDFNet.AlgorithmIdentifier"
Type
Promise.<Core.PDFNet.AlgorithmIdentifier>

<static> createFromObjectIdentifierAndParams(oid, params)

Constructs an AlgorithmIdentifier from an ObjectIdentifier and an AlgorithmParams object.
Parameters:
Name Type Description
oid Core.PDFNet.ObjectIdentifier The ObjectIdentifier object to use.
params Core.PDFNet.AlgorithmParams The AlgorithmParams object to use.
Returns:
A promise that resolves to an object of type: "PDFNet.AlgorithmIdentifier"
Type
Promise.<Core.PDFNet.AlgorithmIdentifier>

<static> createFromPredefined(oid_type)

Constructs an AlgorithmIdentifier from a Predefined enum.
Parameters:
Name Type Description
oid_type number
PDFNet.ObjectIdentifier.Predefined = {
	e_commonName : 0
	e_surname : 1
	e_countryName : 2
	e_localityName : 3
	e_stateOrProvinceName : 4
	e_streetAddress : 5
	e_organizationName : 6
	e_organizationalUnitName : 7
	e_SHA1 : 8
	e_SHA256 : 9
	e_SHA384 : 10
	e_SHA512 : 11
	e_RIPEMD160 : 12
	e_RSA_encryption_PKCS1 : 13
	e_RSASSA_PSS : 14
	e_MGF1 : 15
}
The Predefined enumerated value to use.
Returns:
A promise that resolves to an object of type: "PDFNet.AlgorithmIdentifier"
Type
Promise.<Core.PDFNet.AlgorithmIdentifier>

<static> createFromPredefinedAndParams(oid_type, params)

Constructs an AlgorithmIdentifier from a Predefined enum and an AlgorithmParams object.
Parameters:
Name Type Description
oid_type number
PDFNet.ObjectIdentifier.Predefined = {
	e_commonName : 0
	e_surname : 1
	e_countryName : 2
	e_localityName : 3
	e_stateOrProvinceName : 4
	e_streetAddress : 5
	e_organizationName : 6
	e_organizationalUnitName : 7
	e_SHA1 : 8
	e_SHA256 : 9
	e_SHA384 : 10
	e_SHA512 : 11
	e_RIPEMD160 : 12
	e_RSA_encryption_PKCS1 : 13
	e_RSASSA_PSS : 14
	e_MGF1 : 15
}
The Predefined enumerated value to use.
params Core.PDFNet.AlgorithmParams The AlgorithmParams object to use.
Returns:
A promise that resolves to an object of type: "PDFNet.AlgorithmIdentifier"
Type
Promise.<Core.PDFNet.AlgorithmIdentifier>

destroy()

Destructor
Inherited From:
Returns:
Type
Promise.<void>

takeOwnership()

Take the ownership of this object, so that PDFNet.runWithCleanup won't destroy this object.
Inherited From:
Returns:
Type
void