Beispiel #1
0
            public static Improbable.Gdk.Tests.AlternateSchemaSyntax.Connection.Update DeserializeUpdate(global::Improbable.Worker.Core.SchemaComponentUpdate updateObj)
            {
                var update = new Improbable.Gdk.Tests.AlternateSchemaSyntax.Connection.Update();
                var obj    = updateObj.GetFields();

                return(update);
            }
Beispiel #2
0
 public static void SerializeUpdate(Improbable.Gdk.Tests.BlittableTypes.BlittableComponent.Component component, global::Improbable.Worker.Core.SchemaComponentUpdate updateObj)
 {
     var obj = updateObj.GetFields();
     {
         if (component.IsDataDirty(0))
         {
             obj.AddBool(1, component.BoolField);
         }
     }
     {
         if (component.IsDataDirty(1))
         {
             obj.AddInt32(2, component.IntField);
         }
     }
     {
         if (component.IsDataDirty(2))
         {
             obj.AddInt64(3, component.LongField);
         }
     }
     {
         if (component.IsDataDirty(3))
         {
             obj.AddFloat(4, component.FloatField);
         }
     }
     {
         if (component.IsDataDirty(4))
         {
             obj.AddDouble(5, component.DoubleField);
         }
     }
 }
            public static Improbable.Gdk.Tests.ComponentsWithNoFields.ComponentWithNoFieldsWithEvents.Update DeserializeUpdate(global::Improbable.Worker.Core.SchemaComponentUpdate updateObj)
            {
                var update = new Improbable.Gdk.Tests.ComponentsWithNoFields.ComponentWithNoFieldsWithEvents.Update();
                var obj    = updateObj.GetFields();

                return(update);
            }
 public static void SerializeUpdate(Improbable.Gdk.Tests.NestedComponent.Component component, global::Improbable.Worker.Core.SchemaComponentUpdate updateObj)
 {
     var obj = updateObj.GetFields();
     {
         if (component.IsDataDirty(0))
         {
             global::Improbable.Gdk.Tests.TypeName.Serialization.Serialize(component.NestedType, obj.AddObject(1));
         }
     }
 }
            public static void ApplyUpdate(global::Improbable.Worker.Core.SchemaComponentUpdate updateObj, ref Improbable.Gdk.Tests.NestedComponent.Component component)
            {
                var obj = updateObj.GetFields();

                {
                    if (obj.GetObjectCount(1) == 1)
                    {
                        var value = global::Improbable.Gdk.Tests.TypeName.Serialization.Deserialize(obj.GetObject(1));
                        component.NestedType = value;
                    }
                }
            }
            public static Improbable.Gdk.Tests.NestedComponent.Update DeserializeUpdate(global::Improbable.Worker.Core.SchemaComponentUpdate updateObj)
            {
                var update = new Improbable.Gdk.Tests.NestedComponent.Update();
                var obj    = updateObj.GetFields();

                {
                    if (obj.GetObjectCount(1) == 1)
                    {
                        var value = global::Improbable.Gdk.Tests.TypeName.Serialization.Deserialize(obj.GetObject(1));
                        update.NestedType = new global::Improbable.Gdk.Core.Option <global::Improbable.Gdk.Tests.TypeName>(value);
                    }
                }
                return(update);
            }
Beispiel #7
0
            public static Improbable.Gdk.Tests.BlittableTypes.BlittableComponent.Update DeserializeUpdate(global::Improbable.Worker.Core.SchemaComponentUpdate updateObj)
            {
                var update = new Improbable.Gdk.Tests.BlittableTypes.BlittableComponent.Update();
                var obj    = updateObj.GetFields();

                {
                    if (obj.GetBoolCount(1) == 1)
                    {
                        var value = obj.GetBool(1);
                        update.BoolField = new global::Improbable.Gdk.Core.Option <BlittableBool>(value);
                    }
                }
                {
                    if (obj.GetInt32Count(2) == 1)
                    {
                        var value = obj.GetInt32(2);
                        update.IntField = new global::Improbable.Gdk.Core.Option <int>(value);
                    }
                }
                {
                    if (obj.GetInt64Count(3) == 1)
                    {
                        var value = obj.GetInt64(3);
                        update.LongField = new global::Improbable.Gdk.Core.Option <long>(value);
                    }
                }
                {
                    if (obj.GetFloatCount(4) == 1)
                    {
                        var value = obj.GetFloat(4);
                        update.FloatField = new global::Improbable.Gdk.Core.Option <float>(value);
                    }
                }
                {
                    if (obj.GetDoubleCount(5) == 1)
                    {
                        var value = obj.GetDouble(5);
                        update.DoubleField = new global::Improbable.Gdk.Core.Option <double>(value);
                    }
                }
                return(update);
            }
