com.ibm.security.certclient.base

Class PkEventFormatter

  1. java.lang.Object
  2. extended bycom.ibm.security.certclient.base.PkEventFormatter
Direct known subclasses:
PkCmpEventFormatter, PkHttpEventFormatter, PkPkcsEventFormatter

  1. public abstract class PkEventFormatter
  2. extends Object
This is the superclass of all event formatters. Event formatters must implement the 2 abstract methods and as many as the remaining methods as necessary. An event formatter should be able to stream in and out at least some subset of the PKI events.
Author:
Rod Mancisidor

Constructor Summary

Constructor and Description
PkEventFormatter()

Method Summary

Modifier and Type Method and Description
  1. abstract
  2. PkEvent
readEvent(Object source,InputStream in,PkReqEvent req)
Returns a new instance of a subclass of PkEvent by reading it from an inputStream.
  1. void
writeCertRep(PkCertRepEvent rep,OutputStream outputStream)
Writes a PkCertRepEvent to the outputStream.
  1. void
writeCertReq(PkCertReqEvent req,OutputStream outputStream)
Writes a PkCertReqEvent to the outputStream.
  1. void
writeConfRep(PkConfRepEvent rep,OutputStream outputStream)
Writes a PkConfRepEvent to the outputStream.
  1. void
writeConfReq(PkConfReqEvent req,OutputStream outputStream)
Writes a PkConfReqEvent to the outputStream.
  1. void
writeEvent(PkEvent ev,OutputStream outputStream)
Writes a PkEvent to the outputStream.
  1. abstract
  2. void
writeException(Exception e,OutputStream outputStream)
Writes the exception e to the ouputStream
  1. void
writeGnrlRep(PkGnrlRepEvent rep,OutputStream outputStream)
Writes a PkGnrlRepEvent to the outputStream.
  1. void
writeGnrlReq(PkGnrlReqEvent req,OutputStream outputStream)
Writes a PkGnrlReqEvent to the outputStream.
  1. void
writeHttpRep(PkHttpRepEvent rep,OutputStream outputStream)
Writes a PkHttpRepEvent to the outputStream.
  1. void
writeHttpReq(PkHttpReqEvent req,OutputStream outputStream)
Writes a PkHttpReqEvent to the outputStream.
  1. void
writeInitRep(PkInitRepEvent rep,OutputStream outputStream)
Writes a PkInitRepEvent to the outputStream.
  1. void
writeInitReq(PkInitReqEvent req,OutputStream outputStream)
Writes a PkInitReqEvent to the outputStream.
  1. void
writeKrecRep(PkKrecRepEvent rep,OutputStream outputStream)
Writes a PkKrecRepEvent to the outputStream.
  1. void
writeKrecReq(PkKrecReqEvent req,OutputStream outputStream)
Writes a PkKrecReqEvent to the outputStream.
  1. void
writeKupdRep(PkKupdRepEvent rep,OutputStream outputStream)
Writes a PkKupdRepEvent to the outputStream.
  1. void
writeKupdReq(PkKupdReqEvent req,OutputStream outputStream)
Writes a PkKupdReqEvent to the outputStream.
  1. void
writePollReq(PkPollReqEvent req,OutputStream outputStream)
Writes a PkPollReqEvent to the outputStream.
  1. void
writeRep(PkRepEvent rep,OutputStream outputStream)
Writes a PkRepEvent to the outputStream.
  1. void
writeReq(PkReqEvent req,OutputStream outputStream)
Writes a PkReqEvent to the outputStream.
  1. void
writeRevoRep(PkRevoRepEvent rep,OutputStream outputStream)
Writes a PkRevoRepEvent to the outputStream.
  1. void
writeRevoReq(PkRevoReqEvent req,OutputStream outputStream)
Writes a PkRevoReqEvent to the outputStream.
  1. void
