You've already forked npm-core-sdk
1999 lines
105 KiB
TypeScript
1999 lines
105 KiB
TypeScript
// @generated by protobuf-ts 2.11.0 with parameter use_proto_field_name,keep_enum_prefix
|
|
// @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 { CarrierInformationWithValue } from "./slotbooking";
|
|
import { SlotGroup } from "./slotbooking";
|
|
import { Commission } from "./slotbooking";
|
|
import { AppointmentType } from "./slotbooking";
|
|
import { RequestSiteHeader } from "./shared";
|
|
import { RequestOrganisationHeader } from "./shared";
|
|
import { CarrierInformation } from "./slotbooking";
|
|
import { Document } from "./slotbooking";
|
|
import { Instruction } from "./slotbooking";
|
|
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
|
|
*/
|
|
ID: string; // Unique identifier for the site. (formatted as such: "SITE_<OrganisationID>_<UUID>")
|
|
/**
|
|
* Name of the Site
|
|
*
|
|
* @generated from protobuf field: string Name = 2
|
|
*/
|
|
Name: string;
|
|
/**
|
|
* Identifier for the organisation associated with the site.
|
|
*
|
|
* @generated from protobuf field: string OrganisationID = 3
|
|
*/
|
|
OrganisationID: string;
|
|
/**
|
|
* @generated from protobuf field: bool Active = 4
|
|
*/
|
|
Active: boolean; // If the Site is active or not
|
|
/**
|
|
* @generated from protobuf field: string PhotoURI = 5
|
|
*/
|
|
PhotoURI: string; // Link to a picture to display
|
|
/**
|
|
* @generated from protobuf field: api.Address Address = 6
|
|
*/
|
|
Address?: Address; // Address of the Site
|
|
/**
|
|
* @generated from protobuf field: repeated string Phones = 7
|
|
*/
|
|
Phones: string[];
|
|
/**
|
|
* @generated from protobuf field: string Fax = 8
|
|
*/
|
|
Fax: string;
|
|
/**
|
|
* List of Segmentations that segment the logistic site.
|
|
*
|
|
* @generated from protobuf field: repeated api.Segmentation Segmentations = 9
|
|
*/
|
|
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
|
|
*/
|
|
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
|
|
*/
|
|
Units: Unit[]; // après le champs
|
|
/**
|
|
* Definition of the opening rules. 2 opening rule definitions cannot overlap.
|
|
*
|
|
* @generated from protobuf field: repeated api.OpeningRule OpeningRules = 12
|
|
*/
|
|
OpeningRules: OpeningRule[];
|
|
/**
|
|
* Definition of the booking slot duration rules.
|
|
*
|
|
* @generated from protobuf field: repeated api.DurationRule DurationRules = 13
|
|
*/
|
|
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
|
|
*/
|
|
CapacityRules: CapacityRule[];
|
|
/**
|
|
* @generated from protobuf field: api.Instruction Instruction = 15
|
|
*/
|
|
Instruction?: Instruction;
|
|
/**
|
|
* Set of instruction document, listing necessary equipment and such
|
|
*
|
|
* @generated from protobuf field: repeated api.Document InstructionDocuments = 16
|
|
*/
|
|
InstructionDocuments: Document[];
|
|
/**
|
|
* Set of required or optional information to ask when a slot is booked
|
|
*
|
|
* @generated from protobuf field: repeated api.CarrierInformation CarrierInformation = 17
|
|
*/
|
|
CarrierInformation: CarrierInformation[];
|
|
/**
|
|
* Defines the rounded value to define booking period
|
|
*
|
|
* @generated from protobuf field: uint32 RoundedPeriodInMinutes = 18
|
|
*/
|
|
RoundedPeriodInMinutes: number;
|
|
/**
|
|
* Site Time zone
|
|
*
|
|
* @generated from protobuf field: string TimeZone = 19
|
|
*/
|
|
TimeZone: string;
|
|
/**
|
|
* Must be a valid email address
|
|
*
|
|
* @generated from protobuf field: repeated string Emails = 20
|
|
*/
|
|
Emails: string[];
|
|
/**
|
|
* Set the fallback language in case of missing translation
|
|
*
|
|
* @generated from protobuf field: string DefaultSiteLanguageISO6391 = 21
|
|
*/
|
|
DefaultSiteLanguageISO6391: string;
|
|
}
|
|
// ========== REQUESTS & RESPONSE MESSAGES ==========
|
|
|
|
/**
|
|
* Create
|
|
*
|
|
* @generated from protobuf message api.CreateSiteRequest
|
|
*/
|
|
export interface CreateSiteRequest {
|
|
/**
|
|
* @generated from protobuf field: api.RequestOrganisationHeader Header = 1
|
|
*/
|
|
Header?: RequestOrganisationHeader;
|
|
/**
|
|
* Identifier of the new Site
|
|
*
|
|
* @generated from protobuf field: string SiteID = 2
|
|
*/
|
|
SiteID: string;
|
|
/**
|
|
* Name of the new Site, modifiable after creation
|
|
*
|
|
* @generated from protobuf field: string SiteName = 3
|
|
*/
|
|
SiteName: string;
|
|
/**
|
|
* Must be a valid email address from a user know to the platform
|
|
*
|
|
* @generated from protobuf field: string Email = 4
|
|
*/
|
|
Email: string;
|
|
}
|
|
/**
|
|
* @generated from protobuf message api.CreateSiteResponse
|
|
*/
|
|
export interface CreateSiteResponse {
|
|
/**
|
|
* @generated from protobuf field: api.Site Site = 1
|
|
*/
|
|
Site?: Site;
|
|
}
|
|
/**
|
|
* Get
|
|
*
|
|
* @generated from protobuf message api.GetSiteRequest
|
|
*/
|
|
export interface GetSiteRequest {
|
|
/**
|
|
* @generated from protobuf field: api.RequestSiteHeader Header = 1
|
|
*/
|
|
Header?: RequestSiteHeader;
|
|
}
|
|
/**
|
|
* @generated from protobuf message api.GetSiteResponse
|
|
*/
|
|
export interface GetSiteResponse {
|
|
/**
|
|
* @generated from protobuf field: api.Site Site = 1
|
|
*/
|
|
Site?: Site;
|
|
}
|
|
/**
|
|
* List
|
|
*
|
|
* @generated from protobuf message api.ListSiteRequest
|
|
*/
|
|
export interface ListSiteRequest {
|
|
/**
|
|
* @generated from protobuf field: api.RequestOrganisationHeader Header = 1
|
|
*/
|
|
Header?: RequestOrganisationHeader;
|
|
}
|
|
/**
|
|
* @generated from protobuf message api.ListSiteResponse
|
|
*/
|
|
export interface ListSiteResponse {
|
|
/**
|
|
* @generated from protobuf field: repeated api.Site Sites = 1
|
|
*/
|
|
Sites: Site[];
|
|
}
|
|
/**
|
|
* Update
|
|
*
|
|
* @generated from protobuf message api.UpdateSiteRequest
|
|
*/
|
|
export interface UpdateSiteRequest {
|
|
/**
|
|
* @generated from protobuf field: api.RequestSiteHeader Header = 1
|
|
*/
|
|
Header?: RequestSiteHeader;
|
|
/**
|
|
* Name of the Site
|
|
*
|
|
* @generated from protobuf field: string Name = 3
|
|
*/
|
|
Name: string;
|
|
/**
|
|
* @generated from protobuf field: bool Active = 4
|
|
*/
|
|
Active: boolean; // If the Site is active or not
|
|
/**
|
|
* @generated from protobuf field: string PhotoURI = 5
|
|
*/
|
|
PhotoURI: string; // link to a picture to display
|
|
/**
|
|
* @generated from protobuf field: api.Address Address = 6
|
|
*/
|
|
Address?: Address; // address of the Site
|
|
/**
|
|
* @generated from protobuf field: repeated string Phones = 7
|
|
*/
|
|
Phones: string[];
|
|
/**
|
|
* @generated from protobuf field: string Fax = 8
|
|
*/
|
|
Fax: string;
|
|
/**
|
|
* List of Segmentations that segment the logistic site.
|
|
*
|
|
* @generated from protobuf field: repeated api.Segmentation Segmentations = 9
|
|
*/
|
|
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
|
|
*/
|
|
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
|
|
*/
|
|
Units: Unit[];
|
|
/**
|
|
* Definition of the opening rules. 2 opening rule definitions cannot overlap.
|
|
*
|
|
* @generated from protobuf field: repeated api.OpeningRule OpeningRules = 12
|
|
*/
|
|
OpeningRules: OpeningRule[];
|
|
/**
|
|
* Definition of the booking slot duration rules.
|
|
*
|
|
* @generated from protobuf field: repeated api.DurationRule DurationRules = 13
|
|
*/
|
|
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
|
|
*/
|
|
CapacityRules: CapacityRule[];
|
|
/**
|
|
* @generated from protobuf field: api.Instruction Instruction = 15
|
|
*/
|
|
Instruction?: Instruction;
|
|
/**
|
|
* Set of instruction document, listing necessary equipment and such
|
|
*
|
|
* @generated from protobuf field: repeated api.Document InstructionDocuments = 16
|
|
*/
|
|
InstructionDocuments: Document[];
|
|
/**
|
|
* Set of required or optional information to ask when a slot is booked
|
|
*
|
|
* @generated from protobuf field: repeated api.CarrierInformation CarrierInformation = 17
|
|
*/
|
|
CarrierInformation: CarrierInformation[];
|
|
/**
|
|
* Defines the rounded value of periods in minutes, must be greater than 0.
|
|
*
|
|
* @generated from protobuf field: uint32 RoundedPeriodInMinutes = 18
|
|
*/
|
|
RoundedPeriodInMinutes: number;
|
|
/**
|
|
* Add Site Time zone
|
|
*
|
|
* @generated from protobuf field: string TimeZone = 19
|
|
*/
|
|
TimeZone: string;
|
|
/**
|
|
* Must be a valid email address
|
|
*
|
|
* @generated from protobuf field: repeated string Emails = 20
|
|
*/
|
|
Emails: string[];
|
|
/**
|
|
* set the fallback language in case of missing translation
|
|
*
|
|
* @generated from protobuf field: string DefaultSiteLanguageISO6391 = 21
|
|
*/
|
|
DefaultSiteLanguageISO6391: string;
|
|
}
|
|
/**
|
|
* @generated from protobuf message api.UpdateSiteResponse
|
|
*/
|
|
export interface UpdateSiteResponse {
|
|
/**
|
|
* @generated from protobuf field: api.Site Site = 1
|
|
*/
|
|
Site?: Site;
|
|
}
|
|
/**
|
|
* Delete
|
|
*
|
|
* @generated from protobuf message api.DeleteSiteRequest
|
|
*/
|
|
export interface DeleteSiteRequest {
|
|
/**
|
|
* @generated from protobuf field: api.RequestOrganisationHeader Header = 1
|
|
*/
|
|
Header?: RequestOrganisationHeader;
|
|
/**
|
|
* @generated from protobuf field: string ID = 2
|
|
*/
|
|
ID: string;
|
|
}
|
|
/**
|
|
* @generated from protobuf message api.DeleteSiteResponse
|
|
*/
|
|
export interface DeleteSiteResponse {
|
|
}
|
|
/**
|
|
* SuggestID
|
|
*
|
|
* @generated from protobuf message api.SuggestSiteIDRequest
|
|
*/
|
|
export interface SuggestSiteIDRequest {
|
|
/**
|
|
* @generated from protobuf field: api.RequestOrganisationHeader Header = 3
|
|
*/
|
|
Header?: RequestOrganisationHeader;
|
|
/**
|
|
* @generated from protobuf field: string Name = 2
|
|
*/
|
|
Name: string;
|
|
}
|
|
/**
|
|
* @generated from protobuf message api.SuggestSiteIDResult
|
|
*/
|
|
export interface SuggestSiteIDResult {
|
|
/**
|
|
* @generated from protobuf field: string SiteID = 1
|
|
*/
|
|
SiteID: string;
|
|
}
|
|
/**
|
|
* GetAvailableSlots
|
|
*
|
|
* @generated from protobuf message api.GetAvailableSlotsRequest
|
|
*/
|
|
export interface GetAvailableSlotsRequest {
|
|
/**
|
|
* @generated from protobuf field: api.RequestSiteHeader Header = 1
|
|
*/
|
|
Header?: RequestSiteHeader;
|
|
/**
|
|
* Type of appointment : Expedition / Reception / Both
|
|
*
|
|
* @generated from protobuf field: api.AppointmentType AppointmentType = 2
|
|
*/
|
|
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
|
|
*/
|
|
Commissions: Commission[];
|
|
/**
|
|
* Set of segmentation constraining the slot booking
|
|
*
|
|
* @generated from protobuf field: repeated api.Segmentation Segmentations = 4
|
|
*/
|
|
Segmentations: Segmentation[];
|
|
/**
|
|
* @generated from protobuf field: string StartDate = 5
|
|
*/
|
|
StartDate: string; // Start date of the range to look for available slots, format yyyy-mm-dd.
|
|
/**
|
|
* @generated from protobuf field: string EndDate = 6
|
|
*/
|
|
EndDate: string; // End date of the range to look for available slots, format yyyy-mm-dd.
|
|
}
|
|
/**
|
|
* @generated from protobuf message api.GetAvailableSlotsResponse
|
|
*/
|
|
export interface GetAvailableSlotsResponse {
|
|
/**
|
|
* @generated from protobuf field: repeated api.SlotGroup SlotGroups = 1
|
|
*/
|
|
SlotGroups: SlotGroup[]; // List of slot groups available for the current request
|
|
}
|
|
/**
|
|
* BookAppointment
|
|
*
|
|
* @generated from protobuf message api.BookAppointmentRequest
|
|
*/
|
|
export interface BookAppointmentRequest {
|
|
/**
|
|
* @generated from protobuf field: api.RequestSiteHeader Header = 1
|
|
*/
|
|
Header?: RequestSiteHeader;
|
|
/**
|
|
* Type of appointment : Expedition / Reception / Both
|
|
*
|
|
* @generated from protobuf field: api.AppointmentType AppointmentType = 2
|
|
*/
|
|
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
|
|
*/
|
|
Commissions: Commission[];
|
|
/**
|
|
* Set of segmentation constraining the slot booking
|
|
*
|
|
* @generated from protobuf field: repeated api.Segmentation Segmentations = 4
|
|
*/
|
|
Segmentations: Segmentation[];
|
|
/**
|
|
* Required carrierInformation, some can be obligatory
|
|
*
|
|
* @generated from protobuf field: repeated api.CarrierInformationWithValue CarrierInformation = 5
|
|
*/
|
|
CarrierInformation: CarrierInformationWithValue[];
|
|
/**
|
|
* The slot to book for the appointment
|
|
*
|
|
* @generated from protobuf field: repeated api.Slot Slots = 6
|
|
*/
|
|
Slots: Slot[];
|
|
/**
|
|
* TODO Need to add a structure to store platform user identifiers which can act on this appointment ?
|
|
* User mails being notified on this appointment
|
|
*
|
|
* @generated from protobuf field: repeated string Emails = 8
|
|
*/
|
|
Emails: string[];
|
|
/**
|
|
* The carrier identifier who requests to book the appointment
|
|
*
|
|
* @generated from protobuf field: string CarrierID = 9
|
|
*/
|
|
CarrierID: string;
|
|
/**
|
|
* The carrier name who requests to book the appointment
|
|
*
|
|
* @generated from protobuf field: string CarrierName = 10
|
|
*/
|
|
CarrierName: string;
|
|
}
|
|
/**
|
|
* @generated from protobuf message api.BookAppointmentResponse
|
|
*/
|
|
export interface BookAppointmentResponse {
|
|
/**
|
|
* @generated from protobuf field: string AppointmentID = 1
|
|
*/
|
|
AppointmentID: string;
|
|
}
|
|
/**
|
|
* CancelAppointment
|
|
*
|
|
* @generated from protobuf message api.CancelAppointmentRequest
|
|
*/
|
|
export interface CancelAppointmentRequest {
|
|
/**
|
|
* @generated from protobuf field: api.RequestSiteHeader Header = 1
|
|
*/
|
|
Header?: RequestSiteHeader;
|
|
/**
|
|
* @generated from protobuf field: string AppointmentID = 2
|
|
*/
|
|
AppointmentID: string;
|
|
}
|
|
/**
|
|
* @generated from protobuf message api.CancelAppointmentResponse
|
|
*/
|
|
export interface CancelAppointmentResponse {
|
|
/**
|
|
* @generated from protobuf field: string AppointmentID = 1
|
|
*/
|
|
AppointmentID: string;
|
|
}
|
|
/**
|
|
* ListUserSites
|
|
*
|
|
* @generated from protobuf message api.ListUserSitesRequest
|
|
*/
|
|
export interface ListUserSitesRequest {
|
|
/**
|
|
* TODO optional filter
|
|
*
|
|
* @generated from protobuf field: repeated string ProjectID = 1
|
|
*/
|
|
ProjectID: string[];
|
|
}
|
|
/**
|
|
* @generated from protobuf message api.ListUserSitesResponse
|
|
*/
|
|
export interface ListUserSitesResponse {
|
|
/**
|
|
* @generated from protobuf field: repeated api.Site Sites = 1
|
|
*/
|
|
Sites: Site[];
|
|
}
|
|
// @generated message type with reflection information, may provide speed optimized methods
|
|
class Site$Type extends MessageType<Site> {
|
|
constructor() {
|
|
super("api.Site", [
|
|
{ no: 1, name: "ID", kind: "scalar", localName: "ID", jsonName: "ID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } },
|
|
{ no: 2, name: "Name", kind: "scalar", localName: "Name", jsonName: "Name", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } },
|
|
{ no: 3, name: "OrganisationID", kind: "scalar", localName: "OrganisationID", jsonName: "OrganisationID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } },
|
|
{ no: 4, name: "Active", kind: "scalar", localName: "Active", jsonName: "Active", T: 8 /*ScalarType.BOOL*/ },
|
|
{ no: 5, name: "PhotoURI", kind: "scalar", localName: "PhotoURI", jsonName: "PhotoURI", T: 9 /*ScalarType.STRING*/ },
|
|
{ no: 6, name: "Address", kind: "message", localName: "Address", jsonName: "Address", T: () => Address },
|
|
{ no: 7, name: "Phones", kind: "scalar", localName: "Phones", 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", localName: "Fax", jsonName: "Fax", T: 9 /*ScalarType.STRING*/, options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { example: "[\"06 00 00 00 00\"]" } } },
|
|
{ no: 9, name: "Segmentations", kind: "message", localName: "Segmentations", jsonName: "Segmentations", repeat: 2 /*RepeatType.UNPACKED*/, T: () => Segmentation },
|
|
{ no: 10, name: "Authorisations", kind: "message", localName: "Authorisations", jsonName: "Authorisations", repeat: 2 /*RepeatType.UNPACKED*/, T: () => ProjectAuthorisation },
|
|
{ no: 11, name: "Units", kind: "message", localName: "Units", jsonName: "Units", repeat: 2 /*RepeatType.UNPACKED*/, T: () => Unit, options: { "validate.rules": { repeated: { minItems: "1" } } } },
|
|
{ no: 12, name: "OpeningRules", kind: "message", localName: "OpeningRules", jsonName: "OpeningRules", repeat: 2 /*RepeatType.UNPACKED*/, T: () => OpeningRule },
|
|
{ no: 13, name: "DurationRules", kind: "message", localName: "DurationRules", jsonName: "DurationRules", repeat: 2 /*RepeatType.UNPACKED*/, T: () => DurationRule },
|
|
{ no: 14, name: "CapacityRules", kind: "message", localName: "CapacityRules", jsonName: "CapacityRules", repeat: 2 /*RepeatType.UNPACKED*/, T: () => CapacityRule },
|
|
{ no: 15, name: "Instruction", kind: "message", localName: "Instruction", jsonName: "Instruction", T: () => Instruction },
|
|
{ no: 16, name: "InstructionDocuments", kind: "message", localName: "InstructionDocuments", jsonName: "InstructionDocuments", repeat: 2 /*RepeatType.UNPACKED*/, T: () => Document },
|
|
{ no: 17, name: "CarrierInformation", kind: "message", localName: "CarrierInformation", jsonName: "CarrierInformation", repeat: 2 /*RepeatType.UNPACKED*/, T: () => CarrierInformation },
|
|
{ no: 18, name: "RoundedPeriodInMinutes", kind: "scalar", localName: "RoundedPeriodInMinutes", jsonName: "RoundedPeriodInMinutes", T: 13 /*ScalarType.UINT32*/ },
|
|
{ no: 19, name: "TimeZone", kind: "scalar", localName: "TimeZone", jsonName: "TimeZone", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1", tzData: true } }, "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "Site time zone <a href='https://en.wikipedia.org/wiki/List_of_tz_database_time_zones'>format</a>", example: "\"Europe/Paris\"" } } },
|
|
{ no: 20, name: "Emails", kind: "scalar", localName: "Emails", 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: 21, name: "DefaultSiteLanguageISO6391", kind: "scalar", localName: "DefaultSiteLanguageISO6391", 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: "<a href='https://en.wikipedia.org/wiki/List_of_ISO_639_language_codes'>ISO 639 code</a> message language", example: "\"en\"" } } }
|
|
]);
|
|
}
|
|
create(value?: PartialMessage<Site>): 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.InstructionDocuments = [];
|
|
message.CarrierInformation = [];
|
|
message.RoundedPeriodInMinutes = 0;
|
|
message.TimeZone = "";
|
|
message.Emails = [];
|
|
message.DefaultSiteLanguageISO6391 = "";
|
|
if (value !== undefined)
|
|
reflectionMergePartial<Site>(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:
|
|
message.ID = reader.string();
|
|
break;
|
|
case /* string Name */ 2:
|
|
message.Name = reader.string();
|
|
break;
|
|
case /* string OrganisationID */ 3:
|
|
message.OrganisationID = reader.string();
|
|
break;
|
|
case /* bool Active */ 4:
|
|
message.Active = reader.bool();
|
|
break;
|
|
case /* string PhotoURI */ 5:
|
|
message.PhotoURI = reader.string();
|
|
break;
|
|
case /* api.Address Address */ 6:
|
|
message.Address = Address.internalBinaryRead(reader, reader.uint32(), options, message.Address);
|
|
break;
|
|
case /* repeated string Phones */ 7:
|
|
message.Phones.push(reader.string());
|
|
break;
|
|
case /* string Fax */ 8:
|
|
message.Fax = reader.string();
|
|
break;
|
|
case /* repeated api.Segmentation Segmentations */ 9:
|
|
message.Segmentations.push(Segmentation.internalBinaryRead(reader, reader.uint32(), options));
|
|
break;
|
|
case /* repeated api.ProjectAuthorisation Authorisations */ 10:
|
|
message.Authorisations.push(ProjectAuthorisation.internalBinaryRead(reader, reader.uint32(), options));
|
|
break;
|
|
case /* repeated api.Unit Units */ 11:
|
|
message.Units.push(Unit.internalBinaryRead(reader, reader.uint32(), options));
|
|
break;
|
|
case /* repeated api.OpeningRule OpeningRules */ 12:
|
|
message.OpeningRules.push(OpeningRule.internalBinaryRead(reader, reader.uint32(), options));
|
|
break;
|
|
case /* repeated api.DurationRule DurationRules */ 13:
|
|
message.DurationRules.push(DurationRule.internalBinaryRead(reader, reader.uint32(), options));
|
|
break;
|
|
case /* repeated api.CapacityRule CapacityRules */ 14:
|
|
message.CapacityRules.push(CapacityRule.internalBinaryRead(reader, reader.uint32(), options));
|
|
break;
|
|
case /* api.Instruction Instruction */ 15:
|
|
message.Instruction = Instruction.internalBinaryRead(reader, reader.uint32(), options, message.Instruction);
|
|
break;
|
|
case /* repeated api.Document InstructionDocuments */ 16:
|
|
message.InstructionDocuments.push(Document.internalBinaryRead(reader, reader.uint32(), options));
|
|
break;
|
|
case /* repeated api.CarrierInformation CarrierInformation */ 17:
|
|
message.CarrierInformation.push(CarrierInformation.internalBinaryRead(reader, reader.uint32(), options));
|
|
break;
|
|
case /* uint32 RoundedPeriodInMinutes */ 18:
|
|
message.RoundedPeriodInMinutes = reader.uint32();
|
|
break;
|
|
case /* string TimeZone */ 19:
|
|
message.TimeZone = reader.string();
|
|
break;
|
|
case /* repeated string Emails */ 20:
|
|
message.Emails.push(reader.string());
|
|
break;
|
|
case /* string DefaultSiteLanguageISO6391 */ 21:
|
|
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; */
|
|
if (message.ID !== "")
|
|
writer.tag(1, WireType.LengthDelimited).string(message.ID);
|
|
/* string Name = 2; */
|
|
if (message.Name !== "")
|
|
writer.tag(2, WireType.LengthDelimited).string(message.Name);
|
|
/* string OrganisationID = 3; */
|
|
if (message.OrganisationID !== "")
|
|
writer.tag(3, WireType.LengthDelimited).string(message.OrganisationID);
|
|
/* bool Active = 4; */
|
|
if (message.Active !== false)
|
|
writer.tag(4, WireType.Varint).bool(message.Active);
|
|
/* string PhotoURI = 5; */
|
|
if (message.PhotoURI !== "")
|
|
writer.tag(5, WireType.LengthDelimited).string(message.PhotoURI);
|
|
/* api.Address Address = 6; */
|
|
if (message.Address)
|
|
Address.internalBinaryWrite(message.Address, writer.tag(6, WireType.LengthDelimited).fork(), options).join();
|
|
/* repeated string Phones = 7; */
|
|
for (let i = 0; i < message.Phones.length; i++)
|
|
writer.tag(7, WireType.LengthDelimited).string(message.Phones[i]);
|
|
/* string Fax = 8; */
|
|
if (message.Fax !== "")
|
|
writer.tag(8, WireType.LengthDelimited).string(message.Fax);
|
|
/* repeated api.Segmentation Segmentations = 9; */
|
|
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; */
|
|
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; */
|
|
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; */
|
|
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; */
|
|
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; */
|
|
for (let i = 0; i < message.CapacityRules.length; i++)
|
|
CapacityRule.internalBinaryWrite(message.CapacityRules[i], writer.tag(14, WireType.LengthDelimited).fork(), options).join();
|
|
/* api.Instruction Instruction = 15; */
|
|
if (message.Instruction)
|
|
Instruction.internalBinaryWrite(message.Instruction, writer.tag(15, WireType.LengthDelimited).fork(), options).join();
|
|
/* repeated api.Document InstructionDocuments = 16; */
|
|
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 CarrierInformation = 17; */
|
|
for (let i = 0; i < message.CarrierInformation.length; i++)
|
|
CarrierInformation.internalBinaryWrite(message.CarrierInformation[i], writer.tag(17, WireType.LengthDelimited).fork(), options).join();
|
|
/* uint32 RoundedPeriodInMinutes = 18; */
|
|
if (message.RoundedPeriodInMinutes !== 0)
|
|
writer.tag(18, WireType.Varint).uint32(message.RoundedPeriodInMinutes);
|
|
/* string TimeZone = 19; */
|
|
if (message.TimeZone !== "")
|
|
writer.tag(19, WireType.LengthDelimited).string(message.TimeZone);
|
|
/* repeated string Emails = 20; */
|
|
for (let i = 0; i < message.Emails.length; i++)
|
|
writer.tag(20, WireType.LengthDelimited).string(message.Emails[i]);
|
|
/* string DefaultSiteLanguageISO6391 = 21; */
|
|
if (message.DefaultSiteLanguageISO6391 !== "")
|
|
writer.tag(21, 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<CreateSiteRequest> {
|
|
constructor() {
|
|
super("api.CreateSiteRequest", [
|
|
{ no: 1, name: "Header", kind: "message", localName: "Header", jsonName: "Header", T: () => RequestOrganisationHeader, options: { "validate.rules": { message: { required: true } } } },
|
|
{ no: 2, name: "SiteID", kind: "scalar", localName: "SiteID", jsonName: "SiteID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } },
|
|
{ no: 3, name: "SiteName", kind: "scalar", localName: "SiteName", jsonName: "SiteName", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } },
|
|
{ no: 4, name: "Email", kind: "scalar", localName: "Email", jsonName: "Email", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1", email: true } } } }
|
|
], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "SiteID", "Email", "SiteName"] } } });
|
|
}
|
|
create(value?: PartialMessage<CreateSiteRequest>): CreateSiteRequest {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
message.SiteID = "";
|
|
message.SiteName = "";
|
|
message.Email = "";
|
|
if (value !== undefined)
|
|
reflectionMergePartial<CreateSiteRequest>(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:
|
|
message.Header = RequestOrganisationHeader.internalBinaryRead(reader, reader.uint32(), options, message.Header);
|
|
break;
|
|
case /* string SiteID */ 2:
|
|
message.SiteID = reader.string();
|
|
break;
|
|
case /* string SiteName */ 3:
|
|
message.SiteName = reader.string();
|
|
break;
|
|
case /* string Email */ 4:
|
|
message.Email = 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; */
|
|
if (message.Header)
|
|
RequestOrganisationHeader.internalBinaryWrite(message.Header, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
/* string SiteID = 2; */
|
|
if (message.SiteID !== "")
|
|
writer.tag(2, WireType.LengthDelimited).string(message.SiteID);
|
|
/* string SiteName = 3; */
|
|
if (message.SiteName !== "")
|
|
writer.tag(3, WireType.LengthDelimited).string(message.SiteName);
|
|
/* string Email = 4; */
|
|
if (message.Email !== "")
|
|
writer.tag(4, WireType.LengthDelimited).string(message.Email);
|
|
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<CreateSiteResponse> {
|
|
constructor() {
|
|
super("api.CreateSiteResponse", [
|
|
{ no: 1, name: "Site", kind: "message", localName: "Site", jsonName: "Site", T: () => Site, options: { "validate.rules": { message: { required: true } } } }
|
|
]);
|
|
}
|
|
create(value?: PartialMessage<CreateSiteResponse>): CreateSiteResponse {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
if (value !== undefined)
|
|
reflectionMergePartial<CreateSiteResponse>(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:
|
|
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; */
|
|
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<GetSiteRequest> {
|
|
constructor() {
|
|
super("api.GetSiteRequest", [
|
|
{ no: 1, name: "Header", kind: "message", localName: "Header", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } }
|
|
], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header"] } } });
|
|
}
|
|
create(value?: PartialMessage<GetSiteRequest>): GetSiteRequest {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
if (value !== undefined)
|
|
reflectionMergePartial<GetSiteRequest>(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.RequestSiteHeader 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: GetSiteRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
/* api.RequestSiteHeader Header = 1; */
|
|
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.GetSiteRequest
|
|
*/
|
|
export const GetSiteRequest = new GetSiteRequest$Type();
|
|
// @generated message type with reflection information, may provide speed optimized methods
|
|
class GetSiteResponse$Type extends MessageType<GetSiteResponse> {
|
|
constructor() {
|
|
super("api.GetSiteResponse", [
|
|
{ no: 1, name: "Site", kind: "message", localName: "Site", jsonName: "Site", T: () => Site, options: { "validate.rules": { message: { required: true } } } }
|
|
]);
|
|
}
|
|
create(value?: PartialMessage<GetSiteResponse>): GetSiteResponse {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
if (value !== undefined)
|
|
reflectionMergePartial<GetSiteResponse>(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:
|
|
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; */
|
|
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<ListSiteRequest> {
|
|
constructor() {
|
|
super("api.ListSiteRequest", [
|
|
{ no: 1, name: "Header", kind: "message", localName: "Header", 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>): ListSiteRequest {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
if (value !== undefined)
|
|
reflectionMergePartial<ListSiteRequest>(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:
|
|
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; */
|
|
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<ListSiteResponse> {
|
|
constructor() {
|
|
super("api.ListSiteResponse", [
|
|
{ no: 1, name: "Sites", kind: "message", localName: "Sites", jsonName: "Sites", repeat: 2 /*RepeatType.UNPACKED*/, T: () => Site }
|
|
]);
|
|
}
|
|
create(value?: PartialMessage<ListSiteResponse>): ListSiteResponse {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
message.Sites = [];
|
|
if (value !== undefined)
|
|
reflectionMergePartial<ListSiteResponse>(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:
|
|
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; */
|
|
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<UpdateSiteRequest> {
|
|
constructor() {
|
|
super("api.UpdateSiteRequest", [
|
|
{ no: 1, name: "Header", kind: "message", localName: "Header", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } },
|
|
{ no: 3, name: "Name", kind: "scalar", localName: "Name", jsonName: "Name", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } },
|
|
{ no: 4, name: "Active", kind: "scalar", localName: "Active", jsonName: "Active", T: 8 /*ScalarType.BOOL*/ },
|
|
{ no: 5, name: "PhotoURI", kind: "scalar", localName: "PhotoURI", jsonName: "PhotoURI", T: 9 /*ScalarType.STRING*/ },
|
|
{ no: 6, name: "Address", kind: "message", localName: "Address", jsonName: "Address", T: () => Address },
|
|
{ no: 7, name: "Phones", kind: "scalar", localName: "Phones", 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", localName: "Fax", jsonName: "Fax", T: 9 /*ScalarType.STRING*/, options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { example: "[\"06 00 00 00 00\"]" } } },
|
|
{ no: 9, name: "Segmentations", kind: "message", localName: "Segmentations", jsonName: "Segmentations", repeat: 2 /*RepeatType.UNPACKED*/, T: () => Segmentation },
|
|
{ no: 10, name: "Authorisations", kind: "message", localName: "Authorisations", jsonName: "Authorisations", repeat: 2 /*RepeatType.UNPACKED*/, T: () => ProjectAuthorisation },
|
|
{ no: 11, name: "Units", kind: "message", localName: "Units", jsonName: "Units", repeat: 2 /*RepeatType.UNPACKED*/, T: () => Unit, options: { "validate.rules": { repeated: { minItems: "1" } } } },
|
|
{ no: 12, name: "OpeningRules", kind: "message", localName: "OpeningRules", jsonName: "OpeningRules", repeat: 2 /*RepeatType.UNPACKED*/, T: () => OpeningRule },
|
|
{ no: 13, name: "DurationRules", kind: "message", localName: "DurationRules", jsonName: "DurationRules", repeat: 2 /*RepeatType.UNPACKED*/, T: () => DurationRule },
|
|
{ no: 14, name: "CapacityRules", kind: "message", localName: "CapacityRules", jsonName: "CapacityRules", repeat: 2 /*RepeatType.UNPACKED*/, T: () => CapacityRule },
|
|
{ no: 15, name: "Instruction", kind: "message", localName: "Instruction", jsonName: "Instruction", T: () => Instruction },
|
|
{ no: 16, name: "InstructionDocuments", kind: "message", localName: "InstructionDocuments", jsonName: "InstructionDocuments", repeat: 2 /*RepeatType.UNPACKED*/, T: () => Document },
|
|
{ no: 17, name: "CarrierInformation", kind: "message", localName: "CarrierInformation", jsonName: "CarrierInformation", repeat: 2 /*RepeatType.UNPACKED*/, T: () => CarrierInformation },
|
|
{ no: 18, name: "RoundedPeriodInMinutes", kind: "scalar", localName: "RoundedPeriodInMinutes", jsonName: "RoundedPeriodInMinutes", T: 13 /*ScalarType.UINT32*/, options: { "validate.rules": { uint32: { gt: 0 } } } },
|
|
{ no: 19, name: "TimeZone", kind: "scalar", localName: "TimeZone", jsonName: "TimeZone", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1", tzData: true } }, "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "Site time zone <a href='https://en.wikipedia.org/wiki/List_of_tz_database_time_zones'>format</a>", example: "\"Europe/Paris\"" } } },
|
|
{ no: 20, name: "Emails", kind: "scalar", localName: "Emails", 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: 21, name: "DefaultSiteLanguageISO6391", kind: "scalar", localName: "DefaultSiteLanguageISO6391", 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: "<a href='https://en.wikipedia.org/wiki/List_of_ISO_639_language_codes'>ISO 639 code</a> message language", example: "\"en\"" } } }
|
|
], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID"] } } });
|
|
}
|
|
create(value?: PartialMessage<UpdateSiteRequest>): UpdateSiteRequest {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
message.Name = "";
|
|
message.Active = false;
|
|
message.PhotoURI = "";
|
|
message.Phones = [];
|
|
message.Fax = "";
|
|
message.Segmentations = [];
|
|
message.Authorisations = [];
|
|
message.Units = [];
|
|
message.OpeningRules = [];
|
|
message.DurationRules = [];
|
|
message.CapacityRules = [];
|
|
message.InstructionDocuments = [];
|
|
message.CarrierInformation = [];
|
|
message.RoundedPeriodInMinutes = 0;
|
|
message.TimeZone = "";
|
|
message.Emails = [];
|
|
message.DefaultSiteLanguageISO6391 = "";
|
|
if (value !== undefined)
|
|
reflectionMergePartial<UpdateSiteRequest>(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.RequestSiteHeader Header */ 1:
|
|
message.Header = RequestSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.Header);
|
|
break;
|
|
case /* string Name */ 3:
|
|
message.Name = reader.string();
|
|
break;
|
|
case /* bool Active */ 4:
|
|
message.Active = reader.bool();
|
|
break;
|
|
case /* string PhotoURI */ 5:
|
|
message.PhotoURI = reader.string();
|
|
break;
|
|
case /* api.Address Address */ 6:
|
|
message.Address = Address.internalBinaryRead(reader, reader.uint32(), options, message.Address);
|
|
break;
|
|
case /* repeated string Phones */ 7:
|
|
message.Phones.push(reader.string());
|
|
break;
|
|
case /* string Fax */ 8:
|
|
message.Fax = reader.string();
|
|
break;
|
|
case /* repeated api.Segmentation Segmentations */ 9:
|
|
message.Segmentations.push(Segmentation.internalBinaryRead(reader, reader.uint32(), options));
|
|
break;
|
|
case /* repeated api.ProjectAuthorisation Authorisations */ 10:
|
|
message.Authorisations.push(ProjectAuthorisation.internalBinaryRead(reader, reader.uint32(), options));
|
|
break;
|
|
case /* repeated api.Unit Units */ 11:
|
|
message.Units.push(Unit.internalBinaryRead(reader, reader.uint32(), options));
|
|
break;
|
|
case /* repeated api.OpeningRule OpeningRules */ 12:
|
|
message.OpeningRules.push(OpeningRule.internalBinaryRead(reader, reader.uint32(), options));
|
|
break;
|
|
case /* repeated api.DurationRule DurationRules */ 13:
|
|
message.DurationRules.push(DurationRule.internalBinaryRead(reader, reader.uint32(), options));
|
|
break;
|
|
case /* repeated api.CapacityRule CapacityRules */ 14:
|
|
message.CapacityRules.push(CapacityRule.internalBinaryRead(reader, reader.uint32(), options));
|
|
break;
|
|
case /* api.Instruction Instruction */ 15:
|
|
message.Instruction = Instruction.internalBinaryRead(reader, reader.uint32(), options, message.Instruction);
|
|
break;
|
|
case /* repeated api.Document InstructionDocuments */ 16:
|
|
message.InstructionDocuments.push(Document.internalBinaryRead(reader, reader.uint32(), options));
|
|
break;
|
|
case /* repeated api.CarrierInformation CarrierInformation */ 17:
|
|
message.CarrierInformation.push(CarrierInformation.internalBinaryRead(reader, reader.uint32(), options));
|
|
break;
|
|
case /* uint32 RoundedPeriodInMinutes */ 18:
|
|
message.RoundedPeriodInMinutes = reader.uint32();
|
|
break;
|
|
case /* string TimeZone */ 19:
|
|
message.TimeZone = reader.string();
|
|
break;
|
|
case /* repeated string Emails */ 20:
|
|
message.Emails.push(reader.string());
|
|
break;
|
|
case /* string DefaultSiteLanguageISO6391 */ 21:
|
|
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.RequestSiteHeader Header = 1; */
|
|
if (message.Header)
|
|
RequestSiteHeader.internalBinaryWrite(message.Header, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
/* string Name = 3; */
|
|
if (message.Name !== "")
|
|
writer.tag(3, WireType.LengthDelimited).string(message.Name);
|
|
/* bool Active = 4; */
|
|
if (message.Active !== false)
|
|
writer.tag(4, WireType.Varint).bool(message.Active);
|
|
/* string PhotoURI = 5; */
|
|
if (message.PhotoURI !== "")
|
|
writer.tag(5, WireType.LengthDelimited).string(message.PhotoURI);
|
|
/* api.Address Address = 6; */
|
|
if (message.Address)
|
|
Address.internalBinaryWrite(message.Address, writer.tag(6, WireType.LengthDelimited).fork(), options).join();
|
|
/* repeated string Phones = 7; */
|
|
for (let i = 0; i < message.Phones.length; i++)
|
|
writer.tag(7, WireType.LengthDelimited).string(message.Phones[i]);
|
|
/* string Fax = 8; */
|
|
if (message.Fax !== "")
|
|
writer.tag(8, WireType.LengthDelimited).string(message.Fax);
|
|
/* repeated api.Segmentation Segmentations = 9; */
|
|
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; */
|
|
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; */
|
|
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; */
|
|
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; */
|
|
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; */
|
|
for (let i = 0; i < message.CapacityRules.length; i++)
|
|
CapacityRule.internalBinaryWrite(message.CapacityRules[i], writer.tag(14, WireType.LengthDelimited).fork(), options).join();
|
|
/* api.Instruction Instruction = 15; */
|
|
if (message.Instruction)
|
|
Instruction.internalBinaryWrite(message.Instruction, writer.tag(15, WireType.LengthDelimited).fork(), options).join();
|
|
/* repeated api.Document InstructionDocuments = 16; */
|
|
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 CarrierInformation = 17; */
|
|
for (let i = 0; i < message.CarrierInformation.length; i++)
|
|
CarrierInformation.internalBinaryWrite(message.CarrierInformation[i], writer.tag(17, WireType.LengthDelimited).fork(), options).join();
|
|
/* uint32 RoundedPeriodInMinutes = 18; */
|
|
if (message.RoundedPeriodInMinutes !== 0)
|
|
writer.tag(18, WireType.Varint).uint32(message.RoundedPeriodInMinutes);
|
|
/* string TimeZone = 19; */
|
|
if (message.TimeZone !== "")
|
|
writer.tag(19, WireType.LengthDelimited).string(message.TimeZone);
|
|
/* repeated string Emails = 20; */
|
|
for (let i = 0; i < message.Emails.length; i++)
|
|
writer.tag(20, WireType.LengthDelimited).string(message.Emails[i]);
|
|
/* string DefaultSiteLanguageISO6391 = 21; */
|
|
if (message.DefaultSiteLanguageISO6391 !== "")
|
|
writer.tag(21, 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<UpdateSiteResponse> {
|
|
constructor() {
|
|
super("api.UpdateSiteResponse", [
|
|
{ no: 1, name: "Site", kind: "message", localName: "Site", jsonName: "Site", T: () => Site, options: { "validate.rules": { message: { required: true } } } }
|
|
]);
|
|
}
|
|
create(value?: PartialMessage<UpdateSiteResponse>): UpdateSiteResponse {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
if (value !== undefined)
|
|
reflectionMergePartial<UpdateSiteResponse>(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:
|
|
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; */
|
|
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<DeleteSiteRequest> {
|
|
constructor() {
|
|
super("api.DeleteSiteRequest", [
|
|
{ no: 1, name: "Header", kind: "message", localName: "Header", jsonName: "Header", T: () => RequestOrganisationHeader, options: { "validate.rules": { message: { required: true } } } },
|
|
{ no: 2, name: "ID", kind: "scalar", localName: "ID", 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>): DeleteSiteRequest {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
message.ID = "";
|
|
if (value !== undefined)
|
|
reflectionMergePartial<DeleteSiteRequest>(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:
|
|
message.Header = RequestOrganisationHeader.internalBinaryRead(reader, reader.uint32(), options, message.Header);
|
|
break;
|
|
case /* string 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; */
|
|
if (message.Header)
|
|
RequestOrganisationHeader.internalBinaryWrite(message.Header, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
/* string ID = 2; */
|
|
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<DeleteSiteResponse> {
|
|
constructor() {
|
|
super("api.DeleteSiteResponse", []);
|
|
}
|
|
create(value?: PartialMessage<DeleteSiteResponse>): DeleteSiteResponse {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
if (value !== undefined)
|
|
reflectionMergePartial<DeleteSiteResponse>(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 SuggestSiteIDRequest$Type extends MessageType<SuggestSiteIDRequest> {
|
|
constructor() {
|
|
super("api.SuggestSiteIDRequest", [
|
|
{ no: 3, name: "Header", kind: "message", localName: "Header", jsonName: "Header", T: () => RequestOrganisationHeader, options: { "validate.rules": { message: { required: true } } } },
|
|
{ no: 2, name: "Name", kind: "scalar", localName: "Name", jsonName: "Name", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } }
|
|
], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "Name"] } } });
|
|
}
|
|
create(value?: PartialMessage<SuggestSiteIDRequest>): SuggestSiteIDRequest {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
message.Name = "";
|
|
if (value !== undefined)
|
|
reflectionMergePartial<SuggestSiteIDRequest>(this, message, value);
|
|
return message;
|
|
}
|
|
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: SuggestSiteIDRequest): SuggestSiteIDRequest {
|
|
let message = target ?? this.create(), end = reader.pos + length;
|
|
while (reader.pos < end) {
|
|
let [fieldNo, wireType] = reader.tag();
|
|
switch (fieldNo) {
|
|
case /* api.RequestOrganisationHeader Header */ 3:
|
|
message.Header = RequestOrganisationHeader.internalBinaryRead(reader, reader.uint32(), options, message.Header);
|
|
break;
|
|
case /* string Name */ 2:
|
|
message.Name = reader.string();
|
|
break;
|
|
default:
|
|
let u = options.readUnknownField;
|
|
if (u === "throw")
|
|
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
let d = reader.skip(wireType);
|
|
if (u !== false)
|
|
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
}
|
|
}
|
|
return message;
|
|
}
|
|
internalBinaryWrite(message: SuggestSiteIDRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
/* string Name = 2; */
|
|
if (message.Name !== "")
|
|
writer.tag(2, WireType.LengthDelimited).string(message.Name);
|
|
/* api.RequestOrganisationHeader Header = 3; */
|
|
if (message.Header)
|
|
RequestOrganisationHeader.internalBinaryWrite(message.Header, 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.SuggestSiteIDRequest
|
|
*/
|
|
export const SuggestSiteIDRequest = new SuggestSiteIDRequest$Type();
|
|
// @generated message type with reflection information, may provide speed optimized methods
|
|
class SuggestSiteIDResult$Type extends MessageType<SuggestSiteIDResult> {
|
|
constructor() {
|
|
super("api.SuggestSiteIDResult", [
|
|
{ no: 1, name: "SiteID", kind: "scalar", localName: "SiteID", jsonName: "SiteID", T: 9 /*ScalarType.STRING*/ }
|
|
]);
|
|
}
|
|
create(value?: PartialMessage<SuggestSiteIDResult>): SuggestSiteIDResult {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
message.SiteID = "";
|
|
if (value !== undefined)
|
|
reflectionMergePartial<SuggestSiteIDResult>(this, message, value);
|
|
return message;
|
|
}
|
|
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: SuggestSiteIDResult): SuggestSiteIDResult {
|
|
let message = target ?? this.create(), end = reader.pos + length;
|
|
while (reader.pos < end) {
|
|
let [fieldNo, wireType] = reader.tag();
|
|
switch (fieldNo) {
|
|
case /* string SiteID */ 1:
|
|
message.SiteID = 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: SuggestSiteIDResult, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
/* string SiteID = 1; */
|
|
if (message.SiteID !== "")
|
|
writer.tag(1, WireType.LengthDelimited).string(message.SiteID);
|
|
let u = options.writeUnknownFields;
|
|
if (u !== false)
|
|
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
return writer;
|
|
}
|
|
}
|
|
/**
|
|
* @generated MessageType for protobuf message api.SuggestSiteIDResult
|
|
*/
|
|
export const SuggestSiteIDResult = new SuggestSiteIDResult$Type();
|
|
// @generated message type with reflection information, may provide speed optimized methods
|
|
class GetAvailableSlotsRequest$Type extends MessageType<GetAvailableSlotsRequest> {
|
|
constructor() {
|
|
super("api.GetAvailableSlotsRequest", [
|
|
{ no: 1, name: "Header", kind: "message", localName: "Header", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } },
|
|
{ no: 2, name: "AppointmentType", kind: "enum", localName: "AppointmentType", jsonName: "AppointmentType", T: () => ["api.AppointmentType", AppointmentType], options: { "validate.rules": { enum: { definedOnly: true } } } },
|
|
{ no: 3, name: "Commissions", kind: "message", localName: "Commissions", jsonName: "Commissions", repeat: 2 /*RepeatType.UNPACKED*/, T: () => Commission },
|
|
{ no: 4, name: "Segmentations", kind: "message", localName: "Segmentations", jsonName: "Segmentations", repeat: 2 /*RepeatType.UNPACKED*/, T: () => Segmentation },
|
|
{ no: 5, name: "StartDate", kind: "scalar", localName: "StartDate", 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", localName: "EndDate", 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"] } } });
|
|
}
|
|
create(value?: PartialMessage<GetAvailableSlotsRequest>): GetAvailableSlotsRequest {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
message.AppointmentType = 0;
|
|
message.Commissions = [];
|
|
message.Segmentations = [];
|
|
message.StartDate = "";
|
|
message.EndDate = "";
|
|
if (value !== undefined)
|
|
reflectionMergePartial<GetAvailableSlotsRequest>(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:
|
|
message.Header = RequestSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.Header);
|
|
break;
|
|
case /* api.AppointmentType AppointmentType */ 2:
|
|
message.AppointmentType = reader.int32();
|
|
break;
|
|
case /* repeated api.Commission Commissions */ 3:
|
|
message.Commissions.push(Commission.internalBinaryRead(reader, reader.uint32(), options));
|
|
break;
|
|
case /* repeated api.Segmentation Segmentations */ 4:
|
|
message.Segmentations.push(Segmentation.internalBinaryRead(reader, reader.uint32(), options));
|
|
break;
|
|
case /* string StartDate */ 5:
|
|
message.StartDate = reader.string();
|
|
break;
|
|
case /* string 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; */
|
|
if (message.Header)
|
|
RequestSiteHeader.internalBinaryWrite(message.Header, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
/* api.AppointmentType AppointmentType = 2; */
|
|
if (message.AppointmentType !== 0)
|
|
writer.tag(2, WireType.Varint).int32(message.AppointmentType);
|
|
/* repeated api.Commission Commissions = 3; */
|
|
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; */
|
|
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; */
|
|
if (message.StartDate !== "")
|
|
writer.tag(5, WireType.LengthDelimited).string(message.StartDate);
|
|
/* string EndDate = 6; */
|
|
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<GetAvailableSlotsResponse> {
|
|
constructor() {
|
|
super("api.GetAvailableSlotsResponse", [
|
|
{ no: 1, name: "SlotGroups", kind: "message", localName: "SlotGroups", jsonName: "SlotGroups", repeat: 2 /*RepeatType.UNPACKED*/, T: () => SlotGroup }
|
|
]);
|
|
}
|
|
create(value?: PartialMessage<GetAvailableSlotsResponse>): GetAvailableSlotsResponse {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
message.SlotGroups = [];
|
|
if (value !== undefined)
|
|
reflectionMergePartial<GetAvailableSlotsResponse>(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.SlotGroup SlotGroups */ 1:
|
|
message.SlotGroups.push(SlotGroup.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.SlotGroup SlotGroups = 1; */
|
|
for (let i = 0; i < message.SlotGroups.length; i++)
|
|
SlotGroup.internalBinaryWrite(message.SlotGroups[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<BookAppointmentRequest> {
|
|
constructor() {
|
|
super("api.BookAppointmentRequest", [
|
|
{ no: 1, name: "Header", kind: "message", localName: "Header", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } },
|
|
{ no: 2, name: "AppointmentType", kind: "enum", localName: "AppointmentType", jsonName: "AppointmentType", T: () => ["api.AppointmentType", AppointmentType], options: { "validate.rules": { enum: { definedOnly: true } } } },
|
|
{ no: 3, name: "Commissions", kind: "message", localName: "Commissions", jsonName: "Commissions", repeat: 2 /*RepeatType.UNPACKED*/, T: () => Commission },
|
|
{ no: 4, name: "Segmentations", kind: "message", localName: "Segmentations", jsonName: "Segmentations", repeat: 2 /*RepeatType.UNPACKED*/, T: () => Segmentation },
|
|
{ no: 5, name: "CarrierInformation", kind: "message", localName: "CarrierInformation", jsonName: "CarrierInformation", repeat: 2 /*RepeatType.UNPACKED*/, T: () => CarrierInformationWithValue },
|
|
{ no: 6, name: "Slots", kind: "message", localName: "Slots", jsonName: "Slots", repeat: 2 /*RepeatType.UNPACKED*/, T: () => Slot },
|
|
{ no: 8, name: "Emails", kind: "scalar", localName: "Emails", 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: 9, name: "CarrierID", kind: "scalar", localName: "CarrierID", jsonName: "CarrierID", T: 9 /*ScalarType.STRING*/ },
|
|
{ no: 10, name: "CarrierName", kind: "scalar", localName: "CarrierName", jsonName: "CarrierName", T: 9 /*ScalarType.STRING*/ }
|
|
], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "AppointmentType", "Segmentations", "CarrierInformation"] } } });
|
|
}
|
|
create(value?: PartialMessage<BookAppointmentRequest>): BookAppointmentRequest {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
message.AppointmentType = 0;
|
|
message.Commissions = [];
|
|
message.Segmentations = [];
|
|
message.CarrierInformation = [];
|
|
message.Slots = [];
|
|
message.Emails = [];
|
|
message.CarrierID = "";
|
|
message.CarrierName = "";
|
|
if (value !== undefined)
|
|
reflectionMergePartial<BookAppointmentRequest>(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:
|
|
message.Header = RequestSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.Header);
|
|
break;
|
|
case /* api.AppointmentType AppointmentType */ 2:
|
|
message.AppointmentType = reader.int32();
|
|
break;
|
|
case /* repeated api.Commission Commissions */ 3:
|
|
message.Commissions.push(Commission.internalBinaryRead(reader, reader.uint32(), options));
|
|
break;
|
|
case /* repeated api.Segmentation Segmentations */ 4:
|
|
message.Segmentations.push(Segmentation.internalBinaryRead(reader, reader.uint32(), options));
|
|
break;
|
|
case /* repeated api.CarrierInformationWithValue CarrierInformation */ 5:
|
|
message.CarrierInformation.push(CarrierInformationWithValue.internalBinaryRead(reader, reader.uint32(), options));
|
|
break;
|
|
case /* repeated api.Slot Slots */ 6:
|
|
message.Slots.push(Slot.internalBinaryRead(reader, reader.uint32(), options));
|
|
break;
|
|
case /* repeated string Emails */ 8:
|
|
message.Emails.push(reader.string());
|
|
break;
|
|
case /* string CarrierID */ 9:
|
|
message.CarrierID = reader.string();
|
|
break;
|
|
case /* string CarrierName */ 10:
|
|
message.CarrierName = 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; */
|
|
if (message.Header)
|
|
RequestSiteHeader.internalBinaryWrite(message.Header, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
/* api.AppointmentType AppointmentType = 2; */
|
|
if (message.AppointmentType !== 0)
|
|
writer.tag(2, WireType.Varint).int32(message.AppointmentType);
|
|
/* repeated api.Commission Commissions = 3; */
|
|
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; */
|
|
for (let i = 0; i < message.Segmentations.length; i++)
|
|
Segmentation.internalBinaryWrite(message.Segmentations[i], writer.tag(4, WireType.LengthDelimited).fork(), options).join();
|
|
/* repeated api.CarrierInformationWithValue CarrierInformation = 5; */
|
|
for (let i = 0; i < message.CarrierInformation.length; i++)
|
|
CarrierInformationWithValue.internalBinaryWrite(message.CarrierInformation[i], writer.tag(5, WireType.LengthDelimited).fork(), options).join();
|
|
/* repeated api.Slot Slots = 6; */
|
|
for (let i = 0; i < message.Slots.length; i++)
|
|
Slot.internalBinaryWrite(message.Slots[i], writer.tag(6, WireType.LengthDelimited).fork(), options).join();
|
|
/* repeated string Emails = 8; */
|
|
for (let i = 0; i < message.Emails.length; i++)
|
|
writer.tag(8, WireType.LengthDelimited).string(message.Emails[i]);
|
|
/* string CarrierID = 9; */
|
|
if (message.CarrierID !== "")
|
|
writer.tag(9, WireType.LengthDelimited).string(message.CarrierID);
|
|
/* string CarrierName = 10; */
|
|
if (message.CarrierName !== "")
|
|
writer.tag(10, WireType.LengthDelimited).string(message.CarrierName);
|
|
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<BookAppointmentResponse> {
|
|
constructor() {
|
|
super("api.BookAppointmentResponse", [
|
|
{ no: 1, name: "AppointmentID", kind: "scalar", localName: "AppointmentID", jsonName: "AppointmentID", T: 9 /*ScalarType.STRING*/ }
|
|
]);
|
|
}
|
|
create(value?: PartialMessage<BookAppointmentResponse>): BookAppointmentResponse {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
message.AppointmentID = "";
|
|
if (value !== undefined)
|
|
reflectionMergePartial<BookAppointmentResponse>(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:
|
|
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; */
|
|
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<CancelAppointmentRequest> {
|
|
constructor() {
|
|
super("api.CancelAppointmentRequest", [
|
|
{ no: 1, name: "Header", kind: "message", localName: "Header", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } },
|
|
{ no: 2, name: "AppointmentID", kind: "scalar", localName: "AppointmentID", 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>): CancelAppointmentRequest {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
message.AppointmentID = "";
|
|
if (value !== undefined)
|
|
reflectionMergePartial<CancelAppointmentRequest>(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:
|
|
message.Header = RequestSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.Header);
|
|
break;
|
|
case /* string 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; */
|
|
if (message.Header)
|
|
RequestSiteHeader.internalBinaryWrite(message.Header, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
/* string AppointmentID = 2; */
|
|
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<CancelAppointmentResponse> {
|
|
constructor() {
|
|
super("api.CancelAppointmentResponse", [
|
|
{ no: 1, name: "AppointmentID", kind: "scalar", localName: "AppointmentID", jsonName: "AppointmentID", T: 9 /*ScalarType.STRING*/ }
|
|
]);
|
|
}
|
|
create(value?: PartialMessage<CancelAppointmentResponse>): CancelAppointmentResponse {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
message.AppointmentID = "";
|
|
if (value !== undefined)
|
|
reflectionMergePartial<CancelAppointmentResponse>(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:
|
|
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; */
|
|
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<ListUserSitesRequest> {
|
|
constructor() {
|
|
super("api.ListUserSitesRequest", [
|
|
{ no: 1, name: "ProjectID", kind: "scalar", localName: "ProjectID", 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>): ListUserSitesRequest {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
message.ProjectID = [];
|
|
if (value !== undefined)
|
|
reflectionMergePartial<ListUserSitesRequest>(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:
|
|
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; */
|
|
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<ListUserSitesResponse> {
|
|
constructor() {
|
|
super("api.ListUserSitesResponse", [
|
|
{ no: 1, name: "Sites", kind: "message", localName: "Sites", jsonName: "Sites", repeat: 2 /*RepeatType.UNPACKED*/, T: () => Site }
|
|
]);
|
|
}
|
|
create(value?: PartialMessage<ListUserSitesResponse>): ListUserSitesResponse {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
message.Sites = [];
|
|
if (value !== undefined)
|
|
reflectionMergePartial<ListUserSitesResponse>(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:
|
|
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; */
|
|
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: "SuggestID", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Site"], description: "Suggest a site ID" }, "api.rscType": "Organisation", "api.roles": "", "google.api.method_visibility": { restriction: "SDK" } }, I: SuggestSiteIDRequest, O: SuggestSiteIDResult },
|
|
{ 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"], description: "Book an appointment on the site, if the requested slots are available." }, "api.rscType": "Site", "api.roles": "", "google.api.method_visibility": { restriction: "SDK" } }, I: BookAppointmentRequest, O: BookAppointmentResponse },
|
|
{ name: "ForceBookAppointment", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Site"], description: "Book an appointment on the site without checking if the slots are available." }, "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"], description: "Cancel an appointment on the site." }, "api.rscType": "Site", "api.roles": "", "google.api.method_visibility": { restriction: "SDK" } }, I: CancelAppointmentRequest, O: CancelAppointmentResponse }
|
|
], { "api.k8sService": "core-site" });
|