aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.RML/Views/ProcessParametersView.xaml.cs
blob: a6d03ca0e2f7e4dc9576b4d42a4e3dee099e9828 (plain)
1
2
3
4
5
6
7
8
9
10
pre { line-height: 125%; }
td.linenos .normal { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; }
span.linenos { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; }
td.linenos .special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
span.linenos.special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
.highlight .hll { background-color: #ffffcc }
.highlight .c { color: #888888 } /* Comment */
.highlight .err { color: #a61717; background-color: #e3d2d2 } /* Error */
.highlight .k { color: #008800; font-weight: bold } /* Keyword */
.highlight .ch { color: #888888 } /* Comment.Hashbang */
.highlight .cm { color: #888888 } /* Comment.Multiline */
.highlight .cp { color: #cc0000; font-weight: bold } /* Comment.Preproc */
.highlight .cpf { color: #888888 } /* Comment.PreprocFile */
.highlight .c1 { color: #888888 } /* Comment.Single */
.highlight .cs { color: #cc0000; font-weight: bold; background-color: #fff0f0 } /* Comment.Special */
.highlight .gd { color: #000000; background-color: #ffdddd } /* Generic.Deleted */
.highlight .ge { font-style: italic } /* Generic.Emph */
.highlight .ges { font-weight: bold; font-style: italic } /* Generic.EmphStrong */
.highlight .gr { color: #aa0000 } /* Generic.Error */
.highlight .gh { color: #333333 } /* Generic.Heading */
.highlight .gi { color: #000000; background-color: #ddffdd } /* Generic.Inserted */
.highlight .go { color: #88888
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
using Tango.MachineStudio.RML.ViewModels;
using Tango.BL.Entities;
using Tango.DragAndDrop;

namespace Tango.MachineStudio.RML.Views
{
    /// <summary>
    /// Interaction logic for ProcessParametersView.xaml
    /// </summary>
    public partial class ProcessParametersView : UserControl
    {
        private MainViewVM _vm;
        public DraggingSurface DraggingSurface
        {
            get { return (DraggingSurface)GetValue(DraggingSurfaceProperty); }
            set { SetValue(DraggingSurfaceProperty, value); }
        }
        public static readonly DependencyProperty DraggingSurfaceProperty =
            DependencyProperty.Register("DraggingSurface", typeof(DraggingSurface), typeof(ProcessParametersView), new PropertyMetadata(null));
        
        public double WidthLilquidFactors
        {
            get { return (double )GetValue(WidthLilquidFactorsProperty); }
            set { SetValue(WidthLilquidFactorsProperty, value); }
        }

        // Using a DependencyProperty as the backing store for WidthLilquidFactors.  This enables animation, styling, binding, etc...
        public static readonly DependencyProperty WidthLilquidFactorsProperty =
            DependencyProperty.Register("WidthLilquidFactors", typeof(double ), typeof(ProcessParametersView), new PropertyMetadata(null));

        
        public ProcessParametersView()
        {
            InitializeComponent();
            DraggingSurface = draggingSurface;
            Loaded += (_, __) => { _vm = DataContext as MainViewVM; };
        }
        private void OnProcessTableDropped(object sender, DropEventArgs e)
        {
            ProcessParametersTable dragged = e.Draggable.DataContext as ProcessParametersTable;
            ProcessParametersTable dropped = e.Droppable.DataContext as ProcessParametersTable;
            _vm.OnProcessParametersTableDropped(dragged, dropped);
        }
    }
}
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: JobSpool.proto

#define INTERNAL_SUPPRESS_PROTOBUF_FIELD_DEPRECATION
#include "JobSpool.pb.h"

#include <algorithm>

#include <google/protobuf/stubs/common.h>
#include <google/protobuf/stubs/port.h>
#include <google/protobuf/stubs/once.h>
#include <google/protobuf/io/coded_stream.h>
#include <google/protobuf/wire_format_lite_inl.h>
#include <google/protobuf/descriptor.h>
#include <google/protobuf/generated_message_reflection.h>
#include <google/protobuf/reflection_ops.h>
#include <google/protobuf/wire_format.h>
// @@protoc_insertion_point(includes)

namespace Tango {
namespace PMR {
namespace Printing {
class JobSpoolDefaultTypeInternal {
public:
 ::google::protobuf::internal::ExplicitlyConstructed<JobSpool>
     _instance;
} _JobSpool_default_instance_;

namespace protobuf_JobSpool_2eproto {


namespace {

::google::protobuf::Metadata file_level_metadata[1];

}  // namespace

PROTOBUF_CONSTEXPR_VAR ::google::protobuf::internal::ParseTableField
    const TableStruct::entries[] GOOGLE_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
  {0, 0, 0, ::google::protobuf::internal::kInvalidMask, 0, 0},
};

PROTOBUF_CONSTEXPR_VAR ::google::protobuf::internal::AuxillaryParseTableField
    const TableStruct::aux[] GOOGLE_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
  ::google::protobuf::internal::AuxillaryParseTableField(),
};
PROTOBUF_CONSTEXPR_VAR ::google::protobuf::internal::ParseTable const
    TableStruct::schema[] GOOGLE_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
  { NULL, NULL, 0, -1, -1, -1, -1, NULL, false },
};

const ::google::protobuf::uint32 TableStruct::offsets[] GOOGLE_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
  ~0u,  // no _has_bits_
  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(JobSpool, _internal_metadata_),
  ~0u,  // no _extensions_
  ~0u,  // no _oneof_case_
  ~0u,  // no _weak_field_map_
  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(JobSpool, jobspooltype_),
  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(JobSpool, length_),
  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(JobSpool, weight_),
  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(JobSpool, diameter_),
  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(JobSpool, startoffsetpulses_),
  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(JobSpool, backingrate_),
  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(JobSpool, segmentoffsetpulses_),
  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(JobSpool, bottombackingrate_),
  GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(JobSpool, rotationsperpassage_),
};
static const ::google::protobuf::internal::MigrationSchema schemas[] GOOGLE_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
  { 0, -1, sizeof(JobSpool)},
};

static ::google::protobuf::Message const * const file_default_instances[] = {
  reinterpret_cast<const ::google::protobuf::Message*>(&_JobSpool_default_instance_),
};

namespace {

void protobuf_AssignDescriptors() {
  AddDescriptors();
  ::google::protobuf::MessageFactory* factory = NULL;
  AssignDescriptors(
      "JobSpool.proto", schemas, file_default_instances, TableStruct::offsets, factory,
      file_level_metadata, NULL, NULL);
}

void protobuf_AssignDescriptorsOnce() {
  static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
  ::google::protobuf::GoogleOnceInit(&once, &protobuf_AssignDescriptors);
}

void protobuf_RegisterTypes(const ::std::string&) GOOGLE_ATTRIBUTE_COLD;
void protobuf_RegisterTypes(const ::std::string&) {
  protobuf_AssignDescriptorsOnce();
  ::google::protobuf::internal::RegisterAllTypes(file_level_metadata, 1);
}

}  // namespace
void TableStruct::InitDefaultsImpl() {
  GOOGLE_PROTOBUF_VERIFY_VERSION;

  ::google::protobuf::internal::InitProtobufDefaults();
  ::Tango::PMR::Printing::protobuf_JobSpoolType_2eproto::InitDefaults();
  _JobSpool_default_instance_._instance.DefaultConstruct();
  ::google::protobuf::internal::OnShutdownDestroyMessage(
      &_JobSpool_default_instance_);}

void InitDefaults() {
  static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
  ::google::protobuf::GoogleOnceInit(&once, &TableStruct::InitDefaultsImpl);
}
namespace {
void AddDescriptorsImpl() {
  InitDefaults();
  static const char descriptor[] GOOGLE_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
      "\n\016JobSpool.proto\022\022Tango.PMR.Printing\032\022Jo"
      "bSpoolType.proto\"\371\001\n\010JobSpool\0226\n\014JobSpoo"
      "lType\030\001 \001(\0162 .Tango.PMR.Printing.JobSpoo"
      "lType\022\016\n\006Length\030\002 \001(\001\022\016\n\006Weight\030\003 \001(\001\022\020\n"
      "\010Diameter\030\004 \001(\001\022\031\n\021StartOffsetPulses\030\005 \001"
      "(\005\022\023\n\013BackingRate\030\006 \001(\005\022\033\n\023SegmentOffset"
      "Pulses\030\007 \001(\005\022\031\n\021BottomBackingRate\030\010 \001(\005\022"
      "\033\n\023RotationsPerPassage\030\t \001(\001B\036\n\034com.twin"
      "e.tango.pmr.printingb\006proto3"
  };
  ::google::protobuf::DescriptorPool::InternalAddGeneratedFile(
      descriptor, 348);
  ::google::protobuf::MessageFactory::InternalRegisterGeneratedFile(
    "JobSpool.proto", &protobuf_RegisterTypes);
  ::Tango::PMR::Printing::protobuf_JobSpoolType_2eproto::AddDescriptors();
}
} // anonymous namespace

void AddDescriptors() {
  static GOOGLE_PROTOBUF_DECLARE_ONCE(once);
  ::google::protobuf::GoogleOnceInit(&once, &AddDescriptorsImpl);
}
// Force AddDescriptors() to be called at dynamic initialization time.
struct StaticDescriptorInitializer {
  StaticDescriptorInitializer() {
    AddDescriptors();
  }
} static_descriptor_initializer;

}  // namespace protobuf_JobSpool_2eproto


// ===================================================================

#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int JobSpool::kJobSpoolTypeFieldNumber;
const int JobSpool::kLengthFieldNumber;
const int JobSpool::kWeightFieldNumber;
const int JobSpool::kDiameterFieldNumber;
const int JobSpool::kStartOffsetPulsesFieldNumber;
const int JobSpool::kBackingRateFieldNumber;
const int JobSpool::kSegmentOffsetPulsesFieldNumber;
const int JobSpool::kBottomBackingRateFieldNumber;
const int JobSpool::kRotationsPerPassageFieldNumber;
#endif  // !defined(_MSC_VER) || _MSC_VER >= 1900

JobSpool::JobSpool()
  : ::google::protobuf::Message(), _internal_metadata_(NULL) {
  if (GOOGLE_PREDICT_TRUE(this != internal_default_instance())) {
    protobuf_JobSpool_2eproto::InitDefaults();
  }
  SharedCtor();
  // @@protoc_insertion_point(constructor:Tango.PMR.Printing.JobSpool)
}
JobSpool::JobSpool(const JobSpool& from)
  : ::google::protobuf::Message(),
      _internal_metadata_(NULL),
      _cached_size_(0) {
  _internal_metadata_.MergeFrom(from._internal_metadata_);
  ::memcpy(&length_, &from.length_,
    static_cast<size_t>(reinterpret_cast<char*>(&bottombackingrate_) -
    reinterpret_cast<char*>(&length_)) + sizeof(bottombackingrate_));
  // @@protoc_insertion_point(copy_constructor:Tango.PMR.Printing.JobSpool)
}

void JobSpool::SharedCtor() {
  ::memset(&length_, 0, static_cast<size_t>(
      reinterpret_cast<char*>(&bottombackingrate_) -
      reinterpret_cast<char*>(&length_)) + sizeof(bottombackingrate_));
  _cached_size_ = 0;
}

JobSpool::~JobSpool() {
  // @@protoc_insertion_point(destructor:Tango.PMR.Printing.JobSpool)
  SharedDtor();
}

void JobSpool::SharedDtor() {
}

void JobSpool::SetCachedSize(int size) const {
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* JobSpool::descriptor() {
  protobuf_JobSpool_2eproto::protobuf_AssignDescriptorsOnce();
  return protobuf_JobSpool_2eproto::file_level_metadata[kIndexInFileMessages].descriptor;
}

const JobSpool& JobSpool::default_instance() {
  protobuf_JobSpool_2eproto::InitDefaults();
  return *internal_default_instance();
}

JobSpool* JobSpool::New(::google::protobuf::Arena* arena) const {
  JobSpool* n = new JobSpool;
  if (arena != NULL) {
    arena->Own(n);
  }
  return n;
}

void JobSpool::Clear() {
// @@protoc_insertion_point(message_clear_start:Tango.PMR.Printing.JobSpool)
  ::google::protobuf::uint32 cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  ::memset(&length_, 0, static_cast<size_t>(
      reinterpret_cast<char*>(&bottombackingrate_) -
      reinterpret_cast<char*>(&length_)) + sizeof(bottombackingrate_));
  _internal_metadata_.Clear();
}

bool JobSpool::MergePartialFromCodedStream(
    ::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
  ::google::protobuf::uint32 tag;
  // @@protoc_insertion_point(parse_start:Tango.PMR.Printing.JobSpool)
  for (;;) {
    ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
    tag = p.first;
    if (!p.second) goto handle_unusual;
    switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
      // .Tango.PMR.Printing.JobSpoolType JobSpoolType = 1;
      case 1: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(8u /* 8 & 0xFF */)) {
          int value;
          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
                 input, &value)));
          set_jobspooltype(static_cast< ::Tango::PMR::Printing::JobSpoolType >(value));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // double Length = 2;
      case 2: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(17u /* 17 & 0xFF */)) {

          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   double, ::google::protobuf::internal::WireFormatLite::TYPE_DOUBLE>(
                 input, &length_)));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // double Weight = 3;
      case 3: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(25u /* 25 & 0xFF */)) {

          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   double, ::google::protobuf::internal::WireFormatLite::TYPE_DOUBLE>(
                 input, &weight_)));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // double Diameter = 4;
      case 4: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(33u /* 33 & 0xFF */)) {

          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   double, ::google::protobuf::internal::WireFormatLite::TYPE_DOUBLE>(
                 input, &diameter_)));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // int32 StartOffsetPulses = 5;
      case 5: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(40u /* 40 & 0xFF */)) {

          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
                 input, &startoffsetpulses_)));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // int32 BackingRate = 6;
      case 6: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(48u /* 48 & 0xFF */)) {

          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
                 input, &backingrate_)));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // int32 SegmentOffsetPulses = 7;
      case 7: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(56u /* 56 & 0xFF */)) {

          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
                 input, &segmentoffsetpulses_)));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // int32 BottomBackingRate = 8;
      case 8: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(64u /* 64 & 0xFF */)) {

          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   ::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
                 input, &bottombackingrate_)));
        } else {
          goto handle_unusual;
        }
        break;
      }

      // double RotationsPerPassage = 9;
      case 9: {
        if (static_cast< ::google::protobuf::uint8>(tag) ==
            static_cast< ::google::protobuf::uint8>(73u /* 73 & 0xFF */)) {

          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
                   double, ::google::protobuf::internal::WireFormatLite::TYPE_DOUBLE>(
                 input, &rotationsperpassage_)));
        } else {
          goto handle_unusual;
        }
        break;
      }

      default: {
      handle_unusual:
        if (tag == 0) {
          goto success;
        }
        DO_(::google::protobuf::internal::WireFormat::SkipField(
              input, tag, _internal_metadata_.mutable_unknown_fields()));
        break;
      }
    }
  }
