Пример #1
0
  /**
   * Fields to restore before calling this method:
   *
   * <p>rootNode [RADFormNode] designForm [DesignForm]
   */
  public void writeExternal(java.io.ObjectOutput oo) throws java.io.IOException {
    // store the version
    oo.writeObject(nbClassVersion);

    oo.writeObject(rootNode);
    oo.writeObject(designForm);
  }
Пример #2
0
 public void writeExternal(ObjectOutput out) throws IOException {
   out.writeObject(factHandle);
   out.writeBoolean(removeLogical);
   out.writeBoolean(updateEqualsMap);
   out.writeObject(ruleOrigin);
   out.writeObject(leftTuple);
 }
Пример #3
0
 public void writeExternal(ObjectOutput out) throws IOException {
   super.writeExternal(out);
   out.writeBoolean(unwrapRightObject);
   out.writeObject(accumulate);
   out.writeObject(resultConstraints);
   out.writeObject(resultBinder);
 }
 public void writeExternal(ObjectOutput out) throws IOException {
   out.writeObject(this.element1);
   out.writeObject(this.element2);
   out.writeObject(this.element3);
   out.writeObject(this.element4);
   out.writeObject(this.element5);
 }
Пример #5
0
  /** @see BTmsg#writeExternal(java.io.ObjectOutput) */
  @Override
  public void writeExternal(ObjectOutput out) throws IOException {
    super.writeExternal(out);

    assert this.offset < Short.MAX_VALUE;
    out.writeShort(this.offset);
    assert this.nbrAssignments < Short.MAX_VALUE;
    out.writeShort(this.nbrAssignments);
    V val = this.assignments[this.offset][0];
    out.writeObject(val); // first assignment
    final boolean externalize = val.externalize();

    // Write the assignments one by one
    for (int i = this.offset; i < this.nbrAssignments; i++) { // the assignments
      V[] assignment = this.assignments[i];
      assert assignment.length < Short.MAX_VALUE;
      out.writeShort(assignment.length);
      for (int j = assignment.length - 1; j >= 0; j--) {
        if (externalize) assignment[j].writeExternal(out);
        else out.writeObject(assignment[j]);
      }
    }

    out.writeObject(this.cost);
  }
Пример #6
0
 public void writeExternal(ObjectOutput out) throws IOException {
   super.writeExternal(out);
   out.writeObject(rmAddress);
   out.writeObject(filter);
   out.writeInt(port);
   out.writeObject(usedAcc);
 }
 @Override
 public void writeExternal(ObjectOutput out) throws IOException {
   out.writeObject(this.propertyName);
   out.writeObject(this.persistList);
   out.writeBoolean(this.clear);
   out.writeBoolean(this.exclusive);
 }
 /**
  * compare the byte-array representation of two TaskObjects.
  *
  * @param f TaskObject
  * @param s TaskObject
  * @return true if the two arguments have the same byte-array
  */
 private boolean sameBytes(TaskObject f, TaskObject s) {
   ByteArrayOutputStream bos = new ByteArrayOutputStream();
   ObjectOutput out = null;
   try {
     out = new ObjectOutputStream(bos);
     out.writeObject(f);
     byte[] fs = bos.toByteArray();
     out.writeObject(s);
     byte[] ss = bos.toByteArray();
     if (fs.length != ss.length) return false;
     for (int i = 0; i < fs.length; i++) {
       if (fs[i] != ss[i]) return false;
     }
     return true;
   } catch (IOException e) {
     e.printStackTrace();
     return false;
   } finally {
     if (out != null) {
       try {
         out.close();
       } catch (IOException e) {
         // ignore
       }
       try {
         bos.close();
       } catch (IOException e) {
         // ignore
       }
     }
   }
 }
