< Summary

Class:DCL.ECSComponents.RaycastResultReflection
Assembly:Decentraland.Protocol.GeneratedCode
File(s):/tmp/workspace/unity-renderer/unity-renderer/Assets/Scripts/MainScripts/DCL/DecentralandProtocol/RaycastResult.gen.cs
Covered lines:0
Uncovered lines:4
Coverable lines:4
Total lines:432
Line coverage:0% (0 of 4)
Covered branches:0
Total branches:0
Covered methods:0
Total methods:2
Method coverage:0% (0 of 2)

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity NPath complexity Sequence coverage
RaycastResultReflection()0%2100%

File(s)

/tmp/workspace/unity-renderer/unity-renderer/Assets/Scripts/MainScripts/DCL/DecentralandProtocol/RaycastResult.gen.cs

#LineLine coverage
 1// <auto-generated>
 2//     Generated by the protocol buffer compiler.  DO NOT EDIT!
 3//     source: decentraland/sdk/components/raycast_result.proto
 4// </auto-generated>
 5#pragma warning disable 1591, 0612, 3021
 6#region Designer generated code
 7
 8using pb = global::Google.Protobuf;
 9using pbc = global::Google.Protobuf.Collections;
 10using pbr = global::Google.Protobuf.Reflection;
 11using scg = global::System.Collections.Generic;
 12namespace DCL.ECSComponents {
 13
 14  /// <summary>Holder for reflection information generated from decentraland/sdk/components/raycast_result.proto</summar
 15  public static partial class RaycastResultReflection {
 16
 17    #region Descriptor
 18    /// <summary>File descriptor for decentraland/sdk/components/raycast_result.proto</summary>
 19    public static pbr::FileDescriptor Descriptor {
 020      get { return descriptor; }
 21    }
 22    private static pbr::FileDescriptor descriptor;
 23
 24    static RaycastResultReflection() {
 025      byte[] descriptorData = global::System.Convert.FromBase64String(
 26          string.Concat(
 27            "CjBkZWNlbnRyYWxhbmQvc2RrL2NvbXBvbmVudHMvcmF5Y2FzdF9yZXN1bHQu",
 28            "cHJvdG8SG2RlY2VudHJhbGFuZC5zZGsuY29tcG9uZW50cxohZGVjZW50cmFs",
 29            "YW5kL2NvbW1vbi92ZWN0b3JzLnByb3RvGjRkZWNlbnRyYWxhbmQvc2RrL2Nv",
 30            "bXBvbmVudHMvY29tbW9uL3JheWNhc3RfaGl0LnByb3RvIvABCg9QQlJheWNh",
 31            "c3RSZXN1bHQSFgoJdGltZXN0YW1wGAEgASgNSACIAQESMwoNZ2xvYmFsX29y",
 32            "aWdpbhgCIAEoCzIcLmRlY2VudHJhbGFuZC5jb21tb24uVmVjdG9yMxIvCglk",
 33            "aXJlY3Rpb24YAyABKAsyHC5kZWNlbnRyYWxhbmQuY29tbW9uLlZlY3RvcjMS",
 34            "PAoEaGl0cxgEIAMoCzIuLmRlY2VudHJhbGFuZC5zZGsuY29tcG9uZW50cy5j",
 35            "b21tb24uUmF5Y2FzdEhpdBITCgt0aWNrX251bWJlchgFIAEoDUIMCgpfdGlt",
 36            "ZXN0YW1wQhSqAhFEQ0wuRUNTQ29tcG9uZW50c2IGcHJvdG8z"));
 037      descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData,
 38          new pbr::FileDescriptor[] { global::Decentraland.Common.VectorsReflection.Descriptor, global::DCL.ECSComponent
 39          new pbr::GeneratedClrTypeInfo(null, null, new pbr::GeneratedClrTypeInfo[] {
 40            new pbr::GeneratedClrTypeInfo(typeof(global::DCL.ECSComponents.PBRaycastResult), global::DCL.ECSComponents.P
 41          }));
 042    }
 43    #endregion
 44
 45  }
 46  #region Messages
 47  /// <summary>
 48  /// The PBRaycast component and PBRaycastResult are defined in https://adr.decentraland.org/adr/ADR-200
 49  ///
 50  /// The RaycastResult component is added to an Entity when the results of a previously attached
 51  /// Raycast component are available. It contains information about the ray and any objects it
 52  /// collided with.
 53  /// </summary>
 54  public sealed partial class PBRaycastResult : pb::IMessage<PBRaycastResult>
 55  #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
 56      , pb::IBufferMessage
 57  #endif
 58  {
 59    private static readonly pb::MessageParser<PBRaycastResult> _parser = new pb::MessageParser<PBRaycastResult>(() => ne
 60    private pb::UnknownFieldSet _unknownFields;
 61    private int _hasBits0;
 62    [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
 63    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
 64    public static pb::MessageParser<PBRaycastResult> Parser { get { return _parser; } }
 65
 66    [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
 67    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
 68    public static pbr::MessageDescriptor Descriptor {
 69      get { return global::DCL.ECSComponents.RaycastResultReflection.Descriptor.MessageTypes[0]; }
 70    }
 71
 72    [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
 73    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
 74    pbr::MessageDescriptor pb::IMessage.Descriptor {
 75      get { return Descriptor; }
 76    }
 77
 78    [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
 79    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
 80    public PBRaycastResult() {
 81      OnConstruction();
 82    }
 83
 84    partial void OnConstruction();
 85
 86    [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
 87    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
 88    public PBRaycastResult(PBRaycastResult other) : this() {
 89      _hasBits0 = other._hasBits0;
 90      timestamp_ = other.timestamp_;
 91      globalOrigin_ = other.globalOrigin_ != null ? other.globalOrigin_.Clone() : null;
 92      direction_ = other.direction_ != null ? other.direction_.Clone() : null;
 93      hits_ = other.hits_.Clone();
 94      tickNumber_ = other.tickNumber_;
 95      _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
 96    }
 97
 98    [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
 99    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
 100    public PBRaycastResult Clone() {
 101      return new PBRaycastResult(this);
 102    }
 103
 104    /// <summary>Field number for the "timestamp" field.</summary>
 105    public const int TimestampFieldNumber = 1;
 106    private uint timestamp_;
 107    /// <summary>
 108    /// timestamp is a correlation id, copied from the PBRaycast
 109    /// </summary>
 110    [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
 111    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
 112    public uint Timestamp {
 113      get { if ((_hasBits0 & 1) != 0) { return timestamp_; } else { return 0; } }
 114      set {
 115        _hasBits0 |= 1;
 116        timestamp_ = value;
 117      }
 118    }
 119    /// <summary>Gets whether the "timestamp" field is set</summary>
 120    [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
 121    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
 122    public bool HasTimestamp {
 123      get { return (_hasBits0 & 1) != 0; }
 124    }
 125    /// <summary>Clears the value of the "timestamp" field</summary>
 126    [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
 127    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
 128    public void ClearTimestamp() {
 129      _hasBits0 &= ~1;
 130    }
 131
 132    /// <summary>Field number for the "global_origin" field.</summary>
 133    public const int GlobalOriginFieldNumber = 2;
 134    private global::Decentraland.Common.Vector3 globalOrigin_;
 135    /// <summary>
 136    /// the starting point of the ray in global coordinates
 137    /// </summary>
 138    [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
 139    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
 140    public global::Decentraland.Common.Vector3 GlobalOrigin {
 141      get { return globalOrigin_; }
 142      set {
 143        globalOrigin_ = value;
 144      }
 145    }
 146
 147    /// <summary>Field number for the "direction" field.</summary>
 148    public const int DirectionFieldNumber = 3;
 149    private global::Decentraland.Common.Vector3 direction_;
 150    /// <summary>
 151    /// the direction vector of the ray in global coordinates
 152    /// </summary>
 153    [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
 154    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
 155    public global::Decentraland.Common.Vector3 Direction {
 156      get { return direction_; }
 157      set {
 158        direction_ = value;
 159      }
 160    }
 161
 162    /// <summary>Field number for the "hits" field.</summary>
 163    public const int HitsFieldNumber = 4;
 164    private static readonly pb::FieldCodec<global::DCL.ECSComponents.RaycastHit> _repeated_hits_codec
 165        = pb::FieldCodec.ForMessage(34, global::DCL.ECSComponents.RaycastHit.Parser);
 166    private readonly pbc::RepeatedField<global::DCL.ECSComponents.RaycastHit> hits_ = new pbc::RepeatedField<global::DCL
 167    /// <summary>
 168    /// zero or more hits
 169    /// </summary>
 170    [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
 171    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
 172    public pbc::RepeatedField<global::DCL.ECSComponents.RaycastHit> Hits {
 173      get { return hits_; }
 174    }
 175
 176    /// <summary>Field number for the "tick_number" field.</summary>
 177    public const int TickNumberFieldNumber = 5;
 178    private uint tickNumber_;
 179    /// <summary>
 180    /// number of tick in which the event was produced, equals to EngineInfo.tick_number
 181    /// </summary>
 182    [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
 183    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
 184    public uint TickNumber {
 185      get { return tickNumber_; }
 186      set {
 187        tickNumber_ = value;
 188      }
 189    }
 190
 191    [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
 192    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
 193    public override bool Equals(object other) {
 194      return Equals(other as PBRaycastResult);
 195    }
 196
 197    [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
 198    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
 199    public bool Equals(PBRaycastResult other) {
 200      if (ReferenceEquals(other, null)) {
 201        return false;
 202      }
 203      if (ReferenceEquals(other, this)) {
 204        return true;
 205      }
 206      if (Timestamp != other.Timestamp) return false;
 207      if (!object.Equals(GlobalOrigin, other.GlobalOrigin)) return false;
 208      if (!object.Equals(Direction, other.Direction)) return false;
 209      if(!hits_.Equals(other.hits_)) return false;
 210      if (TickNumber != other.TickNumber) return false;
 211      return Equals(_unknownFields, other._unknownFields);
 212    }
 213
 214    [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
 215    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
 216    public override int GetHashCode() {
 217      int hash = 1;
 218      if (HasTimestamp) hash ^= Timestamp.GetHashCode();
 219      if (globalOrigin_ != null) hash ^= GlobalOrigin.GetHashCode();
 220      if (direction_ != null) hash ^= Direction.GetHashCode();
 221      hash ^= hits_.GetHashCode();
 222      if (TickNumber != 0) hash ^= TickNumber.GetHashCode();
 223      if (_unknownFields != null) {
 224        hash ^= _unknownFields.GetHashCode();
 225      }
 226      return hash;
 227    }
 228
 229    [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
 230    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
 231    public override string ToString() {
 232      return pb::JsonFormatter.ToDiagnosticString(this);
 233    }
 234
 235    [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
 236    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
 237    public void WriteTo(pb::CodedOutputStream output) {
 238    #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
 239      output.WriteRawMessage(this);
 240    #else
 241      if (HasTimestamp) {
 242        output.WriteRawTag(8);
 243        output.WriteUInt32(Timestamp);
 244      }
 245      if (globalOrigin_ != null) {
 246        output.WriteRawTag(18);
 247        output.WriteMessage(GlobalOrigin);
 248      }
 249      if (direction_ != null) {
 250        output.WriteRawTag(26);
 251        output.WriteMessage(Direction);
 252      }
 253      hits_.WriteTo(output, _repeated_hits_codec);
 254      if (TickNumber != 0) {
 255        output.WriteRawTag(40);
 256        output.WriteUInt32(TickNumber);
 257      }
 258      if (_unknownFields != null) {
 259        _unknownFields.WriteTo(output);
 260      }
 261    #endif
 262    }
 263
 264    #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
 265    [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
 266    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
 267    void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
 268      if (HasTimestamp) {
 269        output.WriteRawTag(8);
 270        output.WriteUInt32(Timestamp);
 271      }
 272      if (globalOrigin_ != null) {
 273        output.WriteRawTag(18);
 274        output.WriteMessage(GlobalOrigin);
 275      }
 276      if (direction_ != null) {
 277        output.WriteRawTag(26);
 278        output.WriteMessage(Direction);
 279      }
 280      hits_.WriteTo(ref output, _repeated_hits_codec);
 281      if (TickNumber != 0) {
 282        output.WriteRawTag(40);
 283        output.WriteUInt32(TickNumber);
 284      }
 285      if (_unknownFields != null) {
 286        _unknownFields.WriteTo(ref output);
 287      }
 288    }
 289    #endif
 290
 291    [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
 292    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
 293    public int CalculateSize() {
 294      int size = 0;
 295      if (HasTimestamp) {
 296        size += 1 + pb::CodedOutputStream.ComputeUInt32Size(Timestamp);
 297      }
 298      if (globalOrigin_ != null) {
 299        size += 1 + pb::CodedOutputStream.ComputeMessageSize(GlobalOrigin);
 300      }
 301      if (direction_ != null) {
 302        size += 1 + pb::CodedOutputStream.ComputeMessageSize(Direction);
 303      }
 304      size += hits_.CalculateSize(_repeated_hits_codec);
 305      if (TickNumber != 0) {
 306        size += 1 + pb::CodedOutputStream.ComputeUInt32Size(TickNumber);
 307      }
 308      if (_unknownFields != null) {
 309        size += _unknownFields.CalculateSize();
 310      }
 311      return size;
 312    }
 313
 314    [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
 315    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
 316    public void MergeFrom(PBRaycastResult other) {
 317      if (other == null) {
 318        return;
 319      }
 320      if (other.HasTimestamp) {
 321        Timestamp = other.Timestamp;
 322      }
 323      if (other.globalOrigin_ != null) {
 324        if (globalOrigin_ == null) {
 325          GlobalOrigin = new global::Decentraland.Common.Vector3();
 326        }
 327        GlobalOrigin.MergeFrom(other.GlobalOrigin);
 328      }
 329      if (other.direction_ != null) {
 330        if (direction_ == null) {
 331          Direction = new global::Decentraland.Common.Vector3();
 332        }
 333        Direction.MergeFrom(other.Direction);
 334      }
 335      hits_.Add(other.hits_);
 336      if (other.TickNumber != 0) {
 337        TickNumber = other.TickNumber;
 338      }
 339      _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields);
 340    }
 341
 342    [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
 343    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
 344    public void MergeFrom(pb::CodedInputStream input) {
 345    #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
 346      input.ReadRawMessage(this);
 347    #else
 348      uint tag;
 349      while ((tag = input.ReadTag()) != 0) {
 350        switch(tag) {
 351          default:
 352            _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input);
 353            break;
 354          case 8: {
 355            Timestamp = input.ReadUInt32();
 356            break;
 357          }
 358          case 18: {
 359            if (globalOrigin_ == null) {
 360              GlobalOrigin = new global::Decentraland.Common.Vector3();
 361            }
 362            input.ReadMessage(GlobalOrigin);
 363            break;
 364          }
 365          case 26: {
 366            if (direction_ == null) {
 367              Direction = new global::Decentraland.Common.Vector3();
 368            }
 369            input.ReadMessage(Direction);
 370            break;
 371          }
 372          case 34: {
 373            hits_.AddEntriesFrom(input, _repeated_hits_codec);
 374            break;
 375          }
 376          case 40: {
 377            TickNumber = input.ReadUInt32();
 378            break;
 379          }
 380        }
 381      }
 382    #endif
 383    }
 384
 385    #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
 386    [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
 387    [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
 388    void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
 389      uint tag;
 390      while ((tag = input.ReadTag()) != 0) {
 391        switch(tag) {
 392          default:
 393            _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input);
 394            break;
 395          case 8: {
 396            Timestamp = input.ReadUInt32();
 397            break;
 398          }
 399          case 18: {
 400            if (globalOrigin_ == null) {
 401              GlobalOrigin = new global::Decentraland.Common.Vector3();
 402            }
 403            input.ReadMessage(GlobalOrigin);
 404            break;
 405          }
 406          case 26: {
 407            if (direction_ == null) {
 408              Direction = new global::Decentraland.Common.Vector3();
 409            }
 410            input.ReadMessage(Direction);
 411            break;
 412          }
 413          case 34: {
 414            hits_.AddEntriesFrom(ref input, _repeated_hits_codec);
 415            break;
 416          }
 417          case 40: {
 418            TickNumber = input.ReadUInt32();
 419            break;
 420          }
 421        }
 422      }
 423    }
 424    #endif
 425
 426  }
 427
 428  #endregion
 429
 430}
 431
 432#endregion Designer generated code