Package net.sf.joafip.store.service.objectio.serialize.output

Examples of net.sf.joafip.store.service.objectio.serialize.output.IObjectOutput.writeBody()


    // storageInfo.setHeaderDataSize(offset);
    final int byteSize = objectOutput
        .byteSize(objectAndPersistInfo, offset);
    final byte[] binary = new byte[byteSize];
    // write
    final ObjectClassInfoAndDeclared[] sons = objectOutput
        .writeBody(binary, offset, objectAndPersistInfo, true/* updateOriginalValue */);
    return new WriteResult(objectAndPersistInfo, sons, binary);
  }

  protected void assertSons(final Object toSerialize,
View Full Code Here


    objectOutput.prepareWrite(objectAndItsClassInfo);
    final byte[] binary = new byte[1000];
    final int offset = storageInfo.getHeaderDataSize();
    storageInfo.setHeaderDataSize(offset);
    // int byte size to skip class name information
    objectOutput
        .writeBody(binary, offset/*
                     * bodyBeginOffset for class id
                     */, objectAndItsClassInfo, false/* updateOriginalValue */);
    // dummy data record identifier for object
    final DataRecordIdentifier dataRecordIdentifier = DataRecordIdentifier.LAST;
View Full Code Here

    if (offset != HEADER_DATA_SIZE) {
      throw new ObjectIOException("header data size miss match");
    }

    /* then object serialization */
    objectOutput.writeBody(binary, offset, toWrite, false);

    try {
      changeFileOutputStream.write(binary, 0, binary.length);
    } catch (final IOException exception) {
      throw new ObjectIOException(exception);
View Full Code Here

    final byte[] binary = new byte[byteSize];
    final int offset = headerWriter.write(classInfo, binary);
    if (offset != HEADER_DATA_SIZE) {
      throw new ObjectIOException("header data size missmatch");
    }
    final ObjectClassInfoAndDeclared[] sonObject = objectOutput.writeBody(
        binary, offset, toWriteObjectAndPersistInfo, true);

    writeDataRecord(dataRecordIdentifier, binary);

    if (logger.debugEnabled) {
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.