Esempio n. 1
0
        public void MergeFrom(BehaviorControlRequest other)
        {
            if (other == null)
            {
                return;
            }
            switch (other.RequestTypeCase)
            {
            case RequestTypeOneofCase.ControlRelease:
                if (ControlRelease == null)
                {
                    ControlRelease = new global::Anki.Vector.ExternalInterface.ControlRelease();
                }
                ControlRelease.MergeFrom(other.ControlRelease);
                break;

            case RequestTypeOneofCase.ControlRequest:
                if (ControlRequest == null)
                {
                    ControlRequest = new global::Anki.Vector.ExternalInterface.ControlRequest();
                }
                ControlRequest.MergeFrom(other.ControlRequest);
                break;
            }

            _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields);
        }
Esempio n. 2
0
        public override int GetHashCode()
        {
            int hash = 1;

            if (requestTypeCase_ == RequestTypeOneofCase.ControlRelease)
            {
                hash ^= ControlRelease.GetHashCode();
            }
            if (requestTypeCase_ == RequestTypeOneofCase.ControlRequest)
            {
                hash ^= ControlRequest.GetHashCode();
            }
            hash ^= (int)requestTypeCase_;
            if (_unknownFields != null)
            {
                hash ^= _unknownFields.GetHashCode();
            }
            return(hash);
        }