Examples of open()


Examples of org.boris.winrun4j.RegistryKey.open()

        // Test registry
        sb.append("\n\nRegistry Test\n=============\n\n");
        RegistryKey key = new RegistryKey(RegistryKey.HKEY_CURRENT_USER,
                "Control Panel\\Appearance\\Schemes");
        key.open();
        String[] names = key.getValueNames();
        for (int i = 0; i < names.length && i < 5; i++) {
            sb.append(names[i]);
            sb.append("\n");
        }
View Full Code Here

Examples of org.bouncycastle.cms.CMSCompressedDataStreamGenerator.open()

        public void write(OutputStream out)
            throws IOException
        {
            CMSCompressedDataStreamGenerator cGen = new CMSCompressedDataStreamGenerator();
           
            OutputStream compressed = cGen.open(out, _compressionOid);
           
            try
            {
                _content.writeTo(compressed);
               
View Full Code Here

Examples of org.bouncycastle.cms.CMSEnvelopedDataStreamGenerator.open()

    public static void encrypt(final InputStream is, OutputStream os, X509Certificate cert) throws Exception {
        final InputStream bis = new BufferedInputStream(is, bufferSize);
        final OutputStream bos = new BufferedOutputStream(os, bufferSize);
        final CMSEnvelopedDataStreamGenerator edGen = new CMSEnvelopedDataStreamGenerator();
        edGen.addKeyTransRecipient(cert.getPublicKey(), "hej".getBytes() );
        final OutputStream out = edGen.open(bos, CMSEnvelopedGenerator.AES128_CBC, "BC");
        fromInToOut(bis, out);
        bos.close();
        os.close();
    }
    /**
 
View Full Code Here

Examples of org.bouncycastle.cms.CMSSignedDataStreamGenerator.open()

        if ( cert!=null ) {
            gen.addSigner(key, cert, digest, providerName);
        } else {
            gen.addSigner(key, "hej".getBytes(), digest, providerName);
        }
        final OutputStream out = gen.open(bos, true);
        fromInToOut(bis, out);
        bos.close();
        os.close();
    }
    public static class VerifyResult {
View Full Code Here

Examples of org.bouncycastle.openpgp.PGPCompressedDataGenerator.open()

        PGPEncryptedDataGenerator encGen = new PGPEncryptedDataGenerator(PGPEncryptedData.CAST5, integrity, new SecureRandom(), "BC");
        encGen.addMethod(key);
        OutputStream encOut = encGen.open(outputStream, new byte[BUFFER_SIZE]);

        PGPCompressedDataGenerator comData = new PGPCompressedDataGenerator(CompressionAlgorithmTags.ZIP);
        OutputStream comOut = new BufferedOutputStream(comData.open(encOut));

        PGPSignatureGenerator sigGen = createSignatureGenerator(exchange, comOut);

        PGPLiteralDataGenerator litData = new PGPLiteralDataGenerator();
        String fileName = exchange.getIn().getHeader(Exchange.FILE_NAME, String.class);
View Full Code Here

Examples of org.bouncycastle.openpgp.PGPEncryptedDataGenerator.open()

            outputStream = new ArmoredOutputStream(outputStream);
        }

        PGPEncryptedDataGenerator encGen = new PGPEncryptedDataGenerator(PGPEncryptedData.CAST5, integrity, new SecureRandom(), "BC");
        encGen.addMethod(key);
        OutputStream encOut = encGen.open(outputStream, new byte[BUFFER_SIZE]);

        PGPCompressedDataGenerator comData = new PGPCompressedDataGenerator(CompressionAlgorithmTags.ZIP);
        OutputStream comOut = new BufferedOutputStream(comData.open(encOut));

        PGPSignatureGenerator sigGen = createSignatureGenerator(exchange, comOut);
View Full Code Here

Examples of org.bouncycastle.openpgp.PGPLiteralDataGenerator.open()

        if (ObjectHelper.isEmpty(fileName)) {
            // This marks the file as For Your Eyes Only... may cause problems for the receiver if they use
            // an automated process to decrypt as the filename is appended with _CONSOLE
            fileName = PGPLiteralData.CONSOLE;
        }
        OutputStream litOut = litData.open(comOut, PGPLiteralData.BINARY, fileName, new Date(), new byte[BUFFER_SIZE]);

        try {
            byte[] buffer = new byte[BUFFER_SIZE];
            int bytesRead;
            while ((bytesRead = input.read(buffer)) != -1) {
View Full Code Here

Examples of org.camunda.bpm.engine.history.HistoricIncidentQuery.open()

  public void testQueryByInvalidOpen() {
    HistoricIncidentQuery query = historyService.createHistoricIncidentQuery();

    try {
      query.open().open();
      fail("It was possible to set a the open flag twice.");
    } catch (ProcessEngineException e) { }
  }

  @Deployment(resources={"org/camunda/bpm/engine/test/api/runtime/oneFailingServiceProcess.bpmn20.xml"})
View Full Code Here

Examples of org.carrot2.util.resource.IResource.open()

                return;
            }
   
            try
            {
                xsltStream = resource.open();
                xsltTemplates = tFactory.newTemplates(new StreamSource(xsltStream));
                config.logger.info("XSL stylesheet loaded successfully from: "
                    + config.xslt);
            }
            catch (IOException e)
View Full Code Here

Examples of org.cdma.interfaces.IDataset.open()

        File newFile = null;
        IDataset dataset = null;
        try {
            newFile = new File(fileURL.toURI());
            dataset = new VcDataset(newFile);
            dataset.open();

        } catch (IOException e1) {
            e1.printStackTrace();
        } catch (URISyntaxException e2) {
            e2.printStackTrace();
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.