public class CVCAFile extends Object
Modifier and Type | Field and Description |
---|---|
static byte |
CAR_TAG |
static int |
LENGTH |
EF_COM_TAG, EF_DG1_TAG, EF_DG10_TAG, EF_DG11_TAG, EF_DG12_TAG, EF_DG13_TAG, EF_DG14_TAG, EF_DG15_TAG, EF_DG16_TAG, EF_DG2_TAG, EF_DG3_TAG, EF_DG4_TAG, EF_DG5_TAG, EF_DG6_TAG, EF_DG7_TAG, EF_DG8_TAG, EF_DG9_TAG, EF_SOD_TAG
Constructor and Description |
---|
CVCAFile(InputStream inputStream) |
CVCAFile(short fid,
InputStream inputStream)
Constructs a new CVCA file from the data contained in an input stream.
|
CVCAFile(short fid,
String caReference)
Constructs a new CVCA file with the given certificate reference.
|
CVCAFile(short fid,
String caReference,
String altCaReference)
Constructs a new CVCA file with the given certificate references.
|
CVCAFile(String caReference,
String altCaReference)
Constructs a new CVCA file with default file identifier.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object other)
Tests whether this CVCAFile is equal to the provided object.
|
CVCPrincipal |
getAltCAReference()
Returns the second (alternative) CA Certificate identifier, null if none
exists.
|
CVCPrincipal |
getCAReference()
Returns the CA Certificate identifier
|
byte[] |
getEncoded()
Gets the contents of this file as byte array,
includes the ICAO tag and length.
|
short |
getFID()
Gets the file identifier of this CVCA file.
|
int |
getLength()
Gets the length of the content of this CVCA file.
|
int |
hashCode()
Computes a hash code of this CVCAFile.
|
protected void |
readObject(InputStream inputStream)
Reads the file from an input stream.
|
String |
toString()
Gets a textual representation of this CVCAFile.
|
protected void |
writeObject(OutputStream outputStream)
Writes the file to an output stream.
|
public static final byte CAR_TAG
public static final int LENGTH
public CVCAFile(InputStream inputStream) throws IOException
IOException
public CVCAFile(short fid, InputStream inputStream) throws IOException
fid
- file identifierinputStream
- stream with the data to be parsedIOException
- on error reading from input streampublic CVCAFile(String caReference, String altCaReference)
caReference
- CA referencealtCaReference
- alternative CA referencepublic CVCAFile(short fid, String caReference, String altCaReference)
fid
- file identifiercaReference
- main CA certificate referencealtCaReference
- second (alternative) CA certificate referencepublic CVCAFile(short fid, String caReference)
fid
- file identifiercaReference
- main CA certificate referencepublic short getFID()
protected void readObject(InputStream inputStream) throws IOException
inputStream
- the input stream to read fromIOException
- if reading failsprotected void writeObject(OutputStream outputStream) throws IOException
outputStream
- the output stream to write toIOException
- if writing failspublic CVCPrincipal getCAReference()
public CVCPrincipal getAltCAReference()
public String toString()
public boolean equals(Object other)
public int hashCode()
public int getLength()
public byte[] getEncoded()
getEncoded
in interface LDSElement
Copyright © 2016. All rights reserved.