コード例 #1
0
        public override string ToString()
        {
            StringBuilder sb = new StringBuilder("Grouping(");

            sb.Append("Fields: ");
            sb.Append(Fields);
            sb.Append(",Shuffle: ");
            sb.Append(Shuffle == null ? "<null>" : Shuffle.ToString());
            sb.Append(",All: ");
            sb.Append(All == null ? "<null>" : All.ToString());
            sb.Append(",None: ");
            sb.Append(None == null ? "<null>" : None.ToString());
            sb.Append(",Direct: ");
            sb.Append(Direct == null ? "<null>" : Direct.ToString());
            sb.Append(",Custom_object: ");
            sb.Append(Custom_object == null ? "<null>" : Custom_object.ToString());
            sb.Append(",Custom_serialized: ");
            sb.Append(Custom_serialized);
            sb.Append(",Local_or_shuffle: ");
            sb.Append(Local_or_shuffle == null ? "<null>" : Local_or_shuffle.ToString());
            sb.Append(")");
            return(sb.ToString());
        }
コード例 #2
0
        public void Write(TProtocol oprot)
        {
            TStruct struc = new TStruct("Grouping");

            oprot.WriteStructBegin(struc);
            TField field = new TField();

            if (Fields != null && __isset.fields)
            {
                field.Name = "fields";
                field.Type = TType.List;
                field.ID   = 1;
                oprot.WriteFieldBegin(field);
                {
                    oprot.WriteListBegin(new TList(TType.String, Fields.Count));
                    foreach (string _iter7 in Fields)
                    {
                        oprot.WriteString(_iter7);
                    }
                    oprot.WriteListEnd();
                }
                oprot.WriteFieldEnd();
            }
            if (Shuffle != null && __isset.shuffle)
            {
                field.Name = "shuffle";
                field.Type = TType.Struct;
                field.ID   = 2;
                oprot.WriteFieldBegin(field);
                Shuffle.Write(oprot);
                oprot.WriteFieldEnd();
            }
            if (All != null && __isset.all)
            {
                field.Name = "all";
                field.Type = TType.Struct;
                field.ID   = 3;
                oprot.WriteFieldBegin(field);
                All.Write(oprot);
                oprot.WriteFieldEnd();
            }
            if (None != null && __isset.none)
            {
                field.Name = "none";
                field.Type = TType.Struct;
                field.ID   = 4;
                oprot.WriteFieldBegin(field);
                None.Write(oprot);
                oprot.WriteFieldEnd();
            }
            if (Direct != null && __isset.direct)
            {
                field.Name = "direct";
                field.Type = TType.Struct;
                field.ID   = 5;
                oprot.WriteFieldBegin(field);
                Direct.Write(oprot);
                oprot.WriteFieldEnd();
            }
            if (Custom_object != null && __isset.custom_object)
            {
                field.Name = "custom_object";
                field.Type = TType.Struct;
                field.ID   = 6;
                oprot.WriteFieldBegin(field);
                Custom_object.Write(oprot);
                oprot.WriteFieldEnd();
            }
            if (Custom_serialized != null && __isset.custom_serialized)
            {
                field.Name = "custom_serialized";
                field.Type = TType.String;
                field.ID   = 7;
                oprot.WriteFieldBegin(field);
                oprot.WriteBinary(Custom_serialized);
                oprot.WriteFieldEnd();
            }
            if (Local_or_shuffle != null && __isset.local_or_shuffle)
            {
                field.Name = "local_or_shuffle";
                field.Type = TType.Struct;
                field.ID   = 8;
                oprot.WriteFieldBegin(field);
                Local_or_shuffle.Write(oprot);
                oprot.WriteFieldEnd();
            }
            oprot.WriteFieldStop();
            oprot.WriteStructEnd();
        }
コード例 #3
0
    public override string ToString()
    {
        StringBuilder __sb    = new StringBuilder("Grouping(");
        bool          __first = true;

        if (Fields != null && __isset.fields)
        {
            if (!__first)
            {
                __sb.Append(", ");
            }
            __first = false;
            __sb.Append("Fields: ");
            __sb.Append(Fields);
        }
        if (Shuffle != null && __isset.shuffle)
        {
            if (!__first)
            {
                __sb.Append(", ");
            }
            __first = false;
            __sb.Append("Shuffle: ");
            __sb.Append(Shuffle == null ? "<null>" : Shuffle.ToString());
        }
        if (All != null && __isset.all)
        {
            if (!__first)
            {
                __sb.Append(", ");
            }
            __first = false;
            __sb.Append("All: ");
            __sb.Append(All == null ? "<null>" : All.ToString());
        }
        if (None != null && __isset.none)
        {
            if (!__first)
            {
                __sb.Append(", ");
            }
            __first = false;
            __sb.Append("None: ");
            __sb.Append(None == null ? "<null>" : None.ToString());
        }
        if (Direct != null && __isset.direct)
        {
            if (!__first)
            {
                __sb.Append(", ");
            }
            __first = false;
            __sb.Append("Direct: ");
            __sb.Append(Direct == null ? "<null>" : Direct.ToString());
        }
        if (Custom_object != null && __isset.custom_object)
        {
            if (!__first)
            {
                __sb.Append(", ");
            }
            __first = false;
            __sb.Append("Custom_object: ");
            __sb.Append(Custom_object == null ? "<null>" : Custom_object.ToString());
        }
        if (Custom_serialized != null && __isset.custom_serialized)
        {
            if (!__first)
            {
                __sb.Append(", ");
            }
            __first = false;
            __sb.Append("Custom_serialized: ");
            __sb.Append(Custom_serialized);
        }
        if (Local_or_shuffle != null && __isset.local_or_shuffle)
        {
            if (!__first)
            {
                __sb.Append(", ");
            }
            __first = false;
            __sb.Append("Local_or_shuffle: ");
            __sb.Append(Local_or_shuffle == null ? "<null>" : Local_or_shuffle.ToString());
        }
        __sb.Append(")");
        return(__sb.ToString());
    }