コード例 #1
0
  public void serialize_key(
      Object endpoint_data,
      Object src,
      CdrOutputStream dst,
      boolean serialize_encapsulation,
      short encapsulation_id,
      boolean serialize_key,
      Object endpoint_plugin_qos) {
    int position = 0;

    if (serialize_encapsulation) {

      dst.serializeAndSetCdrEncapsulation(encapsulation_id);

      position = dst.resetAlignment();
    }

    if (serialize_key) {
      BaseValueType typedSrc = (BaseValueType) src;

      dst.writeInt(typedSrc.longMember1);
    }

    if (serialize_encapsulation) {
      dst.restoreAlignment(position);
    }
  }
  public void serialize_key(
      Object endpoint_data,
      Object src,
      CdrOutputStream dst,
      boolean serialize_encapsulation,
      short encapsulation_id,
      boolean serialize_key,
      Object endpoint_plugin_qos) {
    int position = 0;

    if (serialize_encapsulation) {
      dst.serializeAndSetCdrEncapsulation(encapsulation_id);

      position = dst.resetAlignment();
    }

    if (serialize_key) {

      SequenceOfGenerationControlSetPoints typedSrc = (SequenceOfGenerationControlSetPoints) src;
      org.openfmb.model.dds.rti.common.SetPointTypeSupport.get_instance()
          .serialize_sequence(
              endpoint_data,
              dst,
              typedSrc.userData,
              ((org.openfmb.model.dds.rti.generation.MaxLengthGenerationControlSetPoints.VALUE)),
              endpoint_plugin_qos);
    }

    if (serialize_encapsulation) {
      dst.restoreAlignment(position);
    }
  }
コード例 #3
0
  public void serialize_key(
      Object endpoint_data,
      Object src,
      CdrOutputStream dst,
      boolean serialize_encapsulation,
      short encapsulation_id,
      boolean serialize_key,
      Object endpoint_plugin_qos) {
    int position = 0;

    if (serialize_encapsulation) {
      dst.serializeAndSetCdrEncapsulation(encapsulation_id);

      position = dst.resetAlignment();
    }

    if (serialize_key) {

      EndDeviceControl typedSrc = (EndDeviceControl) src;
      serialize(
          endpoint_data,
          src,
          dst,
          false,
          CdrEncapsulation.CDR_ENCAPSULATION_ID_CDR_BE,
          true,
          endpoint_plugin_qos);
    }

    if (serialize_encapsulation) {
      dst.restoreAlignment(position);
    }
  }
コード例 #4
0
  public void serialize(
      Object endpoint_data,
      Object src,
      CdrOutputStream dst,
      boolean serialize_encapsulation,
      short encapsulation_id,
      boolean serialize_sample,
      Object endpoint_plugin_qos) {
    int position = 0;

    if (serialize_encapsulation) {
      dst.serializeAndSetCdrEncapsulation(encapsulation_id);

      position = dst.resetAlignment();
    }

    if (serialize_sample) {

      EndDeviceControl typedSrc = (EndDeviceControl) src;

      dst.writeString(typedSrc.issueID, (255));

      dst.writeString(typedSrc.name, (255));

      org.openfmb.model.dds.rti.openfmb.commonmodule.EndDeviceControlTypeTypeSupport.get_instance()
          .serialize(
              endpoint_data,
              typedSrc.endDeviceControlType,
              dst,
              false,
              encapsulation_id,
              true,
              endpoint_plugin_qos);

      org.openfmb.model.dds.rti.openfmb.commonmodule.DateTimeIntervalTypeSupport.get_instance()
          .serialize(
              endpoint_data,
              typedSrc.scheduledInterval,
              dst,
              false,
              encapsulation_id,
              true,
              endpoint_plugin_qos);

      org.openfmb.model.dds.rti.openfmb.commonmodule.SequenceOfEndDeviceControlSetPointsTypeSupport
          .get_instance()
          .serialize(
              endpoint_data,
              typedSrc.setPoints,
              dst,
              false,
              encapsulation_id,
              true,
              endpoint_plugin_qos);
    }

    if (serialize_encapsulation) {
      dst.restoreAlignment(position);
    }
  }
コード例 #5
0
  public void serialize(
      Object endpoint_data,
      Object src,
      CdrOutputStream dst,
      boolean serialize_encapsulation,
      short encapsulation_id,
      boolean serialize_sample,
      Object endpoint_plugin_qos) {
    int position = 0;

    if (serialize_encapsulation) {
      dst.serializeAndSetCdrEncapsulation(encapsulation_id);

      position = dst.resetAlignment();
    }

    if (serialize_sample) {

      SunRadiationData typedSrc = (SunRadiationData) src;

      dst.writeLong(typedSrc.timestamp);

      dst.writeFloat(typedSrc.value);
    }

    if (serialize_encapsulation) {
      dst.restoreAlignment(position);
    }
  }
コード例 #6
0
  @Override
  public void serialize_key(
      Object endpoint_data,
      Object src,
      CdrOutputStream dst,
      boolean serialize_encapsulation,
      short encapsulation_id,
      boolean serialize_key,
      Object endpoint_plugin_qos) {
    int position = 0;

    if (serialize_encapsulation) {

      dst.serializeAndSetCdrEncapsulation(encapsulation_id);

      position = dst.resetAlignment();
    }

    if (serialize_key) {
      MDSConnectivity typedSrc = (MDSConnectivity) src;

      dst.writeString(typedSrc.unique_device_identifier, (64));
    }

    if (serialize_encapsulation) {
      dst.restoreAlignment(position);
    }
  }