Initial Client/Server Communication
#1 Followed the MagicOnion quickstart guide, borrowing code from the chat sample app to get something working
This commit is contained in:
parent
52b0d4d8ff
commit
a0c8dbee72
493 changed files with 57790 additions and 3 deletions
33
Assets/Scripts/MessagePack/ExtensionHeader.cs
Normal file
33
Assets/Scripts/MessagePack/ExtensionHeader.cs
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
// Copyright (c) All contributors. All rights reserved.
|
||||
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
||||
|
||||
using System;
|
||||
|
||||
namespace MessagePack
|
||||
{
|
||||
#if MESSAGEPACK_INTERNAL
|
||||
internal
|
||||
#else
|
||||
public
|
||||
#endif
|
||||
struct ExtensionHeader : IEquatable<ExtensionHeader>
|
||||
{
|
||||
public sbyte TypeCode { get; private set; }
|
||||
|
||||
public uint Length { get; private set; }
|
||||
|
||||
public ExtensionHeader(sbyte typeCode, uint length)
|
||||
{
|
||||
this.TypeCode = typeCode;
|
||||
this.Length = length;
|
||||
}
|
||||
|
||||
public ExtensionHeader(sbyte typeCode, int length)
|
||||
{
|
||||
this.TypeCode = typeCode;
|
||||
this.Length = (uint)length;
|
||||
}
|
||||
|
||||
public bool Equals(ExtensionHeader other) => this.TypeCode == other.TypeCode && this.Length == other.Length;
|
||||
}
|
||||
}
|
||||
Loading…
Reference in a new issue