writeSecnRep(PkSecnRepEvent rep,OutputStream outputStream)
Writes a PkSecnRepEvent to the outputStream.
  1. void
writeSecnReq(PkSecnReqEvent req,OutputStream outputStream)
Writes a PkSecnReqEvent to the outputStream.
  1. void
writeXcerRep(PkXcerRepEvent rep,OutputStream outputStream)
Writes a PkXcerRepEvent to the outputStream.
  1. void
writeXcerReq(PkXcerReqEvent req,OutputStream outputStream)
Writes a PkXcerReqEvent to the outputStream.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail

PkEventFormatter

  1. public PkEventFormatter()

Method Detail

readEvent

  1. public abstract PkEvent readEvent( Object source,
  2. InputStream in,
  3. PkReqEvent req)
  4. throws PkException
  5. IOException
Returns a new instance of a subclass of PkEvent by reading it from an inputStream. This is a factory method.
Parameters:
source - The instance that creates the event. Usually this.
in - The inputstream from which the event is read.
req - The request that generated the corresponding reply. This parameter can be null when readEvent is expected to return a PkReqevent.
Throws:

writeException

  1. public abstract void writeException( Exception e,
  2. OutputStream outputStream)
  3. throws IOException
Writes the exception e to the ouputStream
Parameters:
e - The exception to write.
outputStream - The output stream where the exception will be written.
Throws:

writeEvent

  1. public void writeEvent(PkEvent ev,
  2. OutputStream outputStream)
  3. throws IOException
Writes a PkEvent to the outputStream.

This is the last method in a PkEventFormatter that has a chance to write an event. This method gets called when the PkEventFormatter has not provided a more specific method to write the event.

Throws:

writeReq

  1. public void writeReq(PkReqEvent req,
  2. OutputStream outputStream)
  3. throws IOException
Writes a PkReqEvent to the outputStream.

This implementation simply invokes the writeReq method.

Throws:

writeHttpReq

  1. public void writeHttpReq(PkHttpReqEvent req,
  2. OutputStream outputStream)
  3. throws IOException
Writes a PkHttpReqEvent to the outputStream.

This implementation simply invokes the writeReq method.

Throws:

writePollReq

  1. public void writePollReq(PkPollReqEvent req,
  2. OutputStream outputStream)
  3. throws IOException
Writes a PkPollReqEvent to the outputStream.

This implementation simply invokes the writeReq method.

Throws:

writeCertReq

  1. public void writeCertReq(PkCertReqEvent req,
  2. OutputStream outputStream)
  3. throws IOException
  4. PkException
Writes a PkCertReqEvent to the outputStream.

This implementation simply invokes the writeReq method.

Throws:

writeInitReq

  1. public void writeInitReq(PkInitReqEvent req,
  2. OutputStream outputStream)
  3. throws IOException
  4. PkException
Writes a PkInitReqEvent to the outputStream.

This implementation simply invokes the writeCertReq method.

Throws:

writeSecnReq

  1. public void writeSecnReq(PkSecnReqEvent req,
  2. OutputStream outputStream)
  3. throws IOException
  4. PkException
Writes a PkSecnReqEvent to the outputStream.

This implementation simply invokes the writeCertReq method.

Throws:

writeKupdReq

  1. public void writeKupdReq(PkKupdReqEvent req,
  2. OutputStream outputStream)
  3. throws IOException
  4. PkException
Writes a PkKupdReqEvent to the outputStream.

This implementation simply invokes the writeCertReq method.

Throws:

writeXcerReq

  1. public void writeXcerReq(PkXcerReqEvent req,
  2. OutputStream outputStream)
  3. throws IOException
  4. PkException
Writes a PkXcerReqEvent to the outputStream.

This implementation simply invokes the writeCertReq method.

Throws:

writeKrecReq

  1. public void writeKrecReq(PkKrecReqEvent req,
  2. OutputStream outputStream)
  3. throws IOException
