Examples of writeData()


Examples of org.apache.poi.poifs.property.DocumentProperty.writeData()

        {
            testblock[ index * 2 ] = name_bytes[ index ];
        }
        ByteArrayOutputStream stream = new ByteArrayOutputStream(512);

        property.writeData(stream);
        byte[] output = stream.toByteArray();

        assertEquals(testblock.length, output.length);
        for (int j = 0; j < testblock.length; j++)
        {
View Full Code Here

Examples of org.apache.sanselan.formats.tiff.fieldtypes.FieldType.writeData()

    FieldType fieldType = tagInfo.dataTypes[0];

    if (tagInfo.length != 1)
      throw new ImageWriteException("Tag does not expect a single value.");

    byte bytes[] = fieldType.writeData(number, byteOrder);

    return new TiffOutputField(tagInfo.tag, tagInfo, fieldType, 1, bytes);
  }

View Full Code Here

Examples of org.drools.guvnor.server.files.Response.writeData()

                        }
                        Response apiRes = api.get(ur);
                        res.setContentType("application/x-download");
                        res.setHeader("Content-Disposition",
                                "attachment; filename=data;");
                        apiRes.writeData(res.getOutputStream());
                        res.getOutputStream().flush();
                    }
                });

    }
View Full Code Here

Examples of org.drools.guvnor.server.files.Response.Text.writeData()


        Response resp = api.get("packages/testVersionHistoryAndArchived/asset1.drl?version=all");
        ByteArrayOutputStream out = new ByteArrayOutputStream();

        res.writeData(out);
        String d = new String(out.toByteArray());
        assertNotNull(d);

        resp = api.get("packages/testVersionHistoryAndArchived/asset2.drl?version=all");
        out = new ByteArrayOutputStream();
View Full Code Here

Examples of org.drools.repository.remoteapi.Response.writeData()

                        }
                        Response apiRes = api.get(ur);
                        res.setContentType("application/x-download");
                        res.setHeader("Content-Disposition",
                                "attachment; filename=data;");
                        apiRes.writeData(res.getOutputStream());
                        res.getOutputStream().flush();
                    }
                });

    }
View Full Code Here

Examples of org.drools.repository.remoteapi.Response.Binary.writeData()

    Binary b = new Response.Binary();
    ByteArrayInputStream in = new ByteArrayInputStream("abc".getBytes());
    b.stream = in;
    ByteArrayOutputStream out = new ByteArrayOutputStream();

    b.writeData(out);

    byte[] d = out.toByteArray();
    assertEquals(3, d.length);

    String s = new String(d);
View Full Code Here

Examples of org.drools.repository.remoteapi.Response.Text.writeData()


    Response resp = api.get("packages/testVersionHistoryAndArchived/asset1.drl?version=all");
    ByteArrayOutputStream out = new ByteArrayOutputStream();

    res.writeData(out);
    String d = new String(out.toByteArray());
    assertNotNull(d);

    resp = api.get("packages/testVersionHistoryAndArchived/asset2.drl?version=all");
    out = new ByteArrayOutputStream();
View Full Code Here

Examples of org.gephi.graph.dhns.utils.DataSerializer.writeData()

    public void writeXML(XMLStreamWriter writer, Workspace workspace) {
        Dhns dhns = workspace.getLookup().lookup(Dhns.class);
        DataSerializer serializer = new DataSerializer();
        try {
            serializer.writeData(writer, dhns);
        } catch (XMLStreamException ex) {
            throw new RuntimeException(ex);
        }
    }
View Full Code Here

Examples of org.jamesii.core.data.runtime.IWriteReadDataStorage.writeData()

    } catch (DataStorageException expected) {
    }

    // this should throw an Exception, that no ExpId has been set:
    try {
      bns.writeData(42, "bla", 13.37, "zweiundvierzig");
      fail("ExpID hast to be set before.");
    } catch (DataStorageException expected) {
    }

    // this should throw an Exception, that no SimId has been set:
View Full Code Here

Examples of org.jboss.serial.persister.Persister.writeData()

            }
           
            Persister persister = PersistResolver.resolvePersister(obj,metaData);

            outputParent.writeByte(persister.getId());
            persister.writeData(metaData, cache.getOutput(), obj, cache.getSubstitution());

            return;
        }
    }
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.