public void write(ObjectWriter out, PersistedPropertyData propData) throws IOException
   {
      // write id
      out.writeInt(SerializationConstants.PERSISTED_PROPERTY_DATA);

      out.writeString(propData.getQPath().getAsString());
      out.writeString(propData.getIdentifier());

      if (propData.getParentIdentifier() != null)
      {
         out.writeByte(SerializationConstants.NOT_NULL_DATA);
         out.writeString(propData.getParentIdentifier());
      }
      else
         out.writeByte(SerializationConstants.NULL_DATA);

      out.writeInt(propData.getPersistedVersion());
      // -------------------

      out.writeInt(propData.getType());
      out.writeBoolean(propData.isMultiValued());
      out.writeLong(propData.getPersistedSize());

      List<ValueData> values = propData.getValues();
      if (values != null)
      {
         out.writeByte(SerializationConstants.NOT_NULL_DATA);
         int listSize = values.size();
         out.writeInt(listSize);
         PersistedValueDataWriter wr = new PersistedValueDataWriter();
         for (int i = 0; i < listSize; i++)
         {
            wr.write(out, (PersistedValueData)values.get(i));
         }
      }
      else
      {
         out.writeByte(SerializationConstants.NULL_DATA);
      }

   }
public void write ( ObjectWriter out , PersistedPropertyData propData ) throws IOException { out . writeInt ( SerializationConstants . PERSISTED_PROPERTY_DATA ) ; out . writeString ( propData . getQPath ( ) . getAsString ( ) ) ; out . writeString ( propData . getIdentifier ( ) ) ; if ( propData . getParentIdentifier ( ) != null ) { out . writeByte ( SerializationConstants . NOT_NULL_DATA ) ; out . writeString ( propData . getParentIdentifier ( ) ) ; } else out . writeByte ( SerializationConstants . NULL_DATA ) ; out . writeInt ( propData . getPersistedVersion ( ) ) ; out . writeInt ( propData . getType ( ) ) ; out . writeBoolean ( propData . isMultiValued ( ) ) ; out . writeLong ( propData . getPersistedSize ( ) ) ; List < ValueData > values = propData . getValues ( ) ; if ( values != null ) { out . writeByte ( SerializationConstants . NOT_NULL_DATA ) ; int listSize = values . size ( ) ; out . writeInt ( listSize ) ; PersistedValueDataWriter wr = new PersistedValueDataWriter ( ) ; for ( int i = 0 ; i < listSize ; i ++ ) { wr . write ( out , ( PersistedValueData ) values . get ( i ) ) ; } } else { out . writeByte ( SerializationConstants . NULL_DATA ) ; } }
Write to stream all necessary object data.

@param out SerializationOutputStream.
@throws IOException If an I/O error has occurred.