Writes a PkKrecReqEvent to the outputStream.

This implementation simply invokes the writeReq method.

Throws:

writeConfReq

  1. public void writeConfReq(PkConfReqEvent req,
  2. OutputStream outputStream)
  3. throws IOException
Writes a PkConfReqEvent to the outputStream.

This implementation simply invokes the writeReq method.

Throws:

writeRevoReq

  1. public void writeRevoReq(PkRevoReqEvent req,
  2. OutputStream outputStream)
  3. throws IOException
  4. PkException
Writes a PkRevoReqEvent to the outputStream.

This implementation simply invokes the writeReq method.

Throws:

writeGnrlReq

  1. public void writeGnrlReq(PkGnrlReqEvent req,
  2. OutputStream outputStream)
  3. throws IOException
Writes a PkGnrlReqEvent to the outputStream.

This implementation simply invokes the writeReq method.

Throws:

writeRep

  1. public void writeRep(PkRepEvent rep,
  2. OutputStream outputStream)
  3. throws IOException
  4. PkException
Writes a PkRepEvent to the outputStream.

This implementation simply invokes the writeEvent method.

Throws:

writeHttpRep

  1. public void writeHttpRep(PkHttpRepEvent rep,
  2. OutputStream outputStream)
  3. throws IOException
  4. PkException
Writes a PkHttpRepEvent to the outputStream.

This implementation simply invokes the writeRep method.

Throws:

writeCertRep

  1. public void writeCertRep(PkCertRepEvent rep,
  2. OutputStream outputStream)
  3. throws IOException
  4. PkException
Writes a PkCertRepEvent to the outputStream.

This implementation simply invokes the writeRep method.

Throws:

writeInitRep

  1. public void writeInitRep(PkInitRepEvent rep,
  2. OutputStream outputStream)
  3. throws IOException
  4. PkException
Writes a PkInitRepEvent to the outputStream.

This implementation simply invokes the writeCertRep method.

Throws:

writeSecnRep

  1. public void writeSecnRep(PkSecnRepEvent rep,
  2. OutputStream outputStream)
  3. throws IOException
  4. PkException
Writes a PkSecnRepEvent to the outputStream.

This implementation simply invokes the writeCertRep method.

Throws:

writeKupdRep

  1. public void writeKupdRep(PkKupdRepEvent rep,
  2. OutputStream outputStream)
  3. throws IOException
  4. PkException
Writes a PkKupdRepEvent to the outputStream.

This implementation simply invokes the writeCertRep method.

Throws:

writeXcerRep

  1. public void writeXcerRep(PkXcerRepEvent rep,
  2. OutputStream outputStream)
  3. throws IOException
  4. PkException
Writes a PkXcerRepEvent to the outputStream.

This implementation simply invokes the writeCertRep method.

Throws:

writeKrecRep

  1. public void writeKrecRep(PkKrecRepEvent rep,
  2. OutputStream outputStream)
  3. throws IOException
  4. PkException
Writes a PkKrecRepEvent to the outputStream.

This implementation simply invokes the writeRep method.

Throws:

writeRevoRep

  1. public void writeRevoRep(PkRevoRepEvent rep,
  2. OutputStream outputStream)
  3. throws IOException
  4. PkException
Writes a PkRevoRepEvent to the outputStream.

This implementation simply invokes the writeRep method.

Throws:

writeConfRep

  1. public void writeConfRep(PkConfRepEvent rep,
  2. OutputStream outputStream)
  3. throws IOException
  4. PkException
Writes a PkConfRepEvent to the outputStream.

This implementation simply invokes the writeRep method.

Throws:

writeGnrlRep

  1. public void writeGnrlRep(PkGnrlRepEvent rep,
  2. OutputStream outputStream)
  3. throws IOException
  4. PkException
Writes a PkGnrlRepEvent to the outputStream.

This implementation simply invokes the writeRep method.

Throws: