Write this object to the ObjectOutputStream.

Note, this is overriding the default Serialize interface implementation.

@see java.io.Serializable
423982
private void writeObject(ObjectOutputStream out) throws IOException {

        final boolean isTraceOn = TraceComponent.isAnyTracingEnabled();
        if (isTraceOn && tc.isEntryEnabled())
            Tr.entry(tc, "writeObject: " + this);

        // Use v1 unless features are present that require v2.
        int version = Constants.TIMER_TASK_V1;
        if (parsedSchedule != null) {
            version = Constants.TIMER_TASK_V2;
        }

        out.defaultWriteObject();

        // Write out header information first.
        out.write(EYECATCHER);
        out.writeShort(PLATFORM);
        out.writeShort(version);

        // Write out the instance data.
        out.writeObject(j2eeName.getBytes());
        out.writeObject(userInfoBytes);

        switch (version) {

            case Constants.TIMER_TASK_V1:
                out.writeLong(expiration);
                out.writeLong(interval);
                break;

            case Constants.TIMER_TASK_V2:
                out.writeObject(parsedSchedule);
                out.writeInt(methodId);
                out.writeObject(automaticMethodName);
                out.writeObject(automaticClassName);
                break;

            default:
                // cannot occur since initialize above
                break;
        }

        if (isTraceOn && tc.isEntryEnabled())
            Tr.exit(tc, "writeObject");
    }
942822
private void writeObject(ObjectOutputStream out) throws IOException
    {
        if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled())
            Tr.debug(tc, "writeObject : " + this);

        throw new NotSerializableException("This entity manager is not serializable");
    }
796078
private void writeObject(final ObjectOutputStream out)
		throws IOException
	{
		out.defaultWriteObject();
		out.writeLong(getGeneration());
		out.writeObject(getGenotype());
		out.writeObject(getFitness());
		out.writeObject(getRawFitness());
	}
329838
private void writeObject(ObjectOutputStream outStream) throws IOException {
        PutField fields = outStream.putFields();
        fields.put(BEGIN_DEFAULT, beginDefaultContext);
        outStream.writeFields();
    }
408146
private void writeObject(java.io.ObjectOutputStream s)
        throws java.io.IOException {
        s.defaultWriteObject();
        for (E e : this)
            s.writeObject(e);
        // Use trailing null as sentinel
        s.writeObject(null);
    }
370774
public void writeObject(DataOutputStream dataOutputStream) throws ObjectManagerException, IOException
    {
        super.writeObject(dataOutputStream);

        // Write out our serialVersionUID
        dataOutputStream.writeLong(serialVersionUID);

        if (_dataSlices != null)
        {
            // Write the number of slices we have
            dataOutputStream.writeInt(_dataSlices.size());
    
            // Write each slice out
            for (DataSlice slice : _dataSlices)
            {
                dataOutputStream.writeInt(slice.getLength());
                dataOutputStream.write(slice.getBytes(), slice.getOffset(), slice.getLength());
            }
        }
        else
        {
            // We have no slices so just write a 
            // zero so we don't try to read any in
            // at readObject time.
            dataOutputStream.writeInt(0);
        }
    }
1038782
private void writeObject(ObjectOutputStream out) throws IOException {
        ClassRef.write(out, type);
        out.writeUTF(name);
        out.writeObject(val);
    }
741136
private void writeObject(ObjectOutputStream stream) throws IOException {

        /*
         * Since this is a simple class all we have to do is write each member to the stream.
         * the order has to remain identical to readObject, so I've just gone alphabetically.
         *
         * If we change the serialversionUID, we may need to modify this method as well.
         */

        if (tc.isEntryEnabled()) {
            Tr.entry(this, tc, "writeObject", stream);
        }

        ObjectOutputStream.PutField putField = stream.putFields();

        putField.put("activationConfigProps", activationConfigProps);
        putField.put("destinationRef", destinationRef);
        putField.put("authenticationAlias", authenticationAlias);
        putField.put("applicationName", applicationName);
        putField.put("qmid", qmid);

        stream.writeFields();

        if (tc.isEntryEnabled()) {
            Tr.exit(this, tc, "writeObject activation config - " + this.toString());
        }

    }
29200
private void writeObject(ObjectOutputStream out) throws IOException
    {
        out.defaultWriteObject();
        out.writeInt(table.length);

        // Have to use null-terminated list because size might shrink
        // during iteration

        for (Iterator iter = entrySet().iterator(); iter.hasNext();)
        {
            Map.Entry entry = (Map.Entry) iter.next();
            out.writeObject(entry.getKey());
            out.writeObject(entry.getValue());
        }
        out.writeObject(null);
    }
287481
@Override
  public void serialize(DataOutput out) throws IOException {
    if (buffer.hasArray()) {
      out.write(buffer.array(), buffer.arrayOffset(), buffer.limit());
    } else {
      ByteBuffer tmp = buffer.duplicate();
      tmp.position(0);
      try (WritableByteChannel channel = Channels.newChannel((OutputStream) out)) {
        channel.write(tmp);
      }
    }
  }
142136
public final void serialize(OutputStream out) throws IOException {
        out.write(Jackson.toJsonString(this).getBytes(UTF8));
        out.flush();
    }
