Package org.bouncycastle.util.io.pem
Class PemObject
- java.lang.Object
-
- org.bouncycastle.util.io.pem.PemObject
-
- All Implemented Interfaces:
PemObjectGenerator
public class PemObject extends Object implements PemObjectGenerator
A generic PEM object - type, header properties, and byte content.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description PemObject
generate()
Generate a PEM object.byte[]
getContent()
List
getHeaders()
String
getType()
-
-
-
Constructor Detail
-
PemObject
public PemObject(String type, byte[] content)
Generic constructor for object without headers.- Parameters:
type
- pem object type.content
- the binary content of the object.
-
-
Method Detail
-
getType
public String getType()
-
getHeaders
public List getHeaders()
-
getContent
public byte[] getContent()
-
generate
public PemObject generate() throws PemGenerationException
Description copied from interface:PemObjectGenerator
Generate a PEM object.- Specified by:
generate
in interfacePemObjectGenerator
- Returns:
- the generated object.
- Throws:
PemGenerationException
- on failure.
-
-