public class RDN extends Object implements DEREncoder
Modifier and Type | Field and Description |
---|---|
private AttributeValueAssertion[] |
attributeValueAssertions
Attribute value assertions in this RDN.
|
private static int |
HASH_CODE_SEED
hash code seed.
|
Constructor and Description |
---|
RDN(AttributeValueAssertion... assertions)
Creates a new RDN.
|
RDN(Collection<AttributeValueAssertion> assertions)
Creates a new RDN.
|
Modifier and Type | Method and Description |
---|---|
static RDN[] |
decode(ByteBuffer encoded)
Converts bytes in the buffer to RDNs by reading from the current position to the limit.
|
byte[] |
encode()
Encode this object into it's DER type.
|
boolean |
equals(Object o) |
AttributeValueAssertion.Value |
getAttributeValue(String oid)
Returns a single attribute value for the supplied oid.
|
<T> T |
getAttributeValue(String oid,
ValueTranscoder<T> transcoder)
Returns a single attribute value for the supplied oid.
|
AttributeValueAssertion[] |
getAttributeValueAssertions()
Returns the attribute value assertions in this RDN.
|
AttributeValueAssertion.Value[] |
getAttributeValues(String oid)
Returns the attribute values for the supplied oid.
|
<T> T[] |
getAttributeValues(String oid,
ValueTranscoder<T> transcoder)
Returns the attribute values decoded by the supplied transcoder.
|
int |
hashCode() |
String |
toString() |
private static final int HASH_CODE_SEED
private final AttributeValueAssertion[] attributeValueAssertions
public RDN(Collection<AttributeValueAssertion> assertions)
assertions
- in this RDNpublic RDN(AttributeValueAssertion... assertions)
assertions
- in this RDNpublic AttributeValueAssertion[] getAttributeValueAssertions()
public AttributeValueAssertion.Value[] getAttributeValues(String oid)
oid
- to matchpublic AttributeValueAssertion.Value getAttributeValue(String oid)
getAttributeValues(String)
.oid
- to matchpublic <T> T[] getAttributeValues(String oid, ValueTranscoder<T> transcoder)
T
- type of valueoid
- to matchtranscoder
- to decode the binary valuepublic <T> T getAttributeValue(String oid, ValueTranscoder<T> transcoder)
getAttributeValues(String, ValueTranscoder)
.T
- type of valueoid
- to matchtranscoder
- to decode the binary valuepublic byte[] encode()
DEREncoder
encode
in interface DEREncoder
public static RDN[] decode(ByteBuffer encoded)
encoded
- buffer containing DER-encoded data where the buffer is positioned at the tag of the RDN and the
limit is set beyond the last byte of the RDN.Copyright © 2003-2019 Virginia Tech. All Rights Reserved.