success:
  // @@protoc_insertion_point(parse_success:Tango.PMR.Printing.JobSpool)
  return true;
failure:
  // @@protoc_insertion_point(parse_failure:Tango.PMR.Printing.JobSpool)
  return false;
#undef DO_
}

void JobSpool::SerializeWithCachedSizes(
    ::google::protobuf::io::CodedOutputStream* output) const {
  // @@protoc_insertion_point(serialize_start:Tango.PMR.Printing.JobSpool)
  ::google::protobuf::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  // .Tango.PMR.Printing.JobSpoolType JobSpoolType = 1;
  if (this->jobspooltype() != 0) {
    ::google::protobuf::internal::WireFormatLite::WriteEnum(
      1, this->jobspooltype(), output);
  }

  // double Length = 2;
  if (this->length() != 0) {
    ::google::protobuf::internal::WireFormatLite::WriteDouble(2, this->length(), output);
  }

  // double Weight = 3;
  if (this->weight() != 0) {
    ::google::protobuf::internal::WireFormatLite::WriteDouble(3, this->weight(), output);
  }

  // double Diameter = 4;
  if (this->diameter() != 0) {
    ::google::protobuf::internal::WireFormatLite::WriteDouble(4, this->diameter(), output);
  }

  // int32 StartOffsetPulses = 5;
  if (this->startoffsetpulses() != 0) {
    ::google::protobuf::internal::WireFormatLite::WriteInt32(5, this->startoffsetpulses(), output);
  }

  // int32 BackingRate = 6;
  if (this->backingrate() != 0) {
    ::google::protobuf::internal::WireFormatLite::WriteInt32(6, this->backingrate(), output);
  }

  // int32 SegmentOffsetPulses = 7;
  if (this->segmentoffsetpulses() != 0) {
    ::google::protobuf::internal::WireFormatLite::WriteInt32(7, this->segmentoffsetpulses(), output);
  }

  // int32 BottomBackingRate = 8;
  if (this->bottombackingrate() != 0) {
    ::google::protobuf::internal::WireFormatLite::WriteInt32(8, this->bottombackingrate(), output);
  }

  // double RotationsPerPassage = 9;
  if (this->rotationsperpassage() != 0) {
    ::google::protobuf::internal::WireFormatLite::WriteDouble(9, this->rotationsperpassage(), output);
  }

  if ((_internal_metadata_.have_unknown_fields() &&  ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
    ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
        (::google::protobuf::internal::GetProto3PreserveUnknownsDefault()   ? _internal_metadata_.unknown_fields()   : _internal_metadata_.default_instance()), output);
  }
  // @@protoc_insertion_point(serialize_end:Tango.PMR.Printing.JobSpool)
}