1360962
private void writeObject(final ObjectOutputStream out) throws IOException {
		// write all the non-transient fields
		out.defaultWriteObject();

		// write the non-serializable default value field
		if (defaultValue == null) {
			// we don't have a default value
			out.writeBoolean(false);
		} else {
			// we have a default value
			out.writeBoolean(true);

			byte[] serializedDefaultValue;
			try (ByteArrayOutputStream baos = new ByteArrayOutputStream();
					DataOutputViewStreamWrapper outView = new DataOutputViewStreamWrapper(baos)) {

				TypeSerializer<T> duplicateSerializer = serializer.duplicate();
				duplicateSerializer.serialize(defaultValue, outView);

				outView.flush();
				serializedDefaultValue = baos.toByteArray();
			}
			catch (Exception e) {
				throw new IOException("Unable to serialize default value of type " +
						defaultValue.getClass().getSimpleName() + ".", e);
			}

			out.writeInt(serializedDefaultValue.length);
			out.write(serializedDefaultValue);
		}
	}
126445
@Override
    public void writeObject(DataOutputStream dataOutputStream) throws ObjectManagerException, IOException
    {
        super.writeObject(dataOutputStream);

        // Write out our serialVersionUID
        dataOutputStream.writeLong(serialVersionUID);

        dataOutputStream.writeLong(_uniqueID);
        dataOutputStream.writeLong(_streamID);
        dataOutputStream.writeLong(_lockID);
        dataOutputStream.writeLong(_referredID);
        dataOutputStream.writeLong(_sequence);
        dataOutputStream.writeLong(_expiryTime);
        dataOutputStream.writeInt(_redeliveredCount);
        dataOutputStream.writeInt(_storageStrategy);
        dataOutputStream.writeInt(_priority);
        dataOutputStream.writeInt(_persistentSize);
        dataOutputStream.writeInt(_maxDepth);

        dataOutputStream.writeBoolean(_canExpireSilently);
        dataOutputStream.writeBoolean(_containsExpirables);

        // If the string variables aren't null then
        // write the flag and then write them to the
        // stream.
        if (_type != null)
        {
            dataOutputStream.writeBoolean(true);
            dataOutputStream.writeUTF(_type);
        }
        else
        {
            dataOutputStream.writeBoolean(false);
        }
        if (_className != null)
        {
            dataOutputStream.writeBoolean(true);
            dataOutputStream.writeUTF(_className);
        }
        else
        {
            dataOutputStream.writeBoolean(false);
        }

        // We need to write out the length of the tran ID
        // before we write the bytes so that we can read
        // it back in successfully
        if (_transactionId != null)
        {
            dataOutputStream.writeInt(_transactionId.length);
            dataOutputStream.write(_transactionId, 0, _transactionId.length);
        }
        else
        {
            dataOutputStream.writeInt(-1);
        }

        // Call the Tokens to write themselves out but
        // only if they exist. If the don't then we need
        // to write a boolean to the stream so that we
        // don't try and read back in non-existent tokens.
        if (_streamListToken != null)
        {
            dataOutputStream.writeBoolean(true);
            _streamListToken.writeObject(dataOutputStream);
        }
        else
        {
            dataOutputStream.writeBoolean(false);
        }

        if (_itemListToken != null)
        {
            dataOutputStream.writeBoolean(true);
            _itemListToken.writeObject(dataOutputStream);
        }
        else
        {
            dataOutputStream.writeBoolean(false);
        }

        if (_rawDataToken != null)
        {
            dataOutputStream.writeBoolean(true);
            _rawDataToken.writeObject(dataOutputStream);
        }
        else
        {
            dataOutputStream.writeBoolean(false);
        }

        if (_streamListEntryToken != null)
        {
            dataOutputStream.writeBoolean(true);
            _streamListEntryToken.writeObject(dataOutputStream);
        }
        else
        {
            dataOutputStream.writeBoolean(false);
        }

        if (_itemListEntryToken != null)
        {
            dataOutputStream.writeBoolean(true);
            _itemListEntryToken.writeObject(dataOutputStream);
        }
        else
        {
            dataOutputStream.writeBoolean(false);
        }

        // write the _deliveryDelayTime
        dataOutputStream.writeLong(_deliveryDelayTime);

        if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled())
            SibTr.debug(this, tc, "bytes written==" + dataOutputStream.size());
    }
1150076
private void writeObject(ObjectOutputStream s) throws IOException
  {
    if (words != null && lastWordIndex < words.length - 1) {
      // compact before serializing
      words = Arrays.copyOf(words, lastWordIndex + 1);
    }
    s.defaultWriteObject();
  }
1030034
public void writeObject (ObjectOutputStream out)
        throws IOException
    {
        out.writeInt(size());
        for (E value : this) {
            out.writeObject(value);
        }
    }
902656
public void writeObject (ObjectOutputStream out)
        throws IOException
    {
        int ecount = size();
        out.writeInt(ecount);
        for (Map.Entry<K, V> entry : entrySet()) {
            out.writeObject(entry.getKey());
            out.writeObject(entry.getValue());
        }
    }
1135595
private void writeObject(java.io.ObjectOutputStream out)
                    throws IOException
    {
        out.defaultWriteObject();
        out.write(frciEyecatcher);
        out.writeShort(frciPlatform);
        out.writeShort(frciVersionID);
    }