es.caib.signatura.impl
Class SMIMEParserProxy

java.lang.Object
  extended by es.caib.signatura.impl.SMIMEParserProxy
All Implemented Interfaces:
SMIMEParser

public class SMIMEParserProxy
extends java.lang.Object
implements SMIMEParser

Proxy que da acceso a la implementación del intérprete de smimes. Guarda internamente una referencia a la implementación del parser de smime en concreto. Cada vez que se parsea un documento se obtiene una referencia a una nueva implementación del intérprete en concreto para ese documento.

Author:
u91940

Constructor Summary
SMIMEParserProxy(java.io.InputStream smime)
           
 
Method Summary
 SMIMEParser getInstance(java.io.InputStream smime)
          Returns a SMIME document parser.
 Signature[] getSignatures()
          Gets an array that contains all the signatures of the SMIME document.
 java.lang.Object getSignedObject()
          Returns the signed object that contains the SMIME document.
 void parse(java.io.InputStream mimeIS)
          This method parses an SMIME document.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SMIMEParserProxy

public SMIMEParserProxy(java.io.InputStream smime)
                 throws java.lang.InstantiationException,
                        java.lang.IllegalAccessException,
                        java.io.IOException,
                        SignatureException
Parameters:
smime -
Throws:
java.lang.InstantiationException
java.lang.IllegalAccessException
java.io.IOException
SignatureException
Method Detail

getInstance

public SMIMEParser getInstance(java.io.InputStream smime)
                        throws java.lang.InstantiationException,
                               java.lang.IllegalAccessException,
                               java.io.IOException,
                               SignatureException
Description copied from interface: SMIMEParser
Returns a SMIME document parser.

Specified by:
getInstance in interface SMIMEParser
Parameters:
smime - SMIME document to parse.
Returns:
the SMIME parser.
Throws:
java.lang.InstantiationException
java.lang.IllegalAccessException
java.io.IOException
SignatureException

getSignatures

public Signature[] getSignatures()
Description copied from interface: SMIMEParser
Gets an array that contains all the signatures of the SMIME document.

Specified by:
getSignatures in interface SMIMEParser
Returns:
The signatures of the SMIME document.

parse

public void parse(java.io.InputStream mimeIS)
           throws java.io.IOException,
                  java.lang.InstantiationException,
                  java.lang.IllegalAccessException,
                  SignatureException
Description copied from interface: SMIMEParser
This method parses an SMIME document.

Specified by:
parse in interface SMIMEParser
Parameters:
mimeIS - Document to parse.
Throws:
java.io.IOException
java.lang.InstantiationException
java.lang.IllegalAccessException
SignatureException

getSignedObject

public java.lang.Object getSignedObject()
Description copied from interface: SMIMEParser
Returns the signed object that contains the SMIME document.

Specified by:
getSignedObject in interface SMIMEParser
Returns:
The signed object (as a byte array).


Copyright © 2011 Direcció General de Tecnologia i Comunicacions. Govern de les Illes Balears. All Rights Reserved.