::google::protobuf::uint8* JobSpool::InternalSerializeWithCachedSizesToArray(
    bool deterministic, ::google::protobuf::uint8* target) const {
  (void)deterministic; // Unused
  // @@protoc_insertion_point(serialize_to_array_start:Tango.PMR.Printing.JobSpool)
  ::google::protobuf::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  // .Tango.PMR.Printing.JobSpoolType JobSpoolType = 1;
  if (this->jobspooltype() != 0) {
    target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
      1, this->jobspooltype(), target);
  }

  // double Length = 2;
  if (this->length() != 0) {
    target = ::google::protobuf::internal::WireFormatLite::WriteDoubleToArray(2, this->length(), target);
  }

  // double Weight = 3;
  if (this->weight() != 0) {
    target = ::google::protobuf::internal::WireFormatLite::WriteDoubleToArray(3, this->weight(), target);
  }

  // double Diameter = 4;
  if (this->diameter() != 0) {
    target = ::google::protobuf::internal::WireFormatLite::WriteDoubleToArray(4, this->diameter(), target);
  }

  // int32 StartOffsetPulses = 5;
  if (this->startoffsetpulses() != 0) {
    target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(5, this->startoffsetpulses(), target);
  }

  // int32 BackingRate = 6;
  if (this->backingrate() != 0) {
    target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(6, this->backingrate(), target);
  }

  // int32 SegmentOffsetPulses = 7;
  if (this->segmentoffsetpulses() != 0) {
    target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(7, this->segmentoffsetpulses(), target);
  }

  // int32 BottomBackingRate = 8;
  if (this->bottombackingrate() != 0) {
    target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(8, this->bottombackingrate(), target);
  }

  // double RotationsPerPassage = 9;
  if (this->rotationsperpassage() != 0) {
    target = ::google::protobuf::internal::WireFormatLite::WriteDoubleToArray(9, this->rotationsperpassage(), target);
  }

  if ((_internal_metadata_.have_unknown_fields() &&  ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
    target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
        (::google::protobuf::internal::GetProto3PreserveUnknownsDefault()   ? _internal_metadata_.unknown_fields()   : _internal_metadata_.default_instance()), target);
  }
  // @@protoc_insertion_point(serialize_to_array_end:Tango.PMR.Printing.JobSpool)
  return target;
}