Beispiel #8
0
            public static void ApplyUpdate(global::Improbable.Worker.Core.SchemaComponentUpdate updateObj, ref Improbable.Gdk.Tests.BlittableTypes.BlittableComponent.Component component)
            {
                var obj = updateObj.GetFields();

                {
                    if (obj.GetBoolCount(1) == 1)
                    {
                        var value = obj.GetBool(1);
                        component.BoolField = value;
                    }
                }
                {
                    if (obj.GetInt32Count(2) == 1)
                    {
                        var value = obj.GetInt32(2);
                        component.IntField = value;
                    }
                }
                {
                    if (obj.GetInt64Count(3) == 1)
                    {
                        var value = obj.GetInt64(3);
                        component.LongField = value;
                    }
                }
                {
                    if (obj.GetFloatCount(4) == 1)
                    {
                        var value = obj.GetFloat(4);
                        component.FloatField = value;
                    }
                }
                {
                    if (obj.GetDoubleCount(5) == 1)
                    {
                        var value = obj.GetDouble(5);
                        component.DoubleField = value;
                    }
                }
            }
            public override void ExecuteReplication(ComponentGroup replicationGroup, global::Improbable.Worker.Core.Connection connection)
            {
                var entityIdDataArray  = replicationGroup.GetComponentDataArray <SpatialEntityId>();
                var componentDataArray = replicationGroup.GetComponentDataArray <SpatialOSConnection>();
                var eventMyEventArray  = replicationGroup.GetComponentDataArray <EventSender.MyEvent>();

                for (var i = 0; i < componentDataArray.Length; i++)
                {
                    var data          = componentDataArray[i];
                    var dirtyEvents   = 0;
                    var eventsMyEvent = eventMyEventArray[i].Events;
                    dirtyEvents += eventsMyEvent.Count;

                    if (data.DirtyBit || dirtyEvents > 0)
                    {
                        var update = new global::Improbable.Worker.Core.SchemaComponentUpdate(1105);
                        SpatialOSConnection.Serialization.Serialize(data, update.GetFields());

                        // Serialize events
                        var eventsObject = update.GetEvents();
                        if (eventsMyEvent.Count > 0)
                        {
                            foreach (var e in eventsMyEvent)
                            {
                                var obj = eventsObject.AddObject(1);
                                global::Generated.Improbable.Gdk.Tests.AlternateSchemaSyntax.RandomDataType.Serialization.Serialize(e, obj);
                            }

                            eventsMyEvent.Clear();
                        }

                        // Send serialized update over the wire
                        connection.SendComponentUpdate(entityIdDataArray[i].EntityId, new global::Improbable.Worker.Core.ComponentUpdate(update));

                        data.DirtyBit         = false;
                        componentDataArray[i] = data;
                    }
                }
            }
            public override void ExecuteReplication(ComponentGroup replicationGroup, global::Improbable.Worker.Core.Connection connection)
            {
                var entityIdDataArray  = replicationGroup.GetComponentDataArray <SpatialEntityId>();
                var componentDataArray = replicationGroup.GetComponentDataArray <SpatialOSExhaustiveSingular>();

                for (var i = 0; i < componentDataArray.Length; i++)
                {
                    var data        = componentDataArray[i];
                    var dirtyEvents = 0;

                    if (data.DirtyBit || dirtyEvents > 0)
                    {
                        var update = new global::Improbable.Worker.Core.SchemaComponentUpdate(197715);
                        SpatialOSExhaustiveSingular.Serialization.Serialize(data, update.GetFields());

                        // Send serialized update over the wire
                        connection.SendComponentUpdate(entityIdDataArray[i].EntityId, new global::Improbable.Worker.Core.ComponentUpdate(update));

                        data.DirtyBit         = false;
                        componentDataArray[i] = data;
                    }
                }
            }
 public static void SerializeUpdate(Improbable.Gdk.Tests.ComponentsWithNoFields.ComponentWithNoFieldsWithEvents.Component component, global::Improbable.Worker.Core.SchemaComponentUpdate updateObj)
 {
     var obj = updateObj.GetFields();
 }
            public static void ApplyUpdate(global::Improbable.Worker.Core.SchemaComponentUpdate updateObj, ref Improbable.Gdk.Tests.NonblittableTypes.NonBlittableComponent.Component component)
            {
                var obj = updateObj.GetFields();

                var clearedFields = updateObj.GetClearedFields();

                {
                    if (obj.GetBoolCount(1) == 1)
                    {
                        var value = obj.GetBool(1);
                        component.BoolField = value;
                    }
                }
                {
                    if (obj.GetInt32Count(2) == 1)
                    {
                        var value = obj.GetInt32(2);
                        component.IntField = value;
                    }
                }
                {
                    if (obj.GetInt64Count(3) == 1)
                    {
                        var value = obj.GetInt64(3);
                        component.LongField = value;
                    }
                }
                {
                    if (obj.GetFloatCount(4) == 1)
                    {
                        var value = obj.GetFloat(4);
                        component.FloatField = value;
                    }
                }
                {
                    if (obj.GetDoubleCount(5) == 1)
                    {
                        var value = obj.GetDouble(5);
                        component.DoubleField = value;
                    }
                }
                {
                    if (obj.GetStringCount(6) == 1)
                    {
                        var value = obj.GetString(6);
                        component.StringField = value;
                    }
                }
                {
                    bool isCleared = false;
                    foreach (var fieldIndex in clearedFields)
                    {
                        isCleared = fieldIndex == 7;
                        if (isCleared)
                        {
                            break;
                        }
                    }
                    if (isCleared)
                    {
                        component.OptionalField = new int?();
                    }
                    else if (obj.GetInt32Count(7) == 1)
                    {
                        var value = obj.GetInt32(7);
                        component.OptionalField = new int?(value);
                    }
                }
                {
                    var  listSize  = obj.GetInt32Count(8);
                    bool isCleared = false;
                    foreach (var fieldIndex in clearedFields)
                    {
                        isCleared = fieldIndex == 8;
                        if (isCleared)
                        {
                            break;
                        }
                    }
                    if (listSize > 0 || isCleared)
                    {
                        component.ListField.Clear();
                    }
                    for (var i = 0; i < listSize; i++)
                    {
                        var value = obj.IndexInt32(8, (uint)i);
                        component.ListField.Add(value);
                    }
                }
                {
                    var  mapSize   = obj.GetObjectCount(9);
                    bool isCleared = false;
                    foreach (var fieldIndex in clearedFields)
                    {
                        isCleared = fieldIndex == 9;
                        if (isCleared)
                        {
                            break;
                        }
                    }
                    if (mapSize > 0 || isCleared)
                    {
                        component.MapField.Clear();
                    }
                    for (var i = 0; i < mapSize; i++)
                    {
                        var mapObj = obj.IndexObject(9, (uint)i);
                        var key    = mapObj.GetInt32(1);
                        var value  = mapObj.GetString(2);
                        component.MapField.Add(key, value);
                    }
                }
            }
 public static void ApplyUpdate(global::Improbable.Worker.Core.SchemaComponentUpdate updateObj, ref Improbable.Gdk.Tests.ComponentsWithNoFields.ComponentWithNoFieldsWithEvents.Component component)
 {
     var obj = updateObj.GetFields();
 }
            public static Improbable.Gdk.Tests.NonblittableTypes.NonBlittableComponent.Update DeserializeUpdate(global::Improbable.Worker.Core.SchemaComponentUpdate updateObj)
            {
                var update = new Improbable.Gdk.Tests.NonblittableTypes.NonBlittableComponent.Update();
                var obj    = updateObj.GetFields();

                var clearedFields = updateObj.GetClearedFields();

                {
                    if (obj.GetBoolCount(1) == 1)
                    {
                        var value = obj.GetBool(1);
                        update.BoolField = new global::Improbable.Gdk.Core.Option <BlittableBool>(value);
                    }
                }
                {
                    if (obj.GetInt32Count(2) == 1)
                    {
                        var value = obj.GetInt32(2);
                        update.IntField = new global::Improbable.Gdk.Core.Option <int>(value);
                    }
                }
                {
                    if (obj.GetInt64Count(3) == 1)
                    {
                        var value = obj.GetInt64(3);
                        update.LongField = new global::Improbable.Gdk.Core.Option <long>(value);
                    }
                }
                {
                    if (obj.GetFloatCount(4) == 1)
                    {
                        var value = obj.GetFloat(4);
                        update.FloatField = new global::Improbable.Gdk.Core.Option <float>(value);
                    }
                }
                {
                    if (obj.GetDoubleCount(5) == 1)
                    {
                        var value = obj.GetDouble(5);
                        update.DoubleField = new global::Improbable.Gdk.Core.Option <double>(value);
                    }
                }
                {
                    if (obj.GetStringCount(6) == 1)
                    {
                        var value = obj.GetString(6);
                        update.StringField = new global::Improbable.Gdk.Core.Option <string>(value);
                    }
                }
                {
                    bool isCleared = false;
                    foreach (var fieldIndex in clearedFields)
                    {
                        isCleared = fieldIndex == 7;
                        if (isCleared)
                        {
                            break;
                        }
                    }
                    if (isCleared)
                    {
                        update.OptionalField = new global::Improbable.Gdk.Core.Option <int?>(new int?());
                    }
                    else if (obj.GetInt32Count(7) == 1)
                    {
                        var value = obj.GetInt32(7);
                        update.OptionalField = new global::Improbable.Gdk.Core.Option <int?>(new int?(value));
                    }
                }
                {
                    var  listSize  = obj.GetInt32Count(8);
                    bool isCleared = false;
                    foreach (var fieldIndex in clearedFields)
                    {
                        isCleared = fieldIndex == 8;
                        if (isCleared)
                        {
                            break;
                        }
                    }
                    if (listSize > 0 || isCleared)
                    {
                        update.ListField = new global::Improbable.Gdk.Core.Option <global::System.Collections.Generic.List <int> >(new global::System.Collections.Generic.List <int>());
                    }
                    for (var i = 0; i < listSize; i++)
                    {
                        var value = obj.IndexInt32(8, (uint)i);
                        update.ListField.Value.Add(value);
                    }
                }
                {
                    var  mapSize   = obj.GetObjectCount(9);
                    bool isCleared = false;
                    foreach (var fieldIndex in clearedFields)
                    {
                        isCleared = fieldIndex == 9;
                        if (isCleared)
                        {
                            break;
                        }
                    }
                    if (mapSize > 0 || isCleared)
                    {
                        update.MapField = new global::Improbable.Gdk.Core.Option <global::System.Collections.Generic.Dictionary <int, string> >(new global::System.Collections.Generic.Dictionary <int, string>());
                    }
                    for (var i = 0; i < mapSize; i++)
                    {
                        var mapObj = obj.IndexObject(9, (uint)i);
                        var key    = mapObj.GetInt32(1);
                        var value  = mapObj.GetString(2);
                        update.MapField.Value.Add(key, value);
                    }
                }
                return(update);
            }
            public static void SerializeUpdate(Improbable.Gdk.Tests.NonblittableTypes.NonBlittableComponent.Component component, global::Improbable.Worker.Core.SchemaComponentUpdate updateObj)
            {
                var obj = updateObj.GetFields();
                {
                    if (component.IsDataDirty(0))
                    {
                        obj.AddBool(1, component.BoolField);
                    }
                }
                {
                    if (component.IsDataDirty(1))
                    {
                        obj.AddInt32(2, component.IntField);
                    }
                }
                {
                    if (component.IsDataDirty(2))
                    {
                        obj.AddInt64(3, component.LongField);
                    }
                }
                {
                    if (component.IsDataDirty(3))
                    {
                        obj.AddFloat(4, component.FloatField);
                    }
                }
                {
                    if (component.IsDataDirty(4))
                    {
                        obj.AddDouble(5, component.DoubleField);
                    }
                }
                {
                    if (component.IsDataDirty(5))
                    {
                        obj.AddString(6, component.StringField);
                    }
                }
                {
                    if (component.IsDataDirty(6))
                    {
                        if (component.OptionalField.HasValue)
                        {
                            obj.AddInt32(7, component.OptionalField.Value);
                        }
                    }

                    if (!component.OptionalField.HasValue)
                    {
                        updateObj.AddClearedField(7);
                    }
                }
                {
                    if (component.IsDataDirty(7))
                    {
                        foreach (var value in component.ListField)
                        {
                            obj.AddInt32(8, value);
                        }
                    }

                    if (component.ListField.Count == 0)
                    {
                        updateObj.AddClearedField(8);
                    }
                }
                {
                    if (component.IsDataDirty(8))
                    {
                        foreach (var keyValuePair in component.MapField)
                        {
                            var mapObj = obj.AddObject(9);
                            mapObj.AddInt32(1, keyValuePair.Key);
                            mapObj.AddString(2, keyValuePair.Value);
                        }
                    }

                    if (component.MapField.Count == 0)
                    {
                        updateObj.AddClearedField(9);
                    }
                }
            }
