Ejemplo n.º 1
0
            public NStorageWriteMessage Build()
            {
                var original = message;

                message = new NStorageWriteMessage
                {
                    payload = { StorageWrite = new TStorageWrite(original.payload.StorageWrite) }
                };
                return(original);
            }
Ejemplo n.º 2
0
            public Builder Update(string bucket, string collection, string record, string version, StoragePermissionRead readPermission, StoragePermissionWrite writePermission, List <TStorageUpdate.Types.StorageUpdate.Types.UpdateOp> ops)
            {
                var update = new TStorageUpdate.Types.StorageUpdate
                {
                    Key = new TStorageUpdate.Types.StorageUpdate.Types.StorageKey
                    {
                        Bucket     = bucket,
                        Collection = collection,
                        Record     = record,
                        Version    = version
                    },
                    Ops             = { ops },
                    PermissionRead  = NStorageWriteMessage.GetReadPermission(readPermission),
                    PermissionWrite = NStorageWriteMessage.GetWritePermission(writePermission),
                };

                message.payload.StorageUpdate.Updates.Add(update);
                return(this);
            }
Ejemplo n.º 3
0
 public Builder()
 {
     message = new NStorageWriteMessage();
 }