size_t JobSpool::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:Tango.PMR.Printing.JobSpool)
  size_t total_size = 0;

  if ((_internal_metadata_.have_unknown_fields() &&  ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) {
    total_size +=
      ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
        (::google::protobuf::internal::GetProto3PreserveUnknownsDefault()   ? _internal_metadata_.unknown_fields()   : _internal_metadata_.default_instance()));
  }
  // double Length = 2;
  if (this->length() != 0) {
    total_size += 1 + 8;
  }

  // double Weight = 3;
  if (this->weight() != 0) {
    total_size += 1 + 8;
  }

  // .Tango.PMR.Printing.JobSpoolType JobSpoolType = 1;
  if (this->jobspooltype() != 0) {
    total_size += 1 +
      ::google::protobuf::internal::WireFormatLite::EnumSize(this->jobspooltype());
  }

  // int32 StartOffsetPulses = 5;
  if (this->startoffsetpulses() != 0) {
    total_size += 1 +
      ::google::protobuf::internal::WireFormatLite::Int32Size(
        this->startoffsetpulses());
  }

  // double Diameter = 4;
  if (this->diameter() != 0) {
    total_size += 1 + 8;
  }

  // int32 BackingRate = 6;
  if (this->backingrate() != 0) {
    total_size += 1 +
      ::google::protobuf::internal::WireFormatLite::Int32Size(
        this->backingrate());
  }

  // int32 SegmentOffsetPulses = 7;
  if (this->segmentoffsetpulses() != 0) {
    total_size += 1 +
      ::google::protobuf::internal::WireFormatLite::Int32Size(
        this->segmentoffsetpulses());
  }

  // double RotationsPerPassage = 9;
  if (this->rotationsperpassage() != 0) {
    total_size += 1 + 8;
  }

  // int32 BottomBackingRate = 8;
  if (this->bottombackingrate() != 0) {
    total_size += 1 +
      ::google::protobuf::internal::WireFormatLite::Int32Size(
        this->bottombackingrate());
  }

  int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
  GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
  _cached_size_ = cached_size;
  GOOGLE_SAFE_CONCURRENT_WRITES_END();
  return total_size;
}

