Package org.bouncycastle.asn1
Class BEROctetStringGenerator
java.lang.Object
org.bouncycastle.asn1.ASN1Generator
org.bouncycastle.asn1.BERGenerator
org.bouncycastle.asn1.BEROctetStringGenerator
A generator for indefinite-length OCTET STRINGs
-
Field Summary
Fields inherited from class org.bouncycastle.asn1.ASN1Generator
_out
-
Constructor Summary
ConstructorDescriptionUse the passed in stream as the target for the generator, writing out the header tag for a constructed OCTET STRING.BEROctetStringGenerator
(OutputStream out, int tagNo, boolean isExplicit) Use the passed in stream as the target for the generator, writing out the header tag for a tagged constructed OCTET STRING (possibly implicit). -
Method Summary
Modifier and TypeMethodDescriptionReturn a stream representing the content target for this OCTET STRINGgetOctetOutputStream
(byte[] buf) Return a stream representing the content target for this OCTET STRINGMethods inherited from class org.bouncycastle.asn1.BERGenerator
getRawOutputStream, writeBEREnd, writeBERHeader
-
Constructor Details
-
BEROctetStringGenerator
Use the passed in stream as the target for the generator, writing out the header tag for a constructed OCTET STRING.- Parameters:
out
- target stream- Throws:
IOException
- if the target stream cannot be written to.
-
BEROctetStringGenerator
Use the passed in stream as the target for the generator, writing out the header tag for a tagged constructed OCTET STRING (possibly implicit).- Parameters:
out
- target streamtagNo
- the tag number to introduceisExplicit
- true if this is an explicitly tagged object, false otherwise.- Throws:
IOException
- if the target stream cannot be written to.
-
-
Method Details
-
getOctetOutputStream
Return a stream representing the content target for this OCTET STRING- Returns:
- an OutputStream which chunks data in blocks of 1000 (CER limit).
-
getOctetOutputStream
Return a stream representing the content target for this OCTET STRING- Parameters:
buf
- the buffer to use for chunking the data.- Returns:
- an OutputStream which chunks data in blocks of buf length.
-