Пример #9
0
 public void writeExternal(ObjectOutput out) throws IOException {
   out.writeInt(1); // version
   if (first instanceof Serializable) out.writeObject(first);
   else out.writeObject(null);
   if (second instanceof Serializable) out.writeObject(second);
   else out.writeObject(null);
 }
 public void writeExternal(ObjectOutput out) throws IOException {
   super.writeExternal(out);
   out.writeInt(LATEST_VERSION);
   out.writeObject(username);
   out.writeObject(dn);
   out.writeObject(tokenTypeLabel);
 }
Пример #11
0
  /**
   * Implements Externalizable interface to write serialized form
   *
   * @param s Output stream to serialize to
   */
  public void writeExternal(java.io.ObjectOutput s) throws IOException {
    // Write column names and column information
    int numFields = 0;
    if (fields == null) {
      s.writeInt(0);
    } else {
      numFields = fields.size();
      s.writeInt(numFields);
      for (int i = 0; i < numFields; i++) {
        String fieldName = (String) fields.get(i);
        s.writeUTF(fieldName);
        s.writeObject(columnInfos.get(fieldName));
      }
    }

    // Write record data
    if (records == null) {
      s.writeInt(0);
    } else {
      int numRows = records.size();
      s.writeInt(numRows);
      for (int row = 0; row < numRows; row++) {
        List record = (List) records.get(row);
        for (int col = 0; col < numFields; col++) {
          s.writeObject(record.get(col));
        }
      }
    }
  }
Пример #12
0
  private void writeTo(ObjectOutput o) throws IOException {
    o.writeInt(x);
    o.writeInt(y);
    o.writeInt(width);
    o.writeInt(height);
    o.writeInt(measuredWidth);
    o.writeInt(measuredHeight);
    o.writeInt(scrollX);
    o.writeInt(scrollY);
    o.writeInt(absoluteX);
    o.writeInt(absoluteY);
    o.writeFloat(cameraDistance);
    o.writeBoolean(visible);
    o.writeLong(drawingTime);
    o.writeBoolean(isShown);
    o.writeBoolean(hasFocus);
    o.writeBoolean(focusable);
    o.writeBoolean(hasOnClickListener);
    o.writeObject(viewType);
    o.writeObject(textContent);
    o.writeBoolean(isEditText);
    o.writeBoolean(isInputMethodTarget);
    o.writeBoolean(isContainer);
    o.writeInt(inputMethod);
    o.writeInt(id);

    if (children != null) {
      o.writeInt(children.size());
      for (ViewComponentInfo child : children) {
        child.writeTo(o);
      }
    } else {
      o.writeInt(0);
    }
  }
Пример #13
0
 @Override
 public void writeObject(ObjectOutput output, CacheTopology cacheTopology) throws IOException {
   output.writeInt(cacheTopology.topologyId);
   output.writeObject(cacheTopology.currentCH);
   output.writeObject(cacheTopology.pendingCH);
   output.writeObject(cacheTopology.unionCH);
 }
Пример #14
0
 @Override
 public void writeExternal(final ObjectOutput out) throws IOException {
   super.writeExternal(out);
   out.writeObject(this.key);
   out.writeObject(this.text);
   out.writeObject(this.nextEvent);
 }
Пример #15
0
 public void writeExternal(ObjectOutput out) throws IOException {
   super.writeExternal(out);
   out.writeObject(tupleSource);
   out.writeBoolean(tupleMemoryEnabled);
   out.writeObject(previousTupleSinkNode);
   out.writeObject(nextTupleSinkNode);
 }
Пример #16
0
 @Override
 public void writeExternal(ObjectOutput out) throws IOException {
   out.writeObject(renderResult);
   out.writeObject(headers);
   out.writeBoolean(eager);
   out.writeUTF(resultContent);
 }
Пример #17
0
 public void writeExternal(ObjectOutput out) throws IOException {
   super.writeExternal(out);
   out.writeObject(queryElement);
   out.writeObject(tupleSource);
   out.writeBoolean(tupleMemoryEnabled);
   out.writeBoolean(openQuery);
 }
 public void writeExternal(ObjectOutput out) throws IOException {
   out.writeObject(otherSinks);
   out.writeObject(hashableSinks);
   out.writeObject(hashedFieldIndexes);
   out.writeObject(hashedSinkMap);
   out.writeInt(alphaNodeHashingThreshold);
 }