void JobSpool::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:Tango.PMR.Printing.JobSpool)
  GOOGLE_DCHECK_NE(&from, this);
  const JobSpool* source =
      ::google::protobuf::internal::DynamicCastToGenerated<const JobSpool>(
          &from);
  if (source == NULL) {
  // @@protoc_insertion_point(generalized_merge_from_cast_fail:Tango.PMR.Printing.JobSpool)
    ::google::protobuf::internal::ReflectionOps::Merge(from, this);
  } else {
  // @@protoc_insertion_point(generalized_merge_from_cast_success:Tango.PMR.Printing.JobSpool)
    MergeFrom(*source);
  }
}

void JobSpool::MergeFrom(const JobSpool& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:Tango.PMR.Printing.JobSpool)
  GOOGLE_DCHECK_NE(&from, this);
  _internal_metadata_.MergeFrom(from._internal_metadata_);
  ::google::protobuf::uint32 cached_has_bits = 0;
  (void) cached_has_bits;

  if (from.length() != 0) {
    set_length(from.length());
  }
  if (from.weight() != 0) {
    set_weight(from.weight());
  }
  if (from.jobspooltype() != 0) {
    set_jobspooltype(from.jobspooltype());
  }
  if (from.startoffsetpulses() != 0) {
    set_startoffsetpulses(from.startoffsetpulses());
  }
  if (from.diameter() != 0) {
    set_diameter(from.diameter());
  }
  if (from.backingrate() != 0) {
    set_backingrate(from.backingrate());
  }
  if (from.segmentoffsetpulses() != 0) {
    set_segmentoffsetpulses(from.segmentoffsetpulses());
  }
  if (from.rotationsperpassage() != 0) {
    set_rotationsperpassage(from.rotationsperpassage());
  }
  if (from.bottombackingrate() != 0) {
    set_bottombackingrate(from.bottombackingrate());
  }
}