Beispiel #16
0
 public static void ApplyUpdate(global::Improbable.Worker.Core.SchemaComponentUpdate updateObj, ref Improbable.Gdk.Tests.AlternateSchemaSyntax.Connection.Component component)
 {
     var obj = updateObj.GetFields();
 }
Beispiel #17
0
            public static void ApplyUpdate(global::Improbable.Worker.Core.SchemaComponentUpdate updateObj, ref Improbable.Gdk.Tests.ExhaustiveSingular.Component component)
            {
                var obj = updateObj.GetFields();

                {
                    if (obj.GetBoolCount(1) == 1)
                    {
                        var value = obj.GetBool(1);
                        component.Field1 = value;
                    }
                }
                {
                    if (obj.GetFloatCount(2) == 1)
                    {
                        var value = obj.GetFloat(2);
                        component.Field2 = value;
                    }
                }
                {
                    if (obj.GetBytesCount(3) == 1)
                    {
                        var value = obj.GetBytes(3);
                        component.Field3 = value;
                    }
                }
                {
                    if (obj.GetInt32Count(4) == 1)
                    {
                        var value = obj.GetInt32(4);
                        component.Field4 = value;
                    }
                }
                {
                    if (obj.GetInt64Count(5) == 1)
                    {
                        var value = obj.GetInt64(5);
                        component.Field5 = value;
                    }
                }
                {
                    if (obj.GetDoubleCount(6) == 1)
                    {
                        var value = obj.GetDouble(6);
                        component.Field6 = value;
                    }
                }
                {
                    if (obj.GetStringCount(7) == 1)
                    {
                        var value = obj.GetString(7);
                        component.Field7 = value;
                    }
                }
                {
                    if (obj.GetUint32Count(8) == 1)
                    {
                        var value = obj.GetUint32(8);
                        component.Field8 = value;
                    }
                }
                {
                    if (obj.GetUint64Count(9) == 1)
                    {
                        var value = obj.GetUint64(9);
                        component.Field9 = value;
                    }
                }
                {
                    if (obj.GetSint32Count(10) == 1)
                    {
                        var value = obj.GetSint32(10);
                        component.Field10 = value;
                    }
                }
                {
                    if (obj.GetSint64Count(11) == 1)
                    {
                        var value = obj.GetSint64(11);
                        component.Field11 = value;
                    }
                }
                {
                    if (obj.GetFixed32Count(12) == 1)
                    {
                        var value = obj.GetFixed32(12);
                        component.Field12 = value;
                    }
                }
                {
                    if (obj.GetFixed64Count(13) == 1)
                    {
                        var value = obj.GetFixed64(13);
                        component.Field13 = value;
                    }
                }
                {
                    if (obj.GetSfixed32Count(14) == 1)
                    {
                        var value = obj.GetSfixed32(14);
                        component.Field14 = value;
                    }
                }
                {
                    if (obj.GetSfixed64Count(15) == 1)
                    {
                        var value = obj.GetSfixed64(15);
                        component.Field15 = value;
                    }
                }
                {
                    if (obj.GetEntityIdCount(16) == 1)
                    {
                        var value = obj.GetEntityId(16);
                        component.Field16 = value;
                    }
                }
                {
                    if (obj.GetObjectCount(17) == 1)
                    {
                        var value = global::Improbable.Gdk.Tests.SomeType.Serialization.Deserialize(obj.GetObject(17));
                        component.Field17 = value;
                    }
                }
            }
