You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

200 lines
4.1 KiB
C#

/**
* Autogenerated by Thrift Compiler (0.9.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
using System;
using System.Collections;
using System.Collections.Generic;
using System.Text;
using System.IO;
using Thrift;
using Thrift.Collections;
using System.Runtime.Serialization;
using Thrift.Protocol;
using Thrift.Transport;
#if !SILVERLIGHT
[Serializable]
#endif
public partial class AreaPlc : TBase
{
private string _AreaName;
private string _MaxSize;
private string _SizeCount;
private string _PlcCount;
public string AreaName
{
get
{
return _AreaName;
}
set
{
__isset.AreaName = true;
this._AreaName = value;
}
}
public string MaxSize
{
get
{
return _MaxSize;
}
set
{
__isset.MaxSize = true;
this._MaxSize = value;
}
}
public string SizeCount
{
get
{
return _SizeCount;
}
set
{
__isset.SizeCount = true;
this._SizeCount = value;
}
}
public string PlcCount
{
get
{
return _PlcCount;
}
set
{
__isset.PlcCount = true;
this._PlcCount = value;
}
}
public Isset __isset;
#if !SILVERLIGHT
[Serializable]
#endif
public struct Isset {
public bool AreaName;
public bool MaxSize;
public bool SizeCount;
public bool PlcCount;
}
public AreaPlc() {
}
public void Read (TProtocol iprot)
{
TField field;
iprot.ReadStructBegin();
while (true)
{
field = iprot.ReadFieldBegin();
if (field.Type == TType.Stop) {
break;
}
switch (field.ID)
{
case 1:
if (field.Type == TType.String) {
AreaName = iprot.ReadString();
} else {
TProtocolUtil.Skip(iprot, field.Type);
}
break;
case 2:
if (field.Type == TType.String) {
MaxSize = iprot.ReadString();
} else {
TProtocolUtil.Skip(iprot, field.Type);
}
break;
case 3:
if (field.Type == TType.String) {
SizeCount = iprot.ReadString();
} else {
TProtocolUtil.Skip(iprot, field.Type);
}
break;
case 4:
if (field.Type == TType.String) {
PlcCount = iprot.ReadString();
} else {
TProtocolUtil.Skip(iprot, field.Type);
}
break;
default:
TProtocolUtil.Skip(iprot, field.Type);
break;
}
iprot.ReadFieldEnd();
}
iprot.ReadStructEnd();
}
public void Write(TProtocol oprot) {
TStruct struc = new TStruct("AreaPlc");
oprot.WriteStructBegin(struc);
TField field = new TField();
if (AreaName != null && __isset.AreaName) {
field.Name = "AreaName";
field.Type = TType.String;
field.ID = 1;
oprot.WriteFieldBegin(field);
oprot.WriteString(AreaName);
oprot.WriteFieldEnd();
}
if (MaxSize != null && __isset.MaxSize) {
field.Name = "MaxSize";
field.Type = TType.String;
field.ID = 2;
oprot.WriteFieldBegin(field);
oprot.WriteString(MaxSize);
oprot.WriteFieldEnd();
}
if (SizeCount != null && __isset.SizeCount) {
field.Name = "SizeCount";
field.Type = TType.String;
field.ID = 3;
oprot.WriteFieldBegin(field);
oprot.WriteString(SizeCount);
oprot.WriteFieldEnd();
}
if (PlcCount != null && __isset.PlcCount) {
field.Name = "PlcCount";
field.Type = TType.String;
field.ID = 4;
oprot.WriteFieldBegin(field);
oprot.WriteString(PlcCount);
oprot.WriteFieldEnd();
}
oprot.WriteFieldStop();
oprot.WriteStructEnd();
}
public override string ToString() {
StringBuilder sb = new StringBuilder("AreaPlc(");
sb.Append("AreaName: ");
sb.Append(AreaName);
sb.Append(",MaxSize: ");
sb.Append(MaxSize);
sb.Append(",SizeCount: ");
sb.Append(SizeCount);
sb.Append(",PlcCount: ");
sb.Append(PlcCount);
sb.Append(")");
return sb.ToString();
}
}