void JobSpool::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:Tango.PMR.Printing.JobSpool)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

void JobSpool::CopyFrom(const JobSpool& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:Tango.PMR.Printing.JobSpool)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}

bool JobSpool::IsInitialized() const {
  return true;
}

void JobSpool::Swap(JobSpool* other) {
  if (other == this) return;
  InternalSwap(other);
}
void JobSpool::InternalSwap(JobSpool* other) {
  using std::swap;
  swap(length_, other->length_);
  swap(weight_, other->weight_);
  swap(jobspooltype_, other->jobspooltype_);
  swap(startoffsetpulses_, other->startoffsetpulses_);
  swap(diameter_, other->diameter_);
  swap(backingrate_, other->backingrate_);
  swap(segmentoffsetpulses_, other->segmentoffsetpulses_);
  swap(rotationsperpassage_, other->rotationsperpassage_);
  swap(bottombackingrate_, other->bottombackingrate_);
  _internal_metadata_.Swap(&other->_internal_metadata_);
  swap(_cached_size_, other->_cached_size_);
}

::google::protobuf::Metadata JobSpool::GetMetadata() const {
  protobuf_JobSpool_2eproto::protobuf_AssignDescriptorsOnce();
  return protobuf_JobSpool_2eproto::file_level_metadata[kIndexInFileMessages];
}

