diff --git a/actor.ts b/actor.ts index b63daa66..fdc85dde 100644 --- a/actor.ts +++ b/actor.ts @@ -11,6 +11,8 @@ import type { PartialMessage } from "@protobuf-ts/runtime"; import { reflectionMergePartial } from "@protobuf-ts/runtime"; import { MessageType } from "@protobuf-ts/runtime"; import { PartnerPayload } from "./partner"; +import { ActorAuthorisation } from "./slotbooking"; +import { SiteAlias } from "./repositoryShared"; import { ClaimSummary } from "./shared"; import { AttachmentSummary } from "./shared"; import { CarrierService } from "./repositoryShared"; @@ -169,6 +171,18 @@ export interface ActorPayload { * @generated from protobuf field: repeated string ConnectionIdentifierPrefixes = 28 [json_name = "ConnectionIdentifierPrefixes"]; */ connectionIdentifierPrefixes: string[]; + /** + * @generated from protobuf field: bool IsSlotBookingEnabled = 29 [json_name = "IsSlotBookingEnabled"]; + */ + isSlotBookingEnabled: boolean; + /** + * @generated from protobuf field: api.SiteAlias SiteAlias = 30 [json_name = "SiteAlias"]; + */ + siteAlias?: SiteAlias; + /** + * @generated from protobuf field: api.ActorAuthorisation AppointmentConstraints = 31 [json_name = "AppointmentConstraints"]; + */ + appointmentConstraints?: ActorAuthorisation; } /** * Actor Enrichment : Obsolete @@ -325,7 +339,10 @@ class ActorPayload$Type extends MessageType { { no: 24, name: "Claims", kind: "message", jsonName: "Claims", repeat: 1 /*RepeatType.PACKED*/, T: () => ClaimSummary, options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "Number of claims per type" }, "api.aggKey": "ClaimTypeID", "api.aggSkip": "ClaimAdded", "api.enrichmentClear": "Order,Executionflow,Stock,Movement,Tracking" } }, { no: 25, name: "ClaimNumber", kind: "scalar", jsonName: "ClaimNumber", T: 5 /*ScalarType.INT32*/, options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "Total number of claims" }, "api.enrichmentClear": "Order,Stock,Movement,Tracking" } }, { no: 26, name: "PhotoURI", kind: "scalar", jsonName: "PhotoURI", T: 9 /*ScalarType.STRING*/, options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { example: "\"https://reflex-visibility-forever.jpg\"" }, "api.kpiItems": { Items: [{ Context: "Actor", Group: "actor", Queryable: true }, { Context: "Executionflow", Group: "executionflow", Queryable: true }, { Context: "Stock", Group: "stock", Queryable: true }, { Context: "Stock", Group: "stock_extended", Queryable: true, CustomType: "SimpleAggregateFunction(anyLast,String)" }] }, "api.viewType": { Types: [{ Context: "*", Type: "image" }] } } }, - { no: 28, name: "ConnectionIdentifierPrefixes", kind: "scalar", jsonName: "ConnectionIdentifierPrefixes", repeat: 2 /*RepeatType.UNPACKED*/, T: 9 /*ScalarType.STRING*/, options: { "api.enrichmentClear": "Stock,Movement,Tracking" } } + { no: 28, name: "ConnectionIdentifierPrefixes", kind: "scalar", jsonName: "ConnectionIdentifierPrefixes", repeat: 2 /*RepeatType.UNPACKED*/, T: 9 /*ScalarType.STRING*/, options: { "api.enrichmentClear": "Stock,Movement,Tracking" } }, + { no: 29, name: "IsSlotBookingEnabled", kind: "scalar", jsonName: "IsSlotBookingEnabled", T: 8 /*ScalarType.BOOL*/, options: { "api.enrichmentClear": "Stock,Movement,Tracking" } }, + { no: 30, name: "SiteAlias", kind: "message", jsonName: "SiteAlias", T: () => SiteAlias, options: { "api.enrichmentClear": "Stock,Movement,Tracking" } }, + { no: 31, name: "AppointmentConstraints", kind: "message", jsonName: "AppointmentConstraints", T: () => ActorAuthorisation } ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Name"] } } }); } create(value?: PartialMessage): ActorPayload { @@ -351,6 +368,7 @@ class ActorPayload$Type extends MessageType { message.claimNumber = 0; message.photoURI = ""; message.connectionIdentifierPrefixes = []; + message.isSlotBookingEnabled = false; if (value !== undefined) reflectionMergePartial(this, message, value); return message; @@ -432,6 +450,15 @@ class ActorPayload$Type extends MessageType { case /* repeated string ConnectionIdentifierPrefixes = 28 [json_name = "ConnectionIdentifierPrefixes"];*/ 28: message.connectionIdentifierPrefixes.push(reader.string()); break; + case /* bool IsSlotBookingEnabled = 29 [json_name = "IsSlotBookingEnabled"];*/ 29: + message.isSlotBookingEnabled = reader.bool(); + break; + case /* api.SiteAlias SiteAlias = 30 [json_name = "SiteAlias"];*/ 30: + message.siteAlias = SiteAlias.internalBinaryRead(reader, reader.uint32(), options, message.siteAlias); + break; + case /* api.ActorAuthorisation AppointmentConstraints = 31 [json_name = "AppointmentConstraints"];*/ 31: + message.appointmentConstraints = ActorAuthorisation.internalBinaryRead(reader, reader.uint32(), options, message.appointmentConstraints); + break; default: let u = options.readUnknownField; if (u === "throw") @@ -516,6 +543,15 @@ class ActorPayload$Type extends MessageType { /* repeated string ConnectionIdentifierPrefixes = 28 [json_name = "ConnectionIdentifierPrefixes"]; */ for (let i = 0; i < message.connectionIdentifierPrefixes.length; i++) writer.tag(28, WireType.LengthDelimited).string(message.connectionIdentifierPrefixes[i]); + /* bool IsSlotBookingEnabled = 29 [json_name = "IsSlotBookingEnabled"]; */ + if (message.isSlotBookingEnabled !== false) + writer.tag(29, WireType.Varint).bool(message.isSlotBookingEnabled); + /* api.SiteAlias SiteAlias = 30 [json_name = "SiteAlias"]; */ + if (message.siteAlias) + SiteAlias.internalBinaryWrite(message.siteAlias, writer.tag(30, WireType.LengthDelimited).fork(), options).join(); + /* api.ActorAuthorisation AppointmentConstraints = 31 [json_name = "AppointmentConstraints"]; */ + if (message.appointmentConstraints) + ActorAuthorisation.internalBinaryWrite(message.appointmentConstraints, writer.tag(31, WireType.LengthDelimited).fork(), options).join(); let u = options.writeUnknownFields; if (u !== false) (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); diff --git a/appointment.ts b/appointment.ts new file mode 100644 index 00000000..3cdec1fc --- /dev/null +++ b/appointment.ts @@ -0,0 +1,351 @@ +// @generated by protobuf-ts 2.9.6 +// @generated from protobuf file "appointment.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 { AppointmentStatusStruct } from "./collabShared"; +import { Slot } from "./slotbooking"; +import { CarrierInformation } from "./slotbooking"; +import { Segmentation } from "./slotbooking"; +import { QuantityByUnit } from "./slotbooking"; +import { Commission } from "./collabShared"; +import { AppointmentType } from "./slotbooking"; +import { EntityID } from "./shared"; +import { EventHeader } from "./shared"; +// _common_ +// import "visibility.proto"; + +/** + * + * Aggregation object message + * + * @generated from protobuf message api.Appointment + */ +export interface Appointment { + /** + * @generated from protobuf field: api.EventHeader LastEventHeader = 1 [json_name = "LastEventHeader"]; + */ + lastEventHeader?: EventHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; + /** + * @generated from protobuf field: api.AppointmentPayload Payload = 3 [json_name = "Payload"]; + */ + payload?: AppointmentPayload; +} +/** + * @generated from protobuf message api.AppointmentPayload + */ +export interface AppointmentPayload { + /** + * Type of appointment : Expedition / Reception / Both + * + * @generated from protobuf field: api.AppointmentType AppointmentType = 1 [json_name = "AppointmentType"]; + */ + appointmentType: AppointmentType; + /** + * List of the orders and projects for which the appointment is made, with the quantities + * TODO ?? + * + * @generated from protobuf field: repeated api.Commission Commissions = 2 [json_name = "Commissions"]; + */ + commissions: Commission[]; + /** + * Cumulative quantity for all the commissions + * + * @generated from protobuf field: repeated api.QuantityByUnit QuantitiesByUnits = 3 [json_name = "QuantitiesByUnits"]; + */ + quantitiesByUnits: QuantityByUnit[]; + /** + * Set of segmentation constraining the slot booking + * + * @generated from protobuf field: repeated api.Segmentation Segmentations = 4 [json_name = "Segmentations"]; + */ + segmentations: Segmentation[]; + /** + * Required carrierInformation, some can be obligatory + * + * @generated from protobuf field: repeated api.CarrierInformation CarrierInformation = 5 [json_name = "CarrierInformation"]; + */ + carrierInformation: CarrierInformation[]; + /** + * The slot booked for the appointment + * + * @generated from protobuf field: api.Slot Slot = 6 [json_name = "Slot"]; + */ + slot?: Slot; + /** + * User mails being notified on this appointment + * TODO Need to add a structure to store platform user identifiers which can act on this appointment ? + * + * @generated from protobuf field: repeated string Emails = 7 [json_name = "Emails"]; + */ + emails: string[]; + /** + * Appointment Status and status history + * + * @generated from protobuf field: api.AppointmentStatusStruct Status = 8 [json_name = "Status"]; + */ + status?: AppointmentStatusStruct; + /** + * Creation date of the appointment + * + * @generated from protobuf field: string CreationDate = 9 [json_name = "CreationDate"]; + */ + creationDate: string; +} +/** + * @generated from protobuf message api.AppointmentTriplet + */ +export interface AppointmentTriplet { + /** + * @generated from protobuf field: api.Appointment Current = 1 [json_name = "Current"]; + */ + current?: Appointment; + /** + * @generated from protobuf field: api.Appointment Previous = 2 [json_name = "Previous"]; + */ + previous?: Appointment; + /** + * @generated from protobuf field: api.Appointment LastEvent = 3 [json_name = "LastEvent"]; + */ + lastEvent?: Appointment; +} +// @generated message type with reflection information, may provide speed optimized methods +class Appointment$Type extends MessageType { + constructor() { + super("api.Appointment", [ + { no: 1, name: "LastEventHeader", kind: "message", jsonName: "LastEventHeader", T: () => EventHeader }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID }, + { no: 3, name: "Payload", kind: "message", jsonName: "Payload", T: () => AppointmentPayload } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { description: "Aggregation object message" } } }); + } + create(value?: PartialMessage): Appointment { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: Appointment): Appointment { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.EventHeader LastEventHeader = 1 [json_name = "LastEventHeader"];*/ 1: + message.lastEventHeader = EventHeader.internalBinaryRead(reader, reader.uint32(), options, message.lastEventHeader); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + break; + case /* api.AppointmentPayload Payload = 3 [json_name = "Payload"];*/ 3: + message.payload = AppointmentPayload.internalBinaryRead(reader, reader.uint32(), options, message.payload); + 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: Appointment, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.EventHeader LastEventHeader = 1 [json_name = "LastEventHeader"]; */ + if (message.lastEventHeader) + EventHeader.internalBinaryWrite(message.lastEventHeader, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* api.AppointmentPayload Payload = 3 [json_name = "Payload"]; */ + if (message.payload) + AppointmentPayload.internalBinaryWrite(message.payload, writer.tag(3, 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.Appointment + */ +export const Appointment = new Appointment$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentPayload$Type extends MessageType { + constructor() { + super("api.AppointmentPayload", [ + { no: 1, name: "AppointmentType", kind: "enum", jsonName: "AppointmentType", T: () => ["api.AppointmentType", AppointmentType] }, + { no: 2, name: "Commissions", kind: "message", jsonName: "Commissions", repeat: 1 /*RepeatType.PACKED*/, T: () => Commission }, + { no: 3, name: "QuantitiesByUnits", kind: "message", jsonName: "QuantitiesByUnits", repeat: 1 /*RepeatType.PACKED*/, T: () => QuantityByUnit }, + { no: 4, name: "Segmentations", kind: "message", jsonName: "Segmentations", repeat: 1 /*RepeatType.PACKED*/, T: () => Segmentation }, + { no: 5, name: "CarrierInformation", kind: "message", jsonName: "CarrierInformation", repeat: 1 /*RepeatType.PACKED*/, T: () => CarrierInformation }, + { no: 6, name: "Slot", kind: "message", jsonName: "Slot", T: () => Slot }, + { no: 7, name: "Emails", kind: "scalar", jsonName: "Emails", repeat: 2 /*RepeatType.UNPACKED*/, T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { repeated: { minItems: "1", items: { string: { email: true, ignoreEmpty: true } } } }, "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "Must be a valid email address", example: "[\"John.doe@reflex.com\", \"will.smith@reflex.com\"]" } } }, + { no: 8, name: "Status", kind: "message", jsonName: "Status", T: () => AppointmentStatusStruct, options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "Status of the appointment" }, "api.aggSkip": "StatusUpdated" } }, + { no: 9, name: "CreationDate", kind: "scalar", jsonName: "CreationDate", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { dateIso8601: true } }, "api.viewType": { Types: [{ Context: "*", Type: "date" }] } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Segmentations"] } } }); + } + create(value?: PartialMessage): AppointmentPayload { + const message = globalThis.Object.create((this.messagePrototype!)); + message.appointmentType = 0; + message.commissions = []; + message.quantitiesByUnits = []; + message.segmentations = []; + message.carrierInformation = []; + message.emails = []; + message.creationDate = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentPayload): AppointmentPayload { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.AppointmentType AppointmentType = 1 [json_name = "AppointmentType"];*/ 1: + message.appointmentType = reader.int32(); + break; + case /* repeated api.Commission Commissions = 2 [json_name = "Commissions"];*/ 2: + message.commissions.push(Commission.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.QuantityByUnit QuantitiesByUnits = 3 [json_name = "QuantitiesByUnits"];*/ 3: + message.quantitiesByUnits.push(QuantityByUnit.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.Segmentation Segmentations = 4 [json_name = "Segmentations"];*/ 4: + message.segmentations.push(Segmentation.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.CarrierInformation CarrierInformation = 5 [json_name = "CarrierInformation"];*/ 5: + message.carrierInformation.push(CarrierInformation.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* api.Slot Slot = 6 [json_name = "Slot"];*/ 6: + message.slot = Slot.internalBinaryRead(reader, reader.uint32(), options, message.slot); + break; + case /* repeated string Emails = 7 [json_name = "Emails"];*/ 7: + message.emails.push(reader.string()); + break; + case /* api.AppointmentStatusStruct Status = 8 [json_name = "Status"];*/ 8: + message.status = AppointmentStatusStruct.internalBinaryRead(reader, reader.uint32(), options, message.status); + break; + case /* string CreationDate = 9 [json_name = "CreationDate"];*/ 9: + message.creationDate = 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: AppointmentPayload, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.AppointmentType AppointmentType = 1 [json_name = "AppointmentType"]; */ + if (message.appointmentType !== 0) + writer.tag(1, WireType.Varint).int32(message.appointmentType); + /* repeated api.Commission Commissions = 2 [json_name = "Commissions"]; */ + for (let i = 0; i < message.commissions.length; i++) + Commission.internalBinaryWrite(message.commissions[i], writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.QuantityByUnit QuantitiesByUnits = 3 [json_name = "QuantitiesByUnits"]; */ + for (let i = 0; i < message.quantitiesByUnits.length; i++) + QuantityByUnit.internalBinaryWrite(message.quantitiesByUnits[i], writer.tag(3, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.Segmentation Segmentations = 4 [json_name = "Segmentations"]; */ + for (let i = 0; i < message.segmentations.length; i++) + Segmentation.internalBinaryWrite(message.segmentations[i], writer.tag(4, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.CarrierInformation CarrierInformation = 5 [json_name = "CarrierInformation"]; */ + for (let i = 0; i < message.carrierInformation.length; i++) + CarrierInformation.internalBinaryWrite(message.carrierInformation[i], writer.tag(5, WireType.LengthDelimited).fork(), options).join(); + /* api.Slot Slot = 6 [json_name = "Slot"]; */ + if (message.slot) + Slot.internalBinaryWrite(message.slot, writer.tag(6, WireType.LengthDelimited).fork(), options).join(); + /* repeated string Emails = 7 [json_name = "Emails"]; */ + for (let i = 0; i < message.emails.length; i++) + writer.tag(7, WireType.LengthDelimited).string(message.emails[i]); + /* api.AppointmentStatusStruct Status = 8 [json_name = "Status"]; */ + if (message.status) + AppointmentStatusStruct.internalBinaryWrite(message.status, writer.tag(8, WireType.LengthDelimited).fork(), options).join(); + /* string CreationDate = 9 [json_name = "CreationDate"]; */ + if (message.creationDate !== "") + writer.tag(9, WireType.LengthDelimited).string(message.creationDate); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.AppointmentPayload + */ +export const AppointmentPayload = new AppointmentPayload$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentTriplet$Type extends MessageType { + constructor() { + super("api.AppointmentTriplet", [ + { no: 1, name: "Current", kind: "message", jsonName: "Current", T: () => Appointment }, + { no: 2, name: "Previous", kind: "message", jsonName: "Previous", T: () => Appointment }, + { no: 3, name: "LastEvent", kind: "message", jsonName: "LastEvent", T: () => Appointment } + ]); + } + create(value?: PartialMessage): AppointmentTriplet { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentTriplet): AppointmentTriplet { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.Appointment Current = 1 [json_name = "Current"];*/ 1: + message.current = Appointment.internalBinaryRead(reader, reader.uint32(), options, message.current); + break; + case /* api.Appointment Previous = 2 [json_name = "Previous"];*/ 2: + message.previous = Appointment.internalBinaryRead(reader, reader.uint32(), options, message.previous); + break; + case /* api.Appointment LastEvent = 3 [json_name = "LastEvent"];*/ 3: + message.lastEvent = Appointment.internalBinaryRead(reader, reader.uint32(), options, message.lastEvent); + 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: AppointmentTriplet, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.Appointment Current = 1 [json_name = "Current"]; */ + if (message.current) + Appointment.internalBinaryWrite(message.current, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.Appointment Previous = 2 [json_name = "Previous"]; */ + if (message.previous) + Appointment.internalBinaryWrite(message.previous, writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* api.Appointment LastEvent = 3 [json_name = "LastEvent"]; */ + if (message.lastEvent) + Appointment.internalBinaryWrite(message.lastEvent, writer.tag(3, 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.AppointmentTriplet + */ +export const AppointmentTriplet = new AppointmentTriplet$Type(); diff --git a/appointmentInput.client.ts b/appointmentInput.client.ts new file mode 100644 index 00000000..75f4c2f4 --- /dev/null +++ b/appointmentInput.client.ts @@ -0,0 +1,160 @@ +// @generated by protobuf-ts 2.9.6 +// @generated from protobuf file "appointmentInput.proto" (package "api", syntax proto3) +// tslint:disable +import type { RpcTransport } from "@protobuf-ts/runtime-rpc"; +import type { ServiceInfo } from "@protobuf-ts/runtime-rpc"; +import { AppointmentInputAPI } from "./appointmentInput"; +import type { AppointmentCarrierDepartedResponse } from "./appointmentInput"; +import type { AppointmentCarrierDepartedRequest } from "./appointmentInput"; +import type { AppointmentReceptionUnloadedResponse } from "./appointmentInput"; +import type { AppointmentReceptionUnloadedRequest } from "./appointmentInput"; +import type { AppointmentReceptionStartedResponse } from "./appointmentInput"; +import type { AppointmentReceptionStartedRequest } from "./appointmentInput"; +import type { AppointmentExpeditionLoadedResponse } from "./appointmentInput"; +import type { AppointmentExpeditionLoadedRequest } from "./appointmentInput"; +import type { AppointmentExpeditionStartedResponse } from "./appointmentInput"; +import type { AppointmentExpeditionStartedRequest } from "./appointmentInput"; +import type { AppointmentCarrierArrivedResponse } from "./appointmentInput"; +import type { AppointmentCarrierArrivedRequest } from "./appointmentInput"; +import type { AppointmentCarrierExpectedResponse } from "./appointmentInput"; +import type { AppointmentCarrierExpectedRequest } from "./appointmentInput"; +import type { AppointmentCarrierInformationUpdatedResponse } from "./appointmentInput"; +import type { AppointmentCarrierInformationUpdatedRequest } from "./appointmentInput"; +import type { AppointmentCanceledResponse } from "./appointmentInput"; +import type { AppointmentCanceledRequest } from "./appointmentInput"; +import { stackIntercept } from "@protobuf-ts/runtime-rpc"; +import type { AppointmentCreatedResponse } from "./appointmentInput"; +import type { AppointmentCreatedRequest } from "./appointmentInput"; +import type { UnaryCall } from "@protobuf-ts/runtime-rpc"; +import type { RpcOptions } from "@protobuf-ts/runtime-rpc"; +/** + * + * API-server services + * + * @generated from protobuf service api.AppointmentInputAPI + */ +export interface IAppointmentInputAPIClient { + /** + * @generated from protobuf rpc: Created(api.AppointmentCreatedRequest) returns (api.AppointmentCreatedResponse); + */ + created(input: AppointmentCreatedRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: Canceled(api.AppointmentCanceledRequest) returns (api.AppointmentCanceledResponse); + */ + canceled(input: AppointmentCanceledRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: CarrierInformationUpdated(api.AppointmentCarrierInformationUpdatedRequest) returns (api.AppointmentCarrierInformationUpdatedResponse); + */ + carrierInformationUpdated(input: AppointmentCarrierInformationUpdatedRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: CarrierExpected(api.AppointmentCarrierExpectedRequest) returns (api.AppointmentCarrierExpectedResponse); + */ + carrierExpected(input: AppointmentCarrierExpectedRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: CarrierArrived(api.AppointmentCarrierArrivedRequest) returns (api.AppointmentCarrierArrivedResponse); + */ + carrierArrived(input: AppointmentCarrierArrivedRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: ExpeditionStarted(api.AppointmentExpeditionStartedRequest) returns (api.AppointmentExpeditionStartedResponse); + */ + expeditionStarted(input: AppointmentExpeditionStartedRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: ExpeditionLoaded(api.AppointmentExpeditionLoadedRequest) returns (api.AppointmentExpeditionLoadedResponse); + */ + expeditionLoaded(input: AppointmentExpeditionLoadedRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: ReceptionStarted(api.AppointmentReceptionStartedRequest) returns (api.AppointmentReceptionStartedResponse); + */ + receptionStarted(input: AppointmentReceptionStartedRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: ReceptionUnloaded(api.AppointmentReceptionUnloadedRequest) returns (api.AppointmentReceptionUnloadedResponse); + */ + receptionUnloaded(input: AppointmentReceptionUnloadedRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: CarrierDeparted(api.AppointmentCarrierDepartedRequest) returns (api.AppointmentCarrierDepartedResponse); + */ + carrierDeparted(input: AppointmentCarrierDepartedRequest, options?: RpcOptions): UnaryCall; +} +/** + * + * API-server services + * + * @generated from protobuf service api.AppointmentInputAPI + */ +export class AppointmentInputAPIClient implements IAppointmentInputAPIClient, ServiceInfo { + typeName = AppointmentInputAPI.typeName; + methods = AppointmentInputAPI.methods; + options = AppointmentInputAPI.options; + constructor(private readonly _transport: RpcTransport) { + } + /** + * @generated from protobuf rpc: Created(api.AppointmentCreatedRequest) returns (api.AppointmentCreatedResponse); + */ + created(input: AppointmentCreatedRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[0], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: Canceled(api.AppointmentCanceledRequest) returns (api.AppointmentCanceledResponse); + */ + canceled(input: AppointmentCanceledRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[1], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: CarrierInformationUpdated(api.AppointmentCarrierInformationUpdatedRequest) returns (api.AppointmentCarrierInformationUpdatedResponse); + */ + carrierInformationUpdated(input: AppointmentCarrierInformationUpdatedRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[2], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: CarrierExpected(api.AppointmentCarrierExpectedRequest) returns (api.AppointmentCarrierExpectedResponse); + */ + carrierExpected(input: AppointmentCarrierExpectedRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[3], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: CarrierArrived(api.AppointmentCarrierArrivedRequest) returns (api.AppointmentCarrierArrivedResponse); + */ + carrierArrived(input: AppointmentCarrierArrivedRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[4], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: ExpeditionStarted(api.AppointmentExpeditionStartedRequest) returns (api.AppointmentExpeditionStartedResponse); + */ + expeditionStarted(input: AppointmentExpeditionStartedRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[5], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: ExpeditionLoaded(api.AppointmentExpeditionLoadedRequest) returns (api.AppointmentExpeditionLoadedResponse); + */ + expeditionLoaded(input: AppointmentExpeditionLoadedRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[6], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: ReceptionStarted(api.AppointmentReceptionStartedRequest) returns (api.AppointmentReceptionStartedResponse); + */ + receptionStarted(input: AppointmentReceptionStartedRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[7], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: ReceptionUnloaded(api.AppointmentReceptionUnloadedRequest) returns (api.AppointmentReceptionUnloadedResponse); + */ + receptionUnloaded(input: AppointmentReceptionUnloadedRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[8], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: CarrierDeparted(api.AppointmentCarrierDepartedRequest) returns (api.AppointmentCarrierDepartedResponse); + */ + carrierDeparted(input: AppointmentCarrierDepartedRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[9], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } +} diff --git a/appointmentInput.ts b/appointmentInput.ts new file mode 100644 index 00000000..8cd583cb --- /dev/null +++ b/appointmentInput.ts @@ -0,0 +1,2893 @@ +// @generated by protobuf-ts 2.9.6 +// @generated from protobuf file "appointmentInput.proto" (package "api", syntax proto3) +// tslint:disable +import { ServiceType } from "@protobuf-ts/runtime-rpc"; +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 { ResponseSiteHeader } from "./shared"; +import { RequestSiteHeader } from "./shared"; +import { EntityID } from "./shared"; +import { EventHeader } from "./shared"; +import { Slot } from "./slotbooking"; +import { CarrierInformation } from "./slotbooking"; +import { Segmentation } from "./slotbooking"; +import { QuantityByUnit } from "./slotbooking"; +import { Commission } from "./collabShared"; +import { AppointmentType } from "./slotbooking"; +// +// Created : this message tells that appointment is created + +/** + * Event Payload + * + * @generated from protobuf message api.AppointmentCreatedPayload + */ +export interface AppointmentCreatedPayload { + /** + * Type of appointment : Expedition / Reception / Both + * + * @generated from protobuf field: api.AppointmentType AppointmentType = 1 [json_name = "AppointmentType"]; + */ + appointmentType: AppointmentType; + /** + * List of the orders and projects for which the appointment is made, with the quantities + * TODO ?? + * + * @generated from protobuf field: repeated api.Commission Commissions = 2 [json_name = "Commissions"]; + */ + commissions: Commission[]; + /** + * Cumulative quantity for all the commissions + * + * @generated from protobuf field: repeated api.QuantityByUnit QuantitiesByUnits = 3 [json_name = "QuantitiesByUnits"]; + */ + quantitiesByUnits: QuantityByUnit[]; + /** + * Set of segmentation constraining the slot booking + * + * @generated from protobuf field: repeated api.Segmentation Segmentations = 4 [json_name = "Segmentations"]; + */ + segmentations: Segmentation[]; + /** + * Required carrierInformation, some can be obligatory + * + * @generated from protobuf field: repeated api.CarrierInformation CarrierInformation = 5 [json_name = "CarrierInformation"]; + */ + carrierInformation: CarrierInformation[]; + /** + * The slot booked for the appointment + * + * @generated from protobuf field: api.Slot Slot = 6 [json_name = "Slot"]; + */ + slot?: Slot; + /** + * User mails being notified on this appointment + * TODO Need to add a structure to store platform user identifiers which can act on this appointment ? + * + * @generated from protobuf field: repeated string Emails = 7 [json_name = "Emails"]; + */ + emails: string[]; +} +/** + * Event message + * + * @generated from protobuf message api.AppointmentCreatedEvent + */ +export interface AppointmentCreatedEvent { + /** + * @generated from protobuf field: api.EventHeader Header = 1 [json_name = "Header"]; + */ + header?: EventHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; + /** + * @generated from protobuf field: api.AppointmentCreatedPayload Payload = 3 [json_name = "Payload"]; + */ + payload?: AppointmentCreatedPayload; +} +/** + * API Request + * + * @generated from protobuf message api.AppointmentCreatedRequest + */ +export interface AppointmentCreatedRequest { + /** + * @generated from protobuf field: api.RequestSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestSiteHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; + /** + * @generated from protobuf field: api.AppointmentCreatedPayload Payload = 3 [json_name = "Payload"]; + */ + payload?: AppointmentCreatedPayload; +} +/** + * API Response + * + * @generated from protobuf message api.AppointmentCreatedResponse + */ +export interface AppointmentCreatedResponse { + /** + * @generated from protobuf field: api.ResponseSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: ResponseSiteHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; +} +// +// Canceled : this message tells that appointment is canceled + +/** + * Event Payload + * + * @generated from protobuf message api.AppointmentCanceledPayload + */ +export interface AppointmentCanceledPayload { +} +/** + * Event message + * + * @generated from protobuf message api.AppointmentCanceledEvent + */ +export interface AppointmentCanceledEvent { + /** + * @generated from protobuf field: api.EventHeader Header = 1 [json_name = "Header"]; + */ + header?: EventHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; + /** + * @generated from protobuf field: api.AppointmentCanceledPayload Payload = 3 [json_name = "Payload"]; + */ + payload?: AppointmentCanceledPayload; +} +/** + * API Request + * + * @generated from protobuf message api.AppointmentCanceledRequest + */ +export interface AppointmentCanceledRequest { + /** + * @generated from protobuf field: api.RequestSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestSiteHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; + /** + * @generated from protobuf field: api.AppointmentCanceledPayload Payload = 3 [json_name = "Payload"]; + */ + payload?: AppointmentCanceledPayload; +} +/** + * API Response + * + * @generated from protobuf message api.AppointmentCanceledResponse + */ +export interface AppointmentCanceledResponse { + /** + * @generated from protobuf field: api.ResponseSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: ResponseSiteHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; +} +// +// CarrierInformationUpdated : this message tells that appointment carrier information are updated + +/** + * Event Payload + * + * @generated from protobuf message api.AppointmentCarrierInformationUpdatedPayload + */ +export interface AppointmentCarrierInformationUpdatedPayload { + /** + * Required carrierInformation, some can be obligatory + * + * @generated from protobuf field: repeated api.CarrierInformation CarrierInformation = 1 [json_name = "CarrierInformation"]; + */ + carrierInformation: CarrierInformation[]; +} +/** + * Event message + * + * @generated from protobuf message api.AppointmentCarrierInformationUpdatedEvent + */ +export interface AppointmentCarrierInformationUpdatedEvent { + /** + * @generated from protobuf field: api.EventHeader Header = 1 [json_name = "Header"]; + */ + header?: EventHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; + /** + * @generated from protobuf field: api.AppointmentCarrierInformationUpdatedPayload Payload = 3 [json_name = "Payload"]; + */ + payload?: AppointmentCarrierInformationUpdatedPayload; +} +/** + * API Request + * + * @generated from protobuf message api.AppointmentCarrierInformationUpdatedRequest + */ +export interface AppointmentCarrierInformationUpdatedRequest { + /** + * @generated from protobuf field: api.RequestSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestSiteHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; + /** + * @generated from protobuf field: api.AppointmentCarrierInformationUpdatedPayload Payload = 3 [json_name = "Payload"]; + */ + payload?: AppointmentCarrierInformationUpdatedPayload; +} +/** + * API Response + * + * @generated from protobuf message api.AppointmentCarrierInformationUpdatedResponse + */ +export interface AppointmentCarrierInformationUpdatedResponse { + /** + * @generated from protobuf field: api.ResponseSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: ResponseSiteHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; +} +// +// CarrierExpected : this message tells that appointment carrier is expected + +/** + * Event Payload + * + * @generated from protobuf message api.AppointmentCarrierExpectedPayload + */ +export interface AppointmentCarrierExpectedPayload { +} +/** + * Event message + * + * @generated from protobuf message api.AppointmentCarrierExpectedEvent + */ +export interface AppointmentCarrierExpectedEvent { + /** + * @generated from protobuf field: api.EventHeader Header = 1 [json_name = "Header"]; + */ + header?: EventHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; + /** + * @generated from protobuf field: api.AppointmentCarrierExpectedPayload Payload = 3 [json_name = "Payload"]; + */ + payload?: AppointmentCarrierExpectedPayload; +} +/** + * API Request + * + * @generated from protobuf message api.AppointmentCarrierExpectedRequest + */ +export interface AppointmentCarrierExpectedRequest { + /** + * @generated from protobuf field: api.RequestSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestSiteHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; + /** + * @generated from protobuf field: api.AppointmentCarrierExpectedPayload Payload = 3 [json_name = "Payload"]; + */ + payload?: AppointmentCarrierExpectedPayload; +} +/** + * API Response + * + * @generated from protobuf message api.AppointmentCarrierExpectedResponse + */ +export interface AppointmentCarrierExpectedResponse { + /** + * @generated from protobuf field: api.ResponseSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: ResponseSiteHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; +} +// +// CarrierArrived : this message tells that appointment carrier is expected + +/** + * Event Payload + * + * @generated from protobuf message api.AppointmentCarrierArrivedPayload + */ +export interface AppointmentCarrierArrivedPayload { +} +/** + * Event message + * + * @generated from protobuf message api.AppointmentCarrierArrivedEvent + */ +export interface AppointmentCarrierArrivedEvent { + /** + * @generated from protobuf field: api.EventHeader Header = 1 [json_name = "Header"]; + */ + header?: EventHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; + /** + * @generated from protobuf field: api.AppointmentCarrierArrivedPayload Payload = 3 [json_name = "Payload"]; + */ + payload?: AppointmentCarrierArrivedPayload; +} +/** + * API Request + * + * @generated from protobuf message api.AppointmentCarrierArrivedRequest + */ +export interface AppointmentCarrierArrivedRequest { + /** + * @generated from protobuf field: api.RequestSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestSiteHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; + /** + * @generated from protobuf field: api.AppointmentCarrierArrivedPayload Payload = 3 [json_name = "Payload"]; + */ + payload?: AppointmentCarrierArrivedPayload; +} +/** + * API Response + * + * @generated from protobuf message api.AppointmentCarrierArrivedResponse + */ +export interface AppointmentCarrierArrivedResponse { + /** + * @generated from protobuf field: api.ResponseSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: ResponseSiteHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; +} +// +// ExpeditionStarted : this message tells that appointment carrier is expected + +/** + * Event Payload + * + * @generated from protobuf message api.AppointmentExpeditionStartedPayload + */ +export interface AppointmentExpeditionStartedPayload { +} +/** + * Event message + * + * @generated from protobuf message api.AppointmentExpeditionStartedEvent + */ +export interface AppointmentExpeditionStartedEvent { + /** + * @generated from protobuf field: api.EventHeader Header = 1 [json_name = "Header"]; + */ + header?: EventHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; + /** + * @generated from protobuf field: api.AppointmentExpeditionStartedPayload Payload = 3 [json_name = "Payload"]; + */ + payload?: AppointmentExpeditionStartedPayload; +} +/** + * API Request + * + * @generated from protobuf message api.AppointmentExpeditionStartedRequest + */ +export interface AppointmentExpeditionStartedRequest { + /** + * @generated from protobuf field: api.RequestSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestSiteHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; + /** + * @generated from protobuf field: api.AppointmentExpeditionStartedPayload Payload = 3 [json_name = "Payload"]; + */ + payload?: AppointmentExpeditionStartedPayload; +} +/** + * API Response + * + * @generated from protobuf message api.AppointmentExpeditionStartedResponse + */ +export interface AppointmentExpeditionStartedResponse { + /** + * @generated from protobuf field: api.ResponseSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: ResponseSiteHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; +} +// +// ExpeditionLoaded : this message tells that appointment carrier is expected + +/** + * Event Payload + * + * @generated from protobuf message api.AppointmentExpeditionLoadedPayload + */ +export interface AppointmentExpeditionLoadedPayload { +} +/** + * Event message + * + * @generated from protobuf message api.AppointmentExpeditionLoadedEvent + */ +export interface AppointmentExpeditionLoadedEvent { + /** + * @generated from protobuf field: api.EventHeader Header = 1 [json_name = "Header"]; + */ + header?: EventHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; + /** + * @generated from protobuf field: api.AppointmentExpeditionLoadedPayload Payload = 3 [json_name = "Payload"]; + */ + payload?: AppointmentExpeditionLoadedPayload; +} +/** + * API Request + * + * @generated from protobuf message api.AppointmentExpeditionLoadedRequest + */ +export interface AppointmentExpeditionLoadedRequest { + /** + * @generated from protobuf field: api.RequestSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestSiteHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; + /** + * @generated from protobuf field: api.AppointmentExpeditionLoadedPayload Payload = 3 [json_name = "Payload"]; + */ + payload?: AppointmentExpeditionLoadedPayload; +} +/** + * API Response + * + * @generated from protobuf message api.AppointmentExpeditionLoadedResponse + */ +export interface AppointmentExpeditionLoadedResponse { + /** + * @generated from protobuf field: api.ResponseSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: ResponseSiteHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; +} +// +// ReceptionStarted : this message tells that appointment carrier is expected + +/** + * Event Payload + * + * @generated from protobuf message api.AppointmentReceptionStartedPayload + */ +export interface AppointmentReceptionStartedPayload { +} +/** + * Event message + * + * @generated from protobuf message api.AppointmentReceptionStartedEvent + */ +export interface AppointmentReceptionStartedEvent { + /** + * @generated from protobuf field: api.EventHeader Header = 1 [json_name = "Header"]; + */ + header?: EventHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; + /** + * @generated from protobuf field: api.AppointmentReceptionStartedPayload Payload = 3 [json_name = "Payload"]; + */ + payload?: AppointmentReceptionStartedPayload; +} +/** + * API Request + * + * @generated from protobuf message api.AppointmentReceptionStartedRequest + */ +export interface AppointmentReceptionStartedRequest { + /** + * @generated from protobuf field: api.RequestSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestSiteHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; + /** + * @generated from protobuf field: api.AppointmentReceptionStartedPayload Payload = 3 [json_name = "Payload"]; + */ + payload?: AppointmentReceptionStartedPayload; +} +/** + * API Response + * + * @generated from protobuf message api.AppointmentReceptionStartedResponse + */ +export interface AppointmentReceptionStartedResponse { + /** + * @generated from protobuf field: api.ResponseSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: ResponseSiteHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; +} +// +// ReceptionUnloaded : this message tells that appointment carrier is expected + +/** + * Event Payload + * + * @generated from protobuf message api.AppointmentReceptionUnloadedPayload + */ +export interface AppointmentReceptionUnloadedPayload { +} +/** + * Event message + * + * @generated from protobuf message api.AppointmentReceptionUnloadedEvent + */ +export interface AppointmentReceptionUnloadedEvent { + /** + * @generated from protobuf field: api.EventHeader Header = 1 [json_name = "Header"]; + */ + header?: EventHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; + /** + * @generated from protobuf field: api.AppointmentReceptionUnloadedPayload Payload = 3 [json_name = "Payload"]; + */ + payload?: AppointmentReceptionUnloadedPayload; +} +/** + * API Request + * + * @generated from protobuf message api.AppointmentReceptionUnloadedRequest + */ +export interface AppointmentReceptionUnloadedRequest { + /** + * @generated from protobuf field: api.RequestSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestSiteHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; + /** + * @generated from protobuf field: api.AppointmentReceptionUnloadedPayload Payload = 3 [json_name = "Payload"]; + */ + payload?: AppointmentReceptionUnloadedPayload; +} +/** + * API Response + * + * @generated from protobuf message api.AppointmentReceptionUnloadedResponse + */ +export interface AppointmentReceptionUnloadedResponse { + /** + * @generated from protobuf field: api.ResponseSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: ResponseSiteHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; +} +// +// CarrierDeparted : this message tells that appointment carrier is expected + +/** + * Event Payload + * + * @generated from protobuf message api.AppointmentCarrierDepartedPayload + */ +export interface AppointmentCarrierDepartedPayload { +} +/** + * Event message + * + * @generated from protobuf message api.AppointmentCarrierDepartedEvent + */ +export interface AppointmentCarrierDepartedEvent { + /** + * @generated from protobuf field: api.EventHeader Header = 1 [json_name = "Header"]; + */ + header?: EventHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; + /** + * @generated from protobuf field: api.AppointmentCarrierDepartedPayload Payload = 3 [json_name = "Payload"]; + */ + payload?: AppointmentCarrierDepartedPayload; +} +/** + * API Request + * + * @generated from protobuf message api.AppointmentCarrierDepartedRequest + */ +export interface AppointmentCarrierDepartedRequest { + /** + * @generated from protobuf field: api.RequestSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestSiteHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; + /** + * @generated from protobuf field: api.AppointmentCarrierDepartedPayload Payload = 3 [json_name = "Payload"]; + */ + payload?: AppointmentCarrierDepartedPayload; +} +/** + * API Response + * + * @generated from protobuf message api.AppointmentCarrierDepartedResponse + */ +export interface AppointmentCarrierDepartedResponse { + /** + * @generated from protobuf field: api.ResponseSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: ResponseSiteHeader; + /** + * @generated from protobuf field: api.EntityID ID = 2 [json_name = "ID"]; + */ + iD?: EntityID; +} +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentCreatedPayload$Type extends MessageType { + constructor() { + super("api.AppointmentCreatedPayload", [ + { no: 1, name: "AppointmentType", kind: "enum", jsonName: "AppointmentType", T: () => ["api.AppointmentType", AppointmentType], options: { "validate.rules": { enum: { definedOnly: true } } } }, + { no: 2, name: "Commissions", kind: "message", jsonName: "Commissions", repeat: 1 /*RepeatType.PACKED*/, T: () => Commission, options: { "validate.rules": { repeated: { minItems: "1" } } } }, + { no: 3, name: "QuantitiesByUnits", kind: "message", jsonName: "QuantitiesByUnits", repeat: 1 /*RepeatType.PACKED*/, T: () => QuantityByUnit, options: { "validate.rules": { repeated: { minItems: "1" } } } }, + { no: 4, name: "Segmentations", kind: "message", jsonName: "Segmentations", repeat: 1 /*RepeatType.PACKED*/, T: () => Segmentation }, + { no: 5, name: "CarrierInformation", kind: "message", jsonName: "CarrierInformation", repeat: 1 /*RepeatType.PACKED*/, T: () => CarrierInformation }, + { no: 6, name: "Slot", kind: "message", jsonName: "Slot", T: () => Slot }, + { no: 7, name: "Emails", kind: "scalar", jsonName: "Emails", repeat: 2 /*RepeatType.UNPACKED*/, T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { repeated: { minItems: "1", items: { string: { email: true, ignoreEmpty: true } } } }, "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "Must be a valid email address", example: "[\"John.doe@reflex.com\", \"will.smith@reflex.com\"]" } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { description: "Event Payload", required: ["AppointmentType"] } }, "api.messageType": "Event", "api.payload": true, "api.inputEvent": "Created" }); + } + create(value?: PartialMessage): AppointmentCreatedPayload { + const message = globalThis.Object.create((this.messagePrototype!)); + message.appointmentType = 0; + message.commissions = []; + message.quantitiesByUnits = []; + message.segmentations = []; + message.carrierInformation = []; + message.emails = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentCreatedPayload): AppointmentCreatedPayload { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.AppointmentType AppointmentType = 1 [json_name = "AppointmentType"];*/ 1: + message.appointmentType = reader.int32(); + break; + case /* repeated api.Commission Commissions = 2 [json_name = "Commissions"];*/ 2: + message.commissions.push(Commission.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.QuantityByUnit QuantitiesByUnits = 3 [json_name = "QuantitiesByUnits"];*/ 3: + message.quantitiesByUnits.push(QuantityByUnit.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.Segmentation Segmentations = 4 [json_name = "Segmentations"];*/ 4: + message.segmentations.push(Segmentation.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.CarrierInformation CarrierInformation = 5 [json_name = "CarrierInformation"];*/ 5: + message.carrierInformation.push(CarrierInformation.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* api.Slot Slot = 6 [json_name = "Slot"];*/ 6: + message.slot = Slot.internalBinaryRead(reader, reader.uint32(), options, message.slot); + break; + case /* repeated string Emails = 7 [json_name = "Emails"];*/ 7: + message.emails.push(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: AppointmentCreatedPayload, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.AppointmentType AppointmentType = 1 [json_name = "AppointmentType"]; */ + if (message.appointmentType !== 0) + writer.tag(1, WireType.Varint).int32(message.appointmentType); + /* repeated api.Commission Commissions = 2 [json_name = "Commissions"]; */ + for (let i = 0; i < message.commissions.length; i++) + Commission.internalBinaryWrite(message.commissions[i], writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.QuantityByUnit QuantitiesByUnits = 3 [json_name = "QuantitiesByUnits"]; */ + for (let i = 0; i < message.quantitiesByUnits.length; i++) + QuantityByUnit.internalBinaryWrite(message.quantitiesByUnits[i], writer.tag(3, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.Segmentation Segmentations = 4 [json_name = "Segmentations"]; */ + for (let i = 0; i < message.segmentations.length; i++) + Segmentation.internalBinaryWrite(message.segmentations[i], writer.tag(4, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.CarrierInformation CarrierInformation = 5 [json_name = "CarrierInformation"]; */ + for (let i = 0; i < message.carrierInformation.length; i++) + CarrierInformation.internalBinaryWrite(message.carrierInformation[i], writer.tag(5, WireType.LengthDelimited).fork(), options).join(); + /* api.Slot Slot = 6 [json_name = "Slot"]; */ + if (message.slot) + Slot.internalBinaryWrite(message.slot, writer.tag(6, WireType.LengthDelimited).fork(), options).join(); + /* repeated string Emails = 7 [json_name = "Emails"]; */ + for (let i = 0; i < message.emails.length; i++) + writer.tag(7, WireType.LengthDelimited).string(message.emails[i]); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.AppointmentCreatedPayload + */ +export const AppointmentCreatedPayload = new AppointmentCreatedPayload$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentCreatedEvent$Type extends MessageType { + constructor() { + super("api.AppointmentCreatedEvent", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => EventHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID, options: { "validate.rules": { message: { required: true } } } }, + { no: 3, name: "Payload", kind: "message", jsonName: "Payload", T: () => AppointmentCreatedPayload, options: { "validate.rules": { message: { required: true } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID", "Payload"] } }, "api.messageType": "Event", "api.inputEvent": "Created" }); + } + create(value?: PartialMessage): AppointmentCreatedEvent { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentCreatedEvent): AppointmentCreatedEvent { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.EventHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = EventHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + break; + case /* api.AppointmentCreatedPayload Payload = 3 [json_name = "Payload"];*/ 3: + message.payload = AppointmentCreatedPayload.internalBinaryRead(reader, reader.uint32(), options, message.payload); + 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: AppointmentCreatedEvent, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.EventHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + EventHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* api.AppointmentCreatedPayload Payload = 3 [json_name = "Payload"]; */ + if (message.payload) + AppointmentCreatedPayload.internalBinaryWrite(message.payload, writer.tag(3, 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.AppointmentCreatedEvent + */ +export const AppointmentCreatedEvent = new AppointmentCreatedEvent$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentCreatedRequest$Type extends MessageType { + constructor() { + super("api.AppointmentCreatedRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID, options: { "validate.rules": { message: { required: true } } } }, + { no: 3, name: "Payload", kind: "message", jsonName: "Payload", T: () => AppointmentCreatedPayload, options: { "validate.rules": { message: { required: true } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID", "Payload"] } }, "api.messageType": "Request", "api.inputEvent": "Created" }); + } + create(value?: PartialMessage): AppointmentCreatedRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentCreatedRequest): AppointmentCreatedRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + break; + case /* api.AppointmentCreatedPayload Payload = 3 [json_name = "Payload"];*/ 3: + message.payload = AppointmentCreatedPayload.internalBinaryRead(reader, reader.uint32(), options, message.payload); + 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: AppointmentCreatedRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* api.AppointmentCreatedPayload Payload = 3 [json_name = "Payload"]; */ + if (message.payload) + AppointmentCreatedPayload.internalBinaryWrite(message.payload, writer.tag(3, 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.AppointmentCreatedRequest + */ +export const AppointmentCreatedRequest = new AppointmentCreatedRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentCreatedResponse$Type extends MessageType { + constructor() { + super("api.AppointmentCreatedResponse", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => ResponseSiteHeader }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID } + ], { "api.messageType": "Response", "api.inputEvent": "Created" }); + } + create(value?: PartialMessage): AppointmentCreatedResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentCreatedResponse): AppointmentCreatedResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.ResponseSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = ResponseSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + 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: AppointmentCreatedResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.ResponseSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + ResponseSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, 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.AppointmentCreatedResponse + */ +export const AppointmentCreatedResponse = new AppointmentCreatedResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentCanceledPayload$Type extends MessageType { + constructor() { + super("api.AppointmentCanceledPayload", [], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { description: "Event Payload" } }, "api.messageType": "Event", "api.payload": true, "api.inputEvent": "Canceled" }); + } + create(value?: PartialMessage): AppointmentCanceledPayload { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentCanceledPayload): AppointmentCanceledPayload { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + 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: AppointmentCanceledPayload, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.AppointmentCanceledPayload + */ +export const AppointmentCanceledPayload = new AppointmentCanceledPayload$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentCanceledEvent$Type extends MessageType { + constructor() { + super("api.AppointmentCanceledEvent", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => EventHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID, options: { "validate.rules": { message: { required: true } } } }, + { no: 3, name: "Payload", kind: "message", jsonName: "Payload", T: () => AppointmentCanceledPayload, options: { "validate.rules": { message: { required: true } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID", "Payload"] } }, "api.messageType": "Event", "api.inputEvent": "Canceled" }); + } + create(value?: PartialMessage): AppointmentCanceledEvent { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentCanceledEvent): AppointmentCanceledEvent { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.EventHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = EventHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + break; + case /* api.AppointmentCanceledPayload Payload = 3 [json_name = "Payload"];*/ 3: + message.payload = AppointmentCanceledPayload.internalBinaryRead(reader, reader.uint32(), options, message.payload); + 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: AppointmentCanceledEvent, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.EventHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + EventHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* api.AppointmentCanceledPayload Payload = 3 [json_name = "Payload"]; */ + if (message.payload) + AppointmentCanceledPayload.internalBinaryWrite(message.payload, writer.tag(3, 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.AppointmentCanceledEvent + */ +export const AppointmentCanceledEvent = new AppointmentCanceledEvent$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentCanceledRequest$Type extends MessageType { + constructor() { + super("api.AppointmentCanceledRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID, options: { "validate.rules": { message: { required: true } } } }, + { no: 3, name: "Payload", kind: "message", jsonName: "Payload", T: () => AppointmentCanceledPayload, options: { "validate.rules": { message: { required: true } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID", "Payload"] } }, "api.messageType": "Request", "api.inputEvent": "Canceled" }); + } + create(value?: PartialMessage): AppointmentCanceledRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentCanceledRequest): AppointmentCanceledRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + break; + case /* api.AppointmentCanceledPayload Payload = 3 [json_name = "Payload"];*/ 3: + message.payload = AppointmentCanceledPayload.internalBinaryRead(reader, reader.uint32(), options, message.payload); + 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: AppointmentCanceledRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* api.AppointmentCanceledPayload Payload = 3 [json_name = "Payload"]; */ + if (message.payload) + AppointmentCanceledPayload.internalBinaryWrite(message.payload, writer.tag(3, 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.AppointmentCanceledRequest + */ +export const AppointmentCanceledRequest = new AppointmentCanceledRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentCanceledResponse$Type extends MessageType { + constructor() { + super("api.AppointmentCanceledResponse", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => ResponseSiteHeader }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID } + ], { "api.messageType": "Response", "api.inputEvent": "Canceled" }); + } + create(value?: PartialMessage): AppointmentCanceledResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentCanceledResponse): AppointmentCanceledResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.ResponseSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = ResponseSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + 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: AppointmentCanceledResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.ResponseSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + ResponseSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, 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.AppointmentCanceledResponse + */ +export const AppointmentCanceledResponse = new AppointmentCanceledResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentCarrierInformationUpdatedPayload$Type extends MessageType { + constructor() { + super("api.AppointmentCarrierInformationUpdatedPayload", [ + { no: 1, name: "CarrierInformation", kind: "message", jsonName: "CarrierInformation", repeat: 1 /*RepeatType.PACKED*/, T: () => CarrierInformation } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { description: "Event Payload" } }, "api.messageType": "Event", "api.payload": true, "api.inputEvent": "CarrierInformationUpdated" }); + } + create(value?: PartialMessage): AppointmentCarrierInformationUpdatedPayload { + const message = globalThis.Object.create((this.messagePrototype!)); + message.carrierInformation = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentCarrierInformationUpdatedPayload): AppointmentCarrierInformationUpdatedPayload { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* repeated api.CarrierInformation CarrierInformation = 1 [json_name = "CarrierInformation"];*/ 1: + message.carrierInformation.push(CarrierInformation.internalBinaryRead(reader, reader.uint32(), options)); + 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: AppointmentCarrierInformationUpdatedPayload, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* repeated api.CarrierInformation CarrierInformation = 1 [json_name = "CarrierInformation"]; */ + for (let i = 0; i < message.carrierInformation.length; i++) + CarrierInformation.internalBinaryWrite(message.carrierInformation[i], 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.AppointmentCarrierInformationUpdatedPayload + */ +export const AppointmentCarrierInformationUpdatedPayload = new AppointmentCarrierInformationUpdatedPayload$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentCarrierInformationUpdatedEvent$Type extends MessageType { + constructor() { + super("api.AppointmentCarrierInformationUpdatedEvent", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => EventHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID, options: { "validate.rules": { message: { required: true } } } }, + { no: 3, name: "Payload", kind: "message", jsonName: "Payload", T: () => AppointmentCarrierInformationUpdatedPayload, options: { "validate.rules": { message: { required: true } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID", "Payload"] } }, "api.messageType": "Event", "api.inputEvent": "CarrierInformationUpdated" }); + } + create(value?: PartialMessage): AppointmentCarrierInformationUpdatedEvent { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentCarrierInformationUpdatedEvent): AppointmentCarrierInformationUpdatedEvent { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.EventHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = EventHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + break; + case /* api.AppointmentCarrierInformationUpdatedPayload Payload = 3 [json_name = "Payload"];*/ 3: + message.payload = AppointmentCarrierInformationUpdatedPayload.internalBinaryRead(reader, reader.uint32(), options, message.payload); + 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: AppointmentCarrierInformationUpdatedEvent, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.EventHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + EventHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* api.AppointmentCarrierInformationUpdatedPayload Payload = 3 [json_name = "Payload"]; */ + if (message.payload) + AppointmentCarrierInformationUpdatedPayload.internalBinaryWrite(message.payload, writer.tag(3, 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.AppointmentCarrierInformationUpdatedEvent + */ +export const AppointmentCarrierInformationUpdatedEvent = new AppointmentCarrierInformationUpdatedEvent$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentCarrierInformationUpdatedRequest$Type extends MessageType { + constructor() { + super("api.AppointmentCarrierInformationUpdatedRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID, options: { "validate.rules": { message: { required: true } } } }, + { no: 3, name: "Payload", kind: "message", jsonName: "Payload", T: () => AppointmentCarrierInformationUpdatedPayload, options: { "validate.rules": { message: { required: true } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID", "Payload"] } }, "api.messageType": "Request", "api.inputEvent": "CarrierInformationUpdated" }); + } + create(value?: PartialMessage): AppointmentCarrierInformationUpdatedRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentCarrierInformationUpdatedRequest): AppointmentCarrierInformationUpdatedRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + break; + case /* api.AppointmentCarrierInformationUpdatedPayload Payload = 3 [json_name = "Payload"];*/ 3: + message.payload = AppointmentCarrierInformationUpdatedPayload.internalBinaryRead(reader, reader.uint32(), options, message.payload); + 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: AppointmentCarrierInformationUpdatedRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* api.AppointmentCarrierInformationUpdatedPayload Payload = 3 [json_name = "Payload"]; */ + if (message.payload) + AppointmentCarrierInformationUpdatedPayload.internalBinaryWrite(message.payload, writer.tag(3, 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.AppointmentCarrierInformationUpdatedRequest + */ +export const AppointmentCarrierInformationUpdatedRequest = new AppointmentCarrierInformationUpdatedRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentCarrierInformationUpdatedResponse$Type extends MessageType { + constructor() { + super("api.AppointmentCarrierInformationUpdatedResponse", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => ResponseSiteHeader }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID } + ], { "api.messageType": "Response", "api.inputEvent": "CarrierInformationUpdated" }); + } + create(value?: PartialMessage): AppointmentCarrierInformationUpdatedResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentCarrierInformationUpdatedResponse): AppointmentCarrierInformationUpdatedResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.ResponseSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = ResponseSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + 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: AppointmentCarrierInformationUpdatedResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.ResponseSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + ResponseSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, 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.AppointmentCarrierInformationUpdatedResponse + */ +export const AppointmentCarrierInformationUpdatedResponse = new AppointmentCarrierInformationUpdatedResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentCarrierExpectedPayload$Type extends MessageType { + constructor() { + super("api.AppointmentCarrierExpectedPayload", [], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { description: "Event Payload" } }, "api.messageType": "Event", "api.payload": true, "api.inputEvent": "CarrierExpected" }); + } + create(value?: PartialMessage): AppointmentCarrierExpectedPayload { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentCarrierExpectedPayload): AppointmentCarrierExpectedPayload { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + 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: AppointmentCarrierExpectedPayload, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.AppointmentCarrierExpectedPayload + */ +export const AppointmentCarrierExpectedPayload = new AppointmentCarrierExpectedPayload$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentCarrierExpectedEvent$Type extends MessageType { + constructor() { + super("api.AppointmentCarrierExpectedEvent", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => EventHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID, options: { "validate.rules": { message: { required: true } } } }, + { no: 3, name: "Payload", kind: "message", jsonName: "Payload", T: () => AppointmentCarrierExpectedPayload, options: { "validate.rules": { message: { required: true } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID", "Payload"] } }, "api.messageType": "Event", "api.inputEvent": "CarrierExpected" }); + } + create(value?: PartialMessage): AppointmentCarrierExpectedEvent { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentCarrierExpectedEvent): AppointmentCarrierExpectedEvent { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.EventHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = EventHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + break; + case /* api.AppointmentCarrierExpectedPayload Payload = 3 [json_name = "Payload"];*/ 3: + message.payload = AppointmentCarrierExpectedPayload.internalBinaryRead(reader, reader.uint32(), options, message.payload); + 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: AppointmentCarrierExpectedEvent, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.EventHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + EventHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* api.AppointmentCarrierExpectedPayload Payload = 3 [json_name = "Payload"]; */ + if (message.payload) + AppointmentCarrierExpectedPayload.internalBinaryWrite(message.payload, writer.tag(3, 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.AppointmentCarrierExpectedEvent + */ +export const AppointmentCarrierExpectedEvent = new AppointmentCarrierExpectedEvent$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentCarrierExpectedRequest$Type extends MessageType { + constructor() { + super("api.AppointmentCarrierExpectedRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID, options: { "validate.rules": { message: { required: true } } } }, + { no: 3, name: "Payload", kind: "message", jsonName: "Payload", T: () => AppointmentCarrierExpectedPayload, options: { "validate.rules": { message: { required: true } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID", "Payload"] } }, "api.messageType": "Request", "api.inputEvent": "CarrierExpected" }); + } + create(value?: PartialMessage): AppointmentCarrierExpectedRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentCarrierExpectedRequest): AppointmentCarrierExpectedRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + break; + case /* api.AppointmentCarrierExpectedPayload Payload = 3 [json_name = "Payload"];*/ 3: + message.payload = AppointmentCarrierExpectedPayload.internalBinaryRead(reader, reader.uint32(), options, message.payload); + 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: AppointmentCarrierExpectedRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* api.AppointmentCarrierExpectedPayload Payload = 3 [json_name = "Payload"]; */ + if (message.payload) + AppointmentCarrierExpectedPayload.internalBinaryWrite(message.payload, writer.tag(3, 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.AppointmentCarrierExpectedRequest + */ +export const AppointmentCarrierExpectedRequest = new AppointmentCarrierExpectedRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentCarrierExpectedResponse$Type extends MessageType { + constructor() { + super("api.AppointmentCarrierExpectedResponse", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => ResponseSiteHeader }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID } + ], { "api.messageType": "Response", "api.inputEvent": "CarrierExpected" }); + } + create(value?: PartialMessage): AppointmentCarrierExpectedResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentCarrierExpectedResponse): AppointmentCarrierExpectedResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.ResponseSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = ResponseSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + 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: AppointmentCarrierExpectedResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.ResponseSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + ResponseSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, 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.AppointmentCarrierExpectedResponse + */ +export const AppointmentCarrierExpectedResponse = new AppointmentCarrierExpectedResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentCarrierArrivedPayload$Type extends MessageType { + constructor() { + super("api.AppointmentCarrierArrivedPayload", [], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { description: "Event Payload" } }, "api.messageType": "Event", "api.payload": true, "api.inputEvent": "CarrierArrived" }); + } + create(value?: PartialMessage): AppointmentCarrierArrivedPayload { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentCarrierArrivedPayload): AppointmentCarrierArrivedPayload { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + 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: AppointmentCarrierArrivedPayload, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.AppointmentCarrierArrivedPayload + */ +export const AppointmentCarrierArrivedPayload = new AppointmentCarrierArrivedPayload$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentCarrierArrivedEvent$Type extends MessageType { + constructor() { + super("api.AppointmentCarrierArrivedEvent", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => EventHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID, options: { "validate.rules": { message: { required: true } } } }, + { no: 3, name: "Payload", kind: "message", jsonName: "Payload", T: () => AppointmentCarrierArrivedPayload, options: { "validate.rules": { message: { required: true } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID", "Payload"] } }, "api.messageType": "Event", "api.inputEvent": "CarrierArrived" }); + } + create(value?: PartialMessage): AppointmentCarrierArrivedEvent { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentCarrierArrivedEvent): AppointmentCarrierArrivedEvent { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.EventHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = EventHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + break; + case /* api.AppointmentCarrierArrivedPayload Payload = 3 [json_name = "Payload"];*/ 3: + message.payload = AppointmentCarrierArrivedPayload.internalBinaryRead(reader, reader.uint32(), options, message.payload); + 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: AppointmentCarrierArrivedEvent, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.EventHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + EventHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* api.AppointmentCarrierArrivedPayload Payload = 3 [json_name = "Payload"]; */ + if (message.payload) + AppointmentCarrierArrivedPayload.internalBinaryWrite(message.payload, writer.tag(3, 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.AppointmentCarrierArrivedEvent + */ +export const AppointmentCarrierArrivedEvent = new AppointmentCarrierArrivedEvent$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentCarrierArrivedRequest$Type extends MessageType { + constructor() { + super("api.AppointmentCarrierArrivedRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID, options: { "validate.rules": { message: { required: true } } } }, + { no: 3, name: "Payload", kind: "message", jsonName: "Payload", T: () => AppointmentCarrierArrivedPayload, options: { "validate.rules": { message: { required: true } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID", "Payload"] } }, "api.messageType": "Request", "api.inputEvent": "CarrierArrived" }); + } + create(value?: PartialMessage): AppointmentCarrierArrivedRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentCarrierArrivedRequest): AppointmentCarrierArrivedRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + break; + case /* api.AppointmentCarrierArrivedPayload Payload = 3 [json_name = "Payload"];*/ 3: + message.payload = AppointmentCarrierArrivedPayload.internalBinaryRead(reader, reader.uint32(), options, message.payload); + 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: AppointmentCarrierArrivedRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* api.AppointmentCarrierArrivedPayload Payload = 3 [json_name = "Payload"]; */ + if (message.payload) + AppointmentCarrierArrivedPayload.internalBinaryWrite(message.payload, writer.tag(3, 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.AppointmentCarrierArrivedRequest + */ +export const AppointmentCarrierArrivedRequest = new AppointmentCarrierArrivedRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentCarrierArrivedResponse$Type extends MessageType { + constructor() { + super("api.AppointmentCarrierArrivedResponse", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => ResponseSiteHeader }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID } + ], { "api.messageType": "Response", "api.inputEvent": "CarrierArrived" }); + } + create(value?: PartialMessage): AppointmentCarrierArrivedResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentCarrierArrivedResponse): AppointmentCarrierArrivedResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.ResponseSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = ResponseSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + 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: AppointmentCarrierArrivedResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.ResponseSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + ResponseSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, 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.AppointmentCarrierArrivedResponse + */ +export const AppointmentCarrierArrivedResponse = new AppointmentCarrierArrivedResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentExpeditionStartedPayload$Type extends MessageType { + constructor() { + super("api.AppointmentExpeditionStartedPayload", [], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { description: "Event Payload" } }, "api.messageType": "Event", "api.payload": true, "api.inputEvent": "ExpeditionStarted" }); + } + create(value?: PartialMessage): AppointmentExpeditionStartedPayload { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentExpeditionStartedPayload): AppointmentExpeditionStartedPayload { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + 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: AppointmentExpeditionStartedPayload, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.AppointmentExpeditionStartedPayload + */ +export const AppointmentExpeditionStartedPayload = new AppointmentExpeditionStartedPayload$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentExpeditionStartedEvent$Type extends MessageType { + constructor() { + super("api.AppointmentExpeditionStartedEvent", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => EventHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID, options: { "validate.rules": { message: { required: true } } } }, + { no: 3, name: "Payload", kind: "message", jsonName: "Payload", T: () => AppointmentExpeditionStartedPayload, options: { "validate.rules": { message: { required: true } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID", "Payload"] } }, "api.messageType": "Event", "api.inputEvent": "ExpeditionStarted" }); + } + create(value?: PartialMessage): AppointmentExpeditionStartedEvent { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentExpeditionStartedEvent): AppointmentExpeditionStartedEvent { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.EventHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = EventHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + break; + case /* api.AppointmentExpeditionStartedPayload Payload = 3 [json_name = "Payload"];*/ 3: + message.payload = AppointmentExpeditionStartedPayload.internalBinaryRead(reader, reader.uint32(), options, message.payload); + 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: AppointmentExpeditionStartedEvent, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.EventHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + EventHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* api.AppointmentExpeditionStartedPayload Payload = 3 [json_name = "Payload"]; */ + if (message.payload) + AppointmentExpeditionStartedPayload.internalBinaryWrite(message.payload, writer.tag(3, 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.AppointmentExpeditionStartedEvent + */ +export const AppointmentExpeditionStartedEvent = new AppointmentExpeditionStartedEvent$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentExpeditionStartedRequest$Type extends MessageType { + constructor() { + super("api.AppointmentExpeditionStartedRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID, options: { "validate.rules": { message: { required: true } } } }, + { no: 3, name: "Payload", kind: "message", jsonName: "Payload", T: () => AppointmentExpeditionStartedPayload, options: { "validate.rules": { message: { required: true } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID", "Payload"] } }, "api.messageType": "Request", "api.inputEvent": "ExpeditionStarted" }); + } + create(value?: PartialMessage): AppointmentExpeditionStartedRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentExpeditionStartedRequest): AppointmentExpeditionStartedRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + break; + case /* api.AppointmentExpeditionStartedPayload Payload = 3 [json_name = "Payload"];*/ 3: + message.payload = AppointmentExpeditionStartedPayload.internalBinaryRead(reader, reader.uint32(), options, message.payload); + 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: AppointmentExpeditionStartedRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* api.AppointmentExpeditionStartedPayload Payload = 3 [json_name = "Payload"]; */ + if (message.payload) + AppointmentExpeditionStartedPayload.internalBinaryWrite(message.payload, writer.tag(3, 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.AppointmentExpeditionStartedRequest + */ +export const AppointmentExpeditionStartedRequest = new AppointmentExpeditionStartedRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentExpeditionStartedResponse$Type extends MessageType { + constructor() { + super("api.AppointmentExpeditionStartedResponse", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => ResponseSiteHeader }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID } + ], { "api.messageType": "Response", "api.inputEvent": "ExpeditionStarted" }); + } + create(value?: PartialMessage): AppointmentExpeditionStartedResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentExpeditionStartedResponse): AppointmentExpeditionStartedResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.ResponseSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = ResponseSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + 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: AppointmentExpeditionStartedResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.ResponseSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + ResponseSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, 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.AppointmentExpeditionStartedResponse + */ +export const AppointmentExpeditionStartedResponse = new AppointmentExpeditionStartedResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentExpeditionLoadedPayload$Type extends MessageType { + constructor() { + super("api.AppointmentExpeditionLoadedPayload", [], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { description: "Event Payload" } }, "api.messageType": "Event", "api.payload": true, "api.inputEvent": "ExpeditionLoaded" }); + } + create(value?: PartialMessage): AppointmentExpeditionLoadedPayload { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentExpeditionLoadedPayload): AppointmentExpeditionLoadedPayload { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + 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: AppointmentExpeditionLoadedPayload, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.AppointmentExpeditionLoadedPayload + */ +export const AppointmentExpeditionLoadedPayload = new AppointmentExpeditionLoadedPayload$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentExpeditionLoadedEvent$Type extends MessageType { + constructor() { + super("api.AppointmentExpeditionLoadedEvent", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => EventHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID, options: { "validate.rules": { message: { required: true } } } }, + { no: 3, name: "Payload", kind: "message", jsonName: "Payload", T: () => AppointmentExpeditionLoadedPayload, options: { "validate.rules": { message: { required: true } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID", "Payload"] } }, "api.messageType": "Event", "api.inputEvent": "ExpeditionLoaded" }); + } + create(value?: PartialMessage): AppointmentExpeditionLoadedEvent { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentExpeditionLoadedEvent): AppointmentExpeditionLoadedEvent { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.EventHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = EventHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + break; + case /* api.AppointmentExpeditionLoadedPayload Payload = 3 [json_name = "Payload"];*/ 3: + message.payload = AppointmentExpeditionLoadedPayload.internalBinaryRead(reader, reader.uint32(), options, message.payload); + 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: AppointmentExpeditionLoadedEvent, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.EventHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + EventHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* api.AppointmentExpeditionLoadedPayload Payload = 3 [json_name = "Payload"]; */ + if (message.payload) + AppointmentExpeditionLoadedPayload.internalBinaryWrite(message.payload, writer.tag(3, 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.AppointmentExpeditionLoadedEvent + */ +export const AppointmentExpeditionLoadedEvent = new AppointmentExpeditionLoadedEvent$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentExpeditionLoadedRequest$Type extends MessageType { + constructor() { + super("api.AppointmentExpeditionLoadedRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID, options: { "validate.rules": { message: { required: true } } } }, + { no: 3, name: "Payload", kind: "message", jsonName: "Payload", T: () => AppointmentExpeditionLoadedPayload, options: { "validate.rules": { message: { required: true } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID", "Payload"] } }, "api.messageType": "Request", "api.inputEvent": "ExpeditionLoaded" }); + } + create(value?: PartialMessage): AppointmentExpeditionLoadedRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentExpeditionLoadedRequest): AppointmentExpeditionLoadedRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + break; + case /* api.AppointmentExpeditionLoadedPayload Payload = 3 [json_name = "Payload"];*/ 3: + message.payload = AppointmentExpeditionLoadedPayload.internalBinaryRead(reader, reader.uint32(), options, message.payload); + 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: AppointmentExpeditionLoadedRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* api.AppointmentExpeditionLoadedPayload Payload = 3 [json_name = "Payload"]; */ + if (message.payload) + AppointmentExpeditionLoadedPayload.internalBinaryWrite(message.payload, writer.tag(3, 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.AppointmentExpeditionLoadedRequest + */ +export const AppointmentExpeditionLoadedRequest = new AppointmentExpeditionLoadedRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentExpeditionLoadedResponse$Type extends MessageType { + constructor() { + super("api.AppointmentExpeditionLoadedResponse", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => ResponseSiteHeader }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID } + ], { "api.messageType": "Response", "api.inputEvent": "ExpeditionLoaded" }); + } + create(value?: PartialMessage): AppointmentExpeditionLoadedResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentExpeditionLoadedResponse): AppointmentExpeditionLoadedResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.ResponseSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = ResponseSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + 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: AppointmentExpeditionLoadedResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.ResponseSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + ResponseSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, 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.AppointmentExpeditionLoadedResponse + */ +export const AppointmentExpeditionLoadedResponse = new AppointmentExpeditionLoadedResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentReceptionStartedPayload$Type extends MessageType { + constructor() { + super("api.AppointmentReceptionStartedPayload", [], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { description: "Event Payload" } }, "api.messageType": "Event", "api.payload": true, "api.inputEvent": "ReceptionStarted" }); + } + create(value?: PartialMessage): AppointmentReceptionStartedPayload { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentReceptionStartedPayload): AppointmentReceptionStartedPayload { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + 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: AppointmentReceptionStartedPayload, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.AppointmentReceptionStartedPayload + */ +export const AppointmentReceptionStartedPayload = new AppointmentReceptionStartedPayload$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentReceptionStartedEvent$Type extends MessageType { + constructor() { + super("api.AppointmentReceptionStartedEvent", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => EventHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID, options: { "validate.rules": { message: { required: true } } } }, + { no: 3, name: "Payload", kind: "message", jsonName: "Payload", T: () => AppointmentReceptionStartedPayload, options: { "validate.rules": { message: { required: true } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID", "Payload"] } }, "api.messageType": "Event", "api.inputEvent": "ReceptionStarted" }); + } + create(value?: PartialMessage): AppointmentReceptionStartedEvent { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentReceptionStartedEvent): AppointmentReceptionStartedEvent { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.EventHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = EventHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + break; + case /* api.AppointmentReceptionStartedPayload Payload = 3 [json_name = "Payload"];*/ 3: + message.payload = AppointmentReceptionStartedPayload.internalBinaryRead(reader, reader.uint32(), options, message.payload); + 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: AppointmentReceptionStartedEvent, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.EventHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + EventHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* api.AppointmentReceptionStartedPayload Payload = 3 [json_name = "Payload"]; */ + if (message.payload) + AppointmentReceptionStartedPayload.internalBinaryWrite(message.payload, writer.tag(3, 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.AppointmentReceptionStartedEvent + */ +export const AppointmentReceptionStartedEvent = new AppointmentReceptionStartedEvent$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentReceptionStartedRequest$Type extends MessageType { + constructor() { + super("api.AppointmentReceptionStartedRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID, options: { "validate.rules": { message: { required: true } } } }, + { no: 3, name: "Payload", kind: "message", jsonName: "Payload", T: () => AppointmentReceptionStartedPayload, options: { "validate.rules": { message: { required: true } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID", "Payload"] } }, "api.messageType": "Request", "api.inputEvent": "ReceptionStarted" }); + } + create(value?: PartialMessage): AppointmentReceptionStartedRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentReceptionStartedRequest): AppointmentReceptionStartedRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + break; + case /* api.AppointmentReceptionStartedPayload Payload = 3 [json_name = "Payload"];*/ 3: + message.payload = AppointmentReceptionStartedPayload.internalBinaryRead(reader, reader.uint32(), options, message.payload); + 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: AppointmentReceptionStartedRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* api.AppointmentReceptionStartedPayload Payload = 3 [json_name = "Payload"]; */ + if (message.payload) + AppointmentReceptionStartedPayload.internalBinaryWrite(message.payload, writer.tag(3, 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.AppointmentReceptionStartedRequest + */ +export const AppointmentReceptionStartedRequest = new AppointmentReceptionStartedRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentReceptionStartedResponse$Type extends MessageType { + constructor() { + super("api.AppointmentReceptionStartedResponse", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => ResponseSiteHeader }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID } + ], { "api.messageType": "Response", "api.inputEvent": "ReceptionStarted" }); + } + create(value?: PartialMessage): AppointmentReceptionStartedResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentReceptionStartedResponse): AppointmentReceptionStartedResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.ResponseSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = ResponseSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + 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: AppointmentReceptionStartedResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.ResponseSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + ResponseSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, 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.AppointmentReceptionStartedResponse + */ +export const AppointmentReceptionStartedResponse = new AppointmentReceptionStartedResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentReceptionUnloadedPayload$Type extends MessageType { + constructor() { + super("api.AppointmentReceptionUnloadedPayload", [], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { description: "Event Payload" } }, "api.messageType": "Event", "api.payload": true, "api.inputEvent": "ReceptionUnloaded" }); + } + create(value?: PartialMessage): AppointmentReceptionUnloadedPayload { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentReceptionUnloadedPayload): AppointmentReceptionUnloadedPayload { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + 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: AppointmentReceptionUnloadedPayload, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.AppointmentReceptionUnloadedPayload + */ +export const AppointmentReceptionUnloadedPayload = new AppointmentReceptionUnloadedPayload$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentReceptionUnloadedEvent$Type extends MessageType { + constructor() { + super("api.AppointmentReceptionUnloadedEvent", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => EventHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID, options: { "validate.rules": { message: { required: true } } } }, + { no: 3, name: "Payload", kind: "message", jsonName: "Payload", T: () => AppointmentReceptionUnloadedPayload, options: { "validate.rules": { message: { required: true } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID", "Payload"] } }, "api.messageType": "Event", "api.inputEvent": "ReceptionUnloaded" }); + } + create(value?: PartialMessage): AppointmentReceptionUnloadedEvent { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentReceptionUnloadedEvent): AppointmentReceptionUnloadedEvent { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.EventHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = EventHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + break; + case /* api.AppointmentReceptionUnloadedPayload Payload = 3 [json_name = "Payload"];*/ 3: + message.payload = AppointmentReceptionUnloadedPayload.internalBinaryRead(reader, reader.uint32(), options, message.payload); + 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: AppointmentReceptionUnloadedEvent, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.EventHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + EventHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* api.AppointmentReceptionUnloadedPayload Payload = 3 [json_name = "Payload"]; */ + if (message.payload) + AppointmentReceptionUnloadedPayload.internalBinaryWrite(message.payload, writer.tag(3, 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.AppointmentReceptionUnloadedEvent + */ +export const AppointmentReceptionUnloadedEvent = new AppointmentReceptionUnloadedEvent$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentReceptionUnloadedRequest$Type extends MessageType { + constructor() { + super("api.AppointmentReceptionUnloadedRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID, options: { "validate.rules": { message: { required: true } } } }, + { no: 3, name: "Payload", kind: "message", jsonName: "Payload", T: () => AppointmentReceptionUnloadedPayload, options: { "validate.rules": { message: { required: true } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID", "Payload"] } }, "api.messageType": "Request", "api.inputEvent": "ReceptionUnloaded" }); + } + create(value?: PartialMessage): AppointmentReceptionUnloadedRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentReceptionUnloadedRequest): AppointmentReceptionUnloadedRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + break; + case /* api.AppointmentReceptionUnloadedPayload Payload = 3 [json_name = "Payload"];*/ 3: + message.payload = AppointmentReceptionUnloadedPayload.internalBinaryRead(reader, reader.uint32(), options, message.payload); + 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: AppointmentReceptionUnloadedRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* api.AppointmentReceptionUnloadedPayload Payload = 3 [json_name = "Payload"]; */ + if (message.payload) + AppointmentReceptionUnloadedPayload.internalBinaryWrite(message.payload, writer.tag(3, 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.AppointmentReceptionUnloadedRequest + */ +export const AppointmentReceptionUnloadedRequest = new AppointmentReceptionUnloadedRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentReceptionUnloadedResponse$Type extends MessageType { + constructor() { + super("api.AppointmentReceptionUnloadedResponse", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => ResponseSiteHeader }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID } + ], { "api.messageType": "Response", "api.inputEvent": "ReceptionUnloaded" }); + } + create(value?: PartialMessage): AppointmentReceptionUnloadedResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentReceptionUnloadedResponse): AppointmentReceptionUnloadedResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.ResponseSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = ResponseSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + 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: AppointmentReceptionUnloadedResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.ResponseSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + ResponseSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, 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.AppointmentReceptionUnloadedResponse + */ +export const AppointmentReceptionUnloadedResponse = new AppointmentReceptionUnloadedResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentCarrierDepartedPayload$Type extends MessageType { + constructor() { + super("api.AppointmentCarrierDepartedPayload", [], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { description: "Event Payload" } }, "api.messageType": "Event", "api.payload": true, "api.inputEvent": "CarrierDeparted" }); + } + create(value?: PartialMessage): AppointmentCarrierDepartedPayload { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentCarrierDepartedPayload): AppointmentCarrierDepartedPayload { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + 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: AppointmentCarrierDepartedPayload, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.AppointmentCarrierDepartedPayload + */ +export const AppointmentCarrierDepartedPayload = new AppointmentCarrierDepartedPayload$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentCarrierDepartedEvent$Type extends MessageType { + constructor() { + super("api.AppointmentCarrierDepartedEvent", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => EventHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID, options: { "validate.rules": { message: { required: true } } } }, + { no: 3, name: "Payload", kind: "message", jsonName: "Payload", T: () => AppointmentCarrierDepartedPayload, options: { "validate.rules": { message: { required: true } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID", "Payload"] } }, "api.messageType": "Event", "api.inputEvent": "CarrierDeparted" }); + } + create(value?: PartialMessage): AppointmentCarrierDepartedEvent { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentCarrierDepartedEvent): AppointmentCarrierDepartedEvent { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.EventHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = EventHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + break; + case /* api.AppointmentCarrierDepartedPayload Payload = 3 [json_name = "Payload"];*/ 3: + message.payload = AppointmentCarrierDepartedPayload.internalBinaryRead(reader, reader.uint32(), options, message.payload); + 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: AppointmentCarrierDepartedEvent, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.EventHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + EventHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* api.AppointmentCarrierDepartedPayload Payload = 3 [json_name = "Payload"]; */ + if (message.payload) + AppointmentCarrierDepartedPayload.internalBinaryWrite(message.payload, writer.tag(3, 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.AppointmentCarrierDepartedEvent + */ +export const AppointmentCarrierDepartedEvent = new AppointmentCarrierDepartedEvent$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentCarrierDepartedRequest$Type extends MessageType { + constructor() { + super("api.AppointmentCarrierDepartedRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID, options: { "validate.rules": { message: { required: true } } } }, + { no: 3, name: "Payload", kind: "message", jsonName: "Payload", T: () => AppointmentCarrierDepartedPayload, options: { "validate.rules": { message: { required: true } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID", "Payload"] } }, "api.messageType": "Request", "api.inputEvent": "CarrierDeparted" }); + } + create(value?: PartialMessage): AppointmentCarrierDepartedRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentCarrierDepartedRequest): AppointmentCarrierDepartedRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + break; + case /* api.AppointmentCarrierDepartedPayload Payload = 3 [json_name = "Payload"];*/ 3: + message.payload = AppointmentCarrierDepartedPayload.internalBinaryRead(reader, reader.uint32(), options, message.payload); + 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: AppointmentCarrierDepartedRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* api.AppointmentCarrierDepartedPayload Payload = 3 [json_name = "Payload"]; */ + if (message.payload) + AppointmentCarrierDepartedPayload.internalBinaryWrite(message.payload, writer.tag(3, 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.AppointmentCarrierDepartedRequest + */ +export const AppointmentCarrierDepartedRequest = new AppointmentCarrierDepartedRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentCarrierDepartedResponse$Type extends MessageType { + constructor() { + super("api.AppointmentCarrierDepartedResponse", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => ResponseSiteHeader }, + { no: 2, name: "ID", kind: "message", jsonName: "ID", T: () => EntityID } + ], { "api.messageType": "Response", "api.inputEvent": "CarrierDeparted" }); + } + create(value?: PartialMessage): AppointmentCarrierDepartedResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentCarrierDepartedResponse): AppointmentCarrierDepartedResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.ResponseSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = ResponseSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.EntityID ID = 2 [json_name = "ID"];*/ 2: + message.iD = EntityID.internalBinaryRead(reader, reader.uint32(), options, message.iD); + 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: AppointmentCarrierDepartedResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.ResponseSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + ResponseSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.EntityID ID = 2 [json_name = "ID"]; */ + if (message.iD) + EntityID.internalBinaryWrite(message.iD, writer.tag(2, 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.AppointmentCarrierDepartedResponse + */ +export const AppointmentCarrierDepartedResponse = new AppointmentCarrierDepartedResponse$Type(); +/** + * @generated ServiceType for protobuf service api.AppointmentInputAPI + */ +export const AppointmentInputAPI = new ServiceType("api.AppointmentInputAPI", [ + { name: "Created", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Appointment Inputs"], description: "An appointment has been created." }, "api.rscType": "Site", "api.roles": "Platform.Site-Input", "google.api.method_visibility": { restriction: "PUBLIC" } }, I: AppointmentCreatedRequest, O: AppointmentCreatedResponse }, + { name: "Canceled", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Appointment Inputs"], description: "An appointment has been canceled." }, "api.rscType": "Site", "api.roles": "Platform.Site-Input", "google.api.method_visibility": { restriction: "PUBLIC" } }, I: AppointmentCanceledRequest, O: AppointmentCanceledResponse }, + { name: "CarrierInformationUpdated", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Appointment Inputs"], description: "An appointment carrier information have been updated." }, "api.rscType": "Site", "api.roles": "Platform.Site-Input", "google.api.method_visibility": { restriction: "PUBLIC" } }, I: AppointmentCarrierInformationUpdatedRequest, O: AppointmentCarrierInformationUpdatedResponse }, + { name: "CarrierExpected", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Appointment Inputs"], description: "The carrier is exopected for the appointment." }, "api.rscType": "Site", "api.roles": "Platform.Site-Input", "google.api.method_visibility": { restriction: "PUBLIC" } }, I: AppointmentCarrierExpectedRequest, O: AppointmentCarrierExpectedResponse }, + { name: "CarrierArrived", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Appointment Inputs"], description: "The carrier is arrived for the appointment." }, "api.rscType": "Site", "api.roles": "Platform.Site-Input", "google.api.method_visibility": { restriction: "PUBLIC" } }, I: AppointmentCarrierArrivedRequest, O: AppointmentCarrierArrivedResponse }, + { name: "ExpeditionStarted", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Appointment Inputs"], description: "The appointment expedition is started." }, "api.rscType": "Site", "api.roles": "Platform.Site-Input", "google.api.method_visibility": { restriction: "PUBLIC" } }, I: AppointmentExpeditionStartedRequest, O: AppointmentExpeditionStartedResponse }, + { name: "ExpeditionLoaded", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Appointment Inputs"], description: "The appointment expedition is loaded." }, "api.rscType": "Site", "api.roles": "Platform.Site-Input", "google.api.method_visibility": { restriction: "PUBLIC" } }, I: AppointmentExpeditionLoadedRequest, O: AppointmentExpeditionLoadedResponse }, + { name: "ReceptionStarted", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Appointment Inputs"], description: "The appointment reception is started." }, "api.rscType": "Site", "api.roles": "Platform.Site-Input", "google.api.method_visibility": { restriction: "PUBLIC" } }, I: AppointmentReceptionStartedRequest, O: AppointmentReceptionStartedResponse }, + { name: "ReceptionUnloaded", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Appointment Inputs"], description: "The appointment reception is unloaded." }, "api.rscType": "Site", "api.roles": "Platform.Site-Input", "google.api.method_visibility": { restriction: "PUBLIC" } }, I: AppointmentReceptionUnloadedRequest, O: AppointmentReceptionUnloadedResponse }, + { name: "CarrierDeparted", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Appointment Inputs"], description: "The carrier is departed for the appointment." }, "api.rscType": "Site", "api.roles": "Platform.Site-Input", "google.api.method_visibility": { restriction: "PUBLIC" } }, I: AppointmentCarrierDepartedRequest, O: AppointmentCarrierDepartedResponse } +], { "api.serviceType": "Api", "api.k8sService": "collab-api-server" }); diff --git a/appointmentQuery.client.ts b/appointmentQuery.client.ts new file mode 100644 index 00000000..4f88befc --- /dev/null +++ b/appointmentQuery.client.ts @@ -0,0 +1,115 @@ +// @generated by protobuf-ts 2.9.6 +// @generated from protobuf file "appointmentQuery.proto" (package "api", syntax proto3) +// tslint:disable +import type { RpcTransport } from "@protobuf-ts/runtime-rpc"; +import type { ServiceInfo } from "@protobuf-ts/runtime-rpc"; +import { AppointmentQuery } from "./appointmentQuery"; +import type { CountLinesResult } from "./shared"; +import type { CountLinesQuery } from "./shared"; +import type { GetKPIDataResult } from "./clickhouse"; +import type { GetKPIDataQuery } from "./clickhouse"; +import type { ExtractResult } from "./shared"; +import type { ExtractQuery } from "./shared"; +import type { ElementByMatchResult } from "./shared"; +import type { ElementByMatchQuery } from "./shared"; +import type { AppointmentByMatchResult } from "./appointmentQuery"; +import type { AppointmentByMatchQuery } from "./appointmentQuery"; +import type { AppointmentByFilterResult } from "./appointmentQuery"; +import type { AppointmentByFilterQuery } from "./appointmentQuery"; +import { stackIntercept } from "@protobuf-ts/runtime-rpc"; +import type { AppointmentByIdResult } from "./appointmentQuery"; +import type { AppointmentByIdQuery } from "./appointmentQuery"; +import type { UnaryCall } from "@protobuf-ts/runtime-rpc"; +import type { RpcOptions } from "@protobuf-ts/runtime-rpc"; +/** + * @generated from protobuf service api.AppointmentQuery + */ +export interface IAppointmentQueryClient { + /** + * @generated from protobuf rpc: GetByIds(api.AppointmentByIdQuery) returns (api.AppointmentByIdResult); + */ + getByIds(input: AppointmentByIdQuery, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: Find(api.AppointmentByFilterQuery) returns (api.AppointmentByFilterResult); + */ + find(input: AppointmentByFilterQuery, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: FindMatchingFieldValues(api.AppointmentByMatchQuery) returns (api.AppointmentByMatchResult); + */ + findMatchingFieldValues(input: AppointmentByMatchQuery, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: FindMatchingFieldElements(api.ElementByMatchQuery) returns (api.ElementByMatchResult); + */ + findMatchingFieldElements(input: ElementByMatchQuery, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: Extract(api.ExtractQuery) returns (api.ExtractResult); + */ + extract(input: ExtractQuery, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: GetKPIData(api.GetKPIDataQuery) returns (api.GetKPIDataResult); + */ + getKPIData(input: GetKPIDataQuery, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: CountLines(api.CountLinesQuery) returns (api.CountLinesResult); + */ + countLines(input: CountLinesQuery, options?: RpcOptions): UnaryCall; +} +/** + * @generated from protobuf service api.AppointmentQuery + */ +export class AppointmentQueryClient implements IAppointmentQueryClient, ServiceInfo { + typeName = AppointmentQuery.typeName; + methods = AppointmentQuery.methods; + options = AppointmentQuery.options; + constructor(private readonly _transport: RpcTransport) { + } + /** + * @generated from protobuf rpc: GetByIds(api.AppointmentByIdQuery) returns (api.AppointmentByIdResult); + */ + getByIds(input: AppointmentByIdQuery, options?: RpcOptions): UnaryCall { + const method = this.methods[0], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: Find(api.AppointmentByFilterQuery) returns (api.AppointmentByFilterResult); + */ + find(input: AppointmentByFilterQuery, options?: RpcOptions): UnaryCall { + const method = this.methods[1], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: FindMatchingFieldValues(api.AppointmentByMatchQuery) returns (api.AppointmentByMatchResult); + */ + findMatchingFieldValues(input: AppointmentByMatchQuery, options?: RpcOptions): UnaryCall { + const method = this.methods[2], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: FindMatchingFieldElements(api.ElementByMatchQuery) returns (api.ElementByMatchResult); + */ + findMatchingFieldElements(input: ElementByMatchQuery, options?: RpcOptions): UnaryCall { + const method = this.methods[3], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: Extract(api.ExtractQuery) returns (api.ExtractResult); + */ + extract(input: ExtractQuery, options?: RpcOptions): UnaryCall { + const method = this.methods[4], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: GetKPIData(api.GetKPIDataQuery) returns (api.GetKPIDataResult); + */ + getKPIData(input: GetKPIDataQuery, options?: RpcOptions): UnaryCall { + const method = this.methods[5], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: CountLines(api.CountLinesQuery) returns (api.CountLinesResult); + */ + countLines(input: CountLinesQuery, options?: RpcOptions): UnaryCall { + const method = this.methods[6], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } +} diff --git a/appointmentQuery.ts b/appointmentQuery.ts new file mode 100644 index 00000000..0d13c0aa --- /dev/null +++ b/appointmentQuery.ts @@ -0,0 +1,490 @@ +// @generated by protobuf-ts 2.9.6 +// @generated from protobuf file "appointmentQuery.proto" (package "api", syntax proto3) +// tslint:disable +import { CountLinesResult } from "./shared"; +import { CountLinesQuery } from "./shared"; +import { GetKPIDataResult } from "./clickhouse"; +import { GetKPIDataQuery } from "./clickhouse"; +import { ExtractResult } from "./shared"; +import { ExtractQuery } from "./shared"; +import { ElementByMatchResult } from "./shared"; +import { ElementByMatchQuery } from "./shared"; +import { ServiceType } from "@protobuf-ts/runtime-rpc"; +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 { MatchFieldResult } from "./shared"; +import { MatchField } from "./shared"; +import { BlockFilter } from "./shared"; +import { Appointment } from "./appointment"; +import { ResultHeader } from "./shared"; +import { EntityID } from "./shared"; +import { QueryProjectHeader } from "./shared"; +// +// Query-server services + +/** + * @generated from protobuf message api.AppointmentByIdQuery + */ +export interface AppointmentByIdQuery { + /** + * @generated from protobuf field: api.QueryProjectHeader Header = 1 [json_name = "Header"]; + */ + header?: QueryProjectHeader; + /** + * @generated from protobuf field: repeated api.EntityID IDs = 2 [json_name = "IDs"]; + */ + iDs: EntityID[]; +} +/** + * @generated from protobuf message api.AppointmentByIdResult + */ +export interface AppointmentByIdResult { + /** + * @generated from protobuf field: api.ResultHeader Header = 1 [json_name = "Header"]; + */ + header?: ResultHeader; + /** + * @generated from protobuf field: repeated api.Appointment Objects = 2 [json_name = "Objects"]; + */ + objects: Appointment[]; +} +/** + * @generated from protobuf message api.AppointmentByFilterQuery + */ +export interface AppointmentByFilterQuery { + /** + * @generated from protobuf field: api.QueryProjectHeader Header = 1 [json_name = "Header"]; + */ + header?: QueryProjectHeader; + /** + * Number of maximum result + * + * @generated from protobuf field: string limitFilter = 4; + */ + limitFilter: string; + /** + * @generated from protobuf field: string queryContext = 5; + */ + queryContext: string; + /** + * list of blockFilters structure for Find query, each element (BlockFilter) in the list is an "OR" part of the query, if not empty, simpleFilters (deprecated) & rangeFilters (deprecated) will be ignored + * + * @generated from protobuf field: repeated api.BlockFilter BlockFilters = 6 [json_name = "BlockFilters"]; + */ + blockFilters: BlockFilter[]; +} +/** + * @generated from protobuf message api.AppointmentByFilterResult + */ +export interface AppointmentByFilterResult { + /** + * @generated from protobuf field: api.ResultHeader Header = 1 [json_name = "Header"]; + */ + header?: ResultHeader; + /** + * @generated from protobuf field: repeated api.Appointment Objects = 2 [json_name = "Objects"]; + */ + objects: Appointment[]; + /** + * @generated from protobuf field: string queryContext = 3; + */ + queryContext: string; +} +/** + * @generated from protobuf message api.AppointmentByMatchQuery + */ +export interface AppointmentByMatchQuery { + /** + * @generated from protobuf field: api.QueryProjectHeader Header = 1 [json_name = "Header"]; + */ + header?: QueryProjectHeader; + /** + * list of blockFilters structure for Find query, each element (BlockFilter) in the list is an "OR" part of the query, if not empty, simpleFilters (deprecated) & rangeFilters (deprecated) will be ignored + * + * @generated from protobuf field: repeated api.BlockFilter BlockFilters = 5 [json_name = "BlockFilters"]; + */ + blockFilters: BlockFilter[]; + /** + * MatchField list structure, for FindMatching query + * + * @generated from protobuf field: repeated api.MatchField MatchFields = 6 [json_name = "MatchFields"]; + */ + matchFields: MatchField[]; +} +/** + * @generated from protobuf message api.AppointmentByMatchResult + */ +export interface AppointmentByMatchResult { + /** + * @generated from protobuf field: repeated api.MatchFieldResult MatchResults = 2 [json_name = "MatchResults"]; + */ + matchResults: MatchFieldResult[]; +} +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentByIdQuery$Type extends MessageType { + constructor() { + super("api.AppointmentByIdQuery", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => QueryProjectHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "IDs", kind: "message", jsonName: "IDs", repeat: 1 /*RepeatType.PACKED*/, T: () => EntityID, options: { "validate.rules": { repeated: { minItems: "1" } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "IDs"] } }, "api.messageType": "Query" }); + } + create(value?: PartialMessage): AppointmentByIdQuery { + const message = globalThis.Object.create((this.messagePrototype!)); + message.iDs = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentByIdQuery): AppointmentByIdQuery { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.QueryProjectHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = QueryProjectHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* repeated api.EntityID IDs = 2 [json_name = "IDs"];*/ 2: + message.iDs.push(EntityID.internalBinaryRead(reader, reader.uint32(), options)); + 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: AppointmentByIdQuery, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.QueryProjectHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + QueryProjectHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.EntityID IDs = 2 [json_name = "IDs"]; */ + for (let i = 0; i < message.iDs.length; i++) + EntityID.internalBinaryWrite(message.iDs[i], writer.tag(2, 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.AppointmentByIdQuery + */ +export const AppointmentByIdQuery = new AppointmentByIdQuery$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentByIdResult$Type extends MessageType { + constructor() { + super("api.AppointmentByIdResult", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => ResultHeader }, + { no: 2, name: "Objects", kind: "message", jsonName: "Objects", repeat: 1 /*RepeatType.PACKED*/, T: () => Appointment } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: {} }, "api.messageType": "Result" }); + } + create(value?: PartialMessage): AppointmentByIdResult { + const message = globalThis.Object.create((this.messagePrototype!)); + message.objects = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentByIdResult): AppointmentByIdResult { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.ResultHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = ResultHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* repeated api.Appointment Objects = 2 [json_name = "Objects"];*/ 2: + message.objects.push(Appointment.internalBinaryRead(reader, reader.uint32(), options)); + 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: AppointmentByIdResult, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.ResultHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + ResultHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.Appointment Objects = 2 [json_name = "Objects"]; */ + for (let i = 0; i < message.objects.length; i++) + Appointment.internalBinaryWrite(message.objects[i], writer.tag(2, 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.AppointmentByIdResult + */ +export const AppointmentByIdResult = new AppointmentByIdResult$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentByFilterQuery$Type extends MessageType { + constructor() { + super("api.AppointmentByFilterQuery", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => QueryProjectHeader, options: { "validate.rules": { message: { required: true } }, "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": {} } }, + { no: 4, name: "limitFilter", kind: "scalar", T: 9 /*ScalarType.STRING*/, options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "Number of maximum result", example: "\"500\"" } } }, + { no: 5, name: "queryContext", kind: "scalar", T: 9 /*ScalarType.STRING*/ }, + { no: 6, name: "BlockFilters", kind: "message", jsonName: "BlockFilters", repeat: 1 /*RepeatType.PACKED*/, T: () => BlockFilter } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header"] } } }); + } + create(value?: PartialMessage): AppointmentByFilterQuery { + const message = globalThis.Object.create((this.messagePrototype!)); + message.limitFilter = ""; + message.queryContext = ""; + message.blockFilters = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentByFilterQuery): AppointmentByFilterQuery { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.QueryProjectHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = QueryProjectHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* string limitFilter */ 4: + message.limitFilter = reader.string(); + break; + case /* string queryContext */ 5: + message.queryContext = reader.string(); + break; + case /* repeated api.BlockFilter BlockFilters = 6 [json_name = "BlockFilters"];*/ 6: + message.blockFilters.push(BlockFilter.internalBinaryRead(reader, reader.uint32(), options)); + 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: AppointmentByFilterQuery, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.QueryProjectHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + QueryProjectHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* string limitFilter = 4; */ + if (message.limitFilter !== "") + writer.tag(4, WireType.LengthDelimited).string(message.limitFilter); + /* string queryContext = 5; */ + if (message.queryContext !== "") + writer.tag(5, WireType.LengthDelimited).string(message.queryContext); + /* repeated api.BlockFilter BlockFilters = 6 [json_name = "BlockFilters"]; */ + for (let i = 0; i < message.blockFilters.length; i++) + BlockFilter.internalBinaryWrite(message.blockFilters[i], writer.tag(6, 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.AppointmentByFilterQuery + */ +export const AppointmentByFilterQuery = new AppointmentByFilterQuery$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentByFilterResult$Type extends MessageType { + constructor() { + super("api.AppointmentByFilterResult", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => ResultHeader }, + { no: 2, name: "Objects", kind: "message", jsonName: "Objects", repeat: 1 /*RepeatType.PACKED*/, T: () => Appointment }, + { no: 3, name: "queryContext", kind: "scalar", T: 9 /*ScalarType.STRING*/ } + ]); + } + create(value?: PartialMessage): AppointmentByFilterResult { + const message = globalThis.Object.create((this.messagePrototype!)); + message.objects = []; + message.queryContext = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentByFilterResult): AppointmentByFilterResult { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.ResultHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = ResultHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* repeated api.Appointment Objects = 2 [json_name = "Objects"];*/ 2: + message.objects.push(Appointment.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* string queryContext */ 3: + message.queryContext = 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: AppointmentByFilterResult, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.ResultHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + ResultHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.Appointment Objects = 2 [json_name = "Objects"]; */ + for (let i = 0; i < message.objects.length; i++) + Appointment.internalBinaryWrite(message.objects[i], writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* string queryContext = 3; */ + if (message.queryContext !== "") + writer.tag(3, WireType.LengthDelimited).string(message.queryContext); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.AppointmentByFilterResult + */ +export const AppointmentByFilterResult = new AppointmentByFilterResult$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentByMatchQuery$Type extends MessageType { + constructor() { + super("api.AppointmentByMatchQuery", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => QueryProjectHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 5, name: "BlockFilters", kind: "message", jsonName: "BlockFilters", repeat: 1 /*RepeatType.PACKED*/, T: () => BlockFilter }, + { no: 6, name: "MatchFields", kind: "message", jsonName: "MatchFields", repeat: 1 /*RepeatType.PACKED*/, T: () => MatchField, options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "MatchField list structure, for FindMatching query" } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header"] } } }); + } + create(value?: PartialMessage): AppointmentByMatchQuery { + const message = globalThis.Object.create((this.messagePrototype!)); + message.blockFilters = []; + message.matchFields = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentByMatchQuery): AppointmentByMatchQuery { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.QueryProjectHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = QueryProjectHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* repeated api.BlockFilter BlockFilters = 5 [json_name = "BlockFilters"];*/ 5: + message.blockFilters.push(BlockFilter.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.MatchField MatchFields = 6 [json_name = "MatchFields"];*/ 6: + message.matchFields.push(MatchField.internalBinaryRead(reader, reader.uint32(), options)); + 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: AppointmentByMatchQuery, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.QueryProjectHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + QueryProjectHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.BlockFilter BlockFilters = 5 [json_name = "BlockFilters"]; */ + for (let i = 0; i < message.blockFilters.length; i++) + BlockFilter.internalBinaryWrite(message.blockFilters[i], writer.tag(5, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.MatchField MatchFields = 6 [json_name = "MatchFields"]; */ + for (let i = 0; i < message.matchFields.length; i++) + MatchField.internalBinaryWrite(message.matchFields[i], writer.tag(6, 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.AppointmentByMatchQuery + */ +export const AppointmentByMatchQuery = new AppointmentByMatchQuery$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentByMatchResult$Type extends MessageType { + constructor() { + super("api.AppointmentByMatchResult", [ + { no: 2, name: "MatchResults", kind: "message", jsonName: "MatchResults", repeat: 1 /*RepeatType.PACKED*/, T: () => MatchFieldResult } + ]); + } + create(value?: PartialMessage): AppointmentByMatchResult { + const message = globalThis.Object.create((this.messagePrototype!)); + message.matchResults = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentByMatchResult): AppointmentByMatchResult { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* repeated api.MatchFieldResult MatchResults = 2 [json_name = "MatchResults"];*/ 2: + message.matchResults.push(MatchFieldResult.internalBinaryRead(reader, reader.uint32(), options)); + 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: AppointmentByMatchResult, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* repeated api.MatchFieldResult MatchResults = 2 [json_name = "MatchResults"]; */ + for (let i = 0; i < message.matchResults.length; i++) + MatchFieldResult.internalBinaryWrite(message.matchResults[i], writer.tag(2, 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.AppointmentByMatchResult + */ +export const AppointmentByMatchResult = new AppointmentByMatchResult$Type(); +/** + * @generated ServiceType for protobuf service api.AppointmentQuery + */ +export const AppointmentQuery = new ServiceType("api.AppointmentQuery", [ + { name: "GetByIds", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Appointment Query"], description: "Get Appointments from Ids" }, "api.rscType": "Site", "api.roles": "Platform.Site-Query", "api.moduleID": "appointment", "api.tableName": "appointmentById", "google.api.method_visibility": { restriction: "PUBLIC" } }, I: AppointmentByIdQuery, O: AppointmentByIdResult }, + { name: "Find", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Appointment Query"], description: "Find Appointments using search criterias" }, "api.customQuery": true, "api.rscType": "Site", "api.roles": "Platform.Site-Query", "api.moduleID": "appointment", "google.api.method_visibility": { restriction: "PUBLIC" } }, I: AppointmentByFilterQuery, O: AppointmentByFilterResult }, + { name: "FindMatchingFieldValues", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Appointment Query"], description: "Using search criteria & a main field word, find the list of fields containing the searched word (used for auto completion purposes ...) " }, "api.customQuery": true, "api.rscType": "Site", "api.roles": "", "api.moduleID": "appointment", "google.api.method_visibility": { restriction: "PUBLIC" } }, I: AppointmentByMatchQuery, O: AppointmentByMatchResult }, + { name: "FindMatchingFieldElements", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Appointment Query"], description: "using search criteria & a main field word, find the list of field elements containing the searched word (used for auto completion purposes ...) " }, "api.rscType": "Site", "api.roles": "", "api.moduleID": "appointment", "google.api.method_visibility": { restriction: "PUBLIC" } }, I: ElementByMatchQuery, O: ElementByMatchResult }, + { name: "Extract", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Appointment Query"], description: "Schedule a data extraction" }, "api.rscType": "Site", "api.roles": "", "api.moduleID": "appointment", "google.api.method_visibility": { restriction: "PUBLIC" } }, I: ExtractQuery, O: ExtractResult }, + { name: "GetKPIData", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Appointment Query"], description: "Get Appointment KPI data" }, "api.rscType": "Site", "api.roles": "", "api.moduleID": "appointment", "google.api.method_visibility": { restriction: "PUBLIC" } }, I: GetKPIDataQuery, O: GetKPIDataResult }, + { name: "CountLines", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Appointment Query"], description: "Count lines in database for project" }, "api.rscType": "Platform", "api.roles": "Platform.Site-Query", "api.moduleID": "appointment", "google.api.method_visibility": { restriction: "PUBLIC" } }, I: CountLinesQuery, O: CountLinesResult } +], { "api.serviceType": "Query", "api.k8sService": "collab-query-server" }); diff --git a/calendar.client.ts b/calendar.client.ts new file mode 100644 index 00000000..8b4b75ea --- /dev/null +++ b/calendar.client.ts @@ -0,0 +1,206 @@ +// @generated by protobuf-ts 2.9.6 +// @generated from protobuf file "calendar.proto" (package "api", syntax proto3) +// tslint:disable +import type { RpcTransport } from "@protobuf-ts/runtime-rpc"; +import type { ServiceInfo } from "@protobuf-ts/runtime-rpc"; +import { CalendarService } from "./calendar"; +import type { CloneCalendarOnSiteResponse } from "./calendar"; +import type { CloneCalendarOnSiteRequest } from "./calendar"; +import type { ImportClassicHolidaysOnSiteResponse } from "./calendar"; +import type { ImportClassicHolidaysOnSiteRequest } from "./calendar"; +import type { DeleteCalendarOnSiteResponse } from "./calendar"; +import type { DeleteCalendarOnSiteRequest } from "./calendar"; +import type { UpdateCalendarOnSiteResponse } from "./calendar"; +import type { UpdateCalendarOnSiteRequest } from "./calendar"; +import type { ListCalendarOnSiteResponse } from "./calendar"; +import type { ListCalendarOnSiteRequest } from "./calendar"; +import type { GetCalendarOnSiteResponse } from "./calendar"; +import type { GetCalendarOnSiteRequest } from "./calendar"; +import type { CreateCalendarOnSiteResponse } from "./calendar"; +import type { CreateCalendarOnSiteRequest } from "./calendar"; +import type { CloneCalendarOnOrganisationResponse } from "./calendar"; +import type { CloneCalendarOnOrganisationRequest } from "./calendar"; +import type { ImportClassicHolidaysOnOrganisationResponse } from "./calendar"; +import type { ImportClassicHolidaysOnOrganisationRequest } from "./calendar"; +import type { DeleteCalendarOnOrganisationResponse } from "./calendar"; +import type { DeleteCalendarOnOrganisationRequest } from "./calendar"; +import type { UpdateCalendarOnOrganisationResponse } from "./calendar"; +import type { UpdateCalendarOnOrganisationRequest } from "./calendar"; +import type { ListCalendarOnOrganisationResponse } from "./calendar"; +import type { ListCalendarOnOrganisationRequest } from "./calendar"; +import type { GetCalendarOnOrganisationResponse } from "./calendar"; +import type { GetCalendarOnOrganisationRequest } from "./calendar"; +import { stackIntercept } from "@protobuf-ts/runtime-rpc"; +import type { CreateCalendarOnOrganisationResponse } from "./calendar"; +import type { CreateCalendarOnOrganisationRequest } from "./calendar"; +import type { UnaryCall } from "@protobuf-ts/runtime-rpc"; +import type { RpcOptions } from "@protobuf-ts/runtime-rpc"; +/** + * @generated from protobuf service api.CalendarService + */ +export interface ICalendarServiceClient { + /** + * @generated from protobuf rpc: CreateCalendarOnOrganisation(api.CreateCalendarOnOrganisationRequest) returns (api.CreateCalendarOnOrganisationResponse); + */ + createCalendarOnOrganisation(input: CreateCalendarOnOrganisationRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: GetCalendarOnOrganisation(api.GetCalendarOnOrganisationRequest) returns (api.GetCalendarOnOrganisationResponse); + */ + getCalendarOnOrganisation(input: GetCalendarOnOrganisationRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: ListCalendarOnOrganisation(api.ListCalendarOnOrganisationRequest) returns (api.ListCalendarOnOrganisationResponse); + */ + listCalendarOnOrganisation(input: ListCalendarOnOrganisationRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: UpdateCalendarOnOrganisation(api.UpdateCalendarOnOrganisationRequest) returns (api.UpdateCalendarOnOrganisationResponse); + */ + updateCalendarOnOrganisation(input: UpdateCalendarOnOrganisationRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: DeleteCalendarOnOrganisation(api.DeleteCalendarOnOrganisationRequest) returns (api.DeleteCalendarOnOrganisationResponse); + */ + deleteCalendarOnOrganisation(input: DeleteCalendarOnOrganisationRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: ImportClassicHolidaysOnOrganisation(api.ImportClassicHolidaysOnOrganisationRequest) returns (api.ImportClassicHolidaysOnOrganisationResponse); + */ + importClassicHolidaysOnOrganisation(input: ImportClassicHolidaysOnOrganisationRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: CloneCalendarOnOrganisation(api.CloneCalendarOnOrganisationRequest) returns (api.CloneCalendarOnOrganisationResponse); + */ + cloneCalendarOnOrganisation(input: CloneCalendarOnOrganisationRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: CreateCalendarOnSite(api.CreateCalendarOnSiteRequest) returns (api.CreateCalendarOnSiteResponse); + */ + createCalendarOnSite(input: CreateCalendarOnSiteRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: GetCalendarOnSite(api.GetCalendarOnSiteRequest) returns (api.GetCalendarOnSiteResponse); + */ + getCalendarOnSite(input: GetCalendarOnSiteRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: ListCalendarOnSite(api.ListCalendarOnSiteRequest) returns (api.ListCalendarOnSiteResponse); + */ + listCalendarOnSite(input: ListCalendarOnSiteRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: UpdateCalendarOnSite(api.UpdateCalendarOnSiteRequest) returns (api.UpdateCalendarOnSiteResponse); + */ + updateCalendarOnSite(input: UpdateCalendarOnSiteRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: DeleteCalendarOnSite(api.DeleteCalendarOnSiteRequest) returns (api.DeleteCalendarOnSiteResponse); + */ + deleteCalendarOnSite(input: DeleteCalendarOnSiteRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: ImportClassicHolidaysOnSite(api.ImportClassicHolidaysOnSiteRequest) returns (api.ImportClassicHolidaysOnSiteResponse); + */ + importClassicHolidaysOnSite(input: ImportClassicHolidaysOnSiteRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: CloneCalendarOnSite(api.CloneCalendarOnSiteRequest) returns (api.CloneCalendarOnSiteResponse); + */ + cloneCalendarOnSite(input: CloneCalendarOnSiteRequest, options?: RpcOptions): UnaryCall; +} +/** + * @generated from protobuf service api.CalendarService + */ +export class CalendarServiceClient implements ICalendarServiceClient, ServiceInfo { + typeName = CalendarService.typeName; + methods = CalendarService.methods; + options = CalendarService.options; + constructor(private readonly _transport: RpcTransport) { + } + /** + * @generated from protobuf rpc: CreateCalendarOnOrganisation(api.CreateCalendarOnOrganisationRequest) returns (api.CreateCalendarOnOrganisationResponse); + */ + createCalendarOnOrganisation(input: CreateCalendarOnOrganisationRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[0], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: GetCalendarOnOrganisation(api.GetCalendarOnOrganisationRequest) returns (api.GetCalendarOnOrganisationResponse); + */ + getCalendarOnOrganisation(input: GetCalendarOnOrganisationRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[1], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: ListCalendarOnOrganisation(api.ListCalendarOnOrganisationRequest) returns (api.ListCalendarOnOrganisationResponse); + */ + listCalendarOnOrganisation(input: ListCalendarOnOrganisationRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[2], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: UpdateCalendarOnOrganisation(api.UpdateCalendarOnOrganisationRequest) returns (api.UpdateCalendarOnOrganisationResponse); + */ + updateCalendarOnOrganisation(input: UpdateCalendarOnOrganisationRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[3], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: DeleteCalendarOnOrganisation(api.DeleteCalendarOnOrganisationRequest) returns (api.DeleteCalendarOnOrganisationResponse); + */ + deleteCalendarOnOrganisation(input: DeleteCalendarOnOrganisationRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[4], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: ImportClassicHolidaysOnOrganisation(api.ImportClassicHolidaysOnOrganisationRequest) returns (api.ImportClassicHolidaysOnOrganisationResponse); + */ + importClassicHolidaysOnOrganisation(input: ImportClassicHolidaysOnOrganisationRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[5], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: CloneCalendarOnOrganisation(api.CloneCalendarOnOrganisationRequest) returns (api.CloneCalendarOnOrganisationResponse); + */ + cloneCalendarOnOrganisation(input: CloneCalendarOnOrganisationRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[6], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: CreateCalendarOnSite(api.CreateCalendarOnSiteRequest) returns (api.CreateCalendarOnSiteResponse); + */ + createCalendarOnSite(input: CreateCalendarOnSiteRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[7], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: GetCalendarOnSite(api.GetCalendarOnSiteRequest) returns (api.GetCalendarOnSiteResponse); + */ + getCalendarOnSite(input: GetCalendarOnSiteRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[8], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: ListCalendarOnSite(api.ListCalendarOnSiteRequest) returns (api.ListCalendarOnSiteResponse); + */ + listCalendarOnSite(input: ListCalendarOnSiteRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[9], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: UpdateCalendarOnSite(api.UpdateCalendarOnSiteRequest) returns (api.UpdateCalendarOnSiteResponse); + */ + updateCalendarOnSite(input: UpdateCalendarOnSiteRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[10], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: DeleteCalendarOnSite(api.DeleteCalendarOnSiteRequest) returns (api.DeleteCalendarOnSiteResponse); + */ + deleteCalendarOnSite(input: DeleteCalendarOnSiteRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[11], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: ImportClassicHolidaysOnSite(api.ImportClassicHolidaysOnSiteRequest) returns (api.ImportClassicHolidaysOnSiteResponse); + */ + importClassicHolidaysOnSite(input: ImportClassicHolidaysOnSiteRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[12], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: CloneCalendarOnSite(api.CloneCalendarOnSiteRequest) returns (api.CloneCalendarOnSiteResponse); + */ + cloneCalendarOnSite(input: CloneCalendarOnSiteRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[13], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } +} diff --git a/calendar.ts b/calendar.ts new file mode 100644 index 00000000..8056b273 --- /dev/null +++ b/calendar.ts @@ -0,0 +1,2171 @@ +// @generated by protobuf-ts 2.9.6 +// @generated from protobuf file "calendar.proto" (package "api", syntax proto3) +// tslint:disable +import { ServiceType } from "@protobuf-ts/runtime-rpc"; +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 { RequestSiteHeader } from "./shared"; +import { RequestOrganisationHeader } from "./shared"; +import { ResourceType } from "./shared"; +import { LabelByLanguage } from "./shared"; +// //TODO for the SLA +// message WorkDay{ +// WeekDay WeekDay = 1 +// [ +// (grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = { +// description: ""} +// ]; + +// string StartWorkHour = 3 +// [ +// (grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = { +// description: "Start WorkHour, format hh-mm-ss"} +// ]; +// string EndWorkHour = 4 +// [ +// (grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = { +// description: "End WorkHour, format hh-mm-ss"} +// ]; +// } + +/** + * @generated from protobuf message api.ExceptionnalClosure + */ +export interface ExceptionnalClosure { + /** + * Name of the holiday + * + * @generated from protobuf field: repeated api.LabelByLanguage Label = 1 [json_name = "Label"]; + */ + label: LabelByLanguage[]; + // string StartDate = 2 + // [ + // (validate.rules).string.dateIso8601 = true, + // (viewType) = {Types: [ + // {Context: "*", Type: "date"} + // ]} + // ]; + // string EndDate = 3 + // [ + // (validate.rules).string.dateIso8601 = true, + // (viewType) = {Types: [ + // {Context: "*", Type: "date"} + // ]} + // ]; + + /** + * Start of the ExceptionnalClosure, format yyyy-mm-dd //TODO are we sure about the format + * + * @generated from protobuf field: string StartDate = 2 [json_name = "StartDate"]; + */ + startDate: string; + /** + * End of the ExceptionnalClosure, format yyyy-mm-dd //TODO are we sure about the format + * + * @generated from protobuf field: string EndDate = 3 [json_name = "EndDate"]; + */ + endDate: string; + /** + * Set to true if the ExceptionnalClosure is a complete closure for the impacted days + * + * @generated from protobuf field: bool FullDay = 4 [json_name = "FullDay"]; + */ + fullDay: boolean; + /** + * Start of the ExceptionnalClosure hour if FullDay is set to false, format hh:mm + * + * @generated from protobuf field: string StartHour = 5 [json_name = "StartHour"]; + */ + startHour: string; + /** + * End of the ExceptionnalClosure hour if FullDay is set to false, format hh:mm + * + * @generated from protobuf field: string EndHour = 6 [json_name = "EndHour"]; + */ + endHour: string; +} +/** + * @generated from protobuf message api.Calendar + */ +export interface Calendar { + /** + * Identifier of the calendar + * + * @generated from protobuf field: string ID = 1 [json_name = "ID"]; + */ + iD: string; + /** + * Resource type on which the calendar is referenced + * + * @generated from protobuf field: api.ResourceType RscType = 2 [json_name = "RscType"]; + */ + rscType: ResourceType; + /** + * @generated from protobuf field: string ResourceID = 3 [json_name = "ResourceID"]; + */ + resourceID: string; + /** + * Name of the calendar + * + * @generated from protobuf field: string Name = 4 [json_name = "Name"]; + */ + name: string; + /** + * Description of the calendar + * + * @generated from protobuf field: string Description = 5 [json_name = "Description"]; + */ + description: string; + /** + * List of exceptionnal closure + * + * @generated from protobuf field: repeated api.ExceptionnalClosure ExceptionnalClosures = 6 [json_name = "ExceptionnalClosures"]; + */ + exceptionnalClosures: ExceptionnalClosure[]; +} +// ========== REQUESTS & RESPONSE MESSAGES ========== + +// //// API at Calendar level + +/** + * Create a calendar at organisation level + * + * @generated from protobuf message api.CreateCalendarOnOrganisationRequest + */ +export interface CreateCalendarOnOrganisationRequest { + /** + * @generated from protobuf field: api.RequestOrganisationHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestOrganisationHeader; + /** + * Name of the calendar + * + * @generated from protobuf field: string Name = 2 [json_name = "Name"]; + */ + name: string; + /** + * Description of the calendar + * + * @generated from protobuf field: string Description = 3 [json_name = "Description"]; + */ + description: string; + /** + * List of exceptionnal closure + * + * @generated from protobuf field: repeated api.ExceptionnalClosure ExceptionnalClosures = 4 [json_name = "ExceptionnalClosures"]; + */ + exceptionnalClosures: ExceptionnalClosure[]; +} +/** + * @generated from protobuf message api.CreateCalendarOnOrganisationResponse + */ +export interface CreateCalendarOnOrganisationResponse { + /** + * @generated from protobuf field: api.Calendar Calendar = 1 [json_name = "Calendar"]; + */ + calendar?: Calendar; +} +/** + * Get a calendar at organisation level + * + * @generated from protobuf message api.GetCalendarOnOrganisationRequest + */ +export interface GetCalendarOnOrganisationRequest { + /** + * @generated from protobuf field: api.RequestOrganisationHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestOrganisationHeader; + /** + * @generated from protobuf field: string ID = 2 [json_name = "ID"]; + */ + iD: string; +} +/** + * @generated from protobuf message api.GetCalendarOnOrganisationResponse + */ +export interface GetCalendarOnOrganisationResponse { + /** + * @generated from protobuf field: api.Calendar Calendar = 1 [json_name = "Calendar"]; + */ + calendar?: Calendar; +} +/** + * List a calendar at organisation level + * + * @generated from protobuf message api.ListCalendarOnOrganisationRequest + */ +export interface ListCalendarOnOrganisationRequest { + /** + * @generated from protobuf field: api.RequestOrganisationHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestOrganisationHeader; +} +/** + * @generated from protobuf message api.ListCalendarOnOrganisationResponse + */ +export interface ListCalendarOnOrganisationResponse { + /** + * @generated from protobuf field: repeated api.Calendar Calendars = 1 [json_name = "Calendars"]; + */ + calendars: Calendar[]; +} +/** + * Update a calendar at organisation level + * + * @generated from protobuf message api.UpdateCalendarOnOrganisationRequest + */ +export interface UpdateCalendarOnOrganisationRequest { + /** + * @generated from protobuf field: api.RequestOrganisationHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestOrganisationHeader; + /** + * Identifier of the calendar + * + * @generated from protobuf field: string ID = 2 [json_name = "ID"]; + */ + iD: string; + /** + * Name of the calendar + * + * @generated from protobuf field: string Name = 3 [json_name = "Name"]; + */ + name: string; + /** + * Description of the calendar + * + * @generated from protobuf field: string Description = 4 [json_name = "Description"]; + */ + description: string; + /** + * List of exceptionnal closure + * + * @generated from protobuf field: repeated api.ExceptionnalClosure ExceptionnalClosures = 5 [json_name = "ExceptionnalClosures"]; + */ + exceptionnalClosures: ExceptionnalClosure[]; +} +/** + * @generated from protobuf message api.UpdateCalendarOnOrganisationResponse + */ +export interface UpdateCalendarOnOrganisationResponse { + /** + * @generated from protobuf field: api.Calendar Calendar = 1 [json_name = "Calendar"]; + */ + calendar?: Calendar; +} +/** + * Delete a calendar at organisation level + * + * @generated from protobuf message api.DeleteCalendarOnOrganisationRequest + */ +export interface DeleteCalendarOnOrganisationRequest { + /** + * @generated from protobuf field: api.RequestOrganisationHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestOrganisationHeader; + /** + * @generated from protobuf field: string ID = 2 [json_name = "ID"]; + */ + iD: string; +} +/** + * @generated from protobuf message api.DeleteCalendarOnOrganisationResponse + */ +export interface DeleteCalendarOnOrganisationResponse { +} +/** + * ImportClassicHolidays on a calendar at organisation level + * + * @generated from protobuf message api.ImportClassicHolidaysOnOrganisationRequest + */ +export interface ImportClassicHolidaysOnOrganisationRequest { + /** + * @generated from protobuf field: api.Calendar Calendar = 1 [json_name = "Calendar"]; + */ + calendar?: Calendar; + /** + * @generated from protobuf field: string CountryToQuery = 2 [json_name = "CountryToQuery"]; + */ + countryToQuery: string; +} +/** + * @generated from protobuf message api.ImportClassicHolidaysOnOrganisationResponse + */ +export interface ImportClassicHolidaysOnOrganisationResponse { + /** + * @generated from protobuf field: api.Calendar Calendar = 1 [json_name = "Calendar"]; + */ + calendar?: Calendar; +} +/** + * Clone a calendar at organisation level + * + * @generated from protobuf message api.CloneCalendarOnOrganisationRequest + */ +export interface CloneCalendarOnOrganisationRequest { + /** + * @generated from protobuf field: string CalendarID = 1 [json_name = "CalendarID"]; + */ + calendarID: string; + /** + * @generated from protobuf field: string CountryToQuery = 2 [json_name = "CountryToQuery"]; + */ + countryToQuery: string; +} +/** + * @generated from protobuf message api.CloneCalendarOnOrganisationResponse + */ +export interface CloneCalendarOnOrganisationResponse { + /** + * @generated from protobuf field: api.Calendar Calendar = 1 [json_name = "Calendar"]; + */ + calendar?: Calendar; +} +/** + * Create a calendar at site level + * + * @generated from protobuf message api.CreateCalendarOnSiteRequest + */ +export interface CreateCalendarOnSiteRequest { + /** + * @generated from protobuf field: api.RequestSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestSiteHeader; + /** + * Name of the calendar + * + * @generated from protobuf field: string Name = 2 [json_name = "Name"]; + */ + name: string; + /** + * Description of the calendar + * + * @generated from protobuf field: string Description = 3 [json_name = "Description"]; + */ + description: string; + /** + * List of exceptionnal closure + * + * @generated from protobuf field: repeated api.ExceptionnalClosure ExceptionnalClosures = 4 [json_name = "ExceptionnalClosures"]; + */ + exceptionnalClosures: ExceptionnalClosure[]; +} +/** + * @generated from protobuf message api.CreateCalendarOnSiteResponse + */ +export interface CreateCalendarOnSiteResponse { + /** + * @generated from protobuf field: api.Calendar Calendar = 1 [json_name = "Calendar"]; + */ + calendar?: Calendar; +} +// //// API at Site level + +/** + * Get a calendar at site level + * + * @generated from protobuf message api.GetCalendarOnSiteRequest + */ +export interface GetCalendarOnSiteRequest { + /** + * @generated from protobuf field: api.RequestSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestSiteHeader; + /** + * @generated from protobuf field: string ID = 2 [json_name = "ID"]; + */ + iD: string; +} +/** + * @generated from protobuf message api.GetCalendarOnSiteResponse + */ +export interface GetCalendarOnSiteResponse { + /** + * @generated from protobuf field: api.Calendar Calendar = 1 [json_name = "Calendar"]; + */ + calendar?: Calendar; +} +/** + * List a calendar at site level + * + * @generated from protobuf message api.ListCalendarOnSiteRequest + */ +export interface ListCalendarOnSiteRequest { + /** + * @generated from protobuf field: api.RequestSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestSiteHeader; +} +/** + * @generated from protobuf message api.ListCalendarOnSiteResponse + */ +export interface ListCalendarOnSiteResponse { + /** + * @generated from protobuf field: repeated api.Calendar Calendars = 1 [json_name = "Calendars"]; + */ + calendars: Calendar[]; +} +/** + * Update a calendar at site level + * + * @generated from protobuf message api.UpdateCalendarOnSiteRequest + */ +export interface UpdateCalendarOnSiteRequest { + /** + * @generated from protobuf field: api.RequestSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestSiteHeader; + /** + * Identifier of the calendar + * + * @generated from protobuf field: string ID = 2 [json_name = "ID"]; + */ + iD: string; + /** + * Name of the calendar + * + * @generated from protobuf field: string Name = 3 [json_name = "Name"]; + */ + name: string; + /** + * Description of the calendar + * + * @generated from protobuf field: string Description = 4 [json_name = "Description"]; + */ + description: string; + /** + * List of exceptionnal closure + * + * @generated from protobuf field: repeated api.ExceptionnalClosure ExceptionnalClosures = 5 [json_name = "ExceptionnalClosures"]; + */ + exceptionnalClosures: ExceptionnalClosure[]; +} +/** + * @generated from protobuf message api.UpdateCalendarOnSiteResponse + */ +export interface UpdateCalendarOnSiteResponse { + /** + * @generated from protobuf field: api.Calendar Calendar = 1 [json_name = "Calendar"]; + */ + calendar?: Calendar; +} +/** + * Delete a calendar at site level + * + * @generated from protobuf message api.DeleteCalendarOnSiteRequest + */ +export interface DeleteCalendarOnSiteRequest { + /** + * @generated from protobuf field: api.RequestSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestSiteHeader; + /** + * @generated from protobuf field: string ID = 2 [json_name = "ID"]; + */ + iD: string; +} +/** + * @generated from protobuf message api.DeleteCalendarOnSiteResponse + */ +export interface DeleteCalendarOnSiteResponse { +} +/** + * ImportClassicHolidays on a calendar at site level + * + * @generated from protobuf message api.ImportClassicHolidaysOnSiteRequest + */ +export interface ImportClassicHolidaysOnSiteRequest { + /** + * @generated from protobuf field: api.Calendar Calendar = 1 [json_name = "Calendar"]; + */ + calendar?: Calendar; + /** + * @generated from protobuf field: string CountryToQuery = 2 [json_name = "CountryToQuery"]; + */ + countryToQuery: string; +} +/** + * @generated from protobuf message api.ImportClassicHolidaysOnSiteResponse + */ +export interface ImportClassicHolidaysOnSiteResponse { + /** + * @generated from protobuf field: api.Calendar Calendar = 1 [json_name = "Calendar"]; + */ + calendar?: Calendar; +} +/** + * Clone a calendar at site level + * + * @generated from protobuf message api.CloneCalendarOnSiteRequest + */ +export interface CloneCalendarOnSiteRequest { + /** + * @generated from protobuf field: string CalendarID = 1 [json_name = "CalendarID"]; + */ + calendarID: string; + /** + * @generated from protobuf field: string CountryToQuery = 2 [json_name = "CountryToQuery"]; + */ + countryToQuery: string; +} +/** + * @generated from protobuf message api.CloneCalendarOnSiteResponse + */ +export interface CloneCalendarOnSiteResponse { + /** + * @generated from protobuf field: api.Calendar Calendar = 1 [json_name = "Calendar"]; + */ + calendar?: Calendar; +} +// @generated message type with reflection information, may provide speed optimized methods +class ExceptionnalClosure$Type extends MessageType { + constructor() { + super("api.ExceptionnalClosure", [ + { no: 1, name: "Label", kind: "message", jsonName: "Label", repeat: 1 /*RepeatType.PACKED*/, T: () => LabelByLanguage }, + { no: 2, name: "StartDate", kind: "scalar", jsonName: "StartDate", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { pattern: "^20[0-9]{2}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" } } } }, + { no: 3, name: "EndDate", kind: "scalar", jsonName: "EndDate", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { pattern: "^20[0-9]{2}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" } } } }, + { no: 4, name: "FullDay", kind: "scalar", jsonName: "FullDay", T: 8 /*ScalarType.BOOL*/ }, + { no: 5, name: "StartHour", kind: "scalar", jsonName: "StartHour", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$" } } } }, + { no: 6, name: "EndHour", kind: "scalar", jsonName: "EndHour", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$" } } } } + ]); + } + create(value?: PartialMessage): ExceptionnalClosure { + const message = globalThis.Object.create((this.messagePrototype!)); + message.label = []; + message.startDate = ""; + message.endDate = ""; + message.fullDay = false; + message.startHour = ""; + message.endHour = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ExceptionnalClosure): ExceptionnalClosure { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* repeated api.LabelByLanguage Label = 1 [json_name = "Label"];*/ 1: + message.label.push(LabelByLanguage.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* string StartDate = 2 [json_name = "StartDate"];*/ 2: + message.startDate = reader.string(); + break; + case /* string EndDate = 3 [json_name = "EndDate"];*/ 3: + message.endDate = reader.string(); + break; + case /* bool FullDay = 4 [json_name = "FullDay"];*/ 4: + message.fullDay = reader.bool(); + break; + case /* string StartHour = 5 [json_name = "StartHour"];*/ 5: + message.startHour = reader.string(); + break; + case /* string EndHour = 6 [json_name = "EndHour"];*/ 6: + message.endHour = 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: ExceptionnalClosure, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* repeated api.LabelByLanguage Label = 1 [json_name = "Label"]; */ + for (let i = 0; i < message.label.length; i++) + LabelByLanguage.internalBinaryWrite(message.label[i], writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* string StartDate = 2 [json_name = "StartDate"]; */ + if (message.startDate !== "") + writer.tag(2, WireType.LengthDelimited).string(message.startDate); + /* string EndDate = 3 [json_name = "EndDate"]; */ + if (message.endDate !== "") + writer.tag(3, WireType.LengthDelimited).string(message.endDate); + /* bool FullDay = 4 [json_name = "FullDay"]; */ + if (message.fullDay !== false) + writer.tag(4, WireType.Varint).bool(message.fullDay); + /* string StartHour = 5 [json_name = "StartHour"]; */ + if (message.startHour !== "") + writer.tag(5, WireType.LengthDelimited).string(message.startHour); + /* string EndHour = 6 [json_name = "EndHour"]; */ + if (message.endHour !== "") + writer.tag(6, WireType.LengthDelimited).string(message.endHour); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.ExceptionnalClosure + */ +export const ExceptionnalClosure = new ExceptionnalClosure$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class Calendar$Type extends MessageType { + constructor() { + super("api.Calendar", [ + { no: 1, name: "ID", kind: "scalar", jsonName: "ID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } }, + { no: 2, name: "RscType", kind: "enum", jsonName: "RscType", T: () => ["api.ResourceType", ResourceType, "RESOURCE_TYPE_"] }, + { no: 3, name: "ResourceID", kind: "scalar", jsonName: "ResourceID", T: 9 /*ScalarType.STRING*/ }, + { no: 4, name: "Name", kind: "scalar", jsonName: "Name", T: 9 /*ScalarType.STRING*/ }, + { no: 5, name: "Description", kind: "scalar", jsonName: "Description", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } }, + { no: 6, name: "ExceptionnalClosures", kind: "message", jsonName: "ExceptionnalClosures", repeat: 1 /*RepeatType.PACKED*/, T: () => ExceptionnalClosure } + ]); + } + create(value?: PartialMessage): Calendar { + const message = globalThis.Object.create((this.messagePrototype!)); + message.iD = ""; + message.rscType = 0; + message.resourceID = ""; + message.name = ""; + message.description = ""; + message.exceptionnalClosures = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: Calendar): Calendar { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string ID = 1 [json_name = "ID"];*/ 1: + message.iD = reader.string(); + break; + case /* api.ResourceType RscType = 2 [json_name = "RscType"];*/ 2: + message.rscType = reader.int32(); + break; + case /* string ResourceID = 3 [json_name = "ResourceID"];*/ 3: + message.resourceID = reader.string(); + break; + case /* string Name = 4 [json_name = "Name"];*/ 4: + message.name = reader.string(); + break; + case /* string Description = 5 [json_name = "Description"];*/ 5: + message.description = reader.string(); + break; + case /* repeated api.ExceptionnalClosure ExceptionnalClosures = 6 [json_name = "ExceptionnalClosures"];*/ 6: + message.exceptionnalClosures.push(ExceptionnalClosure.internalBinaryRead(reader, reader.uint32(), options)); + 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: Calendar, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string ID = 1 [json_name = "ID"]; */ + if (message.iD !== "") + writer.tag(1, WireType.LengthDelimited).string(message.iD); + /* api.ResourceType RscType = 2 [json_name = "RscType"]; */ + if (message.rscType !== 0) + writer.tag(2, WireType.Varint).int32(message.rscType); + /* string ResourceID = 3 [json_name = "ResourceID"]; */ + if (message.resourceID !== "") + writer.tag(3, WireType.LengthDelimited).string(message.resourceID); + /* string Name = 4 [json_name = "Name"]; */ + if (message.name !== "") + writer.tag(4, WireType.LengthDelimited).string(message.name); + /* string Description = 5 [json_name = "Description"]; */ + if (message.description !== "") + writer.tag(5, WireType.LengthDelimited).string(message.description); + /* repeated api.ExceptionnalClosure ExceptionnalClosures = 6 [json_name = "ExceptionnalClosures"]; */ + for (let i = 0; i < message.exceptionnalClosures.length; i++) + ExceptionnalClosure.internalBinaryWrite(message.exceptionnalClosures[i], writer.tag(6, 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.Calendar + */ +export const Calendar = new Calendar$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class CreateCalendarOnOrganisationRequest$Type extends MessageType { + constructor() { + super("api.CreateCalendarOnOrganisationRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestOrganisationHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "Name", kind: "scalar", jsonName: "Name", T: 9 /*ScalarType.STRING*/ }, + { no: 3, name: "Description", kind: "scalar", jsonName: "Description", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } }, + { no: 4, name: "ExceptionnalClosures", kind: "message", jsonName: "ExceptionnalClosures", repeat: 1 /*RepeatType.PACKED*/, T: () => ExceptionnalClosure } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header"] } } }); + } + create(value?: PartialMessage): CreateCalendarOnOrganisationRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + message.name = ""; + message.description = ""; + message.exceptionnalClosures = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: CreateCalendarOnOrganisationRequest): CreateCalendarOnOrganisationRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestOrganisationHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestOrganisationHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* string Name = 2 [json_name = "Name"];*/ 2: + message.name = reader.string(); + break; + case /* string Description = 3 [json_name = "Description"];*/ 3: + message.description = reader.string(); + break; + case /* repeated api.ExceptionnalClosure ExceptionnalClosures = 4 [json_name = "ExceptionnalClosures"];*/ 4: + message.exceptionnalClosures.push(ExceptionnalClosure.internalBinaryRead(reader, reader.uint32(), options)); + 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: CreateCalendarOnOrganisationRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestOrganisationHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestOrganisationHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* string Name = 2 [json_name = "Name"]; */ + if (message.name !== "") + writer.tag(2, WireType.LengthDelimited).string(message.name); + /* string Description = 3 [json_name = "Description"]; */ + if (message.description !== "") + writer.tag(3, WireType.LengthDelimited).string(message.description); + /* repeated api.ExceptionnalClosure ExceptionnalClosures = 4 [json_name = "ExceptionnalClosures"]; */ + for (let i = 0; i < message.exceptionnalClosures.length; i++) + ExceptionnalClosure.internalBinaryWrite(message.exceptionnalClosures[i], writer.tag(4, 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.CreateCalendarOnOrganisationRequest + */ +export const CreateCalendarOnOrganisationRequest = new CreateCalendarOnOrganisationRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class CreateCalendarOnOrganisationResponse$Type extends MessageType { + constructor() { + super("api.CreateCalendarOnOrganisationResponse", [ + { no: 1, name: "Calendar", kind: "message", jsonName: "Calendar", T: () => Calendar, options: { "validate.rules": { message: { required: true } } } } + ]); + } + create(value?: PartialMessage): CreateCalendarOnOrganisationResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: CreateCalendarOnOrganisationResponse): CreateCalendarOnOrganisationResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.Calendar Calendar = 1 [json_name = "Calendar"];*/ 1: + message.calendar = Calendar.internalBinaryRead(reader, reader.uint32(), options, message.calendar); + 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: CreateCalendarOnOrganisationResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.Calendar Calendar = 1 [json_name = "Calendar"]; */ + if (message.calendar) + Calendar.internalBinaryWrite(message.calendar, 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.CreateCalendarOnOrganisationResponse + */ +export const CreateCalendarOnOrganisationResponse = new CreateCalendarOnOrganisationResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class GetCalendarOnOrganisationRequest$Type extends MessageType { + constructor() { + super("api.GetCalendarOnOrganisationRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestOrganisationHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "scalar", jsonName: "ID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID"] } } }); + } + create(value?: PartialMessage): GetCalendarOnOrganisationRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + message.iD = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GetCalendarOnOrganisationRequest): GetCalendarOnOrganisationRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestOrganisationHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestOrganisationHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* string ID = 2 [json_name = "ID"];*/ 2: + message.iD = 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: GetCalendarOnOrganisationRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestOrganisationHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestOrganisationHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* string ID = 2 [json_name = "ID"]; */ + if (message.iD !== "") + writer.tag(2, WireType.LengthDelimited).string(message.iD); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.GetCalendarOnOrganisationRequest + */ +export const GetCalendarOnOrganisationRequest = new GetCalendarOnOrganisationRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class GetCalendarOnOrganisationResponse$Type extends MessageType { + constructor() { + super("api.GetCalendarOnOrganisationResponse", [ + { no: 1, name: "Calendar", kind: "message", jsonName: "Calendar", T: () => Calendar, options: { "validate.rules": { message: { required: true } } } } + ]); + } + create(value?: PartialMessage): GetCalendarOnOrganisationResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GetCalendarOnOrganisationResponse): GetCalendarOnOrganisationResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.Calendar Calendar = 1 [json_name = "Calendar"];*/ 1: + message.calendar = Calendar.internalBinaryRead(reader, reader.uint32(), options, message.calendar); + 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: GetCalendarOnOrganisationResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.Calendar Calendar = 1 [json_name = "Calendar"]; */ + if (message.calendar) + Calendar.internalBinaryWrite(message.calendar, 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.GetCalendarOnOrganisationResponse + */ +export const GetCalendarOnOrganisationResponse = new GetCalendarOnOrganisationResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class ListCalendarOnOrganisationRequest$Type extends MessageType { + constructor() { + super("api.ListCalendarOnOrganisationRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestOrganisationHeader, options: { "validate.rules": { message: { required: true } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header"] } } }); + } + create(value?: PartialMessage): ListCalendarOnOrganisationRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ListCalendarOnOrganisationRequest): ListCalendarOnOrganisationRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestOrganisationHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestOrganisationHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + 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: ListCalendarOnOrganisationRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestOrganisationHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestOrganisationHeader.internalBinaryWrite(message.header, 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.ListCalendarOnOrganisationRequest + */ +export const ListCalendarOnOrganisationRequest = new ListCalendarOnOrganisationRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class ListCalendarOnOrganisationResponse$Type extends MessageType { + constructor() { + super("api.ListCalendarOnOrganisationResponse", [ + { no: 1, name: "Calendars", kind: "message", jsonName: "Calendars", repeat: 1 /*RepeatType.PACKED*/, T: () => Calendar } + ]); + } + create(value?: PartialMessage): ListCalendarOnOrganisationResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + message.calendars = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ListCalendarOnOrganisationResponse): ListCalendarOnOrganisationResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* repeated api.Calendar Calendars = 1 [json_name = "Calendars"];*/ 1: + message.calendars.push(Calendar.internalBinaryRead(reader, reader.uint32(), options)); + 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: ListCalendarOnOrganisationResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* repeated api.Calendar Calendars = 1 [json_name = "Calendars"]; */ + for (let i = 0; i < message.calendars.length; i++) + Calendar.internalBinaryWrite(message.calendars[i], 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.ListCalendarOnOrganisationResponse + */ +export const ListCalendarOnOrganisationResponse = new ListCalendarOnOrganisationResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class UpdateCalendarOnOrganisationRequest$Type extends MessageType { + constructor() { + super("api.UpdateCalendarOnOrganisationRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestOrganisationHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "scalar", jsonName: "ID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } }, + { no: 3, name: "Name", kind: "scalar", jsonName: "Name", T: 9 /*ScalarType.STRING*/ }, + { no: 4, name: "Description", kind: "scalar", jsonName: "Description", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } }, + { no: 5, name: "ExceptionnalClosures", kind: "message", jsonName: "ExceptionnalClosures", repeat: 1 /*RepeatType.PACKED*/, T: () => ExceptionnalClosure } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID"] } } }); + } + create(value?: PartialMessage): UpdateCalendarOnOrganisationRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + message.iD = ""; + message.name = ""; + message.description = ""; + message.exceptionnalClosures = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: UpdateCalendarOnOrganisationRequest): UpdateCalendarOnOrganisationRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestOrganisationHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestOrganisationHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* string ID = 2 [json_name = "ID"];*/ 2: + message.iD = reader.string(); + break; + case /* string Name = 3 [json_name = "Name"];*/ 3: + message.name = reader.string(); + break; + case /* string Description = 4 [json_name = "Description"];*/ 4: + message.description = reader.string(); + break; + case /* repeated api.ExceptionnalClosure ExceptionnalClosures = 5 [json_name = "ExceptionnalClosures"];*/ 5: + message.exceptionnalClosures.push(ExceptionnalClosure.internalBinaryRead(reader, reader.uint32(), options)); + 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: UpdateCalendarOnOrganisationRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestOrganisationHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestOrganisationHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* string ID = 2 [json_name = "ID"]; */ + if (message.iD !== "") + writer.tag(2, WireType.LengthDelimited).string(message.iD); + /* string Name = 3 [json_name = "Name"]; */ + if (message.name !== "") + writer.tag(3, WireType.LengthDelimited).string(message.name); + /* string Description = 4 [json_name = "Description"]; */ + if (message.description !== "") + writer.tag(4, WireType.LengthDelimited).string(message.description); + /* repeated api.ExceptionnalClosure ExceptionnalClosures = 5 [json_name = "ExceptionnalClosures"]; */ + for (let i = 0; i < message.exceptionnalClosures.length; i++) + ExceptionnalClosure.internalBinaryWrite(message.exceptionnalClosures[i], 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.UpdateCalendarOnOrganisationRequest + */ +export const UpdateCalendarOnOrganisationRequest = new UpdateCalendarOnOrganisationRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class UpdateCalendarOnOrganisationResponse$Type extends MessageType { + constructor() { + super("api.UpdateCalendarOnOrganisationResponse", [ + { no: 1, name: "Calendar", kind: "message", jsonName: "Calendar", T: () => Calendar, options: { "validate.rules": { message: { required: true } } } } + ]); + } + create(value?: PartialMessage): UpdateCalendarOnOrganisationResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: UpdateCalendarOnOrganisationResponse): UpdateCalendarOnOrganisationResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.Calendar Calendar = 1 [json_name = "Calendar"];*/ 1: + message.calendar = Calendar.internalBinaryRead(reader, reader.uint32(), options, message.calendar); + 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: UpdateCalendarOnOrganisationResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.Calendar Calendar = 1 [json_name = "Calendar"]; */ + if (message.calendar) + Calendar.internalBinaryWrite(message.calendar, 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.UpdateCalendarOnOrganisationResponse + */ +export const UpdateCalendarOnOrganisationResponse = new UpdateCalendarOnOrganisationResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class DeleteCalendarOnOrganisationRequest$Type extends MessageType { + constructor() { + super("api.DeleteCalendarOnOrganisationRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestOrganisationHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "scalar", jsonName: "ID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID"] } } }); + } + create(value?: PartialMessage): DeleteCalendarOnOrganisationRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + message.iD = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: DeleteCalendarOnOrganisationRequest): DeleteCalendarOnOrganisationRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestOrganisationHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestOrganisationHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* string ID = 2 [json_name = "ID"];*/ 2: + message.iD = 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: DeleteCalendarOnOrganisationRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestOrganisationHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestOrganisationHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* string ID = 2 [json_name = "ID"]; */ + if (message.iD !== "") + writer.tag(2, WireType.LengthDelimited).string(message.iD); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.DeleteCalendarOnOrganisationRequest + */ +export const DeleteCalendarOnOrganisationRequest = new DeleteCalendarOnOrganisationRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class DeleteCalendarOnOrganisationResponse$Type extends MessageType { + constructor() { + super("api.DeleteCalendarOnOrganisationResponse", []); + } + create(value?: PartialMessage): DeleteCalendarOnOrganisationResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: DeleteCalendarOnOrganisationResponse): DeleteCalendarOnOrganisationResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + 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: DeleteCalendarOnOrganisationResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.DeleteCalendarOnOrganisationResponse + */ +export const DeleteCalendarOnOrganisationResponse = new DeleteCalendarOnOrganisationResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class ImportClassicHolidaysOnOrganisationRequest$Type extends MessageType { + constructor() { + super("api.ImportClassicHolidaysOnOrganisationRequest", [ + { no: 1, name: "Calendar", kind: "message", jsonName: "Calendar", T: () => Calendar, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "CountryToQuery", kind: "scalar", jsonName: "CountryToQuery", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } } + ]); + } + create(value?: PartialMessage): ImportClassicHolidaysOnOrganisationRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + message.countryToQuery = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ImportClassicHolidaysOnOrganisationRequest): ImportClassicHolidaysOnOrganisationRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.Calendar Calendar = 1 [json_name = "Calendar"];*/ 1: + message.calendar = Calendar.internalBinaryRead(reader, reader.uint32(), options, message.calendar); + break; + case /* string CountryToQuery = 2 [json_name = "CountryToQuery"];*/ 2: + message.countryToQuery = 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: ImportClassicHolidaysOnOrganisationRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.Calendar Calendar = 1 [json_name = "Calendar"]; */ + if (message.calendar) + Calendar.internalBinaryWrite(message.calendar, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* string CountryToQuery = 2 [json_name = "CountryToQuery"]; */ + if (message.countryToQuery !== "") + writer.tag(2, WireType.LengthDelimited).string(message.countryToQuery); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.ImportClassicHolidaysOnOrganisationRequest + */ +export const ImportClassicHolidaysOnOrganisationRequest = new ImportClassicHolidaysOnOrganisationRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class ImportClassicHolidaysOnOrganisationResponse$Type extends MessageType { + constructor() { + super("api.ImportClassicHolidaysOnOrganisationResponse", [ + { no: 1, name: "Calendar", kind: "message", jsonName: "Calendar", T: () => Calendar, options: { "validate.rules": { message: { required: true } } } } + ]); + } + create(value?: PartialMessage): ImportClassicHolidaysOnOrganisationResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ImportClassicHolidaysOnOrganisationResponse): ImportClassicHolidaysOnOrganisationResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.Calendar Calendar = 1 [json_name = "Calendar"];*/ 1: + message.calendar = Calendar.internalBinaryRead(reader, reader.uint32(), options, message.calendar); + 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: ImportClassicHolidaysOnOrganisationResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.Calendar Calendar = 1 [json_name = "Calendar"]; */ + if (message.calendar) + Calendar.internalBinaryWrite(message.calendar, 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.ImportClassicHolidaysOnOrganisationResponse + */ +export const ImportClassicHolidaysOnOrganisationResponse = new ImportClassicHolidaysOnOrganisationResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class CloneCalendarOnOrganisationRequest$Type extends MessageType { + constructor() { + super("api.CloneCalendarOnOrganisationRequest", [ + { no: 1, name: "CalendarID", kind: "scalar", jsonName: "CalendarID", T: 9 /*ScalarType.STRING*/ }, + { no: 2, name: "CountryToQuery", kind: "scalar", jsonName: "CountryToQuery", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } } + ]); + } + create(value?: PartialMessage): CloneCalendarOnOrganisationRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + message.calendarID = ""; + message.countryToQuery = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: CloneCalendarOnOrganisationRequest): CloneCalendarOnOrganisationRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string CalendarID = 1 [json_name = "CalendarID"];*/ 1: + message.calendarID = reader.string(); + break; + case /* string CountryToQuery = 2 [json_name = "CountryToQuery"];*/ 2: + message.countryToQuery = 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: CloneCalendarOnOrganisationRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string CalendarID = 1 [json_name = "CalendarID"]; */ + if (message.calendarID !== "") + writer.tag(1, WireType.LengthDelimited).string(message.calendarID); + /* string CountryToQuery = 2 [json_name = "CountryToQuery"]; */ + if (message.countryToQuery !== "") + writer.tag(2, WireType.LengthDelimited).string(message.countryToQuery); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.CloneCalendarOnOrganisationRequest + */ +export const CloneCalendarOnOrganisationRequest = new CloneCalendarOnOrganisationRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class CloneCalendarOnOrganisationResponse$Type extends MessageType { + constructor() { + super("api.CloneCalendarOnOrganisationResponse", [ + { no: 1, name: "Calendar", kind: "message", jsonName: "Calendar", T: () => Calendar, options: { "validate.rules": { message: { required: true } } } } + ]); + } + create(value?: PartialMessage): CloneCalendarOnOrganisationResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: CloneCalendarOnOrganisationResponse): CloneCalendarOnOrganisationResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.Calendar Calendar = 1 [json_name = "Calendar"];*/ 1: + message.calendar = Calendar.internalBinaryRead(reader, reader.uint32(), options, message.calendar); + 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: CloneCalendarOnOrganisationResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.Calendar Calendar = 1 [json_name = "Calendar"]; */ + if (message.calendar) + Calendar.internalBinaryWrite(message.calendar, 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.CloneCalendarOnOrganisationResponse + */ +export const CloneCalendarOnOrganisationResponse = new CloneCalendarOnOrganisationResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class CreateCalendarOnSiteRequest$Type extends MessageType { + constructor() { + super("api.CreateCalendarOnSiteRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "Name", kind: "scalar", jsonName: "Name", T: 9 /*ScalarType.STRING*/ }, + { no: 3, name: "Description", kind: "scalar", jsonName: "Description", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } }, + { no: 4, name: "ExceptionnalClosures", kind: "message", jsonName: "ExceptionnalClosures", repeat: 1 /*RepeatType.PACKED*/, T: () => ExceptionnalClosure } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header"] } } }); + } + create(value?: PartialMessage): CreateCalendarOnSiteRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + message.name = ""; + message.description = ""; + message.exceptionnalClosures = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: CreateCalendarOnSiteRequest): CreateCalendarOnSiteRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* string Name = 2 [json_name = "Name"];*/ 2: + message.name = reader.string(); + break; + case /* string Description = 3 [json_name = "Description"];*/ 3: + message.description = reader.string(); + break; + case /* repeated api.ExceptionnalClosure ExceptionnalClosures = 4 [json_name = "ExceptionnalClosures"];*/ 4: + message.exceptionnalClosures.push(ExceptionnalClosure.internalBinaryRead(reader, reader.uint32(), options)); + 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: CreateCalendarOnSiteRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* string Name = 2 [json_name = "Name"]; */ + if (message.name !== "") + writer.tag(2, WireType.LengthDelimited).string(message.name); + /* string Description = 3 [json_name = "Description"]; */ + if (message.description !== "") + writer.tag(3, WireType.LengthDelimited).string(message.description); + /* repeated api.ExceptionnalClosure ExceptionnalClosures = 4 [json_name = "ExceptionnalClosures"]; */ + for (let i = 0; i < message.exceptionnalClosures.length; i++) + ExceptionnalClosure.internalBinaryWrite(message.exceptionnalClosures[i], writer.tag(4, 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.CreateCalendarOnSiteRequest + */ +export const CreateCalendarOnSiteRequest = new CreateCalendarOnSiteRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class CreateCalendarOnSiteResponse$Type extends MessageType { + constructor() { + super("api.CreateCalendarOnSiteResponse", [ + { no: 1, name: "Calendar", kind: "message", jsonName: "Calendar", T: () => Calendar, options: { "validate.rules": { message: { required: true } } } } + ]); + } + create(value?: PartialMessage): CreateCalendarOnSiteResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: CreateCalendarOnSiteResponse): CreateCalendarOnSiteResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.Calendar Calendar = 1 [json_name = "Calendar"];*/ 1: + message.calendar = Calendar.internalBinaryRead(reader, reader.uint32(), options, message.calendar); + 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: CreateCalendarOnSiteResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.Calendar Calendar = 1 [json_name = "Calendar"]; */ + if (message.calendar) + Calendar.internalBinaryWrite(message.calendar, 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.CreateCalendarOnSiteResponse + */ +export const CreateCalendarOnSiteResponse = new CreateCalendarOnSiteResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class GetCalendarOnSiteRequest$Type extends MessageType { + constructor() { + super("api.GetCalendarOnSiteRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "scalar", jsonName: "ID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID"] } } }); + } + create(value?: PartialMessage): GetCalendarOnSiteRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + message.iD = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GetCalendarOnSiteRequest): GetCalendarOnSiteRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* string ID = 2 [json_name = "ID"];*/ 2: + message.iD = 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: GetCalendarOnSiteRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* string ID = 2 [json_name = "ID"]; */ + if (message.iD !== "") + writer.tag(2, WireType.LengthDelimited).string(message.iD); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.GetCalendarOnSiteRequest + */ +export const GetCalendarOnSiteRequest = new GetCalendarOnSiteRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class GetCalendarOnSiteResponse$Type extends MessageType { + constructor() { + super("api.GetCalendarOnSiteResponse", [ + { no: 1, name: "Calendar", kind: "message", jsonName: "Calendar", T: () => Calendar, options: { "validate.rules": { message: { required: true } } } } + ]); + } + create(value?: PartialMessage): GetCalendarOnSiteResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GetCalendarOnSiteResponse): GetCalendarOnSiteResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.Calendar Calendar = 1 [json_name = "Calendar"];*/ 1: + message.calendar = Calendar.internalBinaryRead(reader, reader.uint32(), options, message.calendar); + 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: GetCalendarOnSiteResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.Calendar Calendar = 1 [json_name = "Calendar"]; */ + if (message.calendar) + Calendar.internalBinaryWrite(message.calendar, 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.GetCalendarOnSiteResponse + */ +export const GetCalendarOnSiteResponse = new GetCalendarOnSiteResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class ListCalendarOnSiteRequest$Type extends MessageType { + constructor() { + super("api.ListCalendarOnSiteRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header"] } } }); + } + create(value?: PartialMessage): ListCalendarOnSiteRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ListCalendarOnSiteRequest): ListCalendarOnSiteRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + 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: ListCalendarOnSiteRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestSiteHeader.internalBinaryWrite(message.header, 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.ListCalendarOnSiteRequest + */ +export const ListCalendarOnSiteRequest = new ListCalendarOnSiteRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class ListCalendarOnSiteResponse$Type extends MessageType { + constructor() { + super("api.ListCalendarOnSiteResponse", [ + { no: 1, name: "Calendars", kind: "message", jsonName: "Calendars", repeat: 1 /*RepeatType.PACKED*/, T: () => Calendar } + ]); + } + create(value?: PartialMessage): ListCalendarOnSiteResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + message.calendars = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ListCalendarOnSiteResponse): ListCalendarOnSiteResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* repeated api.Calendar Calendars = 1 [json_name = "Calendars"];*/ 1: + message.calendars.push(Calendar.internalBinaryRead(reader, reader.uint32(), options)); + 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: ListCalendarOnSiteResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* repeated api.Calendar Calendars = 1 [json_name = "Calendars"]; */ + for (let i = 0; i < message.calendars.length; i++) + Calendar.internalBinaryWrite(message.calendars[i], 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.ListCalendarOnSiteResponse + */ +export const ListCalendarOnSiteResponse = new ListCalendarOnSiteResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class UpdateCalendarOnSiteRequest$Type extends MessageType { + constructor() { + super("api.UpdateCalendarOnSiteRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "scalar", jsonName: "ID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } }, + { no: 3, name: "Name", kind: "scalar", jsonName: "Name", T: 9 /*ScalarType.STRING*/ }, + { no: 4, name: "Description", kind: "scalar", jsonName: "Description", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } }, + { no: 5, name: "ExceptionnalClosures", kind: "message", jsonName: "ExceptionnalClosures", repeat: 1 /*RepeatType.PACKED*/, T: () => ExceptionnalClosure } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID"] } } }); + } + create(value?: PartialMessage): UpdateCalendarOnSiteRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + message.iD = ""; + message.name = ""; + message.description = ""; + message.exceptionnalClosures = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: UpdateCalendarOnSiteRequest): UpdateCalendarOnSiteRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* string ID = 2 [json_name = "ID"];*/ 2: + message.iD = reader.string(); + break; + case /* string Name = 3 [json_name = "Name"];*/ 3: + message.name = reader.string(); + break; + case /* string Description = 4 [json_name = "Description"];*/ 4: + message.description = reader.string(); + break; + case /* repeated api.ExceptionnalClosure ExceptionnalClosures = 5 [json_name = "ExceptionnalClosures"];*/ 5: + message.exceptionnalClosures.push(ExceptionnalClosure.internalBinaryRead(reader, reader.uint32(), options)); + 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: UpdateCalendarOnSiteRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* string ID = 2 [json_name = "ID"]; */ + if (message.iD !== "") + writer.tag(2, WireType.LengthDelimited).string(message.iD); + /* string Name = 3 [json_name = "Name"]; */ + if (message.name !== "") + writer.tag(3, WireType.LengthDelimited).string(message.name); + /* string Description = 4 [json_name = "Description"]; */ + if (message.description !== "") + writer.tag(4, WireType.LengthDelimited).string(message.description); + /* repeated api.ExceptionnalClosure ExceptionnalClosures = 5 [json_name = "ExceptionnalClosures"]; */ + for (let i = 0; i < message.exceptionnalClosures.length; i++) + ExceptionnalClosure.internalBinaryWrite(message.exceptionnalClosures[i], 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.UpdateCalendarOnSiteRequest + */ +export const UpdateCalendarOnSiteRequest = new UpdateCalendarOnSiteRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class UpdateCalendarOnSiteResponse$Type extends MessageType { + constructor() { + super("api.UpdateCalendarOnSiteResponse", [ + { no: 1, name: "Calendar", kind: "message", jsonName: "Calendar", T: () => Calendar, options: { "validate.rules": { message: { required: true } } } } + ]); + } + create(value?: PartialMessage): UpdateCalendarOnSiteResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: UpdateCalendarOnSiteResponse): UpdateCalendarOnSiteResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.Calendar Calendar = 1 [json_name = "Calendar"];*/ 1: + message.calendar = Calendar.internalBinaryRead(reader, reader.uint32(), options, message.calendar); + 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: UpdateCalendarOnSiteResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.Calendar Calendar = 1 [json_name = "Calendar"]; */ + if (message.calendar) + Calendar.internalBinaryWrite(message.calendar, 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.UpdateCalendarOnSiteResponse + */ +export const UpdateCalendarOnSiteResponse = new UpdateCalendarOnSiteResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class DeleteCalendarOnSiteRequest$Type extends MessageType { + constructor() { + super("api.DeleteCalendarOnSiteRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "scalar", jsonName: "ID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID"] } } }); + } + create(value?: PartialMessage): DeleteCalendarOnSiteRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + message.iD = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: DeleteCalendarOnSiteRequest): DeleteCalendarOnSiteRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* string ID = 2 [json_name = "ID"];*/ 2: + message.iD = 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: DeleteCalendarOnSiteRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* string ID = 2 [json_name = "ID"]; */ + if (message.iD !== "") + writer.tag(2, WireType.LengthDelimited).string(message.iD); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.DeleteCalendarOnSiteRequest + */ +export const DeleteCalendarOnSiteRequest = new DeleteCalendarOnSiteRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class DeleteCalendarOnSiteResponse$Type extends MessageType { + constructor() { + super("api.DeleteCalendarOnSiteResponse", []); + } + create(value?: PartialMessage): DeleteCalendarOnSiteResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: DeleteCalendarOnSiteResponse): DeleteCalendarOnSiteResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + 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: DeleteCalendarOnSiteResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.DeleteCalendarOnSiteResponse + */ +export const DeleteCalendarOnSiteResponse = new DeleteCalendarOnSiteResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class ImportClassicHolidaysOnSiteRequest$Type extends MessageType { + constructor() { + super("api.ImportClassicHolidaysOnSiteRequest", [ + { no: 1, name: "Calendar", kind: "message", jsonName: "Calendar", T: () => Calendar, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "CountryToQuery", kind: "scalar", jsonName: "CountryToQuery", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } } + ]); + } + create(value?: PartialMessage): ImportClassicHolidaysOnSiteRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + message.countryToQuery = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ImportClassicHolidaysOnSiteRequest): ImportClassicHolidaysOnSiteRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.Calendar Calendar = 1 [json_name = "Calendar"];*/ 1: + message.calendar = Calendar.internalBinaryRead(reader, reader.uint32(), options, message.calendar); + break; + case /* string CountryToQuery = 2 [json_name = "CountryToQuery"];*/ 2: + message.countryToQuery = 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: ImportClassicHolidaysOnSiteRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.Calendar Calendar = 1 [json_name = "Calendar"]; */ + if (message.calendar) + Calendar.internalBinaryWrite(message.calendar, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* string CountryToQuery = 2 [json_name = "CountryToQuery"]; */ + if (message.countryToQuery !== "") + writer.tag(2, WireType.LengthDelimited).string(message.countryToQuery); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.ImportClassicHolidaysOnSiteRequest + */ +export const ImportClassicHolidaysOnSiteRequest = new ImportClassicHolidaysOnSiteRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class ImportClassicHolidaysOnSiteResponse$Type extends MessageType { + constructor() { + super("api.ImportClassicHolidaysOnSiteResponse", [ + { no: 1, name: "Calendar", kind: "message", jsonName: "Calendar", T: () => Calendar, options: { "validate.rules": { message: { required: true } } } } + ]); + } + create(value?: PartialMessage): ImportClassicHolidaysOnSiteResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ImportClassicHolidaysOnSiteResponse): ImportClassicHolidaysOnSiteResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.Calendar Calendar = 1 [json_name = "Calendar"];*/ 1: + message.calendar = Calendar.internalBinaryRead(reader, reader.uint32(), options, message.calendar); + 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: ImportClassicHolidaysOnSiteResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.Calendar Calendar = 1 [json_name = "Calendar"]; */ + if (message.calendar) + Calendar.internalBinaryWrite(message.calendar, 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.ImportClassicHolidaysOnSiteResponse + */ +export const ImportClassicHolidaysOnSiteResponse = new ImportClassicHolidaysOnSiteResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class CloneCalendarOnSiteRequest$Type extends MessageType { + constructor() { + super("api.CloneCalendarOnSiteRequest", [ + { no: 1, name: "CalendarID", kind: "scalar", jsonName: "CalendarID", T: 9 /*ScalarType.STRING*/ }, + { no: 2, name: "CountryToQuery", kind: "scalar", jsonName: "CountryToQuery", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } } + ]); + } + create(value?: PartialMessage): CloneCalendarOnSiteRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + message.calendarID = ""; + message.countryToQuery = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: CloneCalendarOnSiteRequest): CloneCalendarOnSiteRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string CalendarID = 1 [json_name = "CalendarID"];*/ 1: + message.calendarID = reader.string(); + break; + case /* string CountryToQuery = 2 [json_name = "CountryToQuery"];*/ 2: + message.countryToQuery = 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: CloneCalendarOnSiteRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string CalendarID = 1 [json_name = "CalendarID"]; */ + if (message.calendarID !== "") + writer.tag(1, WireType.LengthDelimited).string(message.calendarID); + /* string CountryToQuery = 2 [json_name = "CountryToQuery"]; */ + if (message.countryToQuery !== "") + writer.tag(2, WireType.LengthDelimited).string(message.countryToQuery); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.CloneCalendarOnSiteRequest + */ +export const CloneCalendarOnSiteRequest = new CloneCalendarOnSiteRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class CloneCalendarOnSiteResponse$Type extends MessageType { + constructor() { + super("api.CloneCalendarOnSiteResponse", [ + { no: 1, name: "Calendar", kind: "message", jsonName: "Calendar", T: () => Calendar, options: { "validate.rules": { message: { required: true } } } } + ]); + } + create(value?: PartialMessage): CloneCalendarOnSiteResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: CloneCalendarOnSiteResponse): CloneCalendarOnSiteResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.Calendar Calendar = 1 [json_name = "Calendar"];*/ 1: + message.calendar = Calendar.internalBinaryRead(reader, reader.uint32(), options, message.calendar); + 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: CloneCalendarOnSiteResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.Calendar Calendar = 1 [json_name = "Calendar"]; */ + if (message.calendar) + Calendar.internalBinaryWrite(message.calendar, 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.CloneCalendarOnSiteResponse + */ +export const CloneCalendarOnSiteResponse = new CloneCalendarOnSiteResponse$Type(); +/** + * @generated ServiceType for protobuf service api.CalendarService + */ +export const CalendarService = new ServiceType("api.CalendarService", [ + { name: "CreateCalendarOnOrganisation", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Calendar"], description: "Create a Calendar for the organisation" }, "api.rscType": "Organisation", "api.roles": "", "api.moduleID": "slotbooking", "google.api.method_visibility": { restriction: "SDK" } }, I: CreateCalendarOnOrganisationRequest, O: CreateCalendarOnOrganisationResponse }, + { name: "GetCalendarOnOrganisation", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Calendar"], description: "Get a Calendar at organisation level" }, "api.rscType": "Organisation", "api.roles": "", "api.moduleID": "slotbooking", "google.api.method_visibility": { restriction: "SDK" } }, I: GetCalendarOnOrganisationRequest, O: GetCalendarOnOrganisationResponse }, + { name: "ListCalendarOnOrganisation", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Calendar"], description: "List Calendar of an organisation" }, "api.rscType": "Organisation", "api.roles": "", "api.moduleID": "slotbooking", "google.api.method_visibility": { restriction: "SDK" } }, I: ListCalendarOnOrganisationRequest, O: ListCalendarOnOrganisationResponse }, + { name: "UpdateCalendarOnOrganisation", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Calendar"], description: "Update a Calendar at organisation level" }, "api.rscType": "Organisation", "api.roles": "", "api.moduleID": "slotbooking", "google.api.method_visibility": { restriction: "SDK" } }, I: UpdateCalendarOnOrganisationRequest, O: UpdateCalendarOnOrganisationResponse }, + { name: "DeleteCalendarOnOrganisation", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Calendar"], description: "Delete a Calendar at organisation level" }, "api.rscType": "Organisation", "api.roles": "", "api.moduleID": "slotbooking", "google.api.method_visibility": { restriction: "SDK" } }, I: DeleteCalendarOnOrganisationRequest, O: DeleteCalendarOnOrganisationResponse }, + { name: "ImportClassicHolidaysOnOrganisation", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Calendar"], description: "Add the classic holiday of a country for the years to come on a calendar at organisation level" }, "api.rscType": "Organisation", "api.roles": "", "api.moduleID": "slotbooking", "google.api.method_visibility": { restriction: "SDK" } }, I: ImportClassicHolidaysOnOrganisationRequest, O: ImportClassicHolidaysOnOrganisationResponse }, + { name: "CloneCalendarOnOrganisation", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Calendar"], description: "Clone another calendar at organisation level" }, "api.rscType": "Organisation", "api.roles": "", "api.moduleID": "slotbooking", "google.api.method_visibility": { restriction: "SDK" } }, I: CloneCalendarOnOrganisationRequest, O: CloneCalendarOnOrganisationResponse }, + { name: "CreateCalendarOnSite", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Calendar"], description: "Create a Calendar for the site" }, "api.rscType": "Site", "api.roles": "", "api.moduleID": "slotbooking", "google.api.method_visibility": { restriction: "SDK" } }, I: CreateCalendarOnSiteRequest, O: CreateCalendarOnSiteResponse }, + { name: "GetCalendarOnSite", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Calendar"], description: "Get a Calendar at site level" }, "api.rscType": "Site", "api.roles": "", "api.moduleID": "slotbooking", "google.api.method_visibility": { restriction: "SDK" } }, I: GetCalendarOnSiteRequest, O: GetCalendarOnSiteResponse }, + { name: "ListCalendarOnSite", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Calendar"], description: "List Calendar of an site" }, "api.rscType": "Site", "api.roles": "", "api.moduleID": "slotbooking", "google.api.method_visibility": { restriction: "SDK" } }, I: ListCalendarOnSiteRequest, O: ListCalendarOnSiteResponse }, + { name: "UpdateCalendarOnSite", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Calendar"], description: "Update a Calendar at site level" }, "api.rscType": "Site", "api.roles": "", "api.moduleID": "slotbooking", "google.api.method_visibility": { restriction: "SDK" } }, I: UpdateCalendarOnSiteRequest, O: UpdateCalendarOnSiteResponse }, + { name: "DeleteCalendarOnSite", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Calendar"], description: "Delete a Calendar at site level" }, "api.rscType": "Site", "api.roles": "", "api.moduleID": "slotbooking", "google.api.method_visibility": { restriction: "SDK" } }, I: DeleteCalendarOnSiteRequest, O: DeleteCalendarOnSiteResponse }, + { name: "ImportClassicHolidaysOnSite", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Calendar"], description: "Add the classic holiday of a country for the years to come on a calendar at site level" }, "api.rscType": "Site", "api.roles": "", "api.moduleID": "slotbooking", "google.api.method_visibility": { restriction: "SDK" } }, I: ImportClassicHolidaysOnSiteRequest, O: ImportClassicHolidaysOnSiteResponse }, + { name: "CloneCalendarOnSite", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Calendar"], description: "Clone another calendar at site level" }, "api.rscType": "Site", "api.roles": "", "api.moduleID": "slotbooking", "google.api.method_visibility": { restriction: "SDK" } }, I: CloneCalendarOnSiteRequest, O: CloneCalendarOnSiteResponse } +], { "api.k8sService": "slotbookingtype-server" }); diff --git a/collabShared.ts b/collabShared.ts index 6d10866a..04018dfa 100644 --- a/collabShared.ts +++ b/collabShared.ts @@ -10,6 +10,7 @@ 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 { QuantityByUnit } from "./slotbooking"; import { Struct } from "./google/protobuf/struct"; import { DateTime } from "./shared"; import { ClaimStatus } from "./shared"; @@ -146,6 +147,79 @@ export interface NotifChanges { */ details?: Struct; } +// +// Appointment entity status structure + +/** + * @generated from protobuf message api.AppointmentStatus + */ +export interface AppointmentStatus { + /** + * @generated from protobuf field: api.AppointmentStatusCode StatusCode = 1 [json_name = "StatusCode"]; + */ + statusCode: AppointmentStatusCode; + /** + * @generated from protobuf field: string Date = 2 [json_name = "Date"]; + */ + date: string; + /** + * Status effective date. Set by the event's RefDate that triggered the status change. + * + * @generated from protobuf field: api.DateTime ActualDate = 3 [json_name = "ActualDate"]; + */ + actualDate?: DateTime; +} +// +// AppointmentStatusStruct statuses structure + +/** + * @generated from protobuf message api.AppointmentStatusStruct + */ +export interface AppointmentStatusStruct { + /** + * Current status of the Appointment entity + * + * @generated from protobuf field: api.AppointmentStatus Current = 1 [json_name = "Current"]; + */ + current?: AppointmentStatus; + /** + * List of all status history of the Appointment entity + * + * @generated from protobuf field: repeated api.AppointmentStatus History = 2 [json_name = "History"]; + */ + history: AppointmentStatus[]; + /** + * @generated from protobuf field: string CreationDate = 3 [json_name = "CreationDate"]; + */ + creationDate: string; + /** + * @generated from protobuf field: uint32 Version = 4 [json_name = "Version"]; + */ + version: number; +} +/** + * @generated from protobuf message api.Commission + */ +export interface Commission { + /** + * Identifier for the project associated with the order + * + * @generated from protobuf field: string ProjectID = 1 [json_name = "ProjectID"]; + */ + projectID: string; + /** + * ID of the order, might be null for standalone + * + * @generated from protobuf field: string OrderID = 2 [json_name = "OrderID"]; + */ + orderID: string; + /** + * Volumetry inside the truck, should have at least one item listed + * + * @generated from protobuf field: repeated api.QuantityByUnit Quantities = 3 [json_name = "Quantities"]; + */ + quantities: QuantityByUnit[]; +} /** * @generated from protobuf enum api.NotifTypeEnum */ @@ -191,6 +265,52 @@ export enum NotifTypeEnum { */ NOTIF_TYPE_COMPLETION = 9 } +// Appointment + +/** + * + * All statuses for Appointment entity + * + * @generated from protobuf enum api.AppointmentStatusCode + */ +export enum AppointmentStatusCode { + /** + * @generated from protobuf enum value: APPOINTMENT_0000_STATUS_UNKNOWN = 0; + */ + APPOINTMENT_0000_STATUS_UNKNOWN = 0, + /** + * @generated from protobuf enum value: APPOINTMENT_0100_CARRIER_EXPECTED = 100; + */ + APPOINTMENT_0100_CARRIER_EXPECTED = 100, + /** + * @generated from protobuf enum value: APPOINTMENT_0200_CARRIER_ARRIVED = 200; + */ + APPOINTMENT_0200_CARRIER_ARRIVED = 200, + /** + * @generated from protobuf enum value: APPOINTMENT_0300_EXPEDITION_LOADING = 300; + */ + APPOINTMENT_0300_EXPEDITION_LOADING = 300, + /** + * @generated from protobuf enum value: APPOINTMENT_0400_EXPEDITION_LOADED = 400; + */ + APPOINTMENT_0400_EXPEDITION_LOADED = 400, + /** + * @generated from protobuf enum value: APPOINTMENT_0600_RECEPTION_UNLOADING = 600; + */ + APPOINTMENT_0600_RECEPTION_UNLOADING = 600, + /** + * @generated from protobuf enum value: APPOINTMENT_0700_RECEPTION_UNLOADED = 700; + */ + APPOINTMENT_0700_RECEPTION_UNLOADED = 700, + /** + * @generated from protobuf enum value: APPOINTMENT_0500_CARRIER_DEPARTED = 800; + */ + APPOINTMENT_0500_CARRIER_DEPARTED = 800, + /** + * @generated from protobuf enum value: APPOINTMENT_0800_CANCELLED = 1000; + */ + APPOINTMENT_0800_CANCELLED = 1000 +} // @generated message type with reflection information, may provide speed optimized methods class ClaimStatusDef$Type extends MessageType { constructor() { @@ -611,3 +731,198 @@ class NotifChanges$Type extends MessageType { * @generated MessageType for protobuf message api.NotifChanges */ export const NotifChanges = new NotifChanges$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentStatus$Type extends MessageType { + constructor() { + super("api.AppointmentStatus", [ + { no: 1, name: "StatusCode", kind: "enum", jsonName: "StatusCode", T: () => ["api.AppointmentStatusCode", AppointmentStatusCode], options: { "api.indexationType": { Types: [{ Context: "*", Type: "generatedText" }] }, "api.kpiItems": {} } }, + { no: 2, name: "Date", kind: "scalar", jsonName: "Date", T: 9 /*ScalarType.STRING*/, options: { "api.indexationType": { Types: [{ Context: "*", Type: "date" }] }, "api.kpiItems": {}, "api.viewType": { Types: [{ Context: "*", Type: "date" }] } } }, + { no: 3, name: "ActualDate", kind: "message", jsonName: "ActualDate", T: () => DateTime, options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "Status effective date. Set by the event's RefDate that triggered the status change." } } } + ]); + } + create(value?: PartialMessage): AppointmentStatus { + const message = globalThis.Object.create((this.messagePrototype!)); + message.statusCode = 0; + message.date = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentStatus): AppointmentStatus { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.AppointmentStatusCode StatusCode = 1 [json_name = "StatusCode"];*/ 1: + message.statusCode = reader.int32(); + break; + case /* string Date = 2 [json_name = "Date"];*/ 2: + message.date = reader.string(); + break; + case /* api.DateTime ActualDate = 3 [json_name = "ActualDate"];*/ 3: + message.actualDate = DateTime.internalBinaryRead(reader, reader.uint32(), options, message.actualDate); + 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: AppointmentStatus, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.AppointmentStatusCode StatusCode = 1 [json_name = "StatusCode"]; */ + if (message.statusCode !== 0) + writer.tag(1, WireType.Varint).int32(message.statusCode); + /* string Date = 2 [json_name = "Date"]; */ + if (message.date !== "") + writer.tag(2, WireType.LengthDelimited).string(message.date); + /* api.DateTime ActualDate = 3 [json_name = "ActualDate"]; */ + if (message.actualDate) + DateTime.internalBinaryWrite(message.actualDate, writer.tag(3, 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.AppointmentStatus + */ +export const AppointmentStatus = new AppointmentStatus$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class AppointmentStatusStruct$Type extends MessageType { + constructor() { + super("api.AppointmentStatusStruct", [ + { no: 1, name: "Current", kind: "message", jsonName: "Current", T: () => AppointmentStatus, options: { "api.kpiExclude": { Items: [{ Context: "Stock", Group: "stock" }, { Context: "Stock", Group: "stock_extended" }, { Context: "Executionflow", Group: "executionflow" }, { Context: "Movement", Group: "movement" }, { Context: "Order", Group: "order" }, { Context: "Tracking", Group: "tracking" }] } } }, + { no: 2, name: "History", kind: "message", jsonName: "History", repeat: 1 /*RepeatType.PACKED*/, T: () => AppointmentStatus, options: { "api.aggKey": "Date", "api.kpiExclude": { Items: [{ Context: "Stock", Group: "stock" }, { Context: "Stock", Group: "stock_extended" }, { Context: "Executionflow", Group: "executionflow" }, { Context: "Movement", Group: "movement" }, { Context: "Order", Group: "order" }, { Context: "Actor", Group: "actor" }, { Context: "Tracking", Group: "tracking" }] } } }, + { no: 3, name: "CreationDate", kind: "scalar", jsonName: "CreationDate", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { dateIso8601: true } } } }, + { no: 4, name: "Version", kind: "scalar", jsonName: "Version", T: 13 /*ScalarType.UINT32*/ } + ]); + } + create(value?: PartialMessage): AppointmentStatusStruct { + const message = globalThis.Object.create((this.messagePrototype!)); + message.history = []; + message.creationDate = ""; + message.version = 0; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AppointmentStatusStruct): AppointmentStatusStruct { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.AppointmentStatus Current = 1 [json_name = "Current"];*/ 1: + message.current = AppointmentStatus.internalBinaryRead(reader, reader.uint32(), options, message.current); + break; + case /* repeated api.AppointmentStatus History = 2 [json_name = "History"];*/ 2: + message.history.push(AppointmentStatus.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* string CreationDate = 3 [json_name = "CreationDate"];*/ 3: + message.creationDate = reader.string(); + break; + case /* uint32 Version = 4 [json_name = "Version"];*/ 4: + message.version = reader.uint32(); + 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: AppointmentStatusStruct, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.AppointmentStatus Current = 1 [json_name = "Current"]; */ + if (message.current) + AppointmentStatus.internalBinaryWrite(message.current, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.AppointmentStatus History = 2 [json_name = "History"]; */ + for (let i = 0; i < message.history.length; i++) + AppointmentStatus.internalBinaryWrite(message.history[i], writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* string CreationDate = 3 [json_name = "CreationDate"]; */ + if (message.creationDate !== "") + writer.tag(3, WireType.LengthDelimited).string(message.creationDate); + /* uint32 Version = 4 [json_name = "Version"]; */ + if (message.version !== 0) + writer.tag(4, WireType.Varint).uint32(message.version); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.AppointmentStatusStruct + */ +export const AppointmentStatusStruct = new AppointmentStatusStruct$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class Commission$Type extends MessageType { + constructor() { + super("api.Commission", [ + { no: 1, name: "ProjectID", kind: "scalar", jsonName: "ProjectID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } }, + { no: 2, name: "OrderID", kind: "scalar", jsonName: "OrderID", T: 9 /*ScalarType.STRING*/ }, + { no: 3, name: "Quantities", kind: "message", jsonName: "Quantities", repeat: 1 /*RepeatType.PACKED*/, T: () => QuantityByUnit, options: { "validate.rules": { repeated: { minItems: "1" } } } } + ]); + } + create(value?: PartialMessage): Commission { + const message = globalThis.Object.create((this.messagePrototype!)); + message.projectID = ""; + message.orderID = ""; + message.quantities = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: Commission): Commission { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string ProjectID = 1 [json_name = "ProjectID"];*/ 1: + message.projectID = reader.string(); + break; + case /* string OrderID = 2 [json_name = "OrderID"];*/ 2: + message.orderID = reader.string(); + break; + case /* repeated api.QuantityByUnit Quantities = 3 [json_name = "Quantities"];*/ 3: + message.quantities.push(QuantityByUnit.internalBinaryRead(reader, reader.uint32(), options)); + 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: Commission, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string ProjectID = 1 [json_name = "ProjectID"]; */ + if (message.projectID !== "") + writer.tag(1, WireType.LengthDelimited).string(message.projectID); + /* string OrderID = 2 [json_name = "OrderID"]; */ + if (message.orderID !== "") + writer.tag(2, WireType.LengthDelimited).string(message.orderID); + /* repeated api.QuantityByUnit Quantities = 3 [json_name = "Quantities"]; */ + for (let i = 0; i < message.quantities.length; i++) + QuantityByUnit.internalBinaryWrite(message.quantities[i], writer.tag(3, 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.Commission + */ +export const Commission = new Commission$Type(); diff --git a/index.ts b/index.ts index b5ac2987..23178d51 100644 --- a/index.ts +++ b/index.ts @@ -16,6 +16,11 @@ export * from './adminConnection' export * from './api.client' export * from './api' + export * from './appointment' + export * from './appointmentInput.client' + export * from './appointmentInput' + export * from './appointmentQuery.client' + export * from './appointmentQuery' export * from './attachmentType.client' export * from './attachmentType' export * from './attachmentV2.client' @@ -23,6 +28,8 @@ export * from './base' export * from './billing.client' export * from './billing' + export * from './calendar.client' + export * from './calendar' export * from './claim-type.client' export * from './claim-type' export * from './claim' @@ -137,6 +144,9 @@ export * from './rules.client' export * from './rules' export * from './shared' + export * from './site.client' + export * from './site' + export * from './slotbooking' export * from './stock' export * from './stockAction' export * from './stockInput.client' diff --git a/package.json b/package.json index 66a62a06..9189abbf 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@reflex-platform/npm-core-sdk", - "version": "1.11.0-SNAPSHOT-250428093032", + "version": "1.11.0-SNAPSHOT-250428113457", "description": "npm libs from core model proto files", "homepage": "", "main": "index.ts", diff --git a/repositoryShared.ts b/repositoryShared.ts index 21cf309e..be599957 100644 --- a/repositoryShared.ts +++ b/repositoryShared.ts @@ -612,6 +612,23 @@ export interface LVDetailedQuantity { */ quantity: number; } +/** + * @generated from protobuf message api.SiteAlias + */ +export interface SiteAlias { + /** + * @generated from protobuf field: string OrganisationID = 1 [json_name = "OrganisationID"]; + */ + organisationID: string; + /** + * @generated from protobuf field: string SiteID = 2 [json_name = "SiteID"]; + */ + siteID: string; + /** + * @generated from protobuf field: string SiteName = 3 [json_name = "SiteName"]; + */ + siteName: string; +} // // This files contains domain objects @@ -2477,3 +2494,66 @@ class LVDetailedQuantity$Type extends MessageType { * @generated MessageType for protobuf message api.LVDetailedQuantity */ export const LVDetailedQuantity = new LVDetailedQuantity$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class SiteAlias$Type extends MessageType { + constructor() { + super("api.SiteAlias", [ + { no: 1, name: "OrganisationID", kind: "scalar", jsonName: "OrganisationID", T: 9 /*ScalarType.STRING*/ }, + { no: 2, name: "SiteID", kind: "scalar", jsonName: "SiteID", T: 9 /*ScalarType.STRING*/ }, + { no: 3, name: "SiteName", kind: "scalar", jsonName: "SiteName", T: 9 /*ScalarType.STRING*/ } + ]); + } + create(value?: PartialMessage): SiteAlias { + const message = globalThis.Object.create((this.messagePrototype!)); + message.organisationID = ""; + message.siteID = ""; + message.siteName = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: SiteAlias): SiteAlias { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string OrganisationID = 1 [json_name = "OrganisationID"];*/ 1: + message.organisationID = reader.string(); + break; + case /* string SiteID = 2 [json_name = "SiteID"];*/ 2: + message.siteID = reader.string(); + break; + case /* string SiteName = 3 [json_name = "SiteName"];*/ 3: + message.siteName = 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: SiteAlias, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string OrganisationID = 1 [json_name = "OrganisationID"]; */ + if (message.organisationID !== "") + writer.tag(1, WireType.LengthDelimited).string(message.organisationID); + /* string SiteID = 2 [json_name = "SiteID"]; */ + if (message.siteID !== "") + writer.tag(2, WireType.LengthDelimited).string(message.siteID); + /* string SiteName = 3 [json_name = "SiteName"]; */ + if (message.siteName !== "") + writer.tag(3, WireType.LengthDelimited).string(message.siteName); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.SiteAlias + */ +export const SiteAlias = new SiteAlias$Type(); diff --git a/shared.ts b/shared.ts index b912e2b6..a9825693 100644 --- a/shared.ts +++ b/shared.ts @@ -52,6 +52,29 @@ export interface RequestProjectHeader { */ technicalID: string; } +/** + * Header for all requests on site resources + * + * @generated from protobuf message api.RequestSiteHeader + */ +export interface RequestSiteHeader { + /** + * Identifier of the site + * + * @generated from protobuf field: string SiteID = 1 [json_name = "SiteID"]; + */ + siteID: string; + /** + * DateTime ActualDate = 2 ; + * + * @generated from protobuf field: string CorrelationID = 3 [json_name = "CorrelationID"]; + */ + correlationID: string; + /** + * @generated from protobuf field: string TechnicalID = 4 [json_name = "TechnicalID"]; + */ + technicalID: string; +} /** * Header for all requests on organisation resources * @@ -158,7 +181,7 @@ export interface RequestAttachmentTypeHeader { technicalID: string; } /** - * Header for all response messages + * Header for all project response messages * * @generated from protobuf message api.ResponseHeader */ @@ -178,6 +201,27 @@ export interface ResponseHeader { */ technicalID: string; } +/** + * Header for all site response messages + * + * @generated from protobuf message api.ResponseSiteHeader + */ +export interface ResponseSiteHeader { + /** + * Identifier of the site + * + * @generated from protobuf field: string SiteID = 1 [json_name = "SiteID"]; + */ + siteID: string; + /** + * @generated from protobuf field: string CorrelationID = 2 [json_name = "CorrelationID"]; + */ + correlationID: string; + /** + * @generated from protobuf field: string TechnicalID = 3 [json_name = "TechnicalID"]; + */ + technicalID: string; +} /** * Header for all response messages * @@ -324,6 +368,8 @@ export interface EventHeader { // DateTime ActualDate = 6; // TODO : add validation rule to make it required : [(validate.rules).message.required = true] /** + * TODO How to manage Site here ? just rename this attribute in Parent ?? + * * @generated from protobuf field: string Project = 3 [json_name = "Project"]; */ project: string; @@ -1750,6 +1796,19 @@ export interface MatchFieldElementResult { [key: string]: string; }; } +/** + * @generated from protobuf message api.LabelByLanguage + */ +export interface LabelByLanguage { + /** + * @generated from protobuf field: string Value = 1 [json_name = "Value"]; + */ + value: string; + /** + * @generated from protobuf field: string LanguageCodeISO6391 = 2 [json_name = "LanguageCodeISO6391"]; + */ + languageCodeISO6391: string; +} /** * List all data set in the model * @@ -1801,6 +1860,43 @@ export enum ModelDataSetEnum { */ CLAIM = 10 } +/** + * @generated from protobuf enum api.WeekDay + */ +export enum WeekDay { + /** + * @generated from protobuf enum value: WEEKDAY_UNDEFINED = 0; + */ + WEEKDAY_UNDEFINED = 0, + /** + * @generated from protobuf enum value: WEEKDAY_MONDAY = 1; + */ + WEEKDAY_MONDAY = 1, + /** + * @generated from protobuf enum value: WEEKDAY_TUESDAY = 2; + */ + WEEKDAY_TUESDAY = 2, + /** + * @generated from protobuf enum value: WEEKDAY_WEDNESDAY = 3; + */ + WEEKDAY_WEDNESDAY = 3, + /** + * @generated from protobuf enum value: WEEKDAY_THURSDAY = 4; + */ + WEEKDAY_THURSDAY = 4, + /** + * @generated from protobuf enum value: WEEKDAY_FRIDAY = 5; + */ + WEEKDAY_FRIDAY = 5, + /** + * @generated from protobuf enum value: WEEKDAY_SATURDAY = 6; + */ + WEEKDAY_SATURDAY = 6, + /** + * @generated from protobuf enum value: WEEKDAY_SUNDAY = 7; + */ + WEEKDAY_SUNDAY = 7 +} /** * @generated from protobuf enum api.SeverityLevel */ @@ -2381,7 +2477,11 @@ export enum ResourceType { /** * @generated from protobuf enum value: RESOURCE_TYPE_CLAIMTYPE = 70; */ - CLAIMTYPE = 70 + CLAIMTYPE = 70, + /** + * @generated from protobuf enum value: RESOURCE_TYPE_SITE = 80; + */ + SITE = 80 } // @generated message type with reflection information, may provide speed optimized methods class RequestHeader$Type extends MessageType { @@ -2494,6 +2594,69 @@ class RequestProjectHeader$Type extends MessageType { */ export const RequestProjectHeader = new RequestProjectHeader$Type(); // @generated message type with reflection information, may provide speed optimized methods +class RequestSiteHeader$Type extends MessageType { + constructor() { + super("api.RequestSiteHeader", [ + { no: 1, name: "SiteID", kind: "scalar", jsonName: "SiteID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1", notContains: " " } }, "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "Identifier of the site", example: "\"Your_Site_ID\"" } } }, + { no: 3, name: "CorrelationID", kind: "scalar", jsonName: "CorrelationID", T: 9 /*ScalarType.STRING*/, options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "This ID is sent back into the response header in order to be able to correlate request and response", example: "\"CorrID_A\"" } } }, + { no: 4, name: "TechnicalID", kind: "scalar", jsonName: "TechnicalID", T: 9 /*ScalarType.STRING*/, options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "This ID is sent back into the response header in order to be able to correlate request and response", example: "\"TechID_A\"" } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["SiteID"] } } }); + } + create(value?: PartialMessage): RequestSiteHeader { + const message = globalThis.Object.create((this.messagePrototype!)); + message.siteID = ""; + message.correlationID = ""; + message.technicalID = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: RequestSiteHeader): RequestSiteHeader { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string SiteID = 1 [json_name = "SiteID"];*/ 1: + message.siteID = reader.string(); + break; + case /* string CorrelationID = 3 [json_name = "CorrelationID"];*/ 3: + message.correlationID = reader.string(); + break; + case /* string TechnicalID = 4 [json_name = "TechnicalID"];*/ 4: + message.technicalID = 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: RequestSiteHeader, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string SiteID = 1 [json_name = "SiteID"]; */ + if (message.siteID !== "") + writer.tag(1, WireType.LengthDelimited).string(message.siteID); + /* string CorrelationID = 3 [json_name = "CorrelationID"]; */ + if (message.correlationID !== "") + writer.tag(3, WireType.LengthDelimited).string(message.correlationID); + /* string TechnicalID = 4 [json_name = "TechnicalID"]; */ + if (message.technicalID !== "") + writer.tag(4, WireType.LengthDelimited).string(message.technicalID); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.RequestSiteHeader + */ +export const RequestSiteHeader = new RequestSiteHeader$Type(); +// @generated message type with reflection information, may provide speed optimized methods class RequestOrganisationHeader$Type extends MessageType { constructor() { super("api.RequestOrganisationHeader", [ @@ -2872,6 +3035,69 @@ class ResponseHeader$Type extends MessageType { */ export const ResponseHeader = new ResponseHeader$Type(); // @generated message type with reflection information, may provide speed optimized methods +class ResponseSiteHeader$Type extends MessageType { + constructor() { + super("api.ResponseSiteHeader", [ + { no: 1, name: "SiteID", kind: "scalar", jsonName: "SiteID", T: 9 /*ScalarType.STRING*/, options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "Identifier of the site" } } }, + { no: 2, name: "CorrelationID", kind: "scalar", jsonName: "CorrelationID", T: 9 /*ScalarType.STRING*/, options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "This ID is filled using the request CorrelationID if provided in order to be able to correlate request and response", example: "\"CorrID_A\"" } } }, + { no: 3, name: "TechnicalID", kind: "scalar", jsonName: "TechnicalID", T: 9 /*ScalarType.STRING*/, options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "This ID is filled using the request TechnicalID if provided in order to be able to correlate request and response", example: "\"TechID_A\"" } } } + ]); + } + create(value?: PartialMessage): ResponseSiteHeader { + const message = globalThis.Object.create((this.messagePrototype!)); + message.siteID = ""; + message.correlationID = ""; + message.technicalID = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ResponseSiteHeader): ResponseSiteHeader { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string SiteID = 1 [json_name = "SiteID"];*/ 1: + message.siteID = reader.string(); + break; + case /* string CorrelationID = 2 [json_name = "CorrelationID"];*/ 2: + message.correlationID = reader.string(); + break; + case /* string TechnicalID = 3 [json_name = "TechnicalID"];*/ 3: + message.technicalID = 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: ResponseSiteHeader, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string SiteID = 1 [json_name = "SiteID"]; */ + if (message.siteID !== "") + writer.tag(1, WireType.LengthDelimited).string(message.siteID); + /* string CorrelationID = 2 [json_name = "CorrelationID"]; */ + if (message.correlationID !== "") + writer.tag(2, WireType.LengthDelimited).string(message.correlationID); + /* string TechnicalID = 3 [json_name = "TechnicalID"]; */ + if (message.technicalID !== "") + writer.tag(3, WireType.LengthDelimited).string(message.technicalID); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.ResponseSiteHeader + */ +export const ResponseSiteHeader = new ResponseSiteHeader$Type(); +// @generated message type with reflection information, may provide speed optimized methods class AttachmentTypeResponseHeader$Type extends MessageType { constructor() { super("api.AttachmentTypeResponseHeader", [ @@ -7387,3 +7613,58 @@ class MatchFieldElementResult$Type extends MessageType * @generated MessageType for protobuf message api.MatchFieldElementResult */ export const MatchFieldElementResult = new MatchFieldElementResult$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class LabelByLanguage$Type extends MessageType { + constructor() { + super("api.LabelByLanguage", [ + { no: 1, name: "Value", kind: "scalar", jsonName: "Value", T: 9 /*ScalarType.STRING*/ }, + { no: 2, name: "LanguageCodeISO6391", kind: "scalar", jsonName: "LanguageCodeISO6391", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "2", maxLen: "3", languageIso639: true } }, "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "ISO 639 code message language", example: "\"en\"" } } } + ]); + } + create(value?: PartialMessage): LabelByLanguage { + const message = globalThis.Object.create((this.messagePrototype!)); + message.value = ""; + message.languageCodeISO6391 = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: LabelByLanguage): LabelByLanguage { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string Value = 1 [json_name = "Value"];*/ 1: + message.value = reader.string(); + break; + case /* string LanguageCodeISO6391 = 2 [json_name = "LanguageCodeISO6391"];*/ 2: + message.languageCodeISO6391 = 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: LabelByLanguage, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string Value = 1 [json_name = "Value"]; */ + if (message.value !== "") + writer.tag(1, WireType.LengthDelimited).string(message.value); + /* string LanguageCodeISO6391 = 2 [json_name = "LanguageCodeISO6391"]; */ + if (message.languageCodeISO6391 !== "") + writer.tag(2, WireType.LengthDelimited).string(message.languageCodeISO6391); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.LabelByLanguage + */ +export const LabelByLanguage = new LabelByLanguage$Type(); diff --git a/site.client.ts b/site.client.ts new file mode 100644 index 00000000..912e3dcd --- /dev/null +++ b/site.client.ts @@ -0,0 +1,141 @@ +// @generated by protobuf-ts 2.9.6 +// @generated from protobuf file "site.proto" (package "api", syntax proto3) +// tslint:disable +import type { RpcTransport } from "@protobuf-ts/runtime-rpc"; +import type { ServiceInfo } from "@protobuf-ts/runtime-rpc"; +import { SiteService } from "./site"; +import type { CancelAppointmentResponse } from "./site"; +import type { CancelAppointmentRequest } from "./site"; +import type { BookAppointmentResponse } from "./site"; +import type { BookAppointmentRequest } from "./site"; +import type { ListUserSitesResponse } from "./site"; +import type { ListUserSitesRequest } from "./site"; +import type { GetAvailableSlotsResponse } from "./site"; +import type { GetAvailableSlotsRequest } from "./site"; +import type { DeleteSiteResponse } from "./site"; +import type { DeleteSiteRequest } from "./site"; +import type { UpdateSiteResponse } from "./site"; +import type { UpdateSiteRequest } from "./site"; +import type { ListSiteResponse } from "./site"; +import type { ListSiteRequest } from "./site"; +import type { GetSiteResponse } from "./site"; +import type { GetSiteRequest } from "./site"; +import { stackIntercept } from "@protobuf-ts/runtime-rpc"; +import type { CreateSiteResponse } from "./site"; +import type { CreateSiteRequest } from "./site"; +import type { UnaryCall } from "@protobuf-ts/runtime-rpc"; +import type { RpcOptions } from "@protobuf-ts/runtime-rpc"; +/** + * @generated from protobuf service api.SiteService + */ +export interface ISiteServiceClient { + /** + * @generated from protobuf rpc: Create(api.CreateSiteRequest) returns (api.CreateSiteResponse); + */ + create(input: CreateSiteRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: Get(api.GetSiteRequest) returns (api.GetSiteResponse); + */ + get(input: GetSiteRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: List(api.ListSiteRequest) returns (api.ListSiteResponse); + */ + list(input: ListSiteRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: Update(api.UpdateSiteRequest) returns (api.UpdateSiteResponse); + */ + update(input: UpdateSiteRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: Delete(api.DeleteSiteRequest) returns (api.DeleteSiteResponse); + */ + delete(input: DeleteSiteRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: GetAvailableSlots(api.GetAvailableSlotsRequest) returns (api.GetAvailableSlotsResponse); + */ + getAvailableSlots(input: GetAvailableSlotsRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: ListUserSites(api.ListUserSitesRequest) returns (api.ListUserSitesResponse); + */ + listUserSites(input: ListUserSitesRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: BookAppointment(api.BookAppointmentRequest) returns (api.BookAppointmentResponse); + */ + bookAppointment(input: BookAppointmentRequest, options?: RpcOptions): UnaryCall; + /** + * @generated from protobuf rpc: CancelAppointment(api.CancelAppointmentRequest) returns (api.CancelAppointmentResponse); + */ + cancelAppointment(input: CancelAppointmentRequest, options?: RpcOptions): UnaryCall; +} +/** + * @generated from protobuf service api.SiteService + */ +export class SiteServiceClient implements ISiteServiceClient, ServiceInfo { + typeName = SiteService.typeName; + methods = SiteService.methods; + options = SiteService.options; + constructor(private readonly _transport: RpcTransport) { + } + /** + * @generated from protobuf rpc: Create(api.CreateSiteRequest) returns (api.CreateSiteResponse); + */ + create(input: CreateSiteRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[0], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: Get(api.GetSiteRequest) returns (api.GetSiteResponse); + */ + get(input: GetSiteRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[1], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: List(api.ListSiteRequest) returns (api.ListSiteResponse); + */ + list(input: ListSiteRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[2], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: Update(api.UpdateSiteRequest) returns (api.UpdateSiteResponse); + */ + update(input: UpdateSiteRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[3], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: Delete(api.DeleteSiteRequest) returns (api.DeleteSiteResponse); + */ + delete(input: DeleteSiteRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[4], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: GetAvailableSlots(api.GetAvailableSlotsRequest) returns (api.GetAvailableSlotsResponse); + */ + getAvailableSlots(input: GetAvailableSlotsRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[5], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: ListUserSites(api.ListUserSitesRequest) returns (api.ListUserSitesResponse); + */ + listUserSites(input: ListUserSitesRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[6], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: BookAppointment(api.BookAppointmentRequest) returns (api.BookAppointmentResponse); + */ + bookAppointment(input: BookAppointmentRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[7], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } + /** + * @generated from protobuf rpc: CancelAppointment(api.CancelAppointmentRequest) returns (api.CancelAppointmentResponse); + */ + cancelAppointment(input: CancelAppointmentRequest, options?: RpcOptions): UnaryCall { + const method = this.methods[8], opt = this._transport.mergeOptions(options); + return stackIntercept("unary", this._transport, method, opt, input); + } +} diff --git a/site.ts b/site.ts new file mode 100644 index 00000000..d34d3dfe --- /dev/null +++ b/site.ts @@ -0,0 +1,1900 @@ +// @generated by protobuf-ts 2.9.6 +// @generated from protobuf file "site.proto" (package "api", syntax proto3) +// tslint:disable +import { ServiceType } from "@protobuf-ts/runtime-rpc"; +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 { Slot } from "./slotbooking"; +import { Commission } from "./collabShared"; +import { AppointmentType } from "./slotbooking"; +import { RequestSiteHeader } from "./shared"; +import { RequestOrganisationHeader } from "./shared"; +import { CarrierInformation } from "./slotbooking"; +import { Document } from "./slotbooking"; +import { LabelByLanguage } from "./shared"; +import { CapacityRule } from "./slotbooking"; +import { DurationRule } from "./slotbooking"; +import { OpeningRule } from "./slotbooking"; +import { Unit } from "./slotbooking"; +import { ProjectAuthorisation } from "./slotbooking"; +import { Segmentation } from "./slotbooking"; +import { Address } from "./repositoryShared"; +/** + * Message defining the structure of a Site. + * + * @generated from protobuf message api.Site + */ +export interface Site { + /** + * @generated from protobuf field: string ID = 1 [json_name = "ID"]; + */ + iD: string; // Unique identifier for the site. (formatted as such: "SITE__") + /** + * Name of the Site + * + * @generated from protobuf field: string Name = 2 [json_name = "Name"]; + */ + name: string; + /** + * Identifier for the organisation associated with the site. + * + * @generated from protobuf field: string OrganisationID = 3 [json_name = "OrganisationID"]; + */ + organisationID: string; + /** + * @generated from protobuf field: bool Active = 4 [json_name = "Active"]; + */ + active: boolean; // If the Site is active or not + /** + * @generated from protobuf field: string PhotoURI = 5 [json_name = "PhotoURI"]; + */ + photoURI: string; // Link to a picture to display + /** + * @generated from protobuf field: api.Address Address = 6 [json_name = "Address"]; + */ + address?: Address; // Address of the Site + /** + * @generated from protobuf field: repeated string Phones = 7 [json_name = "Phones"]; + */ + phones: string[]; + /** + * @generated from protobuf field: string Fax = 8 [json_name = "Fax"]; + */ + fax: string; + /** + * List of Segmentations that segment the logistic site. + * + * @generated from protobuf field: repeated api.Segmentation Segmentations = 9 [json_name = "Segmentations"]; + */ + segmentations: Segmentation[]; + /** + * List of allowed project and the constraints (interval time in which they can book an appointment) they are associated with. + * + * @generated from protobuf field: repeated api.ProjectAuthorisation Authorisations = 10 [json_name = "Authorisations"]; + */ + authorisations: ProjectAuthorisation[]; + /** + * List of containment units which will be used to estimate the needed time to load or unload. + * + * @generated from protobuf field: repeated api.Unit Units = 11 [json_name = "Units"]; + */ + units: Unit[]; + /** + * Definition of the opening rules. 2 opening rule definitions cannot overlap. + * + * @generated from protobuf field: repeated api.OpeningRule OpeningRules = 12 [json_name = "OpeningRules"]; + */ + openingRules: OpeningRule[]; + /** + * Definition of the booking slot duration rules. + * + * @generated from protobuf field: repeated api.DurationRule DurationRules = 13 [json_name = "DurationRules"]; + */ + durationRules: DurationRule[]; + /** + * Definition of the capacity rules. 2 capacity rule can overlap and the more constraining one will be applied. + * + * @generated from protobuf field: repeated api.CapacityRule CapacityRules = 14 [json_name = "CapacityRules"]; + */ + capacityRules: CapacityRule[]; + /** + * @generated from protobuf field: repeated api.LabelByLanguage Instructions = 15 [json_name = "Instructions"]; + */ + instructions: LabelByLanguage[]; // @option language + /** + * Set of instruction document, listing necessary equipment and such + * + * @generated from protobuf field: repeated api.Document InstructionDocuments = 16 [json_name = "InstructionDocuments"]; + */ + instructionDocuments: Document[]; + /** + * Set of required or optional information to ask when a slot is booked + * + * @generated from protobuf field: repeated api.CarrierInformation CarrierInformations = 17 [json_name = "CarrierInformations"]; + */ + carrierInformations: CarrierInformation[]; + /** + * Link to calendar ID available at organisation level + * + * @generated from protobuf field: repeated string CalendarIDs = 18 [json_name = "CalendarIDs"]; + */ + calendarIDs: string[]; + /** + * Defines the rounded value to define booking period + * + * @generated from protobuf field: int64 RoundedPeriodInMinutes = 19 [json_name = "RoundedPeriodInMinutes"]; + */ + roundedPeriodInMinutes: bigint; + /** + * Add Site Time zone + * + * @generated from protobuf field: string TargetTimeZone = 20 [json_name = "TargetTimeZone"]; + */ + targetTimeZone: string; + /** + * Must be a valid email address + * + * @generated from protobuf field: repeated string Emails = 21 [json_name = "Emails"]; + */ + emails: string[]; + /** + * set the fallback language in case of missing translation + * + * @generated from protobuf field: string DefaultSiteLanguageISO6391 = 22 [json_name = "DefaultSiteLanguageISO6391"]; + */ + defaultSiteLanguageISO6391: string; +} +// ========== REQUESTS & RESPONSE MESSAGES ========== + +/** + * Create + * + * @generated from protobuf message api.CreateSiteRequest + */ +export interface CreateSiteRequest { + /** + * @generated from protobuf field: api.RequestOrganisationHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestOrganisationHeader; + /** + * Identifier of the new Site + * + * @generated from protobuf field: string SiteID = 2 [json_name = "SiteID"]; + */ + siteID: string; + /** + * Name of the new Site, modifiable after creation + * + * @generated from protobuf field: string SiteName = 3 [json_name = "SiteName"]; + */ + siteName: string; + /** + * Must be a valid email address from a user know to the platform + * + * @generated from protobuf field: string Emails = 4 [json_name = "Emails"]; + */ + emails: string; +} +/** + * @generated from protobuf message api.CreateSiteResponse + */ +export interface CreateSiteResponse { + /** + * @generated from protobuf field: api.Site Site = 1 [json_name = "Site"]; + */ + site?: Site; +} +/** + * Get + * + * @generated from protobuf message api.GetSiteRequest + */ +export interface GetSiteRequest { + /** + * @generated from protobuf field: api.RequestOrganisationHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestOrganisationHeader; + /** + * @generated from protobuf field: string ID = 2 [json_name = "ID"]; + */ + iD: string; +} +/** + * @generated from protobuf message api.GetSiteResponse + */ +export interface GetSiteResponse { + /** + * @generated from protobuf field: api.Site Site = 1 [json_name = "Site"]; + */ + site?: Site; +} +/** + * List + * + * @generated from protobuf message api.ListSiteRequest + */ +export interface ListSiteRequest { + /** + * @generated from protobuf field: api.RequestOrganisationHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestOrganisationHeader; +} +/** + * @generated from protobuf message api.ListSiteResponse + */ +export interface ListSiteResponse { + /** + * @generated from protobuf field: repeated api.Site Sites = 1 [json_name = "Sites"]; + */ + sites: Site[]; +} +/** + * Update + * + * @generated from protobuf message api.UpdateSiteRequest + */ +export interface UpdateSiteRequest { + /** + * @generated from protobuf field: api.RequestOrganisationHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestOrganisationHeader; + /** + * Unique identifier of the site + * + * @generated from protobuf field: string ID = 2 [json_name = "ID"]; + */ + iD: string; + /** + * Name of the Site + * + * @generated from protobuf field: string Name = 3 [json_name = "Name"]; + */ + name: string; + /** + * @generated from protobuf field: bool Active = 4 [json_name = "Active"]; + */ + active: boolean; // If the Site is active or not + /** + * @generated from protobuf field: string PhotoURI = 5 [json_name = "PhotoURI"]; + */ + photoURI: string; // link to a picture to display + /** + * @generated from protobuf field: api.Address Address = 6 [json_name = "Address"]; + */ + address?: Address; // address of the Site + /** + * @generated from protobuf field: repeated string Phones = 7 [json_name = "Phones"]; + */ + phones: string[]; + /** + * @generated from protobuf field: string Fax = 8 [json_name = "Fax"]; + */ + fax: string; + /** + * List of Segmentations that segment the logistic site. + * + * @generated from protobuf field: repeated api.Segmentation Segmentations = 9 [json_name = "Segmentations"]; + */ + segmentations: Segmentation[]; + /** + * List of allowed project and the constraints (interval time in which they can book an appointment) they are associated with. + * + * @generated from protobuf field: repeated api.ProjectAuthorisation Authorisations = 10 [json_name = "Authorisations"]; + */ + authorisations: ProjectAuthorisation[]; + /** + * List of containment units which will be used to estimate the needed time to load or unload. + * + * @generated from protobuf field: repeated api.Unit Units = 11 [json_name = "Units"]; + */ + units: Unit[]; + /** + * Definition of the opening rules. 2 opening rule definitions cannot overlap. + * + * @generated from protobuf field: repeated api.OpeningRule OpeningRules = 12 [json_name = "OpeningRules"]; + */ + openingRules: OpeningRule[]; + /** + * Definition of the booking slot duration rules. + * + * @generated from protobuf field: repeated api.DurationRule DurationRules = 13 [json_name = "DurationRules"]; + */ + durationRules: DurationRule[]; + /** + * Definition of the capacity rules. 2 capacity rule can overlap and the more constraining one will be applied. + * + * @generated from protobuf field: repeated api.CapacityRule CapacityRules = 14 [json_name = "CapacityRules"]; + */ + capacityRules: CapacityRule[]; + /** + * @generated from protobuf field: repeated api.LabelByLanguage Instructions = 15 [json_name = "Instructions"]; + */ + instructions: LabelByLanguage[]; // @option language + /** + * Set of instruction document, listing necessary equipment and such + * + * @generated from protobuf field: repeated api.Document InstructionDocuments = 16 [json_name = "InstructionDocuments"]; + */ + instructionDocuments: Document[]; + /** + * Set of required or optional information to ask when a slot is booked + * + * @generated from protobuf field: repeated api.CarrierInformation CarrierInformations = 17 [json_name = "CarrierInformations"]; + */ + carrierInformations: CarrierInformation[]; + /** + * Link to calendar ID available at organisation level + * + * @generated from protobuf field: repeated string CalendarIDs = 18 [json_name = "CalendarIDs"]; + */ + calendarIDs: string[]; + /** + * Defines the rounded value to define booking period + * + * @generated from protobuf field: int64 RoundedPeriodInMinutes = 19 [json_name = "RoundedPeriodInMinutes"]; + */ + roundedPeriodInMinutes: bigint; + /** + * Add Site Time zone + * + * @generated from protobuf field: string TargetTimeZone = 20 [json_name = "TargetTimeZone"]; + */ + targetTimeZone: string; + /** + * Must be a valid email address + * + * @generated from protobuf field: repeated string Emails = 21 [json_name = "Emails"]; + */ + emails: string[]; + /** + * set the fallback language in case of missing translation + * + * @generated from protobuf field: string DefaultSiteLanguageISO6391 = 22 [json_name = "DefaultSiteLanguageISO6391"]; + */ + defaultSiteLanguageISO6391: string; +} +/** + * @generated from protobuf message api.UpdateSiteResponse + */ +export interface UpdateSiteResponse { + /** + * @generated from protobuf field: api.Site Site = 1 [json_name = "Site"]; + */ + site?: Site; +} +/** + * Delete + * + * @generated from protobuf message api.DeleteSiteRequest + */ +export interface DeleteSiteRequest { + /** + * @generated from protobuf field: api.RequestOrganisationHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestOrganisationHeader; + /** + * @generated from protobuf field: string ID = 2 [json_name = "ID"]; + */ + iD: string; +} +/** + * @generated from protobuf message api.DeleteSiteResponse + */ +export interface DeleteSiteResponse { +} +/** + * GetAvailableSlots + * + * @generated from protobuf message api.GetAvailableSlotsRequest + */ +export interface GetAvailableSlotsRequest { + /** + * @generated from protobuf field: api.RequestSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestSiteHeader; + /** + * Type of appointment : Expedition / Reception / Both + * + * @generated from protobuf field: api.AppointmentType AppointmentType = 2 [json_name = "AppointmentType"]; + */ + appointmentType: AppointmentType; + /** + * List of the orders and projects for which the appointment is made, with the quantities + * + * @generated from protobuf field: repeated api.Commission Commissions = 3 [json_name = "Commissions"]; + */ + commissions: Commission[]; + /** + * Set of segmentation constraining the slot booking + * + * @generated from protobuf field: repeated api.Segmentation Segmentations = 4 [json_name = "Segmentations"]; + */ + segmentations: Segmentation[]; + /** + * Start date of the range to look for available slots + * + * @generated from protobuf field: string StartDate = 5 [json_name = "StartDate"]; + */ + startDate: string; + /** + * End date of the range to look for available slots + * + * @generated from protobuf field: string EndDate = 6 [json_name = "EndDate"]; + */ + endDate: string; +} +/** + * @generated from protobuf message api.GetAvailableSlotsResponse + */ +export interface GetAvailableSlotsResponse { + /** + * @generated from protobuf field: repeated api.Slot Slots = 1 [json_name = "Slots"]; + */ + slots: Slot[]; +} +/** + * BookAppointment + * + * @generated from protobuf message api.BookAppointmentRequest + */ +export interface BookAppointmentRequest { + /** + * @generated from protobuf field: api.RequestSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestSiteHeader; + /** + * Type of appointment : Expedition / Reception / Both + * + * @generated from protobuf field: api.AppointmentType AppointmentType = 2 [json_name = "AppointmentType"]; + */ + appointmentType: AppointmentType; + /** + * List of the orders and projects for which the appointment is made, with the quantities + * + * @generated from protobuf field: repeated api.Commission Commissions = 3 [json_name = "Commissions"]; + */ + commissions: Commission[]; + /** + * Set of segmentation constraining the slot booking + * + * @generated from protobuf field: repeated api.Segmentation Segmentations = 4 [json_name = "Segmentations"]; + */ + segmentations: Segmentation[]; + /** + * Required carrierInformation, some can be obligatory + * + * @generated from protobuf field: repeated api.CarrierInformation CarrierInformation = 5 [json_name = "CarrierInformation"]; + */ + carrierInformation: CarrierInformation[]; + /** + * The slot to book for the appointment + * + * @generated from protobuf field: api.Slot Slot = 6 [json_name = "Slot"]; + */ + slot?: Slot; + /** + * User mails being notified on this appointment + * TODO Need to add a structure to store platform user identifiers which can act on this appointment ? + * + * @generated from protobuf field: repeated string Emails = 8 [json_name = "Emails"]; + */ + emails: string[]; +} +/** + * @generated from protobuf message api.BookAppointmentResponse + */ +export interface BookAppointmentResponse { + /** + * @generated from protobuf field: string AppointmentID = 1 [json_name = "AppointmentID"]; + */ + appointmentID: string; +} +/** + * CancelAppointment + * + * @generated from protobuf message api.CancelAppointmentRequest + */ +export interface CancelAppointmentRequest { + /** + * @generated from protobuf field: api.RequestSiteHeader Header = 1 [json_name = "Header"]; + */ + header?: RequestSiteHeader; + /** + * @generated from protobuf field: string AppointmentID = 2 [json_name = "AppointmentID"]; + */ + appointmentID: string; +} +/** + * @generated from protobuf message api.CancelAppointmentResponse + */ +export interface CancelAppointmentResponse { + /** + * @generated from protobuf field: string AppointmentID = 1 [json_name = "AppointmentID"]; + */ + appointmentID: string; +} +/** + * ListUserSites + * + * @generated from protobuf message api.ListUserSitesRequest + */ +export interface ListUserSitesRequest { + /** + * TODO optional filter + * + * @generated from protobuf field: repeated string ProjectID = 1 [json_name = "ProjectID"]; + */ + projectID: string[]; +} +/** + * @generated from protobuf message api.ListUserSitesResponse + */ +export interface ListUserSitesResponse { + /** + * @generated from protobuf field: repeated api.Site Sites = 1 [json_name = "Sites"]; + */ + sites: Site[]; +} +// @generated message type with reflection information, may provide speed optimized methods +class Site$Type extends MessageType { + constructor() { + super("api.Site", [ + { no: 1, name: "ID", kind: "scalar", jsonName: "ID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } }, + { no: 2, name: "Name", kind: "scalar", jsonName: "Name", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } }, + { no: 3, name: "OrganisationID", kind: "scalar", jsonName: "OrganisationID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } }, + { no: 4, name: "Active", kind: "scalar", jsonName: "Active", T: 8 /*ScalarType.BOOL*/ }, + { no: 5, name: "PhotoURI", kind: "scalar", jsonName: "PhotoURI", T: 9 /*ScalarType.STRING*/ }, + { no: 6, name: "Address", kind: "message", jsonName: "Address", T: () => Address }, + { no: 7, name: "Phones", kind: "scalar", jsonName: "Phones", repeat: 2 /*RepeatType.UNPACKED*/, T: 9 /*ScalarType.STRING*/, options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { example: "[\"06 00 00 00 00\", \"+49 00 0000 0000\"]" } } }, + { no: 8, name: "Fax", kind: "scalar", jsonName: "Fax", T: 9 /*ScalarType.STRING*/, options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { example: "[\"06 00 00 00 00\", \"+49 00 0000 0000\"]" } } }, + { no: 9, name: "Segmentations", kind: "message", jsonName: "Segmentations", repeat: 1 /*RepeatType.PACKED*/, T: () => Segmentation }, + { no: 10, name: "Authorisations", kind: "message", jsonName: "Authorisations", repeat: 1 /*RepeatType.PACKED*/, T: () => ProjectAuthorisation }, + { no: 11, name: "Units", kind: "message", jsonName: "Units", repeat: 1 /*RepeatType.PACKED*/, T: () => Unit, options: { "validate.rules": { repeated: { minItems: "1" } } } }, + { no: 12, name: "OpeningRules", kind: "message", jsonName: "OpeningRules", repeat: 1 /*RepeatType.PACKED*/, T: () => OpeningRule }, + { no: 13, name: "DurationRules", kind: "message", jsonName: "DurationRules", repeat: 1 /*RepeatType.PACKED*/, T: () => DurationRule }, + { no: 14, name: "CapacityRules", kind: "message", jsonName: "CapacityRules", repeat: 1 /*RepeatType.PACKED*/, T: () => CapacityRule }, + { no: 15, name: "Instructions", kind: "message", jsonName: "Instructions", repeat: 1 /*RepeatType.PACKED*/, T: () => LabelByLanguage, options: { "api.language": true, "api.aggKey": "LanguageCodeISO6391" } }, + { no: 16, name: "InstructionDocuments", kind: "message", jsonName: "InstructionDocuments", repeat: 1 /*RepeatType.PACKED*/, T: () => Document }, + { no: 17, name: "CarrierInformations", kind: "message", jsonName: "CarrierInformations", repeat: 1 /*RepeatType.PACKED*/, T: () => CarrierInformation }, + { no: 18, name: "CalendarIDs", kind: "scalar", jsonName: "CalendarIDs", repeat: 2 /*RepeatType.UNPACKED*/, T: 9 /*ScalarType.STRING*/ }, + { no: 19, name: "RoundedPeriodInMinutes", kind: "scalar", jsonName: "RoundedPeriodInMinutes", T: 3 /*ScalarType.INT64*/, L: 0 /*LongType.BIGINT*/ }, + { no: 20, name: "TargetTimeZone", kind: "scalar", jsonName: "TargetTimeZone", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1", tzData: true } }, "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "Target site time zone format", example: "\"Europe/Paris\"" } } }, + { no: 21, name: "Emails", kind: "scalar", jsonName: "Emails", repeat: 2 /*RepeatType.UNPACKED*/, T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { repeated: { items: { string: { email: true, ignoreEmpty: true } } } }, "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { example: "[\"John.doe@reflex.com\", \"will.smith@reflex.com\"]" } } }, + { no: 22, name: "DefaultSiteLanguageISO6391", kind: "scalar", jsonName: "DefaultSiteLanguageISO6391", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "2", maxLen: "3", languageIso639: true } }, "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "ISO 639 code message language", example: "\"en\"" } } } + ]); + } + create(value?: PartialMessage): Site { + const message = globalThis.Object.create((this.messagePrototype!)); + message.iD = ""; + message.name = ""; + message.organisationID = ""; + message.active = false; + message.photoURI = ""; + message.phones = []; + message.fax = ""; + message.segmentations = []; + message.authorisations = []; + message.units = []; + message.openingRules = []; + message.durationRules = []; + message.capacityRules = []; + message.instructions = []; + message.instructionDocuments = []; + message.carrierInformations = []; + message.calendarIDs = []; + message.roundedPeriodInMinutes = 0n; + message.targetTimeZone = ""; + message.emails = []; + message.defaultSiteLanguageISO6391 = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: Site): Site { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string ID = 1 [json_name = "ID"];*/ 1: + message.iD = reader.string(); + break; + case /* string Name = 2 [json_name = "Name"];*/ 2: + message.name = reader.string(); + break; + case /* string OrganisationID = 3 [json_name = "OrganisationID"];*/ 3: + message.organisationID = reader.string(); + break; + case /* bool Active = 4 [json_name = "Active"];*/ 4: + message.active = reader.bool(); + break; + case /* string PhotoURI = 5 [json_name = "PhotoURI"];*/ 5: + message.photoURI = reader.string(); + break; + case /* api.Address Address = 6 [json_name = "Address"];*/ 6: + message.address = Address.internalBinaryRead(reader, reader.uint32(), options, message.address); + break; + case /* repeated string Phones = 7 [json_name = "Phones"];*/ 7: + message.phones.push(reader.string()); + break; + case /* string Fax = 8 [json_name = "Fax"];*/ 8: + message.fax = reader.string(); + break; + case /* repeated api.Segmentation Segmentations = 9 [json_name = "Segmentations"];*/ 9: + message.segmentations.push(Segmentation.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.ProjectAuthorisation Authorisations = 10 [json_name = "Authorisations"];*/ 10: + message.authorisations.push(ProjectAuthorisation.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.Unit Units = 11 [json_name = "Units"];*/ 11: + message.units.push(Unit.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.OpeningRule OpeningRules = 12 [json_name = "OpeningRules"];*/ 12: + message.openingRules.push(OpeningRule.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.DurationRule DurationRules = 13 [json_name = "DurationRules"];*/ 13: + message.durationRules.push(DurationRule.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.CapacityRule CapacityRules = 14 [json_name = "CapacityRules"];*/ 14: + message.capacityRules.push(CapacityRule.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.LabelByLanguage Instructions = 15 [json_name = "Instructions"];*/ 15: + message.instructions.push(LabelByLanguage.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.Document InstructionDocuments = 16 [json_name = "InstructionDocuments"];*/ 16: + message.instructionDocuments.push(Document.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.CarrierInformation CarrierInformations = 17 [json_name = "CarrierInformations"];*/ 17: + message.carrierInformations.push(CarrierInformation.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated string CalendarIDs = 18 [json_name = "CalendarIDs"];*/ 18: + message.calendarIDs.push(reader.string()); + break; + case /* int64 RoundedPeriodInMinutes = 19 [json_name = "RoundedPeriodInMinutes"];*/ 19: + message.roundedPeriodInMinutes = reader.int64().toBigInt(); + break; + case /* string TargetTimeZone = 20 [json_name = "TargetTimeZone"];*/ 20: + message.targetTimeZone = reader.string(); + break; + case /* repeated string Emails = 21 [json_name = "Emails"];*/ 21: + message.emails.push(reader.string()); + break; + case /* string DefaultSiteLanguageISO6391 = 22 [json_name = "DefaultSiteLanguageISO6391"];*/ 22: + message.defaultSiteLanguageISO6391 = 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: Site, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string ID = 1 [json_name = "ID"]; */ + if (message.iD !== "") + writer.tag(1, WireType.LengthDelimited).string(message.iD); + /* string Name = 2 [json_name = "Name"]; */ + if (message.name !== "") + writer.tag(2, WireType.LengthDelimited).string(message.name); + /* string OrganisationID = 3 [json_name = "OrganisationID"]; */ + if (message.organisationID !== "") + writer.tag(3, WireType.LengthDelimited).string(message.organisationID); + /* bool Active = 4 [json_name = "Active"]; */ + if (message.active !== false) + writer.tag(4, WireType.Varint).bool(message.active); + /* string PhotoURI = 5 [json_name = "PhotoURI"]; */ + if (message.photoURI !== "") + writer.tag(5, WireType.LengthDelimited).string(message.photoURI); + /* api.Address Address = 6 [json_name = "Address"]; */ + if (message.address) + Address.internalBinaryWrite(message.address, writer.tag(6, WireType.LengthDelimited).fork(), options).join(); + /* repeated string Phones = 7 [json_name = "Phones"]; */ + for (let i = 0; i < message.phones.length; i++) + writer.tag(7, WireType.LengthDelimited).string(message.phones[i]); + /* string Fax = 8 [json_name = "Fax"]; */ + if (message.fax !== "") + writer.tag(8, WireType.LengthDelimited).string(message.fax); + /* repeated api.Segmentation Segmentations = 9 [json_name = "Segmentations"]; */ + for (let i = 0; i < message.segmentations.length; i++) + Segmentation.internalBinaryWrite(message.segmentations[i], writer.tag(9, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.ProjectAuthorisation Authorisations = 10 [json_name = "Authorisations"]; */ + for (let i = 0; i < message.authorisations.length; i++) + ProjectAuthorisation.internalBinaryWrite(message.authorisations[i], writer.tag(10, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.Unit Units = 11 [json_name = "Units"]; */ + for (let i = 0; i < message.units.length; i++) + Unit.internalBinaryWrite(message.units[i], writer.tag(11, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.OpeningRule OpeningRules = 12 [json_name = "OpeningRules"]; */ + for (let i = 0; i < message.openingRules.length; i++) + OpeningRule.internalBinaryWrite(message.openingRules[i], writer.tag(12, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.DurationRule DurationRules = 13 [json_name = "DurationRules"]; */ + for (let i = 0; i < message.durationRules.length; i++) + DurationRule.internalBinaryWrite(message.durationRules[i], writer.tag(13, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.CapacityRule CapacityRules = 14 [json_name = "CapacityRules"]; */ + for (let i = 0; i < message.capacityRules.length; i++) + CapacityRule.internalBinaryWrite(message.capacityRules[i], writer.tag(14, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.LabelByLanguage Instructions = 15 [json_name = "Instructions"]; */ + for (let i = 0; i < message.instructions.length; i++) + LabelByLanguage.internalBinaryWrite(message.instructions[i], writer.tag(15, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.Document InstructionDocuments = 16 [json_name = "InstructionDocuments"]; */ + for (let i = 0; i < message.instructionDocuments.length; i++) + Document.internalBinaryWrite(message.instructionDocuments[i], writer.tag(16, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.CarrierInformation CarrierInformations = 17 [json_name = "CarrierInformations"]; */ + for (let i = 0; i < message.carrierInformations.length; i++) + CarrierInformation.internalBinaryWrite(message.carrierInformations[i], writer.tag(17, WireType.LengthDelimited).fork(), options).join(); + /* repeated string CalendarIDs = 18 [json_name = "CalendarIDs"]; */ + for (let i = 0; i < message.calendarIDs.length; i++) + writer.tag(18, WireType.LengthDelimited).string(message.calendarIDs[i]); + /* int64 RoundedPeriodInMinutes = 19 [json_name = "RoundedPeriodInMinutes"]; */ + if (message.roundedPeriodInMinutes !== 0n) + writer.tag(19, WireType.Varint).int64(message.roundedPeriodInMinutes); + /* string TargetTimeZone = 20 [json_name = "TargetTimeZone"]; */ + if (message.targetTimeZone !== "") + writer.tag(20, WireType.LengthDelimited).string(message.targetTimeZone); + /* repeated string Emails = 21 [json_name = "Emails"]; */ + for (let i = 0; i < message.emails.length; i++) + writer.tag(21, WireType.LengthDelimited).string(message.emails[i]); + /* string DefaultSiteLanguageISO6391 = 22 [json_name = "DefaultSiteLanguageISO6391"]; */ + if (message.defaultSiteLanguageISO6391 !== "") + writer.tag(22, WireType.LengthDelimited).string(message.defaultSiteLanguageISO6391); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.Site + */ +export const Site = new Site$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class CreateSiteRequest$Type extends MessageType { + constructor() { + super("api.CreateSiteRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestOrganisationHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "SiteID", kind: "scalar", jsonName: "SiteID", T: 9 /*ScalarType.STRING*/ }, + { no: 3, name: "SiteName", kind: "scalar", jsonName: "SiteName", T: 9 /*ScalarType.STRING*/ }, + { no: 4, name: "Emails", kind: "scalar", jsonName: "Emails", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1", email: true } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header,Emails"] } } }); + } + create(value?: PartialMessage): CreateSiteRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + message.siteID = ""; + message.siteName = ""; + message.emails = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: CreateSiteRequest): CreateSiteRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestOrganisationHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestOrganisationHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* string SiteID = 2 [json_name = "SiteID"];*/ 2: + message.siteID = reader.string(); + break; + case /* string SiteName = 3 [json_name = "SiteName"];*/ 3: + message.siteName = reader.string(); + break; + case /* string Emails = 4 [json_name = "Emails"];*/ 4: + message.emails = 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: CreateSiteRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestOrganisationHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestOrganisationHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* string SiteID = 2 [json_name = "SiteID"]; */ + if (message.siteID !== "") + writer.tag(2, WireType.LengthDelimited).string(message.siteID); + /* string SiteName = 3 [json_name = "SiteName"]; */ + if (message.siteName !== "") + writer.tag(3, WireType.LengthDelimited).string(message.siteName); + /* string Emails = 4 [json_name = "Emails"]; */ + if (message.emails !== "") + writer.tag(4, WireType.LengthDelimited).string(message.emails); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.CreateSiteRequest + */ +export const CreateSiteRequest = new CreateSiteRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class CreateSiteResponse$Type extends MessageType { + constructor() { + super("api.CreateSiteResponse", [ + { no: 1, name: "Site", kind: "message", jsonName: "Site", T: () => Site, options: { "validate.rules": { message: { required: true } } } } + ]); + } + create(value?: PartialMessage): CreateSiteResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: CreateSiteResponse): CreateSiteResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.Site Site = 1 [json_name = "Site"];*/ 1: + message.site = Site.internalBinaryRead(reader, reader.uint32(), options, message.site); + 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: CreateSiteResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.Site Site = 1 [json_name = "Site"]; */ + if (message.site) + Site.internalBinaryWrite(message.site, 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.CreateSiteResponse + */ +export const CreateSiteResponse = new CreateSiteResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class GetSiteRequest$Type extends MessageType { + constructor() { + super("api.GetSiteRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestOrganisationHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "scalar", jsonName: "ID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID"] } } }); + } + create(value?: PartialMessage): GetSiteRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + message.iD = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GetSiteRequest): GetSiteRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestOrganisationHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestOrganisationHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* string ID = 2 [json_name = "ID"];*/ 2: + message.iD = 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: GetSiteRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestOrganisationHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestOrganisationHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* string ID = 2 [json_name = "ID"]; */ + if (message.iD !== "") + writer.tag(2, WireType.LengthDelimited).string(message.iD); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.GetSiteRequest + */ +export const GetSiteRequest = new GetSiteRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class GetSiteResponse$Type extends MessageType { + constructor() { + super("api.GetSiteResponse", [ + { no: 1, name: "Site", kind: "message", jsonName: "Site", T: () => Site, options: { "validate.rules": { message: { required: true } } } } + ]); + } + create(value?: PartialMessage): GetSiteResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GetSiteResponse): GetSiteResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.Site Site = 1 [json_name = "Site"];*/ 1: + message.site = Site.internalBinaryRead(reader, reader.uint32(), options, message.site); + 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: GetSiteResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.Site Site = 1 [json_name = "Site"]; */ + if (message.site) + Site.internalBinaryWrite(message.site, 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.GetSiteResponse + */ +export const GetSiteResponse = new GetSiteResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class ListSiteRequest$Type extends MessageType { + constructor() { + super("api.ListSiteRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestOrganisationHeader, options: { "validate.rules": { message: { required: true } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header"] } } }); + } + create(value?: PartialMessage): ListSiteRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ListSiteRequest): ListSiteRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestOrganisationHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestOrganisationHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + 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: ListSiteRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestOrganisationHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestOrganisationHeader.internalBinaryWrite(message.header, 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.ListSiteRequest + */ +export const ListSiteRequest = new ListSiteRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class ListSiteResponse$Type extends MessageType { + constructor() { + super("api.ListSiteResponse", [ + { no: 1, name: "Sites", kind: "message", jsonName: "Sites", repeat: 1 /*RepeatType.PACKED*/, T: () => Site } + ]); + } + create(value?: PartialMessage): ListSiteResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + message.sites = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ListSiteResponse): ListSiteResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* repeated api.Site Sites = 1 [json_name = "Sites"];*/ 1: + message.sites.push(Site.internalBinaryRead(reader, reader.uint32(), options)); + 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: ListSiteResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* repeated api.Site Sites = 1 [json_name = "Sites"]; */ + for (let i = 0; i < message.sites.length; i++) + Site.internalBinaryWrite(message.sites[i], 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.ListSiteResponse + */ +export const ListSiteResponse = new ListSiteResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class UpdateSiteRequest$Type extends MessageType { + constructor() { + super("api.UpdateSiteRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestOrganisationHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "scalar", jsonName: "ID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } }, + { no: 3, name: "Name", kind: "scalar", jsonName: "Name", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } }, + { no: 4, name: "Active", kind: "scalar", jsonName: "Active", T: 8 /*ScalarType.BOOL*/ }, + { no: 5, name: "PhotoURI", kind: "scalar", jsonName: "PhotoURI", T: 9 /*ScalarType.STRING*/ }, + { no: 6, name: "Address", kind: "message", jsonName: "Address", T: () => Address }, + { no: 7, name: "Phones", kind: "scalar", jsonName: "Phones", repeat: 2 /*RepeatType.UNPACKED*/, T: 9 /*ScalarType.STRING*/, options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { example: "[\"06 00 00 00 00\", \"+49 00 0000 0000\"]" } } }, + { no: 8, name: "Fax", kind: "scalar", jsonName: "Fax", T: 9 /*ScalarType.STRING*/, options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { example: "[\"06 00 00 00 00\", \"+49 00 0000 0000\"]" } } }, + { no: 9, name: "Segmentations", kind: "message", jsonName: "Segmentations", repeat: 1 /*RepeatType.PACKED*/, T: () => Segmentation }, + { no: 10, name: "Authorisations", kind: "message", jsonName: "Authorisations", repeat: 1 /*RepeatType.PACKED*/, T: () => ProjectAuthorisation }, + { no: 11, name: "Units", kind: "message", jsonName: "Units", repeat: 1 /*RepeatType.PACKED*/, T: () => Unit, options: { "validate.rules": { repeated: { minItems: "1" } } } }, + { no: 12, name: "OpeningRules", kind: "message", jsonName: "OpeningRules", repeat: 1 /*RepeatType.PACKED*/, T: () => OpeningRule }, + { no: 13, name: "DurationRules", kind: "message", jsonName: "DurationRules", repeat: 1 /*RepeatType.PACKED*/, T: () => DurationRule }, + { no: 14, name: "CapacityRules", kind: "message", jsonName: "CapacityRules", repeat: 1 /*RepeatType.PACKED*/, T: () => CapacityRule }, + { no: 15, name: "Instructions", kind: "message", jsonName: "Instructions", repeat: 1 /*RepeatType.PACKED*/, T: () => LabelByLanguage, options: { "api.language": true, "api.aggKey": "LanguageCodeISO6391" } }, + { no: 16, name: "InstructionDocuments", kind: "message", jsonName: "InstructionDocuments", repeat: 1 /*RepeatType.PACKED*/, T: () => Document }, + { no: 17, name: "CarrierInformations", kind: "message", jsonName: "CarrierInformations", repeat: 1 /*RepeatType.PACKED*/, T: () => CarrierInformation }, + { no: 18, name: "CalendarIDs", kind: "scalar", jsonName: "CalendarIDs", repeat: 2 /*RepeatType.UNPACKED*/, T: 9 /*ScalarType.STRING*/ }, + { no: 19, name: "RoundedPeriodInMinutes", kind: "scalar", jsonName: "RoundedPeriodInMinutes", T: 3 /*ScalarType.INT64*/, L: 0 /*LongType.BIGINT*/ }, + { no: 20, name: "TargetTimeZone", kind: "scalar", jsonName: "TargetTimeZone", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1", tzData: true } }, "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "Target site time zone format", example: "\"Europe/Paris\"" } } }, + { no: 21, name: "Emails", kind: "scalar", jsonName: "Emails", repeat: 2 /*RepeatType.UNPACKED*/, T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { repeated: { items: { string: { email: true, ignoreEmpty: true } } } }, "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { example: "[\"John.doe@reflex.com\", \"will.smith@reflex.com\"]" } } }, + { no: 22, name: "DefaultSiteLanguageISO6391", kind: "scalar", jsonName: "DefaultSiteLanguageISO6391", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "2", maxLen: "3", languageIso639: true } }, "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "ISO 639 code message language", example: "\"en\"" } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID"] } } }); + } + create(value?: PartialMessage): UpdateSiteRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + message.iD = ""; + message.name = ""; + message.active = false; + message.photoURI = ""; + message.phones = []; + message.fax = ""; + message.segmentations = []; + message.authorisations = []; + message.units = []; + message.openingRules = []; + message.durationRules = []; + message.capacityRules = []; + message.instructions = []; + message.instructionDocuments = []; + message.carrierInformations = []; + message.calendarIDs = []; + message.roundedPeriodInMinutes = 0n; + message.targetTimeZone = ""; + message.emails = []; + message.defaultSiteLanguageISO6391 = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: UpdateSiteRequest): UpdateSiteRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestOrganisationHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestOrganisationHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* string ID = 2 [json_name = "ID"];*/ 2: + message.iD = reader.string(); + break; + case /* string Name = 3 [json_name = "Name"];*/ 3: + message.name = reader.string(); + break; + case /* bool Active = 4 [json_name = "Active"];*/ 4: + message.active = reader.bool(); + break; + case /* string PhotoURI = 5 [json_name = "PhotoURI"];*/ 5: + message.photoURI = reader.string(); + break; + case /* api.Address Address = 6 [json_name = "Address"];*/ 6: + message.address = Address.internalBinaryRead(reader, reader.uint32(), options, message.address); + break; + case /* repeated string Phones = 7 [json_name = "Phones"];*/ 7: + message.phones.push(reader.string()); + break; + case /* string Fax = 8 [json_name = "Fax"];*/ 8: + message.fax = reader.string(); + break; + case /* repeated api.Segmentation Segmentations = 9 [json_name = "Segmentations"];*/ 9: + message.segmentations.push(Segmentation.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.ProjectAuthorisation Authorisations = 10 [json_name = "Authorisations"];*/ 10: + message.authorisations.push(ProjectAuthorisation.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.Unit Units = 11 [json_name = "Units"];*/ 11: + message.units.push(Unit.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.OpeningRule OpeningRules = 12 [json_name = "OpeningRules"];*/ 12: + message.openingRules.push(OpeningRule.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.DurationRule DurationRules = 13 [json_name = "DurationRules"];*/ 13: + message.durationRules.push(DurationRule.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.CapacityRule CapacityRules = 14 [json_name = "CapacityRules"];*/ 14: + message.capacityRules.push(CapacityRule.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.LabelByLanguage Instructions = 15 [json_name = "Instructions"];*/ 15: + message.instructions.push(LabelByLanguage.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.Document InstructionDocuments = 16 [json_name = "InstructionDocuments"];*/ 16: + message.instructionDocuments.push(Document.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.CarrierInformation CarrierInformations = 17 [json_name = "CarrierInformations"];*/ 17: + message.carrierInformations.push(CarrierInformation.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated string CalendarIDs = 18 [json_name = "CalendarIDs"];*/ 18: + message.calendarIDs.push(reader.string()); + break; + case /* int64 RoundedPeriodInMinutes = 19 [json_name = "RoundedPeriodInMinutes"];*/ 19: + message.roundedPeriodInMinutes = reader.int64().toBigInt(); + break; + case /* string TargetTimeZone = 20 [json_name = "TargetTimeZone"];*/ 20: + message.targetTimeZone = reader.string(); + break; + case /* repeated string Emails = 21 [json_name = "Emails"];*/ 21: + message.emails.push(reader.string()); + break; + case /* string DefaultSiteLanguageISO6391 = 22 [json_name = "DefaultSiteLanguageISO6391"];*/ 22: + message.defaultSiteLanguageISO6391 = 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: UpdateSiteRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestOrganisationHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestOrganisationHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* string ID = 2 [json_name = "ID"]; */ + if (message.iD !== "") + writer.tag(2, WireType.LengthDelimited).string(message.iD); + /* string Name = 3 [json_name = "Name"]; */ + if (message.name !== "") + writer.tag(3, WireType.LengthDelimited).string(message.name); + /* bool Active = 4 [json_name = "Active"]; */ + if (message.active !== false) + writer.tag(4, WireType.Varint).bool(message.active); + /* string PhotoURI = 5 [json_name = "PhotoURI"]; */ + if (message.photoURI !== "") + writer.tag(5, WireType.LengthDelimited).string(message.photoURI); + /* api.Address Address = 6 [json_name = "Address"]; */ + if (message.address) + Address.internalBinaryWrite(message.address, writer.tag(6, WireType.LengthDelimited).fork(), options).join(); + /* repeated string Phones = 7 [json_name = "Phones"]; */ + for (let i = 0; i < message.phones.length; i++) + writer.tag(7, WireType.LengthDelimited).string(message.phones[i]); + /* string Fax = 8 [json_name = "Fax"]; */ + if (message.fax !== "") + writer.tag(8, WireType.LengthDelimited).string(message.fax); + /* repeated api.Segmentation Segmentations = 9 [json_name = "Segmentations"]; */ + for (let i = 0; i < message.segmentations.length; i++) + Segmentation.internalBinaryWrite(message.segmentations[i], writer.tag(9, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.ProjectAuthorisation Authorisations = 10 [json_name = "Authorisations"]; */ + for (let i = 0; i < message.authorisations.length; i++) + ProjectAuthorisation.internalBinaryWrite(message.authorisations[i], writer.tag(10, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.Unit Units = 11 [json_name = "Units"]; */ + for (let i = 0; i < message.units.length; i++) + Unit.internalBinaryWrite(message.units[i], writer.tag(11, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.OpeningRule OpeningRules = 12 [json_name = "OpeningRules"]; */ + for (let i = 0; i < message.openingRules.length; i++) + OpeningRule.internalBinaryWrite(message.openingRules[i], writer.tag(12, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.DurationRule DurationRules = 13 [json_name = "DurationRules"]; */ + for (let i = 0; i < message.durationRules.length; i++) + DurationRule.internalBinaryWrite(message.durationRules[i], writer.tag(13, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.CapacityRule CapacityRules = 14 [json_name = "CapacityRules"]; */ + for (let i = 0; i < message.capacityRules.length; i++) + CapacityRule.internalBinaryWrite(message.capacityRules[i], writer.tag(14, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.LabelByLanguage Instructions = 15 [json_name = "Instructions"]; */ + for (let i = 0; i < message.instructions.length; i++) + LabelByLanguage.internalBinaryWrite(message.instructions[i], writer.tag(15, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.Document InstructionDocuments = 16 [json_name = "InstructionDocuments"]; */ + for (let i = 0; i < message.instructionDocuments.length; i++) + Document.internalBinaryWrite(message.instructionDocuments[i], writer.tag(16, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.CarrierInformation CarrierInformations = 17 [json_name = "CarrierInformations"]; */ + for (let i = 0; i < message.carrierInformations.length; i++) + CarrierInformation.internalBinaryWrite(message.carrierInformations[i], writer.tag(17, WireType.LengthDelimited).fork(), options).join(); + /* repeated string CalendarIDs = 18 [json_name = "CalendarIDs"]; */ + for (let i = 0; i < message.calendarIDs.length; i++) + writer.tag(18, WireType.LengthDelimited).string(message.calendarIDs[i]); + /* int64 RoundedPeriodInMinutes = 19 [json_name = "RoundedPeriodInMinutes"]; */ + if (message.roundedPeriodInMinutes !== 0n) + writer.tag(19, WireType.Varint).int64(message.roundedPeriodInMinutes); + /* string TargetTimeZone = 20 [json_name = "TargetTimeZone"]; */ + if (message.targetTimeZone !== "") + writer.tag(20, WireType.LengthDelimited).string(message.targetTimeZone); + /* repeated string Emails = 21 [json_name = "Emails"]; */ + for (let i = 0; i < message.emails.length; i++) + writer.tag(21, WireType.LengthDelimited).string(message.emails[i]); + /* string DefaultSiteLanguageISO6391 = 22 [json_name = "DefaultSiteLanguageISO6391"]; */ + if (message.defaultSiteLanguageISO6391 !== "") + writer.tag(22, WireType.LengthDelimited).string(message.defaultSiteLanguageISO6391); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.UpdateSiteRequest + */ +export const UpdateSiteRequest = new UpdateSiteRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class UpdateSiteResponse$Type extends MessageType { + constructor() { + super("api.UpdateSiteResponse", [ + { no: 1, name: "Site", kind: "message", jsonName: "Site", T: () => Site, options: { "validate.rules": { message: { required: true } } } } + ]); + } + create(value?: PartialMessage): UpdateSiteResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: UpdateSiteResponse): UpdateSiteResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.Site Site = 1 [json_name = "Site"];*/ 1: + message.site = Site.internalBinaryRead(reader, reader.uint32(), options, message.site); + 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: UpdateSiteResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.Site Site = 1 [json_name = "Site"]; */ + if (message.site) + Site.internalBinaryWrite(message.site, 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.UpdateSiteResponse + */ +export const UpdateSiteResponse = new UpdateSiteResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class DeleteSiteRequest$Type extends MessageType { + constructor() { + super("api.DeleteSiteRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestOrganisationHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "ID", kind: "scalar", jsonName: "ID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID"] } } }); + } + create(value?: PartialMessage): DeleteSiteRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + message.iD = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: DeleteSiteRequest): DeleteSiteRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestOrganisationHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestOrganisationHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* string ID = 2 [json_name = "ID"];*/ 2: + message.iD = 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: DeleteSiteRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestOrganisationHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestOrganisationHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* string ID = 2 [json_name = "ID"]; */ + if (message.iD !== "") + writer.tag(2, WireType.LengthDelimited).string(message.iD); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.DeleteSiteRequest + */ +export const DeleteSiteRequest = new DeleteSiteRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class DeleteSiteResponse$Type extends MessageType { + constructor() { + super("api.DeleteSiteResponse", []); + } + create(value?: PartialMessage): DeleteSiteResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: DeleteSiteResponse): DeleteSiteResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + 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: DeleteSiteResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.DeleteSiteResponse + */ +export const DeleteSiteResponse = new DeleteSiteResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class GetAvailableSlotsRequest$Type extends MessageType { + constructor() { + super("api.GetAvailableSlotsRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "AppointmentType", kind: "enum", jsonName: "AppointmentType", T: () => ["api.AppointmentType", AppointmentType], options: { "validate.rules": { enum: { definedOnly: true } } } }, + { no: 3, name: "Commissions", kind: "message", jsonName: "Commissions", repeat: 1 /*RepeatType.PACKED*/, T: () => Commission, options: { "validate.rules": { repeated: { minItems: "1" } } } }, + { no: 4, name: "Segmentations", kind: "message", jsonName: "Segmentations", repeat: 1 /*RepeatType.PACKED*/, T: () => Segmentation }, + { no: 5, name: "StartDate", kind: "scalar", jsonName: "StartDate", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { pattern: "^20[0-9]{2}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" } } } }, + { no: 6, name: "EndDate", kind: "scalar", jsonName: "EndDate", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { pattern: "^20[0-9]{2}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "DurationInMinutes"] } } }); + } + create(value?: PartialMessage): GetAvailableSlotsRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + message.appointmentType = 0; + message.commissions = []; + message.segmentations = []; + message.startDate = ""; + message.endDate = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GetAvailableSlotsRequest): GetAvailableSlotsRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.AppointmentType AppointmentType = 2 [json_name = "AppointmentType"];*/ 2: + message.appointmentType = reader.int32(); + break; + case /* repeated api.Commission Commissions = 3 [json_name = "Commissions"];*/ 3: + message.commissions.push(Commission.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.Segmentation Segmentations = 4 [json_name = "Segmentations"];*/ 4: + message.segmentations.push(Segmentation.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* string StartDate = 5 [json_name = "StartDate"];*/ 5: + message.startDate = reader.string(); + break; + case /* string EndDate = 6 [json_name = "EndDate"];*/ 6: + message.endDate = 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: GetAvailableSlotsRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.AppointmentType AppointmentType = 2 [json_name = "AppointmentType"]; */ + if (message.appointmentType !== 0) + writer.tag(2, WireType.Varint).int32(message.appointmentType); + /* repeated api.Commission Commissions = 3 [json_name = "Commissions"]; */ + for (let i = 0; i < message.commissions.length; i++) + Commission.internalBinaryWrite(message.commissions[i], writer.tag(3, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.Segmentation Segmentations = 4 [json_name = "Segmentations"]; */ + for (let i = 0; i < message.segmentations.length; i++) + Segmentation.internalBinaryWrite(message.segmentations[i], writer.tag(4, WireType.LengthDelimited).fork(), options).join(); + /* string StartDate = 5 [json_name = "StartDate"]; */ + if (message.startDate !== "") + writer.tag(5, WireType.LengthDelimited).string(message.startDate); + /* string EndDate = 6 [json_name = "EndDate"]; */ + if (message.endDate !== "") + writer.tag(6, WireType.LengthDelimited).string(message.endDate); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.GetAvailableSlotsRequest + */ +export const GetAvailableSlotsRequest = new GetAvailableSlotsRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class GetAvailableSlotsResponse$Type extends MessageType { + constructor() { + super("api.GetAvailableSlotsResponse", [ + { no: 1, name: "Slots", kind: "message", jsonName: "Slots", repeat: 1 /*RepeatType.PACKED*/, T: () => Slot } + ]); + } + create(value?: PartialMessage): GetAvailableSlotsResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + message.slots = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GetAvailableSlotsResponse): GetAvailableSlotsResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* repeated api.Slot Slots = 1 [json_name = "Slots"];*/ 1: + message.slots.push(Slot.internalBinaryRead(reader, reader.uint32(), options)); + 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: GetAvailableSlotsResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* repeated api.Slot Slots = 1 [json_name = "Slots"]; */ + for (let i = 0; i < message.slots.length; i++) + Slot.internalBinaryWrite(message.slots[i], 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.GetAvailableSlotsResponse + */ +export const GetAvailableSlotsResponse = new GetAvailableSlotsResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class BookAppointmentRequest$Type extends MessageType { + constructor() { + super("api.BookAppointmentRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "AppointmentType", kind: "enum", jsonName: "AppointmentType", T: () => ["api.AppointmentType", AppointmentType], options: { "validate.rules": { enum: { definedOnly: true } } } }, + { no: 3, name: "Commissions", kind: "message", jsonName: "Commissions", repeat: 1 /*RepeatType.PACKED*/, T: () => Commission, options: { "validate.rules": { repeated: { minItems: "1" } } } }, + { no: 4, name: "Segmentations", kind: "message", jsonName: "Segmentations", repeat: 1 /*RepeatType.PACKED*/, T: () => Segmentation }, + { no: 5, name: "CarrierInformation", kind: "message", jsonName: "CarrierInformation", repeat: 1 /*RepeatType.PACKED*/, T: () => CarrierInformation }, + { no: 6, name: "Slot", kind: "message", jsonName: "Slot", T: () => Slot }, + { no: 8, name: "Emails", kind: "scalar", jsonName: "Emails", repeat: 2 /*RepeatType.UNPACKED*/, T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { repeated: { minItems: "1", items: { string: { email: true, ignoreEmpty: true } } } }, "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "Must be a valid email address", example: "[\"John.doe@reflex.com\", \"will.smith@reflex.com\"]" } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "AppointmentType", "Commissions", "QuantitiesByUnits", "Segmentations", "CarrierInformation"] } } }); + } + create(value?: PartialMessage): BookAppointmentRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + message.appointmentType = 0; + message.commissions = []; + message.segmentations = []; + message.carrierInformation = []; + message.emails = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: BookAppointmentRequest): BookAppointmentRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* api.AppointmentType AppointmentType = 2 [json_name = "AppointmentType"];*/ 2: + message.appointmentType = reader.int32(); + break; + case /* repeated api.Commission Commissions = 3 [json_name = "Commissions"];*/ 3: + message.commissions.push(Commission.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.Segmentation Segmentations = 4 [json_name = "Segmentations"];*/ 4: + message.segmentations.push(Segmentation.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.CarrierInformation CarrierInformation = 5 [json_name = "CarrierInformation"];*/ 5: + message.carrierInformation.push(CarrierInformation.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* api.Slot Slot = 6 [json_name = "Slot"];*/ 6: + message.slot = Slot.internalBinaryRead(reader, reader.uint32(), options, message.slot); + break; + case /* repeated string Emails = 8 [json_name = "Emails"];*/ 8: + message.emails.push(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: BookAppointmentRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.AppointmentType AppointmentType = 2 [json_name = "AppointmentType"]; */ + if (message.appointmentType !== 0) + writer.tag(2, WireType.Varint).int32(message.appointmentType); + /* repeated api.Commission Commissions = 3 [json_name = "Commissions"]; */ + for (let i = 0; i < message.commissions.length; i++) + Commission.internalBinaryWrite(message.commissions[i], writer.tag(3, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.Segmentation Segmentations = 4 [json_name = "Segmentations"]; */ + for (let i = 0; i < message.segmentations.length; i++) + Segmentation.internalBinaryWrite(message.segmentations[i], writer.tag(4, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.CarrierInformation CarrierInformation = 5 [json_name = "CarrierInformation"]; */ + for (let i = 0; i < message.carrierInformation.length; i++) + CarrierInformation.internalBinaryWrite(message.carrierInformation[i], writer.tag(5, WireType.LengthDelimited).fork(), options).join(); + /* api.Slot Slot = 6 [json_name = "Slot"]; */ + if (message.slot) + Slot.internalBinaryWrite(message.slot, writer.tag(6, WireType.LengthDelimited).fork(), options).join(); + /* repeated string Emails = 8 [json_name = "Emails"]; */ + for (let i = 0; i < message.emails.length; i++) + writer.tag(8, WireType.LengthDelimited).string(message.emails[i]); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.BookAppointmentRequest + */ +export const BookAppointmentRequest = new BookAppointmentRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class BookAppointmentResponse$Type extends MessageType { + constructor() { + super("api.BookAppointmentResponse", [ + { no: 1, name: "AppointmentID", kind: "scalar", jsonName: "AppointmentID", T: 9 /*ScalarType.STRING*/ } + ]); + } + create(value?: PartialMessage): BookAppointmentResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + message.appointmentID = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: BookAppointmentResponse): BookAppointmentResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string AppointmentID = 1 [json_name = "AppointmentID"];*/ 1: + message.appointmentID = 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: BookAppointmentResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string AppointmentID = 1 [json_name = "AppointmentID"]; */ + if (message.appointmentID !== "") + writer.tag(1, WireType.LengthDelimited).string(message.appointmentID); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.BookAppointmentResponse + */ +export const BookAppointmentResponse = new BookAppointmentResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class CancelAppointmentRequest$Type extends MessageType { + constructor() { + super("api.CancelAppointmentRequest", [ + { no: 1, name: "Header", kind: "message", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } }, + { no: 2, name: "AppointmentID", kind: "scalar", jsonName: "AppointmentID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "AppointmentID"] } } }); + } + create(value?: PartialMessage): CancelAppointmentRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + message.appointmentID = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: CancelAppointmentRequest): CancelAppointmentRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RequestSiteHeader Header = 1 [json_name = "Header"];*/ 1: + message.header = RequestSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.header); + break; + case /* string AppointmentID = 2 [json_name = "AppointmentID"];*/ 2: + message.appointmentID = 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: CancelAppointmentRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RequestSiteHeader Header = 1 [json_name = "Header"]; */ + if (message.header) + RequestSiteHeader.internalBinaryWrite(message.header, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* string AppointmentID = 2 [json_name = "AppointmentID"]; */ + if (message.appointmentID !== "") + writer.tag(2, WireType.LengthDelimited).string(message.appointmentID); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.CancelAppointmentRequest + */ +export const CancelAppointmentRequest = new CancelAppointmentRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class CancelAppointmentResponse$Type extends MessageType { + constructor() { + super("api.CancelAppointmentResponse", [ + { no: 1, name: "AppointmentID", kind: "scalar", jsonName: "AppointmentID", T: 9 /*ScalarType.STRING*/ } + ]); + } + create(value?: PartialMessage): CancelAppointmentResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + message.appointmentID = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: CancelAppointmentResponse): CancelAppointmentResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string AppointmentID = 1 [json_name = "AppointmentID"];*/ 1: + message.appointmentID = 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: CancelAppointmentResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string AppointmentID = 1 [json_name = "AppointmentID"]; */ + if (message.appointmentID !== "") + writer.tag(1, WireType.LengthDelimited).string(message.appointmentID); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.CancelAppointmentResponse + */ +export const CancelAppointmentResponse = new CancelAppointmentResponse$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class ListUserSitesRequest$Type extends MessageType { + constructor() { + super("api.ListUserSitesRequest", [ + { no: 1, name: "ProjectID", kind: "scalar", jsonName: "ProjectID", repeat: 2 /*RepeatType.UNPACKED*/, T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { repeated: { minItems: "1", items: { string: { minLen: "1" } } } } } } + ], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": {} }); + } + create(value?: PartialMessage): ListUserSitesRequest { + const message = globalThis.Object.create((this.messagePrototype!)); + message.projectID = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ListUserSitesRequest): ListUserSitesRequest { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* repeated string ProjectID = 1 [json_name = "ProjectID"];*/ 1: + message.projectID.push(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: ListUserSitesRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* repeated string ProjectID = 1 [json_name = "ProjectID"]; */ + for (let i = 0; i < message.projectID.length; i++) + writer.tag(1, WireType.LengthDelimited).string(message.projectID[i]); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.ListUserSitesRequest + */ +export const ListUserSitesRequest = new ListUserSitesRequest$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class ListUserSitesResponse$Type extends MessageType { + constructor() { + super("api.ListUserSitesResponse", [ + { no: 1, name: "Sites", kind: "message", jsonName: "Sites", repeat: 1 /*RepeatType.PACKED*/, T: () => Site } + ]); + } + create(value?: PartialMessage): ListUserSitesResponse { + const message = globalThis.Object.create((this.messagePrototype!)); + message.sites = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ListUserSitesResponse): ListUserSitesResponse { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* repeated api.Site Sites = 1 [json_name = "Sites"];*/ 1: + message.sites.push(Site.internalBinaryRead(reader, reader.uint32(), options)); + 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: ListUserSitesResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* repeated api.Site Sites = 1 [json_name = "Sites"]; */ + for (let i = 0; i < message.sites.length; i++) + Site.internalBinaryWrite(message.sites[i], 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.ListUserSitesResponse + */ +export const ListUserSitesResponse = new ListUserSitesResponse$Type(); +/** + * @generated ServiceType for protobuf service api.SiteService + */ +export const SiteService = new ServiceType("api.SiteService", [ + { name: "Create", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Site"], description: "Create a site" }, "api.rscType": "Organisation", "api.roles": "", "api.moduleID": "slotbooking", "google.api.method_visibility": { restriction: "SDK" } }, I: CreateSiteRequest, O: CreateSiteResponse }, + { name: "Get", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Site"], description: "Get a site" }, "api.rscType": "Site", "api.roles": "Platform.Site", "api.moduleID": "slotbooking", "google.api.method_visibility": { restriction: "SDK" } }, I: GetSiteRequest, O: GetSiteResponse }, + { name: "List", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Site"], description: "List site of an organisation" }, "api.rscType": "Organisation", "api.roles": "", "api.moduleID": "slotbooking", "google.api.method_visibility": { restriction: "SDK" } }, I: ListSiteRequest, O: ListSiteResponse }, + { name: "Update", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Site"], description: "Update a site" }, "api.rscType": "Site", "api.roles": "", "api.moduleID": "slotbooking", "google.api.method_visibility": { restriction: "SDK" } }, I: UpdateSiteRequest, O: UpdateSiteResponse }, + { name: "Delete", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Site"], description: "Delete a site" }, "api.rscType": "Organisation", "api.roles": "", "api.moduleID": "slotbooking", "google.api.method_visibility": { restriction: "SDK" } }, I: DeleteSiteRequest, O: DeleteSiteResponse }, + { name: "GetAvailableSlots", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Site"], description: "Get available slots to book an appointment on the site." }, "api.rscType": "Site", "api.roles": "", "google.api.method_visibility": { restriction: "SDK" } }, I: GetAvailableSlotsRequest, O: GetAvailableSlotsResponse }, + { name: "ListUserSites", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Site"], description: "List sites authorized for a user according to its permissions." }, "api.rscType": "Platform", "api.roles": "Platform.Site", "google.api.method_visibility": { restriction: "SDK" } }, I: ListUserSitesRequest, O: ListUserSitesResponse }, + { name: "BookAppointment", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Site,Appointment"], description: "Book an appointment on the site." }, "api.rscType": "Site", "api.roles": "", "google.api.method_visibility": { restriction: "SDK" } }, I: BookAppointmentRequest, O: BookAppointmentResponse }, + { name: "CancelAppointment", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Site,Appointment"], description: "Cancel an appointment on the site." }, "api.rscType": "Site", "api.roles": "", "google.api.method_visibility": { restriction: "SDK" } }, I: CancelAppointmentRequest, O: CancelAppointmentResponse } +], { "api.k8sService": "slotbookingtype-server" }); diff --git a/slotbooking.ts b/slotbooking.ts new file mode 100644 index 00000000..52fc41a2 --- /dev/null +++ b/slotbooking.ts @@ -0,0 +1,2287 @@ +// @generated by protobuf-ts 2.9.6 +// @generated from protobuf file "slotbooking.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 { WeekDay } from "./shared"; +import { LabelByLanguage } from "./shared"; +/** + * @generated from protobuf message api.Unit + */ +export interface Unit { + /** + * @generated from protobuf field: string UnitID = 1 [json_name = "UnitID"]; + */ + unitID: string; + /** + * @generated from protobuf field: repeated api.LabelByLanguage Labels = 2 [json_name = "Labels"]; + */ + labels: LabelByLanguage[]; // @option language +} +/** + * @generated from protobuf message api.QuantityByUnit + */ +export interface QuantityByUnit { + /** + * referring to the Unit ID defined by the Site + * + * @generated from protobuf field: api.Unit UnitID = 1 [json_name = "UnitID"]; + */ + unitID?: Unit; + /** + * Number of the specified unit + * + * @generated from protobuf field: double Value = 2 [json_name = "Value"]; + */ + value: number; +} +/** + * @generated from protobuf message api.Period + */ +export interface Period { + /** + * @generated from protobuf field: int64 Value = 1 [json_name = "Value"]; + */ + value: bigint; + /** + * @generated from protobuf field: api.PeriodUnit Unit = 2 [json_name = "Unit"]; + */ + unit: PeriodUnit; +} +/** + * @generated from protobuf message api.Slot + */ +export interface Slot { + /** + * Slot start date time, + * format yyyy-mm-jjThh:mm:ss (iso8601 without timezone, because the time zone is defined by the site on which the slot is booked) + * + * @generated from protobuf field: string StartDateTime = 1 [json_name = "StartDateTime"]; + */ + startDateTime: string; + /** + * Slot duration in minutes. + * + * @generated from protobuf field: int64 DurationInMinutes = 3 [json_name = "DurationInMinutes"]; + */ + durationInMinutes: bigint; +} +/** + * Segmentations + * + * @generated from protobuf message api.Segmentation + */ +export interface Segmentation { + /** + * Identifier of the Segmentation + * + * @generated from protobuf field: string SegmentationID = 1 [json_name = "SegmentationID"]; + */ + segmentationID: string; + /** + * Translated labels of the Segmentation + * + * @generated from protobuf field: repeated api.LabelByLanguage SegmentationLabel = 2 [json_name = "SegmentationLabel"]; + */ + segmentationLabel: LabelByLanguage[]; // @option language + /** + * Possible values of the Segmentation + * + * @generated from protobuf field: repeated api.SegmentationValue Values = 3 [json_name = "Values"]; + */ + values: SegmentationValue[]; +} +/** + * @generated from protobuf message api.SegmentationValue + */ +export interface SegmentationValue { + /** + * Identifier of the Segmentation value + * + * @generated from protobuf field: string ID = 1 [json_name = "ID"]; + */ + iD: string; + /** + * Translated labels of the Segmentation value + * + * @generated from protobuf field: repeated api.LabelByLanguage Label = 2 [json_name = "Label"]; + */ + label: LabelByLanguage[]; // @option language +} +/** + * Rules + * + * @generated from protobuf message api.OpeningRule + */ +export interface OpeningRule { + /** + * Start date of the opening rule validity, format yyyy-mm-jj + * + * @generated from protobuf field: string StartDate = 1 [json_name = "StartDate"]; + */ + startDate: string; + /** + * End date of the opening rule validity, format yyyy-mm-jj + * + * @generated from protobuf field: string EndDate = 2 [json_name = "EndDate"]; + */ + endDate: string; + /** + * Definition of the opening rules by week day + * + * @generated from protobuf field: repeated api.OpeningDefinition OpeningDays = 3 [json_name = "OpeningDays"]; + */ + openingDays: OpeningDefinition[]; + /** + * The identifier of the calendar to be used within this period of time + * + * @generated from protobuf field: string CalendarID = 4 [json_name = "CalendarID"]; + */ + calendarID: string; + /** + * Label of the Rule + * + * @generated from protobuf field: string Label = 5 [json_name = "Label"]; + */ + label: string; +} +/** + * @generated from protobuf message api.OpeningDefinition + */ +export interface OpeningDefinition { + /** + * Day of the week + * + * @generated from protobuf field: api.WeekDay WeekDay = 1 [json_name = "WeekDay"]; + */ + weekDay: WeekDay; + /** + * Opening hours definition according to filters + * + * @generated from protobuf field: repeated api.OpeningDayDefinition Definition = 2 [json_name = "Definition"]; + */ + definition: OpeningDayDefinition[]; +} +/** + * @generated from protobuf message api.OpeningDayDefinition + */ +export interface OpeningDayDefinition { + /** + * List of opening hours + * + * @generated from protobuf field: repeated api.TimeRange TimeRanges = 2 [json_name = "TimeRanges"]; + */ + timeRanges: TimeRange[]; + /** + * Validity filters for this opening rule definition + * + * @generated from protobuf field: api.RuleFilter Filter = 3 [json_name = "Filter"]; + */ + filter?: RuleFilter; + /** + * Order in which the Rule will be applied + * + * @generated from protobuf field: int32 OrderAppliance = 4 [json_name = "OrderAppliance"]; + */ + orderAppliance: number; +} +/** + * @generated from protobuf message api.TimeRange + */ +export interface TimeRange { + /** + * Start time, format hh:mm + * + * @generated from protobuf field: string StartTime = 1 [json_name = "StartTime"]; + */ + startTime: string; + /** + * End time, format hh:mm + * + * @generated from protobuf field: string EndTime = 2 [json_name = "EndTime"]; + */ + endTime: string; +} +/** + * @generated from protobuf message api.CapacityRule + */ +export interface CapacityRule { + /** + * Start date of the capacity rule validity, format yyyy-mm-jj. + * + * @generated from protobuf field: string StartDate = 1 [json_name = "StartDate"]; + */ + startDate: string; + /** + * End date of the capacity rule validity, format yyyy-mm-jj. + * + * @generated from protobuf field: string EndDate = 2 [json_name = "EndDate"]; + */ + endDate: string; + /** + * Label of the Rule + * + * @generated from protobuf field: string Label = 5 [json_name = "Label"]; + */ + label: string; + /** + * List of the days on which this rule is applied. + * + * @generated from protobuf field: repeated api.WeekDay Days = 3 [json_name = "Days"]; + */ + days: WeekDay[]; + /** + * Definition of the capacity rules. + * + * @generated from protobuf field: repeated api.CapacityDefinition Capacities = 4 [json_name = "Capacities"]; + */ + capacities: CapacityDefinition[]; +} +/** + * @generated from protobuf message api.CapacityDefinition + */ +export interface CapacityDefinition { + /** + * Validity filters for this capacity rule definition. + * + * @generated from protobuf field: api.RuleFilter Filter = 1 [json_name = "Filter"]; + */ + filter?: RuleFilter; + /** + * Scope of the rule, simultaneous or daily. + * + * @generated from protobuf field: api.CapacityRuleScope Scope = 2 [json_name = "Scope"]; + */ + scope: CapacityRuleScope; + /** + * The capacity constraint to apply. + * + * @generated from protobuf field: int64 MaximalCapacity = 3 [json_name = "MaximalCapacity"]; + */ + maximalCapacity: bigint; + /** + * Site unit identifier of the capacity if not 'APPOINTMENT'. + * + * @generated from protobuf field: string UnitID = 4 [json_name = "UnitID"]; + */ + unitID: string; +} +/** + * @generated from protobuf message api.DurationRule + */ +export interface DurationRule { + /** + * Validity filters for this duration rule definition. + * + * @generated from protobuf field: api.RuleFilter Filter = 1 [json_name = "Filter"]; + */ + filter?: RuleFilter; + /** + * Base duration in seconds + * + * @generated from protobuf field: int64 BaseDurationInSeconds = 2 [json_name = "BaseDurationInSeconds"]; + */ + baseDurationInSeconds: bigint; + /** + * Variable duration definition by site unit. + * + * @generated from protobuf field: repeated api.VariableDuration VariableDurations = 3 [json_name = "VariableDurations"]; + */ + variableDurations: VariableDuration[]; + /** + * Order in which the Rule will be applied + * + * @generated from protobuf field: int32 OrderAppliance = 4 [json_name = "OrderAppliance"]; + */ + orderAppliance: number; +} +/** + * @generated from protobuf message api.VariableDuration + */ +export interface VariableDuration { + /** + * Site unit identifier + * + * @generated from protobuf field: string UnitID = 1 [json_name = "UnitID"]; + */ + unitID: string; + /** + * Duration in seconds + * + * @generated from protobuf field: int64 DurationInSeconds = 2 [json_name = "DurationInSeconds"]; + */ + durationInSeconds: bigint; +} +/** + * Conditions on ProjectID, AppointmentType or/and Segmentation keys + * + * @generated from protobuf message api.RuleFilter + */ +export interface RuleFilter { + /** + * Filter on appointment type (expedition or reception). + * + * @generated from protobuf field: api.AppointmentType Type = 1 [json_name = "Type"]; + */ + type: AppointmentType; + /** + * Filter on project identifier. + * + * @generated from protobuf field: repeated string ProjectID = 2 [json_name = "ProjectID"]; + */ + projectID: string[]; + /** + * Filter on site Segmentation keys. + * + * @generated from protobuf field: repeated api.SegmentationFilter SegmentationKeys = 3 [json_name = "SegmentationKeys"]; + */ + segmentationKeys: SegmentationFilter[]; +} +/** + * @generated from protobuf message api.SegmentationFilter + */ +export interface SegmentationFilter { + /** + * Identifier of the Segmentation key. + * + * @generated from protobuf field: string SegmentationID = 1 [json_name = "SegmentationID"]; + */ + segmentationID: string; + /** + * Identifiers of the Segmentation key values. + * + * @generated from protobuf field: repeated string SegmentationValueIDs = 2 [json_name = "SegmentationValueIDs"]; + */ + segmentationValueIDs: string[]; +} +/** + * The five following messages are pretty similar, for each added object, they can add a translated version + * + * @generated from protobuf message api.CarrierInformation + */ +export interface CarrierInformation { + /** + * @generated from protobuf field: string CarrierInformationID = 1 [json_name = "CarrierInformationID"]; + */ + carrierInformationID: string; + /** + * @generated from protobuf field: repeated api.LabelByLanguage Label = 2 [json_name = "Label"]; + */ + label: LabelByLanguage[]; // @option language + /** + * @generated from protobuf field: api.CarrierInformationType Type = 3 [json_name = "Type"]; + */ + type: CarrierInformationType; + /** + * @generated from protobuf field: bool IsMandatory = 4 [json_name = "IsMandatory"]; + */ + isMandatory: boolean; + /** + * @generated from protobuf field: bool FormatCheck = 5 [json_name = "FormatCheck"]; + */ + formatCheck: boolean; +} +/** + * we anticipate that they want to put several but if they only have one with all the language, it should still work + * + * @generated from protobuf message api.Document + */ +export interface Document { + /** + * @generated from protobuf field: string DocID = 1 [json_name = "DocID"]; + */ + docID: string; + /** + * @generated from protobuf field: repeated api.DocumentByLanguage DocsByLang = 2 [json_name = "DocsByLang"]; + */ + docsByLang: DocumentByLanguage[]; // @option language + /** + * @generated from protobuf field: bool AckRequired = 3 [json_name = "AckRequired"]; + */ + ackRequired: boolean; +} +/** + * @generated from protobuf message api.DocumentByLanguage + */ +export interface DocumentByLanguage { + /** + * @generated from protobuf field: string Name = 1 [json_name = "Name"]; + */ + name: string; + /** + * @generated from protobuf field: bytes Doc = 2 [json_name = "Doc"]; + */ + doc: Uint8Array; + /** + * @generated from protobuf field: string LanguageCodeISO6391 = 3 [json_name = "LanguageCodeISO6391"]; + */ + languageCodeISO6391: string; +} +/** + * Authorisation + * + * @generated from protobuf message api.ProjectAuthorisation + */ +export interface ProjectAuthorisation { + /** + * Identifier of the organisation + * + * @generated from protobuf field: string OrganisationID = 1 [json_name = "OrganisationID"]; + */ + organisationID: string; + /** + * Identifier of the project + * + * @generated from protobuf field: string ProjectID = 2 [json_name = "ProjectID"]; + */ + projectID: string; + /** + * TODO Do we need explicit flags to show if receipt / ship is allowed / forbidden ? + * Constraints applied for reception appointment + * + * @generated from protobuf field: api.ProjectConstraints InConstraints = 3 [json_name = "InConstraints"]; + */ + inConstraints?: ProjectConstraints; + /** + * Constraints applied for expedition appointment + * + * @generated from protobuf field: api.ProjectConstraints OutConstraints = 4 [json_name = "OutConstraints"]; + */ + outConstraints?: ProjectConstraints; +} +/** + * @generated from protobuf message api.ProjectConstraints + */ +export interface ProjectConstraints { + /** + * Specific Segmentation constraints applicable for the project + * + * @generated from protobuf field: repeated api.SegmentationConstraint SegmentationConstraints = 1 [json_name = "SegmentationConstraints"]; + */ + segmentationConstraints: SegmentationConstraint[]; + /** + * Minimal notice delay to book or cancel an appointment + * + * @generated from protobuf field: api.Period MinNoticePeriod = 2 [json_name = "MinNoticePeriod"]; + */ + minNoticePeriod?: Period; + /** + * Maximal delay to book an appointment + * + * @generated from protobuf field: api.Period MaxBookingPeriod = 3 [json_name = "MaxBookingPeriod"]; + */ + maxBookingPeriod?: Period; +} +/** + * @generated from protobuf message api.SegmentationConstraint + */ +export interface SegmentationConstraint { + /** + * Identifier of the Segmentation key to constraint + * + * @generated from protobuf field: string SegmentationID = 1 [json_name = "SegmentationID"]; + */ + segmentationID: string; + /** + * If some Segmentation values are restricted, define here the identifiers to keep + * + * @generated from protobuf field: repeated int64 RestrictedValueIDs = 2 [json_name = "RestrictedValueIDs"]; + */ + restrictedValueIDs: bigint[]; + /** + * Set to not apply Segmentation value restriction and keep all the values + * + * @generated from protobuf field: bool AllValues = 3 [json_name = "AllValues"]; + */ + allValues: boolean; +} +/** + * @generated from protobuf message api.ActorAuthorisation + */ +export interface ActorAuthorisation { + // TODO Do we need explicit flags to show if receipt / ship is allowed / forbidden ? + + /** + * Constraints applied for reception appointment + * + * @generated from protobuf field: api.ActorConstraints InConstraints = 3 [json_name = "InConstraints"]; + */ + inConstraints?: ActorConstraints; + /** + * Constraints applied for expedition appointment + * + * @generated from protobuf field: api.ActorConstraints OutConstraints = 4 [json_name = "OutConstraints"]; + */ + outConstraints?: ActorConstraints; +} +/** + * @generated from protobuf message api.ActorConstraints + */ +export interface ActorConstraints { + /** + * Specific Segmentation constraints applicable for the project + * + * @generated from protobuf field: repeated api.SegmentationActorConstraint SegmentationConstraints = 1 [json_name = "SegmentationConstraints"]; + */ + segmentationConstraints: SegmentationActorConstraint[]; + /** + * Maximal delay to book an appointment + * + * @generated from protobuf field: api.Period MaxBookingPeriod = 3 [json_name = "MaxBookingPeriod"]; + */ + maxBookingPeriod?: Period; +} +/** + * TODO Need to add here all the Segmentation definition by language + * in order to avoid to have to retrieve the site payload to display Segmentation values + * + * @generated from protobuf message api.SegmentationActorConstraint + */ +export interface SegmentationActorConstraint { + /** + * Identifier of the Segmentation key to constraint + * + * @generated from protobuf field: string SegmentationID = 1 [json_name = "SegmentationID"]; + */ + segmentationID: string; + /** + * If some Segmentation values are restricted, define here the identifiers to keep + * + * @generated from protobuf field: repeated int64 RestrictedValueIDs = 2 [json_name = "RestrictedValueIDs"]; + */ + restrictedValueIDs: bigint[]; + /** + * In case of user value choice, to restrict Segmentation values + * + * @generated from protobuf field: bool AllValues = 3 [json_name = "AllValues"]; + */ + allValues: boolean; + /** + * Define the type of restriction applied on the Segmentation key + * + * @generated from protobuf field: api.SegmentationConstraintType Type = 4 [json_name = "Type"]; + */ + type: SegmentationConstraintType; + /** + * In case of order attribute choice, to define the attribute path + * + * @generated from protobuf field: string AttributePath = 5 [json_name = "AttributePath"]; + */ + attributePath: string; +} +/** + * @generated from protobuf enum api.AppointmentType + */ +export enum AppointmentType { + /** + * @generated from protobuf enum value: APPOINTMENTTYPE_UNKNOWN = 0; + */ + APPOINTMENTTYPE_UNKNOWN = 0, + /** + * @generated from protobuf enum value: APPOINTMENTTYPE_EXPEDITION = 1; + */ + APPOINTMENTTYPE_EXPEDITION = 1, + /** + * @generated from protobuf enum value: APPOINTMENTTYPE_RECEPTION = 2; + */ + APPOINTMENTTYPE_RECEPTION = 2, + /** + * @generated from protobuf enum value: APPOINTMENTTYPE_UNDEFINED = 3; + */ + APPOINTMENTTYPE_UNDEFINED = 3, + /** + * @generated from protobuf enum value: APPOINTMENTTYPE_BOTH = 4; + */ + APPOINTMENTTYPE_BOTH = 4 +} +/** + * @generated from protobuf enum api.PeriodUnit + */ +export enum PeriodUnit { + /** + * @generated from protobuf enum value: PERIODUNIT_UNDEFINED = 0; + */ + PERIODUNIT_UNDEFINED = 0, + /** + * @generated from protobuf enum value: PERIODUNIT_WORK_HOUR = 1; + */ + PERIODUNIT_WORK_HOUR = 1, + /** + * @generated from protobuf enum value: PERIODUNIT_WORK_DAY = 2; + */ + PERIODUNIT_WORK_DAY = 2, + /** + * Google Duration class only expresses durations in seconds and nanoseconds + * To get it in calendar days, working days, it is more complex because all year days do not have the same length... + * Some go libraries will be required + * + * @generated from protobuf enum value: PERIODUNIT_CALENDAR_DAY = 3; + */ + PERIODUNIT_CALENDAR_DAY = 3 +} +/** + * @generated from protobuf enum api.CapacityRuleScope + */ +export enum CapacityRuleScope { + /** + * @generated from protobuf enum value: CAPACITY_RULE_SCOPE_UNKNOWN = 0; + */ + UNKNOWN = 0, + /** + * @generated from protobuf enum value: CAPACITY_RULE_SCOPE_SIMULTANEOUS = 1; + */ + SIMULTANEOUS = 1, + /** + * @generated from protobuf enum value: CAPACITY_RULE_SCOPE_DAILY = 2; + */ + DAILY = 2 +} +/** + * @generated from protobuf enum api.CarrierInformationType + */ +export enum CarrierInformationType { + /** + * @generated from protobuf enum value: CARRIERINFORMATIONTYPE_UNKNOWN = 0; + */ + CARRIERINFORMATIONTYPE_UNKNOWN = 0, + /** + * @generated from protobuf enum value: CARRIERINFORMATIONTYPE_SHORT_TEXT = 1; + */ + CARRIERINFORMATIONTYPE_SHORT_TEXT = 1, + /** + * @generated from protobuf enum value: CARRIERINFORMATIONTYPE_LONG_TEXT = 2; + */ + CARRIERINFORMATIONTYPE_LONG_TEXT = 2, + /** + * @generated from protobuf enum value: CARRIERINFORMATIONTYPE_PHONE = 3; + */ + CARRIERINFORMATIONTYPE_PHONE = 3, + /** + * @generated from protobuf enum value: CARRIERINFORMATIONTYPE_MAIL = 4; + */ + CARRIERINFORMATIONTYPE_MAIL = 4, + /** + * @generated from protobuf enum value: CARRIERINFORMATIONTYPE_LICENSE_NUMBER = 5; + */ + CARRIERINFORMATIONTYPE_LICENSE_NUMBER = 5, + /** + * @generated from protobuf enum value: CARRIERINFORMATIONTYPE_DOCUMENT = 6; + */ + CARRIERINFORMATIONTYPE_DOCUMENT = 6 +} +/** + * @generated from protobuf enum api.SegmentationConstraintType + */ +export enum SegmentationConstraintType { + /** + * @generated from protobuf enum value: SegmentationConstraintType_UNKNOWN = 0; + */ + SegmentationConstraintType_UNKNOWN = 0, + /** + * @generated from protobuf enum value: SegmentationConstraintType_USER_CHOICE = 1; + */ + SegmentationConstraintType_USER_CHOICE = 1, + /** + * @generated from protobuf enum value: SegmentationConstraintType_ORDER_ATTRIBUTE = 2; + */ + SegmentationConstraintType_ORDER_ATTRIBUTE = 2, + /** + * @generated from protobuf enum value: SegmentationConstraintType_ENFORCED = 3; + */ + SegmentationConstraintType_ENFORCED = 3 +} +// @generated message type with reflection information, may provide speed optimized methods +class Unit$Type extends MessageType { + constructor() { + super("api.Unit", [ + { no: 1, name: "UnitID", kind: "scalar", jsonName: "UnitID", T: 9 /*ScalarType.STRING*/ }, + { no: 2, name: "Labels", kind: "message", jsonName: "Labels", repeat: 1 /*RepeatType.PACKED*/, T: () => LabelByLanguage, options: { "api.language": true, "api.aggKey": "LanguageCodeISO6391" } } + ]); + } + create(value?: PartialMessage): Unit { + const message = globalThis.Object.create((this.messagePrototype!)); + message.unitID = ""; + message.labels = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: Unit): Unit { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string UnitID = 1 [json_name = "UnitID"];*/ 1: + message.unitID = reader.string(); + break; + case /* repeated api.LabelByLanguage Labels = 2 [json_name = "Labels"];*/ 2: + message.labels.push(LabelByLanguage.internalBinaryRead(reader, reader.uint32(), options)); + 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: Unit, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string UnitID = 1 [json_name = "UnitID"]; */ + if (message.unitID !== "") + writer.tag(1, WireType.LengthDelimited).string(message.unitID); + /* repeated api.LabelByLanguage Labels = 2 [json_name = "Labels"]; */ + for (let i = 0; i < message.labels.length; i++) + LabelByLanguage.internalBinaryWrite(message.labels[i], writer.tag(2, 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.Unit + */ +export const Unit = new Unit$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class QuantityByUnit$Type extends MessageType { + constructor() { + super("api.QuantityByUnit", [ + { no: 1, name: "UnitID", kind: "message", jsonName: "UnitID", T: () => Unit }, + { no: 2, name: "Value", kind: "scalar", jsonName: "Value", T: 1 /*ScalarType.DOUBLE*/, options: { "validate.rules": { double: { gte: 0 } } } } + ]); + } + create(value?: PartialMessage): QuantityByUnit { + const message = globalThis.Object.create((this.messagePrototype!)); + message.value = 0; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: QuantityByUnit): QuantityByUnit { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.Unit UnitID = 1 [json_name = "UnitID"];*/ 1: + message.unitID = Unit.internalBinaryRead(reader, reader.uint32(), options, message.unitID); + break; + case /* double Value = 2 [json_name = "Value"];*/ 2: + message.value = reader.double(); + 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: QuantityByUnit, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.Unit UnitID = 1 [json_name = "UnitID"]; */ + if (message.unitID) + Unit.internalBinaryWrite(message.unitID, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* double Value = 2 [json_name = "Value"]; */ + if (message.value !== 0) + writer.tag(2, WireType.Bit64).double(message.value); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.QuantityByUnit + */ +export const QuantityByUnit = new QuantityByUnit$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class Period$Type extends MessageType { + constructor() { + super("api.Period", [ + { no: 1, name: "Value", kind: "scalar", jsonName: "Value", T: 3 /*ScalarType.INT64*/, L: 0 /*LongType.BIGINT*/ }, + { no: 2, name: "Unit", kind: "enum", jsonName: "Unit", T: () => ["api.PeriodUnit", PeriodUnit] } + ]); + } + create(value?: PartialMessage): Period { + const message = globalThis.Object.create((this.messagePrototype!)); + message.value = 0n; + message.unit = 0; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: Period): Period { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* int64 Value = 1 [json_name = "Value"];*/ 1: + message.value = reader.int64().toBigInt(); + break; + case /* api.PeriodUnit Unit = 2 [json_name = "Unit"];*/ 2: + message.unit = reader.int32(); + 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: Period, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* int64 Value = 1 [json_name = "Value"]; */ + if (message.value !== 0n) + writer.tag(1, WireType.Varint).int64(message.value); + /* api.PeriodUnit Unit = 2 [json_name = "Unit"]; */ + if (message.unit !== 0) + writer.tag(2, WireType.Varint).int32(message.unit); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.Period + */ +export const Period = new Period$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class Slot$Type extends MessageType { + constructor() { + super("api.Slot", [ + { no: 1, name: "StartDateTime", kind: "scalar", jsonName: "StartDateTime", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { pattern: "^20[0-9]{2}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])T[01][0-9]|2[0-3]:[0-5][0-9]:[0-5][0-9]$" } } } }, + { no: 3, name: "DurationInMinutes", kind: "scalar", jsonName: "DurationInMinutes", T: 3 /*ScalarType.INT64*/, L: 0 /*LongType.BIGINT*/ } + ]); + } + create(value?: PartialMessage): Slot { + const message = globalThis.Object.create((this.messagePrototype!)); + message.startDateTime = ""; + message.durationInMinutes = 0n; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: Slot): Slot { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string StartDateTime = 1 [json_name = "StartDateTime"];*/ 1: + message.startDateTime = reader.string(); + break; + case /* int64 DurationInMinutes = 3 [json_name = "DurationInMinutes"];*/ 3: + message.durationInMinutes = reader.int64().toBigInt(); + 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: Slot, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string StartDateTime = 1 [json_name = "StartDateTime"]; */ + if (message.startDateTime !== "") + writer.tag(1, WireType.LengthDelimited).string(message.startDateTime); + /* int64 DurationInMinutes = 3 [json_name = "DurationInMinutes"]; */ + if (message.durationInMinutes !== 0n) + writer.tag(3, WireType.Varint).int64(message.durationInMinutes); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.Slot + */ +export const Slot = new Slot$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class Segmentation$Type extends MessageType { + constructor() { + super("api.Segmentation", [ + { no: 1, name: "SegmentationID", kind: "scalar", jsonName: "SegmentationID", T: 9 /*ScalarType.STRING*/ }, + { no: 2, name: "SegmentationLabel", kind: "message", jsonName: "SegmentationLabel", repeat: 1 /*RepeatType.PACKED*/, T: () => LabelByLanguage, options: { "api.language": true, "api.aggKey": "LanguageCodeISO6391" } }, + { no: 3, name: "Values", kind: "message", jsonName: "Values", repeat: 1 /*RepeatType.PACKED*/, T: () => SegmentationValue } + ]); + } + create(value?: PartialMessage): Segmentation { + const message = globalThis.Object.create((this.messagePrototype!)); + message.segmentationID = ""; + message.segmentationLabel = []; + message.values = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: Segmentation): Segmentation { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string SegmentationID = 1 [json_name = "SegmentationID"];*/ 1: + message.segmentationID = reader.string(); + break; + case /* repeated api.LabelByLanguage SegmentationLabel = 2 [json_name = "SegmentationLabel"];*/ 2: + message.segmentationLabel.push(LabelByLanguage.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* repeated api.SegmentationValue Values = 3 [json_name = "Values"];*/ 3: + message.values.push(SegmentationValue.internalBinaryRead(reader, reader.uint32(), options)); + 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: Segmentation, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string SegmentationID = 1 [json_name = "SegmentationID"]; */ + if (message.segmentationID !== "") + writer.tag(1, WireType.LengthDelimited).string(message.segmentationID); + /* repeated api.LabelByLanguage SegmentationLabel = 2 [json_name = "SegmentationLabel"]; */ + for (let i = 0; i < message.segmentationLabel.length; i++) + LabelByLanguage.internalBinaryWrite(message.segmentationLabel[i], writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* repeated api.SegmentationValue Values = 3 [json_name = "Values"]; */ + for (let i = 0; i < message.values.length; i++) + SegmentationValue.internalBinaryWrite(message.values[i], writer.tag(3, 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.Segmentation + */ +export const Segmentation = new Segmentation$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class SegmentationValue$Type extends MessageType { + constructor() { + super("api.SegmentationValue", [ + { no: 1, name: "ID", kind: "scalar", jsonName: "ID", T: 9 /*ScalarType.STRING*/ }, + { no: 2, name: "Label", kind: "message", jsonName: "Label", repeat: 1 /*RepeatType.PACKED*/, T: () => LabelByLanguage, options: { "api.language": true, "api.aggKey": "LanguageCodeISO6391" } } + ]); + } + create(value?: PartialMessage): SegmentationValue { + const message = globalThis.Object.create((this.messagePrototype!)); + message.iD = ""; + message.label = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: SegmentationValue): SegmentationValue { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string ID = 1 [json_name = "ID"];*/ 1: + message.iD = reader.string(); + break; + case /* repeated api.LabelByLanguage Label = 2 [json_name = "Label"];*/ 2: + message.label.push(LabelByLanguage.internalBinaryRead(reader, reader.uint32(), options)); + 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: SegmentationValue, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string ID = 1 [json_name = "ID"]; */ + if (message.iD !== "") + writer.tag(1, WireType.LengthDelimited).string(message.iD); + /* repeated api.LabelByLanguage Label = 2 [json_name = "Label"]; */ + for (let i = 0; i < message.label.length; i++) + LabelByLanguage.internalBinaryWrite(message.label[i], writer.tag(2, 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.SegmentationValue + */ +export const SegmentationValue = new SegmentationValue$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class OpeningRule$Type extends MessageType { + constructor() { + super("api.OpeningRule", [ + { no: 1, name: "StartDate", kind: "scalar", jsonName: "StartDate", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { pattern: "^20[0-9]{2}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" } } } }, + { no: 2, name: "EndDate", kind: "scalar", jsonName: "EndDate", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { pattern: "^20[0-9]{2}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" } } } }, + { no: 3, name: "OpeningDays", kind: "message", jsonName: "OpeningDays", repeat: 1 /*RepeatType.PACKED*/, T: () => OpeningDefinition, options: { "api.aggKey": "WeekDay" } }, + { no: 4, name: "CalendarID", kind: "scalar", jsonName: "CalendarID", T: 9 /*ScalarType.STRING*/ }, + { no: 5, name: "Label", kind: "scalar", jsonName: "Label", T: 9 /*ScalarType.STRING*/ } + ]); + } + create(value?: PartialMessage): OpeningRule { + const message = globalThis.Object.create((this.messagePrototype!)); + message.startDate = ""; + message.endDate = ""; + message.openingDays = []; + message.calendarID = ""; + message.label = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: OpeningRule): OpeningRule { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string StartDate = 1 [json_name = "StartDate"];*/ 1: + message.startDate = reader.string(); + break; + case /* string EndDate = 2 [json_name = "EndDate"];*/ 2: + message.endDate = reader.string(); + break; + case /* repeated api.OpeningDefinition OpeningDays = 3 [json_name = "OpeningDays"];*/ 3: + message.openingDays.push(OpeningDefinition.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* string CalendarID = 4 [json_name = "CalendarID"];*/ 4: + message.calendarID = reader.string(); + break; + case /* string Label = 5 [json_name = "Label"];*/ 5: + message.label = 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: OpeningRule, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string StartDate = 1 [json_name = "StartDate"]; */ + if (message.startDate !== "") + writer.tag(1, WireType.LengthDelimited).string(message.startDate); + /* string EndDate = 2 [json_name = "EndDate"]; */ + if (message.endDate !== "") + writer.tag(2, WireType.LengthDelimited).string(message.endDate); + /* repeated api.OpeningDefinition OpeningDays = 3 [json_name = "OpeningDays"]; */ + for (let i = 0; i < message.openingDays.length; i++) + OpeningDefinition.internalBinaryWrite(message.openingDays[i], writer.tag(3, WireType.LengthDelimited).fork(), options).join(); + /* string CalendarID = 4 [json_name = "CalendarID"]; */ + if (message.calendarID !== "") + writer.tag(4, WireType.LengthDelimited).string(message.calendarID); + /* string Label = 5 [json_name = "Label"]; */ + if (message.label !== "") + writer.tag(5, WireType.LengthDelimited).string(message.label); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.OpeningRule + */ +export const OpeningRule = new OpeningRule$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class OpeningDefinition$Type extends MessageType { + constructor() { + super("api.OpeningDefinition", [ + { no: 1, name: "WeekDay", kind: "enum", jsonName: "WeekDay", T: () => ["api.WeekDay", WeekDay] }, + { no: 2, name: "Definition", kind: "message", jsonName: "Definition", repeat: 1 /*RepeatType.PACKED*/, T: () => OpeningDayDefinition } + ]); + } + create(value?: PartialMessage): OpeningDefinition { + const message = globalThis.Object.create((this.messagePrototype!)); + message.weekDay = 0; + message.definition = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: OpeningDefinition): OpeningDefinition { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.WeekDay WeekDay = 1 [json_name = "WeekDay"];*/ 1: + message.weekDay = reader.int32(); + break; + case /* repeated api.OpeningDayDefinition Definition = 2 [json_name = "Definition"];*/ 2: + message.definition.push(OpeningDayDefinition.internalBinaryRead(reader, reader.uint32(), options)); + 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: OpeningDefinition, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.WeekDay WeekDay = 1 [json_name = "WeekDay"]; */ + if (message.weekDay !== 0) + writer.tag(1, WireType.Varint).int32(message.weekDay); + /* repeated api.OpeningDayDefinition Definition = 2 [json_name = "Definition"]; */ + for (let i = 0; i < message.definition.length; i++) + OpeningDayDefinition.internalBinaryWrite(message.definition[i], writer.tag(2, 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.OpeningDefinition + */ +export const OpeningDefinition = new OpeningDefinition$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class OpeningDayDefinition$Type extends MessageType { + constructor() { + super("api.OpeningDayDefinition", [ + { no: 2, name: "TimeRanges", kind: "message", jsonName: "TimeRanges", repeat: 1 /*RepeatType.PACKED*/, T: () => TimeRange }, + { no: 3, name: "Filter", kind: "message", jsonName: "Filter", T: () => RuleFilter }, + { no: 4, name: "OrderAppliance", kind: "scalar", jsonName: "OrderAppliance", T: 5 /*ScalarType.INT32*/ } + ]); + } + create(value?: PartialMessage): OpeningDayDefinition { + const message = globalThis.Object.create((this.messagePrototype!)); + message.timeRanges = []; + message.orderAppliance = 0; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: OpeningDayDefinition): OpeningDayDefinition { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* repeated api.TimeRange TimeRanges = 2 [json_name = "TimeRanges"];*/ 2: + message.timeRanges.push(TimeRange.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* api.RuleFilter Filter = 3 [json_name = "Filter"];*/ 3: + message.filter = RuleFilter.internalBinaryRead(reader, reader.uint32(), options, message.filter); + break; + case /* int32 OrderAppliance = 4 [json_name = "OrderAppliance"];*/ 4: + message.orderAppliance = reader.int32(); + 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: OpeningDayDefinition, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* repeated api.TimeRange TimeRanges = 2 [json_name = "TimeRanges"]; */ + for (let i = 0; i < message.timeRanges.length; i++) + TimeRange.internalBinaryWrite(message.timeRanges[i], writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* api.RuleFilter Filter = 3 [json_name = "Filter"]; */ + if (message.filter) + RuleFilter.internalBinaryWrite(message.filter, writer.tag(3, WireType.LengthDelimited).fork(), options).join(); + /* int32 OrderAppliance = 4 [json_name = "OrderAppliance"]; */ + if (message.orderAppliance !== 0) + writer.tag(4, WireType.Varint).int32(message.orderAppliance); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.OpeningDayDefinition + */ +export const OpeningDayDefinition = new OpeningDayDefinition$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class TimeRange$Type extends MessageType { + constructor() { + super("api.TimeRange", [ + { no: 1, name: "StartTime", kind: "scalar", jsonName: "StartTime", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$" } } } }, + { no: 2, name: "EndTime", kind: "scalar", jsonName: "EndTime", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$" } } } } + ]); + } + create(value?: PartialMessage): TimeRange { + const message = globalThis.Object.create((this.messagePrototype!)); + message.startTime = ""; + message.endTime = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: TimeRange): TimeRange { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string StartTime = 1 [json_name = "StartTime"];*/ 1: + message.startTime = reader.string(); + break; + case /* string EndTime = 2 [json_name = "EndTime"];*/ 2: + message.endTime = 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: TimeRange, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string StartTime = 1 [json_name = "StartTime"]; */ + if (message.startTime !== "") + writer.tag(1, WireType.LengthDelimited).string(message.startTime); + /* string EndTime = 2 [json_name = "EndTime"]; */ + if (message.endTime !== "") + writer.tag(2, WireType.LengthDelimited).string(message.endTime); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.TimeRange + */ +export const TimeRange = new TimeRange$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class CapacityRule$Type extends MessageType { + constructor() { + super("api.CapacityRule", [ + { no: 1, name: "StartDate", kind: "scalar", jsonName: "StartDate", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { pattern: "^20[0-9]{2}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" } } } }, + { no: 2, name: "EndDate", kind: "scalar", jsonName: "EndDate", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { pattern: "^20[0-9]{2}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$" } } } }, + { no: 5, name: "Label", kind: "scalar", jsonName: "Label", T: 9 /*ScalarType.STRING*/ }, + { no: 3, name: "Days", kind: "enum", jsonName: "Days", repeat: 1 /*RepeatType.PACKED*/, T: () => ["api.WeekDay", WeekDay] }, + { no: 4, name: "Capacities", kind: "message", jsonName: "Capacities", repeat: 1 /*RepeatType.PACKED*/, T: () => CapacityDefinition } + ]); + } + create(value?: PartialMessage): CapacityRule { + const message = globalThis.Object.create((this.messagePrototype!)); + message.startDate = ""; + message.endDate = ""; + message.label = ""; + message.days = []; + message.capacities = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: CapacityRule): CapacityRule { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string StartDate = 1 [json_name = "StartDate"];*/ 1: + message.startDate = reader.string(); + break; + case /* string EndDate = 2 [json_name = "EndDate"];*/ 2: + message.endDate = reader.string(); + break; + case /* string Label = 5 [json_name = "Label"];*/ 5: + message.label = reader.string(); + break; + case /* repeated api.WeekDay Days = 3 [json_name = "Days"];*/ 3: + if (wireType === WireType.LengthDelimited) + for (let e = reader.int32() + reader.pos; reader.pos < e;) + message.days.push(reader.int32()); + else + message.days.push(reader.int32()); + break; + case /* repeated api.CapacityDefinition Capacities = 4 [json_name = "Capacities"];*/ 4: + message.capacities.push(CapacityDefinition.internalBinaryRead(reader, reader.uint32(), options)); + 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: CapacityRule, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string StartDate = 1 [json_name = "StartDate"]; */ + if (message.startDate !== "") + writer.tag(1, WireType.LengthDelimited).string(message.startDate); + /* string EndDate = 2 [json_name = "EndDate"]; */ + if (message.endDate !== "") + writer.tag(2, WireType.LengthDelimited).string(message.endDate); + /* string Label = 5 [json_name = "Label"]; */ + if (message.label !== "") + writer.tag(5, WireType.LengthDelimited).string(message.label); + /* repeated api.WeekDay Days = 3 [json_name = "Days"]; */ + if (message.days.length) { + writer.tag(3, WireType.LengthDelimited).fork(); + for (let i = 0; i < message.days.length; i++) + writer.int32(message.days[i]); + writer.join(); + } + /* repeated api.CapacityDefinition Capacities = 4 [json_name = "Capacities"]; */ + for (let i = 0; i < message.capacities.length; i++) + CapacityDefinition.internalBinaryWrite(message.capacities[i], writer.tag(4, 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.CapacityRule + */ +export const CapacityRule = new CapacityRule$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class CapacityDefinition$Type extends MessageType { + constructor() { + super("api.CapacityDefinition", [ + { no: 1, name: "Filter", kind: "message", jsonName: "Filter", T: () => RuleFilter }, + { no: 2, name: "Scope", kind: "enum", jsonName: "Scope", T: () => ["api.CapacityRuleScope", CapacityRuleScope, "CAPACITY_RULE_SCOPE_"] }, + { no: 3, name: "MaximalCapacity", kind: "scalar", jsonName: "MaximalCapacity", T: 3 /*ScalarType.INT64*/, L: 0 /*LongType.BIGINT*/ }, + { no: 4, name: "UnitID", kind: "scalar", jsonName: "UnitID", T: 9 /*ScalarType.STRING*/ } + ]); + } + create(value?: PartialMessage): CapacityDefinition { + const message = globalThis.Object.create((this.messagePrototype!)); + message.scope = 0; + message.maximalCapacity = 0n; + message.unitID = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: CapacityDefinition): CapacityDefinition { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RuleFilter Filter = 1 [json_name = "Filter"];*/ 1: + message.filter = RuleFilter.internalBinaryRead(reader, reader.uint32(), options, message.filter); + break; + case /* api.CapacityRuleScope Scope = 2 [json_name = "Scope"];*/ 2: + message.scope = reader.int32(); + break; + case /* int64 MaximalCapacity = 3 [json_name = "MaximalCapacity"];*/ 3: + message.maximalCapacity = reader.int64().toBigInt(); + break; + case /* string UnitID = 4 [json_name = "UnitID"];*/ 4: + message.unitID = 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: CapacityDefinition, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RuleFilter Filter = 1 [json_name = "Filter"]; */ + if (message.filter) + RuleFilter.internalBinaryWrite(message.filter, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.CapacityRuleScope Scope = 2 [json_name = "Scope"]; */ + if (message.scope !== 0) + writer.tag(2, WireType.Varint).int32(message.scope); + /* int64 MaximalCapacity = 3 [json_name = "MaximalCapacity"]; */ + if (message.maximalCapacity !== 0n) + writer.tag(3, WireType.Varint).int64(message.maximalCapacity); + /* string UnitID = 4 [json_name = "UnitID"]; */ + if (message.unitID !== "") + writer.tag(4, WireType.LengthDelimited).string(message.unitID); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.CapacityDefinition + */ +export const CapacityDefinition = new CapacityDefinition$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class DurationRule$Type extends MessageType { + constructor() { + super("api.DurationRule", [ + { no: 1, name: "Filter", kind: "message", jsonName: "Filter", T: () => RuleFilter }, + { no: 2, name: "BaseDurationInSeconds", kind: "scalar", jsonName: "BaseDurationInSeconds", T: 3 /*ScalarType.INT64*/, L: 0 /*LongType.BIGINT*/ }, + { no: 3, name: "VariableDurations", kind: "message", jsonName: "VariableDurations", repeat: 1 /*RepeatType.PACKED*/, T: () => VariableDuration, options: { "api.aggKey": "UnitID" } }, + { no: 4, name: "OrderAppliance", kind: "scalar", jsonName: "OrderAppliance", T: 5 /*ScalarType.INT32*/ } + ]); + } + create(value?: PartialMessage): DurationRule { + const message = globalThis.Object.create((this.messagePrototype!)); + message.baseDurationInSeconds = 0n; + message.variableDurations = []; + message.orderAppliance = 0; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: DurationRule): DurationRule { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.RuleFilter Filter = 1 [json_name = "Filter"];*/ 1: + message.filter = RuleFilter.internalBinaryRead(reader, reader.uint32(), options, message.filter); + break; + case /* int64 BaseDurationInSeconds = 2 [json_name = "BaseDurationInSeconds"];*/ 2: + message.baseDurationInSeconds = reader.int64().toBigInt(); + break; + case /* repeated api.VariableDuration VariableDurations = 3 [json_name = "VariableDurations"];*/ 3: + message.variableDurations.push(VariableDuration.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* int32 OrderAppliance = 4 [json_name = "OrderAppliance"];*/ 4: + message.orderAppliance = reader.int32(); + 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: DurationRule, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.RuleFilter Filter = 1 [json_name = "Filter"]; */ + if (message.filter) + RuleFilter.internalBinaryWrite(message.filter, writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* int64 BaseDurationInSeconds = 2 [json_name = "BaseDurationInSeconds"]; */ + if (message.baseDurationInSeconds !== 0n) + writer.tag(2, WireType.Varint).int64(message.baseDurationInSeconds); + /* repeated api.VariableDuration VariableDurations = 3 [json_name = "VariableDurations"]; */ + for (let i = 0; i < message.variableDurations.length; i++) + VariableDuration.internalBinaryWrite(message.variableDurations[i], writer.tag(3, WireType.LengthDelimited).fork(), options).join(); + /* int32 OrderAppliance = 4 [json_name = "OrderAppliance"]; */ + if (message.orderAppliance !== 0) + writer.tag(4, WireType.Varint).int32(message.orderAppliance); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.DurationRule + */ +export const DurationRule = new DurationRule$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class VariableDuration$Type extends MessageType { + constructor() { + super("api.VariableDuration", [ + { no: 1, name: "UnitID", kind: "scalar", jsonName: "UnitID", T: 9 /*ScalarType.STRING*/ }, + { no: 2, name: "DurationInSeconds", kind: "scalar", jsonName: "DurationInSeconds", T: 3 /*ScalarType.INT64*/, L: 0 /*LongType.BIGINT*/ } + ]); + } + create(value?: PartialMessage): VariableDuration { + const message = globalThis.Object.create((this.messagePrototype!)); + message.unitID = ""; + message.durationInSeconds = 0n; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: VariableDuration): VariableDuration { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string UnitID = 1 [json_name = "UnitID"];*/ 1: + message.unitID = reader.string(); + break; + case /* int64 DurationInSeconds = 2 [json_name = "DurationInSeconds"];*/ 2: + message.durationInSeconds = reader.int64().toBigInt(); + 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: VariableDuration, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string UnitID = 1 [json_name = "UnitID"]; */ + if (message.unitID !== "") + writer.tag(1, WireType.LengthDelimited).string(message.unitID); + /* int64 DurationInSeconds = 2 [json_name = "DurationInSeconds"]; */ + if (message.durationInSeconds !== 0n) + writer.tag(2, WireType.Varint).int64(message.durationInSeconds); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.VariableDuration + */ +export const VariableDuration = new VariableDuration$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class RuleFilter$Type extends MessageType { + constructor() { + super("api.RuleFilter", [ + { no: 1, name: "Type", kind: "enum", jsonName: "Type", T: () => ["api.AppointmentType", AppointmentType] }, + { no: 2, name: "ProjectID", kind: "scalar", jsonName: "ProjectID", repeat: 2 /*RepeatType.UNPACKED*/, T: 9 /*ScalarType.STRING*/ }, + { no: 3, name: "SegmentationKeys", kind: "message", jsonName: "SegmentationKeys", repeat: 1 /*RepeatType.PACKED*/, T: () => SegmentationFilter } + ]); + } + create(value?: PartialMessage): RuleFilter { + const message = globalThis.Object.create((this.messagePrototype!)); + message.type = 0; + message.projectID = []; + message.segmentationKeys = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: RuleFilter): RuleFilter { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.AppointmentType Type = 1 [json_name = "Type"];*/ 1: + message.type = reader.int32(); + break; + case /* repeated string ProjectID = 2 [json_name = "ProjectID"];*/ 2: + message.projectID.push(reader.string()); + break; + case /* repeated api.SegmentationFilter SegmentationKeys = 3 [json_name = "SegmentationKeys"];*/ 3: + message.segmentationKeys.push(SegmentationFilter.internalBinaryRead(reader, reader.uint32(), options)); + 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: RuleFilter, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.AppointmentType Type = 1 [json_name = "Type"]; */ + if (message.type !== 0) + writer.tag(1, WireType.Varint).int32(message.type); + /* repeated string ProjectID = 2 [json_name = "ProjectID"]; */ + for (let i = 0; i < message.projectID.length; i++) + writer.tag(2, WireType.LengthDelimited).string(message.projectID[i]); + /* repeated api.SegmentationFilter SegmentationKeys = 3 [json_name = "SegmentationKeys"]; */ + for (let i = 0; i < message.segmentationKeys.length; i++) + SegmentationFilter.internalBinaryWrite(message.segmentationKeys[i], writer.tag(3, 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.RuleFilter + */ +export const RuleFilter = new RuleFilter$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class SegmentationFilter$Type extends MessageType { + constructor() { + super("api.SegmentationFilter", [ + { no: 1, name: "SegmentationID", kind: "scalar", jsonName: "SegmentationID", T: 9 /*ScalarType.STRING*/ }, + { no: 2, name: "SegmentationValueIDs", kind: "scalar", jsonName: "SegmentationValueIDs", repeat: 2 /*RepeatType.UNPACKED*/, T: 9 /*ScalarType.STRING*/ } + ]); + } + create(value?: PartialMessage): SegmentationFilter { + const message = globalThis.Object.create((this.messagePrototype!)); + message.segmentationID = ""; + message.segmentationValueIDs = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: SegmentationFilter): SegmentationFilter { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string SegmentationID = 1 [json_name = "SegmentationID"];*/ 1: + message.segmentationID = reader.string(); + break; + case /* repeated string SegmentationValueIDs = 2 [json_name = "SegmentationValueIDs"];*/ 2: + message.segmentationValueIDs.push(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: SegmentationFilter, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string SegmentationID = 1 [json_name = "SegmentationID"]; */ + if (message.segmentationID !== "") + writer.tag(1, WireType.LengthDelimited).string(message.segmentationID); + /* repeated string SegmentationValueIDs = 2 [json_name = "SegmentationValueIDs"]; */ + for (let i = 0; i < message.segmentationValueIDs.length; i++) + writer.tag(2, WireType.LengthDelimited).string(message.segmentationValueIDs[i]); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.SegmentationFilter + */ +export const SegmentationFilter = new SegmentationFilter$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class CarrierInformation$Type extends MessageType { + constructor() { + super("api.CarrierInformation", [ + { no: 1, name: "CarrierInformationID", kind: "scalar", jsonName: "CarrierInformationID", T: 9 /*ScalarType.STRING*/ }, + { no: 2, name: "Label", kind: "message", jsonName: "Label", repeat: 1 /*RepeatType.PACKED*/, T: () => LabelByLanguage, options: { "api.language": true, "api.aggKey": "LanguageCodeISO6391" } }, + { no: 3, name: "Type", kind: "enum", jsonName: "Type", T: () => ["api.CarrierInformationType", CarrierInformationType] }, + { no: 4, name: "IsMandatory", kind: "scalar", jsonName: "IsMandatory", T: 8 /*ScalarType.BOOL*/ }, + { no: 5, name: "FormatCheck", kind: "scalar", jsonName: "FormatCheck", T: 8 /*ScalarType.BOOL*/ } + ]); + } + create(value?: PartialMessage): CarrierInformation { + const message = globalThis.Object.create((this.messagePrototype!)); + message.carrierInformationID = ""; + message.label = []; + message.type = 0; + message.isMandatory = false; + message.formatCheck = false; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: CarrierInformation): CarrierInformation { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string CarrierInformationID = 1 [json_name = "CarrierInformationID"];*/ 1: + message.carrierInformationID = reader.string(); + break; + case /* repeated api.LabelByLanguage Label = 2 [json_name = "Label"];*/ 2: + message.label.push(LabelByLanguage.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* api.CarrierInformationType Type = 3 [json_name = "Type"];*/ 3: + message.type = reader.int32(); + break; + case /* bool IsMandatory = 4 [json_name = "IsMandatory"];*/ 4: + message.isMandatory = reader.bool(); + break; + case /* bool FormatCheck = 5 [json_name = "FormatCheck"];*/ 5: + message.formatCheck = 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: CarrierInformation, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string CarrierInformationID = 1 [json_name = "CarrierInformationID"]; */ + if (message.carrierInformationID !== "") + writer.tag(1, WireType.LengthDelimited).string(message.carrierInformationID); + /* repeated api.LabelByLanguage Label = 2 [json_name = "Label"]; */ + for (let i = 0; i < message.label.length; i++) + LabelByLanguage.internalBinaryWrite(message.label[i], writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* api.CarrierInformationType Type = 3 [json_name = "Type"]; */ + if (message.type !== 0) + writer.tag(3, WireType.Varint).int32(message.type); + /* bool IsMandatory = 4 [json_name = "IsMandatory"]; */ + if (message.isMandatory !== false) + writer.tag(4, WireType.Varint).bool(message.isMandatory); + /* bool FormatCheck = 5 [json_name = "FormatCheck"]; */ + if (message.formatCheck !== false) + writer.tag(5, WireType.Varint).bool(message.formatCheck); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.CarrierInformation + */ +export const CarrierInformation = new CarrierInformation$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class Document$Type extends MessageType { + constructor() { + super("api.Document", [ + { no: 1, name: "DocID", kind: "scalar", jsonName: "DocID", T: 9 /*ScalarType.STRING*/ }, + { no: 2, name: "DocsByLang", kind: "message", jsonName: "DocsByLang", repeat: 1 /*RepeatType.PACKED*/, T: () => DocumentByLanguage, options: { "api.language": true, "api.aggKey": "LanguageCodeISO6391" } }, + { no: 3, name: "AckRequired", kind: "scalar", jsonName: "AckRequired", T: 8 /*ScalarType.BOOL*/ } + ]); + } + create(value?: PartialMessage): Document { + const message = globalThis.Object.create((this.messagePrototype!)); + message.docID = ""; + message.docsByLang = []; + message.ackRequired = false; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: Document): Document { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string DocID = 1 [json_name = "DocID"];*/ 1: + message.docID = reader.string(); + break; + case /* repeated api.DocumentByLanguage DocsByLang = 2 [json_name = "DocsByLang"];*/ 2: + message.docsByLang.push(DocumentByLanguage.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* bool AckRequired = 3 [json_name = "AckRequired"];*/ 3: + message.ackRequired = 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: Document, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string DocID = 1 [json_name = "DocID"]; */ + if (message.docID !== "") + writer.tag(1, WireType.LengthDelimited).string(message.docID); + /* repeated api.DocumentByLanguage DocsByLang = 2 [json_name = "DocsByLang"]; */ + for (let i = 0; i < message.docsByLang.length; i++) + DocumentByLanguage.internalBinaryWrite(message.docsByLang[i], writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* bool AckRequired = 3 [json_name = "AckRequired"]; */ + if (message.ackRequired !== false) + writer.tag(3, WireType.Varint).bool(message.ackRequired); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.Document + */ +export const Document = new Document$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class DocumentByLanguage$Type extends MessageType { + constructor() { + super("api.DocumentByLanguage", [ + { no: 1, name: "Name", kind: "scalar", jsonName: "Name", T: 9 /*ScalarType.STRING*/ }, + { no: 2, name: "Doc", kind: "scalar", jsonName: "Doc", T: 12 /*ScalarType.BYTES*/ }, + { no: 3, name: "LanguageCodeISO6391", kind: "scalar", jsonName: "LanguageCodeISO6391", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "2", maxLen: "3", languageIso639: true } }, "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "ISO 639 code message language", example: "\"en\"" } } } + ]); + } + create(value?: PartialMessage): DocumentByLanguage { + const message = globalThis.Object.create((this.messagePrototype!)); + message.name = ""; + message.doc = new Uint8Array(0); + message.languageCodeISO6391 = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: DocumentByLanguage): DocumentByLanguage { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string Name = 1 [json_name = "Name"];*/ 1: + message.name = reader.string(); + break; + case /* bytes Doc = 2 [json_name = "Doc"];*/ 2: + message.doc = reader.bytes(); + break; + case /* string LanguageCodeISO6391 = 3 [json_name = "LanguageCodeISO6391"];*/ 3: + message.languageCodeISO6391 = 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: DocumentByLanguage, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string Name = 1 [json_name = "Name"]; */ + if (message.name !== "") + writer.tag(1, WireType.LengthDelimited).string(message.name); + /* bytes Doc = 2 [json_name = "Doc"]; */ + if (message.doc.length) + writer.tag(2, WireType.LengthDelimited).bytes(message.doc); + /* string LanguageCodeISO6391 = 3 [json_name = "LanguageCodeISO6391"]; */ + if (message.languageCodeISO6391 !== "") + writer.tag(3, WireType.LengthDelimited).string(message.languageCodeISO6391); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.DocumentByLanguage + */ +export const DocumentByLanguage = new DocumentByLanguage$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class ProjectAuthorisation$Type extends MessageType { + constructor() { + super("api.ProjectAuthorisation", [ + { no: 1, name: "OrganisationID", kind: "scalar", jsonName: "OrganisationID", T: 9 /*ScalarType.STRING*/ }, + { no: 2, name: "ProjectID", kind: "scalar", jsonName: "ProjectID", T: 9 /*ScalarType.STRING*/ }, + { no: 3, name: "InConstraints", kind: "message", jsonName: "InConstraints", T: () => ProjectConstraints }, + { no: 4, name: "OutConstraints", kind: "message", jsonName: "OutConstraints", T: () => ProjectConstraints } + ]); + } + create(value?: PartialMessage): ProjectAuthorisation { + const message = globalThis.Object.create((this.messagePrototype!)); + message.organisationID = ""; + message.projectID = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ProjectAuthorisation): ProjectAuthorisation { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string OrganisationID = 1 [json_name = "OrganisationID"];*/ 1: + message.organisationID = reader.string(); + break; + case /* string ProjectID = 2 [json_name = "ProjectID"];*/ 2: + message.projectID = reader.string(); + break; + case /* api.ProjectConstraints InConstraints = 3 [json_name = "InConstraints"];*/ 3: + message.inConstraints = ProjectConstraints.internalBinaryRead(reader, reader.uint32(), options, message.inConstraints); + break; + case /* api.ProjectConstraints OutConstraints = 4 [json_name = "OutConstraints"];*/ 4: + message.outConstraints = ProjectConstraints.internalBinaryRead(reader, reader.uint32(), options, message.outConstraints); + 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: ProjectAuthorisation, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string OrganisationID = 1 [json_name = "OrganisationID"]; */ + if (message.organisationID !== "") + writer.tag(1, WireType.LengthDelimited).string(message.organisationID); + /* string ProjectID = 2 [json_name = "ProjectID"]; */ + if (message.projectID !== "") + writer.tag(2, WireType.LengthDelimited).string(message.projectID); + /* api.ProjectConstraints InConstraints = 3 [json_name = "InConstraints"]; */ + if (message.inConstraints) + ProjectConstraints.internalBinaryWrite(message.inConstraints, writer.tag(3, WireType.LengthDelimited).fork(), options).join(); + /* api.ProjectConstraints OutConstraints = 4 [json_name = "OutConstraints"]; */ + if (message.outConstraints) + ProjectConstraints.internalBinaryWrite(message.outConstraints, writer.tag(4, 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.ProjectAuthorisation + */ +export const ProjectAuthorisation = new ProjectAuthorisation$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class ProjectConstraints$Type extends MessageType { + constructor() { + super("api.ProjectConstraints", [ + { no: 1, name: "SegmentationConstraints", kind: "message", jsonName: "SegmentationConstraints", repeat: 1 /*RepeatType.PACKED*/, T: () => SegmentationConstraint, options: { "api.aggKey": "SegmentationID" } }, + { no: 2, name: "MinNoticePeriod", kind: "message", jsonName: "MinNoticePeriod", T: () => Period }, + { no: 3, name: "MaxBookingPeriod", kind: "message", jsonName: "MaxBookingPeriod", T: () => Period } + ]); + } + create(value?: PartialMessage): ProjectConstraints { + const message = globalThis.Object.create((this.messagePrototype!)); + message.segmentationConstraints = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ProjectConstraints): ProjectConstraints { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* repeated api.SegmentationConstraint SegmentationConstraints = 1 [json_name = "SegmentationConstraints"];*/ 1: + message.segmentationConstraints.push(SegmentationConstraint.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* api.Period MinNoticePeriod = 2 [json_name = "MinNoticePeriod"];*/ 2: + message.minNoticePeriod = Period.internalBinaryRead(reader, reader.uint32(), options, message.minNoticePeriod); + break; + case /* api.Period MaxBookingPeriod = 3 [json_name = "MaxBookingPeriod"];*/ 3: + message.maxBookingPeriod = Period.internalBinaryRead(reader, reader.uint32(), options, message.maxBookingPeriod); + 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: ProjectConstraints, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* repeated api.SegmentationConstraint SegmentationConstraints = 1 [json_name = "SegmentationConstraints"]; */ + for (let i = 0; i < message.segmentationConstraints.length; i++) + SegmentationConstraint.internalBinaryWrite(message.segmentationConstraints[i], writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.Period MinNoticePeriod = 2 [json_name = "MinNoticePeriod"]; */ + if (message.minNoticePeriod) + Period.internalBinaryWrite(message.minNoticePeriod, writer.tag(2, WireType.LengthDelimited).fork(), options).join(); + /* api.Period MaxBookingPeriod = 3 [json_name = "MaxBookingPeriod"]; */ + if (message.maxBookingPeriod) + Period.internalBinaryWrite(message.maxBookingPeriod, writer.tag(3, 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.ProjectConstraints + */ +export const ProjectConstraints = new ProjectConstraints$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class SegmentationConstraint$Type extends MessageType { + constructor() { + super("api.SegmentationConstraint", [ + { no: 1, name: "SegmentationID", kind: "scalar", jsonName: "SegmentationID", T: 9 /*ScalarType.STRING*/ }, + { no: 2, name: "RestrictedValueIDs", kind: "scalar", jsonName: "RestrictedValueIDs", repeat: 1 /*RepeatType.PACKED*/, T: 3 /*ScalarType.INT64*/, L: 0 /*LongType.BIGINT*/ }, + { no: 3, name: "AllValues", kind: "scalar", jsonName: "AllValues", T: 8 /*ScalarType.BOOL*/ } + ]); + } + create(value?: PartialMessage): SegmentationConstraint { + const message = globalThis.Object.create((this.messagePrototype!)); + message.segmentationID = ""; + message.restrictedValueIDs = []; + message.allValues = false; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: SegmentationConstraint): SegmentationConstraint { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string SegmentationID = 1 [json_name = "SegmentationID"];*/ 1: + message.segmentationID = reader.string(); + break; + case /* repeated int64 RestrictedValueIDs = 2 [json_name = "RestrictedValueIDs"];*/ 2: + if (wireType === WireType.LengthDelimited) + for (let e = reader.int32() + reader.pos; reader.pos < e;) + message.restrictedValueIDs.push(reader.int64().toBigInt()); + else + message.restrictedValueIDs.push(reader.int64().toBigInt()); + break; + case /* bool AllValues = 3 [json_name = "AllValues"];*/ 3: + message.allValues = 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: SegmentationConstraint, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string SegmentationID = 1 [json_name = "SegmentationID"]; */ + if (message.segmentationID !== "") + writer.tag(1, WireType.LengthDelimited).string(message.segmentationID); + /* repeated int64 RestrictedValueIDs = 2 [json_name = "RestrictedValueIDs"]; */ + if (message.restrictedValueIDs.length) { + writer.tag(2, WireType.LengthDelimited).fork(); + for (let i = 0; i < message.restrictedValueIDs.length; i++) + writer.int64(message.restrictedValueIDs[i]); + writer.join(); + } + /* bool AllValues = 3 [json_name = "AllValues"]; */ + if (message.allValues !== false) + writer.tag(3, WireType.Varint).bool(message.allValues); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.SegmentationConstraint + */ +export const SegmentationConstraint = new SegmentationConstraint$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class ActorAuthorisation$Type extends MessageType { + constructor() { + super("api.ActorAuthorisation", [ + { no: 3, name: "InConstraints", kind: "message", jsonName: "InConstraints", T: () => ActorConstraints }, + { no: 4, name: "OutConstraints", kind: "message", jsonName: "OutConstraints", T: () => ActorConstraints } + ]); + } + create(value?: PartialMessage): ActorAuthorisation { + const message = globalThis.Object.create((this.messagePrototype!)); + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ActorAuthorisation): ActorAuthorisation { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* api.ActorConstraints InConstraints = 3 [json_name = "InConstraints"];*/ 3: + message.inConstraints = ActorConstraints.internalBinaryRead(reader, reader.uint32(), options, message.inConstraints); + break; + case /* api.ActorConstraints OutConstraints = 4 [json_name = "OutConstraints"];*/ 4: + message.outConstraints = ActorConstraints.internalBinaryRead(reader, reader.uint32(), options, message.outConstraints); + 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: ActorAuthorisation, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* api.ActorConstraints InConstraints = 3 [json_name = "InConstraints"]; */ + if (message.inConstraints) + ActorConstraints.internalBinaryWrite(message.inConstraints, writer.tag(3, WireType.LengthDelimited).fork(), options).join(); + /* api.ActorConstraints OutConstraints = 4 [json_name = "OutConstraints"]; */ + if (message.outConstraints) + ActorConstraints.internalBinaryWrite(message.outConstraints, writer.tag(4, 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.ActorAuthorisation + */ +export const ActorAuthorisation = new ActorAuthorisation$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class ActorConstraints$Type extends MessageType { + constructor() { + super("api.ActorConstraints", [ + { no: 1, name: "SegmentationConstraints", kind: "message", jsonName: "SegmentationConstraints", repeat: 1 /*RepeatType.PACKED*/, T: () => SegmentationActorConstraint, options: { "api.aggKey": "SegmentationID" } }, + { no: 3, name: "MaxBookingPeriod", kind: "message", jsonName: "MaxBookingPeriod", T: () => Period } + ]); + } + create(value?: PartialMessage): ActorConstraints { + const message = globalThis.Object.create((this.messagePrototype!)); + message.segmentationConstraints = []; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ActorConstraints): ActorConstraints { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* repeated api.SegmentationActorConstraint SegmentationConstraints = 1 [json_name = "SegmentationConstraints"];*/ 1: + message.segmentationConstraints.push(SegmentationActorConstraint.internalBinaryRead(reader, reader.uint32(), options)); + break; + case /* api.Period MaxBookingPeriod = 3 [json_name = "MaxBookingPeriod"];*/ 3: + message.maxBookingPeriod = Period.internalBinaryRead(reader, reader.uint32(), options, message.maxBookingPeriod); + 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: ActorConstraints, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* repeated api.SegmentationActorConstraint SegmentationConstraints = 1 [json_name = "SegmentationConstraints"]; */ + for (let i = 0; i < message.segmentationConstraints.length; i++) + SegmentationActorConstraint.internalBinaryWrite(message.segmentationConstraints[i], writer.tag(1, WireType.LengthDelimited).fork(), options).join(); + /* api.Period MaxBookingPeriod = 3 [json_name = "MaxBookingPeriod"]; */ + if (message.maxBookingPeriod) + Period.internalBinaryWrite(message.maxBookingPeriod, writer.tag(3, 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.ActorConstraints + */ +export const ActorConstraints = new ActorConstraints$Type(); +// @generated message type with reflection information, may provide speed optimized methods +class SegmentationActorConstraint$Type extends MessageType { + constructor() { + super("api.SegmentationActorConstraint", [ + { no: 1, name: "SegmentationID", kind: "scalar", jsonName: "SegmentationID", T: 9 /*ScalarType.STRING*/ }, + { no: 2, name: "RestrictedValueIDs", kind: "scalar", jsonName: "RestrictedValueIDs", repeat: 1 /*RepeatType.PACKED*/, T: 3 /*ScalarType.INT64*/, L: 0 /*LongType.BIGINT*/ }, + { no: 3, name: "AllValues", kind: "scalar", jsonName: "AllValues", T: 8 /*ScalarType.BOOL*/ }, + { no: 4, name: "Type", kind: "enum", jsonName: "Type", T: () => ["api.SegmentationConstraintType", SegmentationConstraintType] }, + { no: 5, name: "AttributePath", kind: "scalar", jsonName: "AttributePath", T: 9 /*ScalarType.STRING*/ } + ]); + } + create(value?: PartialMessage): SegmentationActorConstraint { + const message = globalThis.Object.create((this.messagePrototype!)); + message.segmentationID = ""; + message.restrictedValueIDs = []; + message.allValues = false; + message.type = 0; + message.attributePath = ""; + if (value !== undefined) + reflectionMergePartial(this, message, value); + return message; + } + internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: SegmentationActorConstraint): SegmentationActorConstraint { + let message = target ?? this.create(), end = reader.pos + length; + while (reader.pos < end) { + let [fieldNo, wireType] = reader.tag(); + switch (fieldNo) { + case /* string SegmentationID = 1 [json_name = "SegmentationID"];*/ 1: + message.segmentationID = reader.string(); + break; + case /* repeated int64 RestrictedValueIDs = 2 [json_name = "RestrictedValueIDs"];*/ 2: + if (wireType === WireType.LengthDelimited) + for (let e = reader.int32() + reader.pos; reader.pos < e;) + message.restrictedValueIDs.push(reader.int64().toBigInt()); + else + message.restrictedValueIDs.push(reader.int64().toBigInt()); + break; + case /* bool AllValues = 3 [json_name = "AllValues"];*/ 3: + message.allValues = reader.bool(); + break; + case /* api.SegmentationConstraintType Type = 4 [json_name = "Type"];*/ 4: + message.type = reader.int32(); + break; + case /* string AttributePath = 5 [json_name = "AttributePath"];*/ 5: + message.attributePath = 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: SegmentationActorConstraint, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter { + /* string SegmentationID = 1 [json_name = "SegmentationID"]; */ + if (message.segmentationID !== "") + writer.tag(1, WireType.LengthDelimited).string(message.segmentationID); + /* repeated int64 RestrictedValueIDs = 2 [json_name = "RestrictedValueIDs"]; */ + if (message.restrictedValueIDs.length) { + writer.tag(2, WireType.LengthDelimited).fork(); + for (let i = 0; i < message.restrictedValueIDs.length; i++) + writer.int64(message.restrictedValueIDs[i]); + writer.join(); + } + /* bool AllValues = 3 [json_name = "AllValues"]; */ + if (message.allValues !== false) + writer.tag(3, WireType.Varint).bool(message.allValues); + /* api.SegmentationConstraintType Type = 4 [json_name = "Type"]; */ + if (message.type !== 0) + writer.tag(4, WireType.Varint).int32(message.type); + /* string AttributePath = 5 [json_name = "AttributePath"]; */ + if (message.attributePath !== "") + writer.tag(5, WireType.LengthDelimited).string(message.attributePath); + let u = options.writeUnknownFields; + if (u !== false) + (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer); + return writer; + } +} +/** + * @generated MessageType for protobuf message api.SegmentationActorConstraint + */ +export const SegmentationActorConstraint = new SegmentationActorConstraint$Type();