Пример #19
0
 /*
  * (non-Javadoc)
  *
  * @see java.io.Externalizable#writeExternal(java.io.ObjectOutput)
  */
 public void writeExternal(ObjectOutput out) throws IOException {
   out.writeUTF(this.expr);
   out.writeUTF((this.expectedType != null) ? this.expectedType.getName() : "");
   out.writeObject(ReflectionUtil.toTypeNameArray(this.paramTypes));
   out.writeObject(this.fnMapper);
   out.writeObject(this.varMapper);
 }
Пример #20
0
 public void writeExternal(ObjectOutput out) throws IOException {
   out.writeObject(name);
   out.writeLong(measurements);
   out.writeDouble(min);
   out.writeDouble(max);
   out.writeDouble(total);
   out.writeObject(childs);
 }
Пример #21
0
 public void writeExternal(ObjectOutput out) throws IOException {
     out.writeObject(sender);
     out.writeBoolean(merge_rejected);
     if(!merge_rejected) {
         out.writeObject(view);
         out.writeObject(digest);
     }
 }
 public void writeExternal(ObjectOutput out) throws IOException {
   out.writeObject(tree);
   out.writeObject(ascendingIndex);
   out.writeObject(ascendingConstraintType);
   out.writeObject(descendingIndex);
   out.writeObject(descendingConstraintType);
   out.writeInt(size);
 }
Пример #23
0
 @Override
 public void writeTo(ObjectOutput output) throws IOException {
   output.writeObject(key);
   output.writeObject(value);
   output.writeLong(Flag.copyWithoutRemotableFlags(getFlagsBitSet()));
   MarshallUtil.marshallEnum(valueMatcher, output);
   output.writeObject(commandInvocationId);
 }
Пример #24
0
 @Override
 public void writeExternal(ObjectOutput out) throws IOException {
   super.writeExternal(out);
   out.writeInt(index);
   out.writeObject(fieldName);
   out.writeObject(initExpr);
   out.writeObject(pattern);
 }
Пример #25
0
 private void save(String file) throws IOException {
   OutputStream buffer;
   buffer = new BufferedOutputStream(new FileOutputStream(file));
   ObjectOutput output = new ObjectOutputStream(buffer);
   output.writeObject(trigramTable);
   output.writeObject(bigramTable);
   output.close();
 }
Пример #26
0
 public void writeExternal(ObjectOutput out) throws IOException {
   super.writeExternal(out);
   out.writeObject(dataProvider);
   out.writeObject(alphaConstraints);
   out.writeObject(betaConstraints);
   out.writeBoolean(tupleMemoryEnabled);
   out.writeObject(from);
 }
Пример #27
0
 @Override
 public void writeExternal(ObjectOutput out) throws IOException {
   super.writeExternal(out);
   out.writeObject(returnType);
   out.writeObject(params);
   out.writeObject(value);
   out.writeBoolean(returnBound);
 }
Пример #28
0
 @Override
 public void writeExternal(ObjectOutput out) throws IOException {
   out.writeObject(animationIndex);
   out.writeInt(animations.size());
   for (int i = 0; i < animations.size(); i++) {
     out.writeObject(animations.get(i));
   }
 }
Пример #29
0
 public final void writeExternal(final ObjectOutput out) throws IOException {
   out.writeInt(listTable.length);
   out.writeInt(size);
   for (int i = 0; i < size; i++) {
     out.writeObject(listTable[i].key);
     out.writeObject(listTable[i].value);
   }
 }
 @Override
 public void writeObject(ObjectOutput output, OffHeapMetadataTransientCacheEntry ice)
     throws IOException {
   output.writeObject(ice.key);
   output.writeObject(ice.value);
   output.writeObject(ice.metadata);
   UnsignedNumeric.writeUnsignedLong(output, ice.lastUsed);
 }