Beispiel #18
0
            public static Improbable.Gdk.Tests.ExhaustiveSingular.Update DeserializeUpdate(global::Improbable.Worker.Core.SchemaComponentUpdate updateObj)
            {
                var update = new Improbable.Gdk.Tests.ExhaustiveSingular.Update();
                var obj    = updateObj.GetFields();

                {
                    if (obj.GetBoolCount(1) == 1)
                    {
                        var value = obj.GetBool(1);
                        update.Field1 = new global::Improbable.Gdk.Core.Option <BlittableBool>(value);
                    }
                }
                {
                    if (obj.GetFloatCount(2) == 1)
                    {
                        var value = obj.GetFloat(2);
                        update.Field2 = new global::Improbable.Gdk.Core.Option <float>(value);
                    }
                }
                {
                    if (obj.GetBytesCount(3) == 1)
                    {
                        var value = obj.GetBytes(3);
                        update.Field3 = new global::Improbable.Gdk.Core.Option <byte[]>(value);
                    }
                }
                {
                    if (obj.GetInt32Count(4) == 1)
                    {
                        var value = obj.GetInt32(4);
                        update.Field4 = new global::Improbable.Gdk.Core.Option <int>(value);
                    }
                }
                {
                    if (obj.GetInt64Count(5) == 1)
                    {
                        var value = obj.GetInt64(5);
                        update.Field5 = new global::Improbable.Gdk.Core.Option <long>(value);
                    }
                }
                {
                    if (obj.GetDoubleCount(6) == 1)
                    {
                        var value = obj.GetDouble(6);
                        update.Field6 = new global::Improbable.Gdk.Core.Option <double>(value);
                    }
                }
                {
                    if (obj.GetStringCount(7) == 1)
                    {
                        var value = obj.GetString(7);
                        update.Field7 = new global::Improbable.Gdk.Core.Option <string>(value);
                    }
                }
                {
                    if (obj.GetUint32Count(8) == 1)
                    {
                        var value = obj.GetUint32(8);
                        update.Field8 = new global::Improbable.Gdk.Core.Option <uint>(value);
                    }
                }
                {
                    if (obj.GetUint64Count(9) == 1)
                    {
                        var value = obj.GetUint64(9);
                        update.Field9 = new global::Improbable.Gdk.Core.Option <ulong>(value);
                    }
                }
                {
                    if (obj.GetSint32Count(10) == 1)
                    {
                        var value = obj.GetSint32(10);
                        update.Field10 = new global::Improbable.Gdk.Core.Option <int>(value);
                    }
                }
                {
                    if (obj.GetSint64Count(11) == 1)
                    {
                        var value = obj.GetSint64(11);
                        update.Field11 = new global::Improbable.Gdk.Core.Option <long>(value);
                    }
                }
                {
                    if (obj.GetFixed32Count(12) == 1)
                    {
                        var value = obj.GetFixed32(12);
                        update.Field12 = new global::Improbable.Gdk.Core.Option <uint>(value);
                    }
                }
                {
                    if (obj.GetFixed64Count(13) == 1)
                    {
                        var value = obj.GetFixed64(13);
                        update.Field13 = new global::Improbable.Gdk.Core.Option <ulong>(value);
                    }
                }
                {
                    if (obj.GetSfixed32Count(14) == 1)
                    {
                        var value = obj.GetSfixed32(14);
                        update.Field14 = new global::Improbable.Gdk.Core.Option <int>(value);
                    }
                }
                {
                    if (obj.GetSfixed64Count(15) == 1)
                    {
                        var value = obj.GetSfixed64(15);
                        update.Field15 = new global::Improbable.Gdk.Core.Option <long>(value);
                    }
                }
                {
                    if (obj.GetEntityIdCount(16) == 1)
                    {
                        var value = obj.GetEntityId(16);
                        update.Field16 = new global::Improbable.Gdk.Core.Option <global::Improbable.Worker.EntityId>(value);
                    }
                }
                {
                    if (obj.GetObjectCount(17) == 1)
                    {
                        var value = global::Improbable.Gdk.Tests.SomeType.Serialization.Deserialize(obj.GetObject(17));
                        update.Field17 = new global::Improbable.Gdk.Core.Option <global::Improbable.Gdk.Tests.SomeType>(value);
                    }
                }
                return(update);
            }
