Code example for DataOutput

Methods: writeFloat, writeInt

0
  public void read(ByteBuffer buffer) {
    vertex = buffer.getInt();
    weight = buffer.getFloat();
  } 
  public void write(DataOutput buffer) throws IOException {
    buffer.writeInt(vertex);
    buffer.writeFloat(weight);
  } 
  public Object setmyarray(Object array) {
    myarray = (MDefInfluence[])array;
    return this;
  } 
  public Object getmyarray() {
    return myarray;
  } 
  public String toString() {
    StringBuilder sb = new StringBuilder("MDefInfluence:\n");
    sb.append("  vertex: ").append(vertex).append("\n");
    sb.append("  weight: ").append(weight).append("\n");
    return sb.toString();
  }