public void writeExternal(PofWriter pofwriter) throws IOException { pofwriter.writeLong(0, id); pofwriter.writeDouble(1, amount); pofwriter.writeInt(2, quantity); pofwriter.writeInt(3, version); }