public CRL engineGenerateCRL(InputStream inStream) throws CRLException {
  if (currentCrlStream == null) {
    currentCrlStream=inStream;
    sCrlData=null;
    sCrlDataObjectCount=0;
  }
 else   if (currentCrlStream != inStream) {
    currentCrlStream=inStream;
    sCrlData=null;
    sCrlDataObjectCount=0;
  }
  try {
    if (sCrlData != null) {
      if (sCrlDataObjectCount != sCrlData.size()) {
        return getCRL();
      }
 else {
        sCrlData=null;
        sCrlDataObjectCount=0;
        return null;
      }
    }
    PushbackInputStream pis=new PushbackInputStream(inStream);
    int tag=pis.read();
    if (tag == -1) {
      return null;
    }
    pis.unread(tag);
    if (tag != 0x30) {
      return readPEMCRL(pis);
    }
 else {
      return readDERCRL(new ASN1InputStream(pis,true));
    }
  }
 catch (  CRLException e) {
    throw e;
  }
catch (  Exception e) {
    throw new CRLException(e.toString());
  }
}

public CRL engineGenerateCRL ( InputStream inStream ) throws CRLException { if ( currentCrlStream == null ) { currentCrlStream = inStream ; sCrlData = null ; sCrlDataObjectCount = 0 ; } else if ( currentCrlStream != inStream ) { currentCrlStream = inStream ; sCrlData = null ; sCrlDataObjectCount = 0 ; } try { if ( sCrlData != null ) { if ( sCrlDataObjectCount != sCrlData . size ( ) ) { return getCRL ( ) ; } else { sCrlData = null ; sCrlDataObjectCount = 0 ; return null ; } } PushbackInputStream pis = new PushbackInputStream ( inStream ) ; int tag = pis . read ( ) ; if ( tag == - 1 ) { return null ; } pis . unread ( tag ) ; if ( tag != 0x30 ) { return readPEMCRL ( pis ) ; } else { return readDERCRL ( new ASN1InputStream ( pis , true ) ) ; } } catch ( CRLException e ) { throw e ; } catch ( Exception e ) { throw new CRLException ( e . toString ( ) ) ; } }
generates a certificate revocation list ( crl ) object and initializes it with the data read from the input stream instream .