#if PROTOBUF_INLINE_NOT_IN_HEADERS
// JobSpool

// .Tango.PMR.Printing.JobSpoolType JobSpoolType = 1;
void JobSpool::clear_jobspooltype() {
  jobspooltype_ = 0;
}
::Tango::PMR::Printing::JobSpoolType JobSpool::jobspooltype() const {
  // @@protoc_insertion_point(field_get:Tango.PMR.Printing.JobSpool.JobSpoolType)
  return static_cast< ::Tango::PMR::Printing::JobSpoolType >(jobspooltype_);
}
void JobSpool::set_jobspooltype(::Tango::PMR::Printing::JobSpoolType value) {
  
  jobspooltype_ = value;
  // @@protoc_insertion_point(field_set:Tango.PMR.Printing.JobSpool.JobSpoolType)
}

// double Length = 2;
void JobSpool::clear_length() {
  length_ = 0;
}
double JobSpool::length() const {
  // @@protoc_insertion_point(field_get:Tango.PMR.Printing.JobSpool.Length)
  return length_;
}
void JobSpool::set_length(double value) {
  
  length_ = value;
  // @@protoc_insertion_point(field_set:Tango.PMR.Printing.JobSpool.Length)
}

// double Weight = 3;
void JobSpool::clear_weight() {
  weight_ = 0;
}
double JobSpool::weight() const {
  // @@protoc_insertion_point(field_get:Tango.PMR.Printing.JobSpool.Weight)
  return weight_;
}
void JobSpool::set_weight(double value) {
  
  weight_ = value;
  // @@protoc_insertion_point(field_set:Tango.PMR.Printing.JobSpool.Weight)
}