Beispiel #19
0
 public static void SerializeUpdate(Improbable.Gdk.Tests.AlternateSchemaSyntax.Connection.Component component, global::Improbable.Worker.Core.SchemaComponentUpdate updateObj)
 {
     var obj = updateObj.GetFields();
 }
Beispiel #20
0
 public static void SerializeUpdate(Improbable.Gdk.Tests.ExhaustiveSingular.Component component, global::Improbable.Worker.Core.SchemaComponentUpdate updateObj)
 {
     var obj = updateObj.GetFields();
     {
         if (component.IsDataDirty(0))
         {
             obj.AddBool(1, component.Field1);
         }
     }
     {
         if (component.IsDataDirty(1))
         {
             obj.AddFloat(2, component.Field2);
         }
     }
     {
         if (component.IsDataDirty(2))
         {
             obj.AddBytes(3, component.Field3);
         }
     }
     {
         if (component.IsDataDirty(3))
         {
             obj.AddInt32(4, component.Field4);
         }
     }
     {
         if (component.IsDataDirty(4))
         {
             obj.AddInt64(5, component.Field5);
         }
     }
     {
         if (component.IsDataDirty(5))
         {
             obj.AddDouble(6, component.Field6);
         }
     }
     {
         if (component.IsDataDirty(6))
         {
             obj.AddString(7, component.Field7);
         }
     }
     {
         if (component.IsDataDirty(7))
         {
             obj.AddUint32(8, component.Field8);
         }
     }
     {
         if (component.IsDataDirty(8))
         {
             obj.AddUint64(9, component.Field9);
         }
     }
     {
         if (component.IsDataDirty(9))
         {
             obj.AddSint32(10, component.Field10);
         }
     }
     {
         if (component.IsDataDirty(10))
         {
             obj.AddSint64(11, component.Field11);
         }
     }
     {
         if (component.IsDataDirty(11))
         {
             obj.AddFixed32(12, component.Field12);
         }
     }
     {
         if (component.IsDataDirty(12))
         {
             obj.AddFixed64(13, component.Field13);
         }
     }
     {
         if (component.IsDataDirty(13))
         {
             obj.AddSfixed32(14, component.Field14);
         }
     }
     {
         if (component.IsDataDirty(14))
         {
             obj.AddSfixed64(15, component.Field15);
         }
     }
     {
         if (component.IsDataDirty(15))
         {
             obj.AddEntityId(16, component.Field16);
         }
     }
     {
         if (component.IsDataDirty(16))
         {
             global::Improbable.Gdk.Tests.SomeType.Serialization.Serialize(component.Field17, obj.AddObject(17));
         }
     }
 }