You've already forked npm-core-sdk
544 lines
29 KiB
TypeScript
544 lines
29 KiB
TypeScript
// @generated by protobuf-ts 2.11.1 with parameter use_proto_field_name,keep_enum_prefix
|
|
// @generated from protobuf file "actorAction.proto" (package "api", syntax proto3)
|
|
// tslint:disable
|
|
import type { BinaryWriteOptions } from "@protobuf-ts/runtime";
|
|
import type { IBinaryWriter } from "@protobuf-ts/runtime";
|
|
import { WireType } from "@protobuf-ts/runtime";
|
|
import type { BinaryReadOptions } from "@protobuf-ts/runtime";
|
|
import type { IBinaryReader } from "@protobuf-ts/runtime";
|
|
import { UnknownFieldHandler } from "@protobuf-ts/runtime";
|
|
import type { PartialMessage } from "@protobuf-ts/runtime";
|
|
import { reflectionMergePartial } from "@protobuf-ts/runtime";
|
|
import { MessageType } from "@protobuf-ts/runtime";
|
|
import { ActorAuthorisation } from "./slotbooking";
|
|
import { SiteAlias } from "./repositoryShared";
|
|
import { EntityID } from "./shared";
|
|
import { CommandHeader } from "./shared";
|
|
import { ActorSnapshot } from "./repositoryShared";
|
|
// Action Summary
|
|
// - CompleteSnapshot : After each Snapshot completed, reset the quantity of the missing Stocks > stock.Snapshotted
|
|
// - SetSiteAlias : After each created, set a new entry in the SiteActor DB >
|
|
// - ClearSiteAlias : After each deleted, clear entry in the SiteActor DB >
|
|
//
|
|
|
|
/**
|
|
*
|
|
* CompleteSnapshot : finalize a actor snapshot
|
|
* by sending cumulated snapshotted quantity on stock id not already cumulated,
|
|
* by reseting the quantity of missing stock entry for the current snapshot
|
|
*
|
|
* @generated from protobuf message api.ActorCompleteSnapshotPayload
|
|
*/
|
|
export interface ActorCompleteSnapshotPayload {
|
|
/**
|
|
* @generated from protobuf field: api.ActorSnapshot Snapshot = 1
|
|
*/
|
|
Snapshot?: ActorSnapshot;
|
|
}
|
|
/**
|
|
* @generated from protobuf message api.ActorCompleteSnapshot
|
|
*/
|
|
export interface ActorCompleteSnapshot {
|
|
/**
|
|
* @generated from protobuf field: api.CommandHeader Header = 1
|
|
*/
|
|
Header?: CommandHeader;
|
|
/**
|
|
* @generated from protobuf field: api.EntityID ID = 2
|
|
*/
|
|
ID?: EntityID;
|
|
/**
|
|
* @generated from protobuf field: api.ActorCompleteSnapshotPayload Payload = 3
|
|
*/
|
|
Payload?: ActorCompleteSnapshotPayload;
|
|
/**
|
|
* @generated from protobuf field: api.ActorCompleteSnapshotPayload EventPayload = 4
|
|
*/
|
|
EventPayload?: ActorCompleteSnapshotPayload;
|
|
/**
|
|
* @generated from protobuf field: api.ActorCompleteSnapshotPayload PreviousPayload = 5
|
|
*/
|
|
PreviousPayload?: ActorCompleteSnapshotPayload;
|
|
}
|
|
/**
|
|
*
|
|
* SetSiteAlias : set a new entry in the SiteActor DB
|
|
*
|
|
* @generated from protobuf message api.ActorSetSiteAliasPayload
|
|
*/
|
|
export interface ActorSetSiteAliasPayload {
|
|
/**
|
|
* @generated from protobuf field: api.SiteAlias SiteAlias = 1
|
|
*/
|
|
SiteAlias?: SiteAlias;
|
|
/**
|
|
* @generated from protobuf field: bool IsSlotBookingEnabled = 2
|
|
*/
|
|
IsSlotBookingEnabled: boolean;
|
|
/**
|
|
* @generated from protobuf field: api.ActorAuthorisation AppointmentConstraints = 3
|
|
*/
|
|
AppointmentConstraints?: ActorAuthorisation;
|
|
/**
|
|
* @generated from protobuf field: string Name = 4
|
|
*/
|
|
Name: string;
|
|
}
|
|
/**
|
|
* @generated from protobuf message api.ActorSetSiteAlias
|
|
*/
|
|
export interface ActorSetSiteAlias {
|
|
/**
|
|
* @generated from protobuf field: api.CommandHeader Header = 1
|
|
*/
|
|
Header?: CommandHeader;
|
|
/**
|
|
* @generated from protobuf field: api.EntityID ID = 2
|
|
*/
|
|
ID?: EntityID;
|
|
/**
|
|
* @generated from protobuf field: api.ActorSetSiteAliasPayload Payload = 3
|
|
*/
|
|
Payload?: ActorSetSiteAliasPayload;
|
|
/**
|
|
* @generated from protobuf field: api.ActorSetSiteAliasPayload EventPayload = 4
|
|
*/
|
|
EventPayload?: ActorSetSiteAliasPayload;
|
|
/**
|
|
* @generated from protobuf field: api.ActorSetSiteAliasPayload PreviousPayload = 5
|
|
*/
|
|
PreviousPayload?: ActorSetSiteAliasPayload;
|
|
}
|
|
/**
|
|
*
|
|
* ClearSiteAlias : clear entry in the SiteActor DB
|
|
*
|
|
* @generated from protobuf message api.ActorClearSiteAliasPayload
|
|
*/
|
|
export interface ActorClearSiteAliasPayload {
|
|
/**
|
|
* @generated from protobuf field: api.SiteAlias SiteAlias = 1
|
|
*/
|
|
SiteAlias?: SiteAlias;
|
|
/**
|
|
* @generated from protobuf field: bool IsSlotBookingEnabled = 2
|
|
*/
|
|
IsSlotBookingEnabled: boolean;
|
|
}
|
|
/**
|
|
* @generated from protobuf message api.ClearSiteAlias
|
|
*/
|
|
export interface ClearSiteAlias {
|
|
/**
|
|
* @generated from protobuf field: api.CommandHeader Header = 1
|
|
*/
|
|
Header?: CommandHeader;
|
|
/**
|
|
* @generated from protobuf field: api.EntityID ID = 2
|
|
*/
|
|
ID?: EntityID;
|
|
/**
|
|
* @generated from protobuf field: api.ActorClearSiteAliasPayload Payload = 3
|
|
*/
|
|
Payload?: ActorClearSiteAliasPayload;
|
|
/**
|
|
* @generated from protobuf field: api.ActorClearSiteAliasPayload EventPayload = 4
|
|
*/
|
|
EventPayload?: ActorClearSiteAliasPayload;
|
|
/**
|
|
* @generated from protobuf field: api.ActorClearSiteAliasPayload PreviousPayload = 5
|
|
*/
|
|
PreviousPayload?: ActorClearSiteAliasPayload;
|
|
}
|
|
// @generated message type with reflection information, may provide speed optimized methods
|
|
class ActorCompleteSnapshotPayload$Type extends MessageType<ActorCompleteSnapshotPayload> {
|
|
constructor() {
|
|
super("api.ActorCompleteSnapshotPayload", [
|
|
{ no: 1, name: "Snapshot", kind: "message", localName: "Snapshot", jsonName: "Snapshot", T: () => ActorSnapshot }
|
|
], { "api.messageType": "Command", "api.payload": true, "api.action": "CompleteSnapshot" });
|
|
}
|
|
create(value?: PartialMessage<ActorCompleteSnapshotPayload>): ActorCompleteSnapshotPayload {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
if (value !== undefined)
|
|
reflectionMergePartial<ActorCompleteSnapshotPayload>(this, message, value);
|
|
return message;
|
|
}
|
|
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ActorCompleteSnapshotPayload): ActorCompleteSnapshotPayload {
|
|
let message = target ?? this.create(), end = reader.pos + length;
|
|
while (reader.pos < end) {
|
|
let [fieldNo, wireType] = reader.tag();
|
|
switch (fieldNo) {
|
|
case /* api.ActorSnapshot Snapshot */ 1:
|
|
message.Snapshot = ActorSnapshot.internalBinaryRead(reader, reader.uint32(), options, message.Snapshot);
|
|
break;
|
|
default:
|
|
let u = options.readUnknownField;
|
|
if (u === "throw")
|
|
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
let d = reader.skip(wireType);
|
|
if (u !== false)
|
|
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
}
|
|
}
|
|
return message;
|
|
}
|
|
internalBinaryWrite(message: ActorCompleteSnapshotPayload, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
/* api.ActorSnapshot Snapshot = 1; */
|
|
if (message.Snapshot)
|
|
ActorSnapshot.internalBinaryWrite(message.Snapshot, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
let u = options.writeUnknownFields;
|
|
if (u !== false)
|
|
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
return writer;
|
|
}
|
|
}
|
|
/**
|
|
* @generated MessageType for protobuf message api.ActorCompleteSnapshotPayload
|
|
*/
|
|
export const ActorCompleteSnapshotPayload = new ActorCompleteSnapshotPayload$Type();
|
|
// @generated message type with reflection information, may provide speed optimized methods
|
|
class ActorCompleteSnapshot$Type extends MessageType<ActorCompleteSnapshot> {
|
|
constructor() {
|
|
super("api.ActorCompleteSnapshot", [
|
|
{ no: 1, name: "Header", kind: "message", localName: "Header", jsonName: "Header", T: () => CommandHeader },
|
|
{ no: 2, name: "ID", kind: "message", localName: "ID", jsonName: "ID", T: () => EntityID },
|
|
{ no: 3, name: "Payload", kind: "message", localName: "Payload", jsonName: "Payload", T: () => ActorCompleteSnapshotPayload },
|
|
{ no: 4, name: "EventPayload", kind: "message", localName: "EventPayload", jsonName: "EventPayload", T: () => ActorCompleteSnapshotPayload },
|
|
{ no: 5, name: "PreviousPayload", kind: "message", localName: "PreviousPayload", jsonName: "PreviousPayload", T: () => ActorCompleteSnapshotPayload }
|
|
], { "api.messageType": "Command", "api.action": "CompleteSnapshot", "api.resultingEvent": "stock.Snapshotted", "api.additionalSource": "stock,getActorID()", "api.triggerEventFilters": "SnapshotCompleted" });
|
|
}
|
|
create(value?: PartialMessage<ActorCompleteSnapshot>): ActorCompleteSnapshot {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
if (value !== undefined)
|
|
reflectionMergePartial<ActorCompleteSnapshot>(this, message, value);
|
|
return message;
|
|
}
|
|
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ActorCompleteSnapshot): ActorCompleteSnapshot {
|
|
let message = target ?? this.create(), end = reader.pos + length;
|
|
while (reader.pos < end) {
|
|
let [fieldNo, wireType] = reader.tag();
|
|
switch (fieldNo) {
|
|
case /* api.CommandHeader Header */ 1:
|
|
message.Header = CommandHeader.internalBinaryRead(reader, reader.uint32(), options, message.Header);
|
|
break;
|
|
case /* api.EntityID ID */ 2:
|
|
message.ID = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.ID);
|
|
break;
|
|
case /* api.ActorCompleteSnapshotPayload Payload */ 3:
|
|
message.Payload = ActorCompleteSnapshotPayload.internalBinaryRead(reader, reader.uint32(), options, message.Payload);
|
|
break;
|
|
case /* api.ActorCompleteSnapshotPayload EventPayload */ 4:
|
|
message.EventPayload = ActorCompleteSnapshotPayload.internalBinaryRead(reader, reader.uint32(), options, message.EventPayload);
|
|
break;
|
|
case /* api.ActorCompleteSnapshotPayload PreviousPayload */ 5:
|
|
message.PreviousPayload = ActorCompleteSnapshotPayload.internalBinaryRead(reader, reader.uint32(), options, message.PreviousPayload);
|
|
break;
|
|
default:
|
|
let u = options.readUnknownField;
|
|
if (u === "throw")
|
|
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
let d = reader.skip(wireType);
|
|
if (u !== false)
|
|
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
}
|
|
}
|
|
return message;
|
|
}
|
|
internalBinaryWrite(message: ActorCompleteSnapshot, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
/* api.CommandHeader Header = 1; */
|
|
if (message.Header)
|
|
CommandHeader.internalBinaryWrite(message.Header, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
/* api.EntityID ID = 2; */
|
|
if (message.ID)
|
|
EntityID.internalBinaryWrite(message.ID, writer.tag(2, WireType.LengthDelimited).fork(), options).join();
|
|
/* api.ActorCompleteSnapshotPayload Payload = 3; */
|
|
if (message.Payload)
|
|
ActorCompleteSnapshotPayload.internalBinaryWrite(message.Payload, writer.tag(3, WireType.LengthDelimited).fork(), options).join();
|
|
/* api.ActorCompleteSnapshotPayload EventPayload = 4; */
|
|
if (message.EventPayload)
|
|
ActorCompleteSnapshotPayload.internalBinaryWrite(message.EventPayload, writer.tag(4, WireType.LengthDelimited).fork(), options).join();
|
|
/* api.ActorCompleteSnapshotPayload PreviousPayload = 5; */
|
|
if (message.PreviousPayload)
|
|
ActorCompleteSnapshotPayload.internalBinaryWrite(message.PreviousPayload, writer.tag(5, WireType.LengthDelimited).fork(), options).join();
|
|
let u = options.writeUnknownFields;
|
|
if (u !== false)
|
|
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
return writer;
|
|
}
|
|
}
|
|
/**
|
|
* @generated MessageType for protobuf message api.ActorCompleteSnapshot
|
|
*/
|
|
export const ActorCompleteSnapshot = new ActorCompleteSnapshot$Type();
|
|
// @generated message type with reflection information, may provide speed optimized methods
|
|
class ActorSetSiteAliasPayload$Type extends MessageType<ActorSetSiteAliasPayload> {
|
|
constructor() {
|
|
super("api.ActorSetSiteAliasPayload", [
|
|
{ no: 1, name: "SiteAlias", kind: "message", localName: "SiteAlias", jsonName: "SiteAlias", T: () => SiteAlias },
|
|
{ no: 2, name: "IsSlotBookingEnabled", kind: "scalar", localName: "IsSlotBookingEnabled", jsonName: "IsSlotBookingEnabled", T: 8 /*ScalarType.BOOL*/ },
|
|
{ no: 3, name: "AppointmentConstraints", kind: "message", localName: "AppointmentConstraints", jsonName: "AppointmentConstraints", T: () => ActorAuthorisation },
|
|
{ no: 4, name: "Name", kind: "scalar", localName: "Name", jsonName: "Name", T: 9 /*ScalarType.STRING*/ }
|
|
], { "api.messageType": "Command", "api.payload": true, "api.action": "SetSiteAlias" });
|
|
}
|
|
create(value?: PartialMessage<ActorSetSiteAliasPayload>): ActorSetSiteAliasPayload {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
message.IsSlotBookingEnabled = false;
|
|
message.Name = "";
|
|
if (value !== undefined)
|
|
reflectionMergePartial<ActorSetSiteAliasPayload>(this, message, value);
|
|
return message;
|
|
}
|
|
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ActorSetSiteAliasPayload): ActorSetSiteAliasPayload {
|
|
let message = target ?? this.create(), end = reader.pos + length;
|
|
while (reader.pos < end) {
|
|
let [fieldNo, wireType] = reader.tag();
|
|
switch (fieldNo) {
|
|
case /* api.SiteAlias SiteAlias */ 1:
|
|
message.SiteAlias = SiteAlias.internalBinaryRead(reader, reader.uint32(), options, message.SiteAlias);
|
|
break;
|
|
case /* bool IsSlotBookingEnabled */ 2:
|
|
message.IsSlotBookingEnabled = reader.bool();
|
|
break;
|
|
case /* api.ActorAuthorisation AppointmentConstraints */ 3:
|
|
message.AppointmentConstraints = ActorAuthorisation.internalBinaryRead(reader, reader.uint32(), options, message.AppointmentConstraints);
|
|
break;
|
|
case /* string Name */ 4:
|
|
message.Name = reader.string();
|
|
break;
|
|
default:
|
|
let u = options.readUnknownField;
|
|
if (u === "throw")
|
|
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
let d = reader.skip(wireType);
|
|
if (u !== false)
|
|
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
}
|
|
}
|
|
return message;
|
|
}
|
|
internalBinaryWrite(message: ActorSetSiteAliasPayload, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
/* api.SiteAlias SiteAlias = 1; */
|
|
if (message.SiteAlias)
|
|
SiteAlias.internalBinaryWrite(message.SiteAlias, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
/* bool IsSlotBookingEnabled = 2; */
|
|
if (message.IsSlotBookingEnabled !== false)
|
|
writer.tag(2, WireType.Varint).bool(message.IsSlotBookingEnabled);
|
|
/* api.ActorAuthorisation AppointmentConstraints = 3; */
|
|
if (message.AppointmentConstraints)
|
|
ActorAuthorisation.internalBinaryWrite(message.AppointmentConstraints, writer.tag(3, WireType.LengthDelimited).fork(), options).join();
|
|
/* string Name = 4; */
|
|
if (message.Name !== "")
|
|
writer.tag(4, WireType.LengthDelimited).string(message.Name);
|
|
let u = options.writeUnknownFields;
|
|
if (u !== false)
|
|
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
return writer;
|
|
}
|
|
}
|
|
/**
|
|
* @generated MessageType for protobuf message api.ActorSetSiteAliasPayload
|
|
*/
|
|
export const ActorSetSiteAliasPayload = new ActorSetSiteAliasPayload$Type();
|
|
// @generated message type with reflection information, may provide speed optimized methods
|
|
class ActorSetSiteAlias$Type extends MessageType<ActorSetSiteAlias> {
|
|
constructor() {
|
|
super("api.ActorSetSiteAlias", [
|
|
{ no: 1, name: "Header", kind: "message", localName: "Header", jsonName: "Header", T: () => CommandHeader },
|
|
{ no: 2, name: "ID", kind: "message", localName: "ID", jsonName: "ID", T: () => EntityID },
|
|
{ no: 3, name: "Payload", kind: "message", localName: "Payload", jsonName: "Payload", T: () => ActorSetSiteAliasPayload },
|
|
{ no: 4, name: "EventPayload", kind: "message", localName: "EventPayload", jsonName: "EventPayload", T: () => ActorSetSiteAliasPayload },
|
|
{ no: 5, name: "PreviousPayload", kind: "message", localName: "PreviousPayload", jsonName: "PreviousPayload", T: () => ActorSetSiteAliasPayload }
|
|
], { "api.messageType": "Command", "api.action": "SetSiteAlias", "api.triggerEventFilters": "AppointmentConfigurationUpdated" });
|
|
}
|
|
create(value?: PartialMessage<ActorSetSiteAlias>): ActorSetSiteAlias {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
if (value !== undefined)
|
|
reflectionMergePartial<ActorSetSiteAlias>(this, message, value);
|
|
return message;
|
|
}
|
|
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ActorSetSiteAlias): ActorSetSiteAlias {
|
|
let message = target ?? this.create(), end = reader.pos + length;
|
|
while (reader.pos < end) {
|
|
let [fieldNo, wireType] = reader.tag();
|
|
switch (fieldNo) {
|
|
case /* api.CommandHeader Header */ 1:
|
|
message.Header = CommandHeader.internalBinaryRead(reader, reader.uint32(), options, message.Header);
|
|
break;
|
|
case /* api.EntityID ID */ 2:
|
|
message.ID = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.ID);
|
|
break;
|
|
case /* api.ActorSetSiteAliasPayload Payload */ 3:
|
|
message.Payload = ActorSetSiteAliasPayload.internalBinaryRead(reader, reader.uint32(), options, message.Payload);
|
|
break;
|
|
case /* api.ActorSetSiteAliasPayload EventPayload */ 4:
|
|
message.EventPayload = ActorSetSiteAliasPayload.internalBinaryRead(reader, reader.uint32(), options, message.EventPayload);
|
|
break;
|
|
case /* api.ActorSetSiteAliasPayload PreviousPayload */ 5:
|
|
message.PreviousPayload = ActorSetSiteAliasPayload.internalBinaryRead(reader, reader.uint32(), options, message.PreviousPayload);
|
|
break;
|
|
default:
|
|
let u = options.readUnknownField;
|
|
if (u === "throw")
|
|
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
let d = reader.skip(wireType);
|
|
if (u !== false)
|
|
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
}
|
|
}
|
|
return message;
|
|
}
|
|
internalBinaryWrite(message: ActorSetSiteAlias, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
/* api.CommandHeader Header = 1; */
|
|
if (message.Header)
|
|
CommandHeader.internalBinaryWrite(message.Header, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
/* api.EntityID ID = 2; */
|
|
if (message.ID)
|
|
EntityID.internalBinaryWrite(message.ID, writer.tag(2, WireType.LengthDelimited).fork(), options).join();
|
|
/* api.ActorSetSiteAliasPayload Payload = 3; */
|
|
if (message.Payload)
|
|
ActorSetSiteAliasPayload.internalBinaryWrite(message.Payload, writer.tag(3, WireType.LengthDelimited).fork(), options).join();
|
|
/* api.ActorSetSiteAliasPayload EventPayload = 4; */
|
|
if (message.EventPayload)
|
|
ActorSetSiteAliasPayload.internalBinaryWrite(message.EventPayload, writer.tag(4, WireType.LengthDelimited).fork(), options).join();
|
|
/* api.ActorSetSiteAliasPayload PreviousPayload = 5; */
|
|
if (message.PreviousPayload)
|
|
ActorSetSiteAliasPayload.internalBinaryWrite(message.PreviousPayload, writer.tag(5, WireType.LengthDelimited).fork(), options).join();
|
|
let u = options.writeUnknownFields;
|
|
if (u !== false)
|
|
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
return writer;
|
|
}
|
|
}
|
|
/**
|
|
* @generated MessageType for protobuf message api.ActorSetSiteAlias
|
|
*/
|
|
export const ActorSetSiteAlias = new ActorSetSiteAlias$Type();
|
|
// @generated message type with reflection information, may provide speed optimized methods
|
|
class ActorClearSiteAliasPayload$Type extends MessageType<ActorClearSiteAliasPayload> {
|
|
constructor() {
|
|
super("api.ActorClearSiteAliasPayload", [
|
|
{ no: 1, name: "SiteAlias", kind: "message", localName: "SiteAlias", jsonName: "SiteAlias", T: () => SiteAlias },
|
|
{ no: 2, name: "IsSlotBookingEnabled", kind: "scalar", localName: "IsSlotBookingEnabled", jsonName: "IsSlotBookingEnabled", T: 8 /*ScalarType.BOOL*/ }
|
|
], { "api.messageType": "Command", "api.payload": true, "api.action": "ClearSiteAlias" });
|
|
}
|
|
create(value?: PartialMessage<ActorClearSiteAliasPayload>): ActorClearSiteAliasPayload {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
message.IsSlotBookingEnabled = false;
|
|
if (value !== undefined)
|
|
reflectionMergePartial<ActorClearSiteAliasPayload>(this, message, value);
|
|
return message;
|
|
}
|
|
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ActorClearSiteAliasPayload): ActorClearSiteAliasPayload {
|
|
let message = target ?? this.create(), end = reader.pos + length;
|
|
while (reader.pos < end) {
|
|
let [fieldNo, wireType] = reader.tag();
|
|
switch (fieldNo) {
|
|
case /* api.SiteAlias SiteAlias */ 1:
|
|
message.SiteAlias = SiteAlias.internalBinaryRead(reader, reader.uint32(), options, message.SiteAlias);
|
|
break;
|
|
case /* bool IsSlotBookingEnabled */ 2:
|
|
message.IsSlotBookingEnabled = reader.bool();
|
|
break;
|
|
default:
|
|
let u = options.readUnknownField;
|
|
if (u === "throw")
|
|
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
let d = reader.skip(wireType);
|
|
if (u !== false)
|
|
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
}
|
|
}
|
|
return message;
|
|
}
|
|
internalBinaryWrite(message: ActorClearSiteAliasPayload, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
/* api.SiteAlias SiteAlias = 1; */
|
|
if (message.SiteAlias)
|
|
SiteAlias.internalBinaryWrite(message.SiteAlias, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
/* bool IsSlotBookingEnabled = 2; */
|
|
if (message.IsSlotBookingEnabled !== false)
|
|
writer.tag(2, WireType.Varint).bool(message.IsSlotBookingEnabled);
|
|
let u = options.writeUnknownFields;
|
|
if (u !== false)
|
|
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
return writer;
|
|
}
|
|
}
|
|
/**
|
|
* @generated MessageType for protobuf message api.ActorClearSiteAliasPayload
|
|
*/
|
|
export const ActorClearSiteAliasPayload = new ActorClearSiteAliasPayload$Type();
|
|
// @generated message type with reflection information, may provide speed optimized methods
|
|
class ClearSiteAlias$Type extends MessageType<ClearSiteAlias> {
|
|
constructor() {
|
|
super("api.ClearSiteAlias", [
|
|
{ no: 1, name: "Header", kind: "message", localName: "Header", jsonName: "Header", T: () => CommandHeader },
|
|
{ no: 2, name: "ID", kind: "message", localName: "ID", jsonName: "ID", T: () => EntityID },
|
|
{ no: 3, name: "Payload", kind: "message", localName: "Payload", jsonName: "Payload", T: () => ActorClearSiteAliasPayload },
|
|
{ no: 4, name: "EventPayload", kind: "message", localName: "EventPayload", jsonName: "EventPayload", T: () => ActorClearSiteAliasPayload },
|
|
{ no: 5, name: "PreviousPayload", kind: "message", localName: "PreviousPayload", jsonName: "PreviousPayload", T: () => ActorClearSiteAliasPayload }
|
|
], { "api.messageType": "Command", "api.action": "ClearSiteAlias", "api.triggerEventFilters": "Deleted" });
|
|
}
|
|
create(value?: PartialMessage<ClearSiteAlias>): ClearSiteAlias {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
if (value !== undefined)
|
|
reflectionMergePartial<ClearSiteAlias>(this, message, value);
|
|
return message;
|
|
}
|
|
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ClearSiteAlias): ClearSiteAlias {
|
|
let message = target ?? this.create(), end = reader.pos + length;
|
|
while (reader.pos < end) {
|
|
let [fieldNo, wireType] = reader.tag();
|
|
switch (fieldNo) {
|
|
case /* api.CommandHeader Header */ 1:
|
|
message.Header = CommandHeader.internalBinaryRead(reader, reader.uint32(), options, message.Header);
|
|
break;
|
|
case /* api.EntityID ID */ 2:
|
|
message.ID = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.ID);
|
|
break;
|
|
case /* api.ActorClearSiteAliasPayload Payload */ 3:
|
|
message.Payload = ActorClearSiteAliasPayload.internalBinaryRead(reader, reader.uint32(), options, message.Payload);
|
|
break;
|
|
case /* api.ActorClearSiteAliasPayload EventPayload */ 4:
|
|
message.EventPayload = ActorClearSiteAliasPayload.internalBinaryRead(reader, reader.uint32(), options, message.EventPayload);
|
|
break;
|
|
case /* api.ActorClearSiteAliasPayload PreviousPayload */ 5:
|
|
message.PreviousPayload = ActorClearSiteAliasPayload.internalBinaryRead(reader, reader.uint32(), options, message.PreviousPayload);
|
|
break;
|
|
default:
|
|
let u = options.readUnknownField;
|
|
if (u === "throw")
|
|
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
let d = reader.skip(wireType);
|
|
if (u !== false)
|
|
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
}
|
|
}
|
|
return message;
|
|
}
|
|
internalBinaryWrite(message: ClearSiteAlias, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
/* api.CommandHeader Header = 1; */
|
|
if (message.Header)
|
|
CommandHeader.internalBinaryWrite(message.Header, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
/* api.EntityID ID = 2; */
|
|
if (message.ID)
|
|
EntityID.internalBinaryWrite(message.ID, writer.tag(2, WireType.LengthDelimited).fork(), options).join();
|
|
/* api.ActorClearSiteAliasPayload Payload = 3; */
|
|
if (message.Payload)
|
|
ActorClearSiteAliasPayload.internalBinaryWrite(message.Payload, writer.tag(3, WireType.LengthDelimited).fork(), options).join();
|
|
/* api.ActorClearSiteAliasPayload EventPayload = 4; */
|
|
if (message.EventPayload)
|
|
ActorClearSiteAliasPayload.internalBinaryWrite(message.EventPayload, writer.tag(4, WireType.LengthDelimited).fork(), options).join();
|
|
/* api.ActorClearSiteAliasPayload PreviousPayload = 5; */
|
|
if (message.PreviousPayload)
|
|
ActorClearSiteAliasPayload.internalBinaryWrite(message.PreviousPayload, writer.tag(5, WireType.LengthDelimited).fork(), options).join();
|
|
let u = options.writeUnknownFields;
|
|
if (u !== false)
|
|
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
return writer;
|
|
}
|
|
}
|
|
/**
|
|
* @generated MessageType for protobuf message api.ClearSiteAlias
|
|
*/
|
|
export const ClearSiteAlias = new ClearSiteAlias$Type();
|