// double Diameter = 4;
void JobSpool::clear_diameter() {
  diameter_ = 0;
}
double JobSpool::diameter() const {
  // @@protoc_insertion_point(field_get:Tango.PMR.Printing.JobSpool.Diameter)
  return diameter_;
}
void JobSpool::set_diameter(double value) {
  
  diameter_ = value;
  // @@protoc_insertion_point(field_set:Tango.PMR.Printing.JobSpool.Diameter)
}

// int32 StartOffsetPulses = 5;
void JobSpool::clear_startoffsetpulses() {
  startoffsetpulses_ = 0;
}
::google::protobuf::int32 JobSpool::startoffsetpulses() const {
  // @@protoc_insertion_point(field_get:Tango.PMR.Printing.JobSpool.StartOffsetPulses)
  return startoffsetpulses_;
}
void JobSpool::set_startoffsetpulses(::google::protobuf::int32 value) {
  
  startoffsetpulses_ = value;
  // @@protoc_insertion_point(field_set:Tango.PMR.Printing.JobSpool.StartOffsetPulses)
}

// int32 BackingRate = 6;
void JobSpool::clear_backingrate() {
  backingrate_ = 0;
}
::google::protobuf::int32 JobSpool::backingrate() const {
  // @@protoc_insertion_point(field_get:Tango.PMR.Printing.JobSpool.BackingRate)
  return backingrate_;
}
void JobSpool::set_backingrate(::google::protobuf::int32 value) {
  
  backingrate_ = value;
  // @@protoc_insertion_point(field_set:Tango.PMR.Printing.JobSpool.BackingRate)
}

// int32 SegmentOffsetPulses = 7;
void JobSpool::clear_segmentoffsetpulses() {
  segmentoffsetpulses_ = 0;
}
::google::protobuf::int32 JobSpool::segmentoffsetpulses() const {
  // @@protoc_insertion_point(field_get:Tango.PMR.Printing.JobSpool.SegmentOffsetPulses)
  return segmentoffsetpulses_;
}
void JobSpool::set_segmentoffsetpulses(::google::protobuf::int32 value) {
  
  segmentoffsetpulses_ = value;
  // @@protoc_insertion_point(field_set:Tango.PMR.Printing.JobSpool.SegmentOffsetPulses)
}

// int32 BottomBackingRate = 8;
void JobSpool::clear_bottombackingrate() {
  bottombackingrate_ = 0;
}
::google::protobuf::int32 JobSpool::bottombackingrate() const {
  // @@protoc_insertion_point(field_get:Tango.PMR.Printing.JobSpool.BottomBackingRate)
  return bottombackingrate_;
}
void JobSpool::set_bottombackingrate(::google::protobuf::int32 value) {
  
  bottombackingrate_ = value;
  // @@protoc_insertion_point(field_set:Tango.PMR.Printing.JobSpool.BottomBackingRate)
}

// double RotationsPerPassage = 9;
void JobSpool::clear_rotationsperpassage() {
  rotationsperpassage_ = 0;
}
double JobSpool::rotationsperpassage() const {
  // @@protoc_insertion_point(field_get:Tango.PMR.Printing.JobSpool.RotationsPerPassage)
  return rotationsperpassage_;
}
void JobSpool::set_rotationsperpassage(double value) {
  
  rotationsperpassage_ = value;
  // @@protoc_insertion_point(field_set:Tango.PMR.Printing.JobSpool.RotationsPerPassage)
}

#endif  // PROTOBUF_INLINE_NOT_IN_HEADERS

// @@protoc_insertion_point(namespace_scope)

}  // namespace Printing
}  // namespace PMR
}  // namespace Tango

// @@protoc_insertion_point(global_scope)