You've already forked npm-core-sdk
1028 lines
53 KiB
TypeScript
1028 lines
53 KiB
TypeScript
// @generated by protobuf-ts 2.11.1 with parameter use_proto_field_name,keep_enum_prefix
|
|
// @generated from protobuf file "restrictionLinks.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 { RequestProjectHeader } from "./shared";
|
|
import { Restriction } from "./restrictions";
|
|
/**
|
|
* ========== MODEL MESSAGES ==========
|
|
*
|
|
* @generated from protobuf message api.RestrictionLink
|
|
*/
|
|
export interface RestrictionLink {
|
|
/**
|
|
* @generated from protobuf field: string ProjectID = 1
|
|
*/
|
|
ProjectID: string;
|
|
/**
|
|
* @generated from protobuf field: string RestrictionID = 2
|
|
*/
|
|
RestrictionID: string;
|
|
/**
|
|
* @generated from protobuf field: string TargetID = 4
|
|
*/
|
|
TargetID: string;
|
|
/**
|
|
* @generated from protobuf field: api.Restriction Restriction = 6
|
|
*/
|
|
Restriction?: Restriction;
|
|
}
|
|
// ========== REQUESTS & RESPONSE MESSAGES ==========
|
|
|
|
/**
|
|
* Create
|
|
*
|
|
* @generated from protobuf message api.CreateRestrictionLinkRequest
|
|
*/
|
|
export interface CreateRestrictionLinkRequest {
|
|
/**
|
|
* @generated from protobuf field: api.RequestProjectHeader Header = 1
|
|
*/
|
|
Header?: RequestProjectHeader;
|
|
/**
|
|
* @generated from protobuf field: string RestrictionID = 2
|
|
*/
|
|
RestrictionID: string;
|
|
/**
|
|
* @generated from protobuf field: string TargetID = 3
|
|
*/
|
|
TargetID: string;
|
|
}
|
|
/**
|
|
* @generated from protobuf message api.CreateRestrictionLinkResponse
|
|
*/
|
|
export interface CreateRestrictionLinkResponse {
|
|
/**
|
|
* @generated from protobuf field: api.RestrictionLink RestrictionLink = 1
|
|
*/
|
|
RestrictionLink?: RestrictionLink;
|
|
}
|
|
/**
|
|
* Update
|
|
*
|
|
* @generated from protobuf message api.UpdateRestrictionLinkRequest
|
|
*/
|
|
export interface UpdateRestrictionLinkRequest {
|
|
/**
|
|
* @generated from protobuf field: api.RequestProjectHeader Header = 1
|
|
*/
|
|
Header?: RequestProjectHeader;
|
|
/**
|
|
* @generated from protobuf field: string RestrictionID = 2
|
|
*/
|
|
RestrictionID: string;
|
|
/**
|
|
* @generated from protobuf field: string TargetID = 3
|
|
*/
|
|
TargetID: string;
|
|
}
|
|
/**
|
|
* @generated from protobuf message api.UpdateRestrictionLinkResponse
|
|
*/
|
|
export interface UpdateRestrictionLinkResponse {
|
|
/**
|
|
* @generated from protobuf field: api.RestrictionLink RestrictionLink = 1
|
|
*/
|
|
RestrictionLink?: RestrictionLink;
|
|
}
|
|
/**
|
|
* Delete
|
|
*
|
|
* @generated from protobuf message api.DeleteRestrictionLinkRequest
|
|
*/
|
|
export interface DeleteRestrictionLinkRequest {
|
|
/**
|
|
* @generated from protobuf field: api.RequestProjectHeader Header = 1
|
|
*/
|
|
Header?: RequestProjectHeader;
|
|
/**
|
|
* @generated from protobuf field: string RestrictionID = 2
|
|
*/
|
|
RestrictionID: string;
|
|
/**
|
|
* @generated from protobuf field: string TargetID = 3
|
|
*/
|
|
TargetID: string;
|
|
}
|
|
/**
|
|
* @generated from protobuf message api.DeleteRestrictionLinkResponse
|
|
*/
|
|
export interface DeleteRestrictionLinkResponse {
|
|
}
|
|
/**
|
|
* Get
|
|
*
|
|
* @generated from protobuf message api.GetRestrictionLinkRequest
|
|
*/
|
|
export interface GetRestrictionLinkRequest {
|
|
/**
|
|
* @generated from protobuf field: api.RequestProjectHeader Header = 1
|
|
*/
|
|
Header?: RequestProjectHeader;
|
|
/**
|
|
* @generated from protobuf field: string RestrictionID = 2
|
|
*/
|
|
RestrictionID: string;
|
|
/**
|
|
* @generated from protobuf field: string TargetID = 3
|
|
*/
|
|
TargetID: string;
|
|
}
|
|
/**
|
|
* @generated from protobuf message api.GetRestrictionLinkResponse
|
|
*/
|
|
export interface GetRestrictionLinkResponse {
|
|
/**
|
|
* @generated from protobuf field: api.RestrictionLink RestrictionLink = 1
|
|
*/
|
|
RestrictionLink?: RestrictionLink;
|
|
}
|
|
/**
|
|
* List
|
|
*
|
|
* @generated from protobuf message api.ListRestrictionLinksRequest
|
|
*/
|
|
export interface ListRestrictionLinksRequest {
|
|
/**
|
|
* @generated from protobuf field: api.RequestProjectHeader Header = 1
|
|
*/
|
|
Header?: RequestProjectHeader;
|
|
/**
|
|
* @generated from protobuf field: string RestrictionID = 2
|
|
*/
|
|
RestrictionID: string;
|
|
/**
|
|
* @generated from protobuf field: string TargetID = 3
|
|
*/
|
|
TargetID: string;
|
|
}
|
|
/**
|
|
* @generated from protobuf message api.ListRestrictionLinksResponse
|
|
*/
|
|
export interface ListRestrictionLinksResponse {
|
|
/**
|
|
* @generated from protobuf field: repeated api.RestrictionLink RestrictionLinks = 1
|
|
*/
|
|
RestrictionLinks: RestrictionLink[];
|
|
}
|
|
/**
|
|
* SetUserActors
|
|
*
|
|
* @generated from protobuf message api.SetUserActorsRequest
|
|
*/
|
|
export interface SetUserActorsRequest {
|
|
/**
|
|
* @generated from protobuf field: api.RequestProjectHeader Header = 1
|
|
*/
|
|
Header?: RequestProjectHeader;
|
|
/**
|
|
* @generated from protobuf field: string RestrictionID = 2
|
|
*/
|
|
RestrictionID: string;
|
|
/**
|
|
* @generated from protobuf field: string UserID = 3
|
|
*/
|
|
UserID: string;
|
|
/**
|
|
* @generated from protobuf field: repeated string UserActorIDs = 4
|
|
*/
|
|
UserActorIDs: string[]; // If empty, it will remove all user actors for this restriction ID and User ID
|
|
}
|
|
/**
|
|
* @generated from protobuf message api.SetUserActorsResponse
|
|
*/
|
|
export interface SetUserActorsResponse {
|
|
}
|
|
/**
|
|
* DeleteForProject
|
|
*
|
|
* @generated from protobuf message api.DeleteForProjectRestrictionLinkRequest
|
|
*/
|
|
export interface DeleteForProjectRestrictionLinkRequest {
|
|
/**
|
|
* @generated from protobuf field: api.RequestProjectHeader Header = 1
|
|
*/
|
|
Header?: RequestProjectHeader;
|
|
}
|
|
/**
|
|
* @generated from protobuf message api.DeleteForProjectRestrictionLinkResponse
|
|
*/
|
|
export interface DeleteForProjectRestrictionLinkResponse {
|
|
}
|
|
// @generated message type with reflection information, may provide speed optimized methods
|
|
class RestrictionLink$Type extends MessageType<RestrictionLink> {
|
|
constructor() {
|
|
super("api.RestrictionLink", [
|
|
{ no: 1, name: "ProjectID", kind: "scalar", localName: "ProjectID", jsonName: "ProjectID", T: 9 /*ScalarType.STRING*/ },
|
|
{ no: 2, name: "RestrictionID", kind: "scalar", localName: "RestrictionID", jsonName: "RestrictionID", T: 9 /*ScalarType.STRING*/ },
|
|
{ no: 4, name: "TargetID", kind: "scalar", localName: "TargetID", jsonName: "TargetID", T: 9 /*ScalarType.STRING*/ },
|
|
{ no: 6, name: "Restriction", kind: "message", localName: "Restriction", jsonName: "Restriction", T: () => Restriction }
|
|
]);
|
|
}
|
|
create(value?: PartialMessage<RestrictionLink>): RestrictionLink {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
message.ProjectID = "";
|
|
message.RestrictionID = "";
|
|
message.TargetID = "";
|
|
if (value !== undefined)
|
|
reflectionMergePartial<RestrictionLink>(this, message, value);
|
|
return message;
|
|
}
|
|
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: RestrictionLink): RestrictionLink {
|
|
let message = target ?? this.create(), end = reader.pos + length;
|
|
while (reader.pos < end) {
|
|
let [fieldNo, wireType] = reader.tag();
|
|
switch (fieldNo) {
|
|
case /* string ProjectID */ 1:
|
|
message.ProjectID = reader.string();
|
|
break;
|
|
case /* string RestrictionID */ 2:
|
|
message.RestrictionID = reader.string();
|
|
break;
|
|
case /* string TargetID */ 4:
|
|
message.TargetID = reader.string();
|
|
break;
|
|
case /* api.Restriction Restriction */ 6:
|
|
message.Restriction = Restriction.internalBinaryRead(reader, reader.uint32(), options, message.Restriction);
|
|
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: RestrictionLink, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
/* string ProjectID = 1; */
|
|
if (message.ProjectID !== "")
|
|
writer.tag(1, WireType.LengthDelimited).string(message.ProjectID);
|
|
/* string RestrictionID = 2; */
|
|
if (message.RestrictionID !== "")
|
|
writer.tag(2, WireType.LengthDelimited).string(message.RestrictionID);
|
|
/* string TargetID = 4; */
|
|
if (message.TargetID !== "")
|
|
writer.tag(4, WireType.LengthDelimited).string(message.TargetID);
|
|
/* api.Restriction Restriction = 6; */
|
|
if (message.Restriction)
|
|
Restriction.internalBinaryWrite(message.Restriction, writer.tag(6, WireType.LengthDelimited).fork(), options).join();
|
|
let u = options.writeUnknownFields;
|
|
if (u !== false)
|
|
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
return writer;
|
|
}
|
|
}
|
|
/**
|
|
* @generated MessageType for protobuf message api.RestrictionLink
|
|
*/
|
|
export const RestrictionLink = new RestrictionLink$Type();
|
|
// @generated message type with reflection information, may provide speed optimized methods
|
|
class CreateRestrictionLinkRequest$Type extends MessageType<CreateRestrictionLinkRequest> {
|
|
constructor() {
|
|
super("api.CreateRestrictionLinkRequest", [
|
|
{ no: 1, name: "Header", kind: "message", localName: "Header", jsonName: "Header", T: () => RequestProjectHeader, options: { "validate.rules": { message: { required: true } } } },
|
|
{ no: 2, name: "RestrictionID", kind: "scalar", localName: "RestrictionID", jsonName: "RestrictionID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } },
|
|
{ no: 3, name: "TargetID", kind: "scalar", localName: "TargetID", jsonName: "TargetID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } }
|
|
], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "RestrictionID", "TargetID"] } } });
|
|
}
|
|
create(value?: PartialMessage<CreateRestrictionLinkRequest>): CreateRestrictionLinkRequest {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
message.RestrictionID = "";
|
|
message.TargetID = "";
|
|
if (value !== undefined)
|
|
reflectionMergePartial<CreateRestrictionLinkRequest>(this, message, value);
|
|
return message;
|
|
}
|
|
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: CreateRestrictionLinkRequest): CreateRestrictionLinkRequest {
|
|
let message = target ?? this.create(), end = reader.pos + length;
|
|
while (reader.pos < end) {
|
|
let [fieldNo, wireType] = reader.tag();
|
|
switch (fieldNo) {
|
|
case /* api.RequestProjectHeader Header */ 1:
|
|
message.Header = RequestProjectHeader.internalBinaryRead(reader, reader.uint32(), options, message.Header);
|
|
break;
|
|
case /* string RestrictionID */ 2:
|
|
message.RestrictionID = reader.string();
|
|
break;
|
|
case /* string TargetID */ 3:
|
|
message.TargetID = 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: CreateRestrictionLinkRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
/* api.RequestProjectHeader Header = 1; */
|
|
if (message.Header)
|
|
RequestProjectHeader.internalBinaryWrite(message.Header, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
/* string RestrictionID = 2; */
|
|
if (message.RestrictionID !== "")
|
|
writer.tag(2, WireType.LengthDelimited).string(message.RestrictionID);
|
|
/* string TargetID = 3; */
|
|
if (message.TargetID !== "")
|
|
writer.tag(3, WireType.LengthDelimited).string(message.TargetID);
|
|
let u = options.writeUnknownFields;
|
|
if (u !== false)
|
|
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
return writer;
|
|
}
|
|
}
|
|
/**
|
|
* @generated MessageType for protobuf message api.CreateRestrictionLinkRequest
|
|
*/
|
|
export const CreateRestrictionLinkRequest = new CreateRestrictionLinkRequest$Type();
|
|
// @generated message type with reflection information, may provide speed optimized methods
|
|
class CreateRestrictionLinkResponse$Type extends MessageType<CreateRestrictionLinkResponse> {
|
|
constructor() {
|
|
super("api.CreateRestrictionLinkResponse", [
|
|
{ no: 1, name: "RestrictionLink", kind: "message", localName: "RestrictionLink", jsonName: "RestrictionLink", T: () => RestrictionLink }
|
|
]);
|
|
}
|
|
create(value?: PartialMessage<CreateRestrictionLinkResponse>): CreateRestrictionLinkResponse {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
if (value !== undefined)
|
|
reflectionMergePartial<CreateRestrictionLinkResponse>(this, message, value);
|
|
return message;
|
|
}
|
|
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: CreateRestrictionLinkResponse): CreateRestrictionLinkResponse {
|
|
let message = target ?? this.create(), end = reader.pos + length;
|
|
while (reader.pos < end) {
|
|
let [fieldNo, wireType] = reader.tag();
|
|
switch (fieldNo) {
|
|
case /* api.RestrictionLink RestrictionLink */ 1:
|
|
message.RestrictionLink = RestrictionLink.internalBinaryRead(reader, reader.uint32(), options, message.RestrictionLink);
|
|
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: CreateRestrictionLinkResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
/* api.RestrictionLink RestrictionLink = 1; */
|
|
if (message.RestrictionLink)
|
|
RestrictionLink.internalBinaryWrite(message.RestrictionLink, 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.CreateRestrictionLinkResponse
|
|
*/
|
|
export const CreateRestrictionLinkResponse = new CreateRestrictionLinkResponse$Type();
|
|
// @generated message type with reflection information, may provide speed optimized methods
|
|
class UpdateRestrictionLinkRequest$Type extends MessageType<UpdateRestrictionLinkRequest> {
|
|
constructor() {
|
|
super("api.UpdateRestrictionLinkRequest", [
|
|
{ no: 1, name: "Header", kind: "message", localName: "Header", jsonName: "Header", T: () => RequestProjectHeader, options: { "validate.rules": { message: { required: true } } } },
|
|
{ no: 2, name: "RestrictionID", kind: "scalar", localName: "RestrictionID", jsonName: "RestrictionID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } },
|
|
{ no: 3, name: "TargetID", kind: "scalar", localName: "TargetID", jsonName: "TargetID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } }
|
|
], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "RestrictionID", "TargetID"] } } });
|
|
}
|
|
create(value?: PartialMessage<UpdateRestrictionLinkRequest>): UpdateRestrictionLinkRequest {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
message.RestrictionID = "";
|
|
message.TargetID = "";
|
|
if (value !== undefined)
|
|
reflectionMergePartial<UpdateRestrictionLinkRequest>(this, message, value);
|
|
return message;
|
|
}
|
|
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: UpdateRestrictionLinkRequest): UpdateRestrictionLinkRequest {
|
|
let message = target ?? this.create(), end = reader.pos + length;
|
|
while (reader.pos < end) {
|
|
let [fieldNo, wireType] = reader.tag();
|
|
switch (fieldNo) {
|
|
case /* api.RequestProjectHeader Header */ 1:
|
|
message.Header = RequestProjectHeader.internalBinaryRead(reader, reader.uint32(), options, message.Header);
|
|
break;
|
|
case /* string RestrictionID */ 2:
|
|
message.RestrictionID = reader.string();
|
|
break;
|
|
case /* string TargetID */ 3:
|
|
message.TargetID = 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: UpdateRestrictionLinkRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
/* api.RequestProjectHeader Header = 1; */
|
|
if (message.Header)
|
|
RequestProjectHeader.internalBinaryWrite(message.Header, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
/* string RestrictionID = 2; */
|
|
if (message.RestrictionID !== "")
|
|
writer.tag(2, WireType.LengthDelimited).string(message.RestrictionID);
|
|
/* string TargetID = 3; */
|
|
if (message.TargetID !== "")
|
|
writer.tag(3, WireType.LengthDelimited).string(message.TargetID);
|
|
let u = options.writeUnknownFields;
|
|
if (u !== false)
|
|
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
return writer;
|
|
}
|
|
}
|
|
/**
|
|
* @generated MessageType for protobuf message api.UpdateRestrictionLinkRequest
|
|
*/
|
|
export const UpdateRestrictionLinkRequest = new UpdateRestrictionLinkRequest$Type();
|
|
// @generated message type with reflection information, may provide speed optimized methods
|
|
class UpdateRestrictionLinkResponse$Type extends MessageType<UpdateRestrictionLinkResponse> {
|
|
constructor() {
|
|
super("api.UpdateRestrictionLinkResponse", [
|
|
{ no: 1, name: "RestrictionLink", kind: "message", localName: "RestrictionLink", jsonName: "RestrictionLink", T: () => RestrictionLink }
|
|
]);
|
|
}
|
|
create(value?: PartialMessage<UpdateRestrictionLinkResponse>): UpdateRestrictionLinkResponse {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
if (value !== undefined)
|
|
reflectionMergePartial<UpdateRestrictionLinkResponse>(this, message, value);
|
|
return message;
|
|
}
|
|
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: UpdateRestrictionLinkResponse): UpdateRestrictionLinkResponse {
|
|
let message = target ?? this.create(), end = reader.pos + length;
|
|
while (reader.pos < end) {
|
|
let [fieldNo, wireType] = reader.tag();
|
|
switch (fieldNo) {
|
|
case /* api.RestrictionLink RestrictionLink */ 1:
|
|
message.RestrictionLink = RestrictionLink.internalBinaryRead(reader, reader.uint32(), options, message.RestrictionLink);
|
|
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: UpdateRestrictionLinkResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
/* api.RestrictionLink RestrictionLink = 1; */
|
|
if (message.RestrictionLink)
|
|
RestrictionLink.internalBinaryWrite(message.RestrictionLink, 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.UpdateRestrictionLinkResponse
|
|
*/
|
|
export const UpdateRestrictionLinkResponse = new UpdateRestrictionLinkResponse$Type();
|
|
// @generated message type with reflection information, may provide speed optimized methods
|
|
class DeleteRestrictionLinkRequest$Type extends MessageType<DeleteRestrictionLinkRequest> {
|
|
constructor() {
|
|
super("api.DeleteRestrictionLinkRequest", [
|
|
{ no: 1, name: "Header", kind: "message", localName: "Header", jsonName: "Header", T: () => RequestProjectHeader, options: { "validate.rules": { message: { required: true } } } },
|
|
{ no: 2, name: "RestrictionID", kind: "scalar", localName: "RestrictionID", jsonName: "RestrictionID", T: 9 /*ScalarType.STRING*/ },
|
|
{ no: 3, name: "TargetID", kind: "scalar", localName: "TargetID", jsonName: "TargetID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } }
|
|
], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "TargetID"] } } });
|
|
}
|
|
create(value?: PartialMessage<DeleteRestrictionLinkRequest>): DeleteRestrictionLinkRequest {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
message.RestrictionID = "";
|
|
message.TargetID = "";
|
|
if (value !== undefined)
|
|
reflectionMergePartial<DeleteRestrictionLinkRequest>(this, message, value);
|
|
return message;
|
|
}
|
|
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: DeleteRestrictionLinkRequest): DeleteRestrictionLinkRequest {
|
|
let message = target ?? this.create(), end = reader.pos + length;
|
|
while (reader.pos < end) {
|
|
let [fieldNo, wireType] = reader.tag();
|
|
switch (fieldNo) {
|
|
case /* api.RequestProjectHeader Header */ 1:
|
|
message.Header = RequestProjectHeader.internalBinaryRead(reader, reader.uint32(), options, message.Header);
|
|
break;
|
|
case /* string RestrictionID */ 2:
|
|
message.RestrictionID = reader.string();
|
|
break;
|
|
case /* string TargetID */ 3:
|
|
message.TargetID = 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: DeleteRestrictionLinkRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
/* api.RequestProjectHeader Header = 1; */
|
|
if (message.Header)
|
|
RequestProjectHeader.internalBinaryWrite(message.Header, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
/* string RestrictionID = 2; */
|
|
if (message.RestrictionID !== "")
|
|
writer.tag(2, WireType.LengthDelimited).string(message.RestrictionID);
|
|
/* string TargetID = 3; */
|
|
if (message.TargetID !== "")
|
|
writer.tag(3, WireType.LengthDelimited).string(message.TargetID);
|
|
let u = options.writeUnknownFields;
|
|
if (u !== false)
|
|
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
return writer;
|
|
}
|
|
}
|
|
/**
|
|
* @generated MessageType for protobuf message api.DeleteRestrictionLinkRequest
|
|
*/
|
|
export const DeleteRestrictionLinkRequest = new DeleteRestrictionLinkRequest$Type();
|
|
// @generated message type with reflection information, may provide speed optimized methods
|
|
class DeleteRestrictionLinkResponse$Type extends MessageType<DeleteRestrictionLinkResponse> {
|
|
constructor() {
|
|
super("api.DeleteRestrictionLinkResponse", []);
|
|
}
|
|
create(value?: PartialMessage<DeleteRestrictionLinkResponse>): DeleteRestrictionLinkResponse {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
if (value !== undefined)
|
|
reflectionMergePartial<DeleteRestrictionLinkResponse>(this, message, value);
|
|
return message;
|
|
}
|
|
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: DeleteRestrictionLinkResponse): DeleteRestrictionLinkResponse {
|
|
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: DeleteRestrictionLinkResponse, 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.DeleteRestrictionLinkResponse
|
|
*/
|
|
export const DeleteRestrictionLinkResponse = new DeleteRestrictionLinkResponse$Type();
|
|
// @generated message type with reflection information, may provide speed optimized methods
|
|
class GetRestrictionLinkRequest$Type extends MessageType<GetRestrictionLinkRequest> {
|
|
constructor() {
|
|
super("api.GetRestrictionLinkRequest", [
|
|
{ no: 1, name: "Header", kind: "message", localName: "Header", jsonName: "Header", T: () => RequestProjectHeader, options: { "validate.rules": { message: { required: true } } } },
|
|
{ no: 2, name: "RestrictionID", kind: "scalar", localName: "RestrictionID", jsonName: "RestrictionID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } },
|
|
{ no: 3, name: "TargetID", kind: "scalar", localName: "TargetID", jsonName: "TargetID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } }
|
|
], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "RestrictionID", "TargetID"] } } });
|
|
}
|
|
create(value?: PartialMessage<GetRestrictionLinkRequest>): GetRestrictionLinkRequest {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
message.RestrictionID = "";
|
|
message.TargetID = "";
|
|
if (value !== undefined)
|
|
reflectionMergePartial<GetRestrictionLinkRequest>(this, message, value);
|
|
return message;
|
|
}
|
|
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GetRestrictionLinkRequest): GetRestrictionLinkRequest {
|
|
let message = target ?? this.create(), end = reader.pos + length;
|
|
while (reader.pos < end) {
|
|
let [fieldNo, wireType] = reader.tag();
|
|
switch (fieldNo) {
|
|
case /* api.RequestProjectHeader Header */ 1:
|
|
message.Header = RequestProjectHeader.internalBinaryRead(reader, reader.uint32(), options, message.Header);
|
|
break;
|
|
case /* string RestrictionID */ 2:
|
|
message.RestrictionID = reader.string();
|
|
break;
|
|
case /* string TargetID */ 3:
|
|
message.TargetID = 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: GetRestrictionLinkRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
/* api.RequestProjectHeader Header = 1; */
|
|
if (message.Header)
|
|
RequestProjectHeader.internalBinaryWrite(message.Header, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
/* string RestrictionID = 2; */
|
|
if (message.RestrictionID !== "")
|
|
writer.tag(2, WireType.LengthDelimited).string(message.RestrictionID);
|
|
/* string TargetID = 3; */
|
|
if (message.TargetID !== "")
|
|
writer.tag(3, WireType.LengthDelimited).string(message.TargetID);
|
|
let u = options.writeUnknownFields;
|
|
if (u !== false)
|
|
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
return writer;
|
|
}
|
|
}
|
|
/**
|
|
* @generated MessageType for protobuf message api.GetRestrictionLinkRequest
|
|
*/
|
|
export const GetRestrictionLinkRequest = new GetRestrictionLinkRequest$Type();
|
|
// @generated message type with reflection information, may provide speed optimized methods
|
|
class GetRestrictionLinkResponse$Type extends MessageType<GetRestrictionLinkResponse> {
|
|
constructor() {
|
|
super("api.GetRestrictionLinkResponse", [
|
|
{ no: 1, name: "RestrictionLink", kind: "message", localName: "RestrictionLink", jsonName: "RestrictionLink", T: () => RestrictionLink }
|
|
]);
|
|
}
|
|
create(value?: PartialMessage<GetRestrictionLinkResponse>): GetRestrictionLinkResponse {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
if (value !== undefined)
|
|
reflectionMergePartial<GetRestrictionLinkResponse>(this, message, value);
|
|
return message;
|
|
}
|
|
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GetRestrictionLinkResponse): GetRestrictionLinkResponse {
|
|
let message = target ?? this.create(), end = reader.pos + length;
|
|
while (reader.pos < end) {
|
|
let [fieldNo, wireType] = reader.tag();
|
|
switch (fieldNo) {
|
|
case /* api.RestrictionLink RestrictionLink */ 1:
|
|
message.RestrictionLink = RestrictionLink.internalBinaryRead(reader, reader.uint32(), options, message.RestrictionLink);
|
|
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: GetRestrictionLinkResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
/* api.RestrictionLink RestrictionLink = 1; */
|
|
if (message.RestrictionLink)
|
|
RestrictionLink.internalBinaryWrite(message.RestrictionLink, 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.GetRestrictionLinkResponse
|
|
*/
|
|
export const GetRestrictionLinkResponse = new GetRestrictionLinkResponse$Type();
|
|
// @generated message type with reflection information, may provide speed optimized methods
|
|
class ListRestrictionLinksRequest$Type extends MessageType<ListRestrictionLinksRequest> {
|
|
constructor() {
|
|
super("api.ListRestrictionLinksRequest", [
|
|
{ no: 1, name: "Header", kind: "message", localName: "Header", jsonName: "Header", T: () => RequestProjectHeader, options: { "validate.rules": { message: { required: true } } } },
|
|
{ no: 2, name: "RestrictionID", kind: "scalar", localName: "RestrictionID", jsonName: "RestrictionID", T: 9 /*ScalarType.STRING*/ },
|
|
{ no: 3, name: "TargetID", kind: "scalar", localName: "TargetID", jsonName: "TargetID", T: 9 /*ScalarType.STRING*/ }
|
|
], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header"] } } });
|
|
}
|
|
create(value?: PartialMessage<ListRestrictionLinksRequest>): ListRestrictionLinksRequest {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
message.RestrictionID = "";
|
|
message.TargetID = "";
|
|
if (value !== undefined)
|
|
reflectionMergePartial<ListRestrictionLinksRequest>(this, message, value);
|
|
return message;
|
|
}
|
|
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ListRestrictionLinksRequest): ListRestrictionLinksRequest {
|
|
let message = target ?? this.create(), end = reader.pos + length;
|
|
while (reader.pos < end) {
|
|
let [fieldNo, wireType] = reader.tag();
|
|
switch (fieldNo) {
|
|
case /* api.RequestProjectHeader Header */ 1:
|
|
message.Header = RequestProjectHeader.internalBinaryRead(reader, reader.uint32(), options, message.Header);
|
|
break;
|
|
case /* string RestrictionID */ 2:
|
|
message.RestrictionID = reader.string();
|
|
break;
|
|
case /* string TargetID */ 3:
|
|
message.TargetID = 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: ListRestrictionLinksRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
/* api.RequestProjectHeader Header = 1; */
|
|
if (message.Header)
|
|
RequestProjectHeader.internalBinaryWrite(message.Header, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
/* string RestrictionID = 2; */
|
|
if (message.RestrictionID !== "")
|
|
writer.tag(2, WireType.LengthDelimited).string(message.RestrictionID);
|
|
/* string TargetID = 3; */
|
|
if (message.TargetID !== "")
|
|
writer.tag(3, WireType.LengthDelimited).string(message.TargetID);
|
|
let u = options.writeUnknownFields;
|
|
if (u !== false)
|
|
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
return writer;
|
|
}
|
|
}
|
|
/**
|
|
* @generated MessageType for protobuf message api.ListRestrictionLinksRequest
|
|
*/
|
|
export const ListRestrictionLinksRequest = new ListRestrictionLinksRequest$Type();
|
|
// @generated message type with reflection information, may provide speed optimized methods
|
|
class ListRestrictionLinksResponse$Type extends MessageType<ListRestrictionLinksResponse> {
|
|
constructor() {
|
|
super("api.ListRestrictionLinksResponse", [
|
|
{ no: 1, name: "RestrictionLinks", kind: "message", localName: "RestrictionLinks", jsonName: "RestrictionLinks", repeat: 2 /*RepeatType.UNPACKED*/, T: () => RestrictionLink }
|
|
]);
|
|
}
|
|
create(value?: PartialMessage<ListRestrictionLinksResponse>): ListRestrictionLinksResponse {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
message.RestrictionLinks = [];
|
|
if (value !== undefined)
|
|
reflectionMergePartial<ListRestrictionLinksResponse>(this, message, value);
|
|
return message;
|
|
}
|
|
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ListRestrictionLinksResponse): ListRestrictionLinksResponse {
|
|
let message = target ?? this.create(), end = reader.pos + length;
|
|
while (reader.pos < end) {
|
|
let [fieldNo, wireType] = reader.tag();
|
|
switch (fieldNo) {
|
|
case /* repeated api.RestrictionLink RestrictionLinks */ 1:
|
|
message.RestrictionLinks.push(RestrictionLink.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: ListRestrictionLinksResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
/* repeated api.RestrictionLink RestrictionLinks = 1; */
|
|
for (let i = 0; i < message.RestrictionLinks.length; i++)
|
|
RestrictionLink.internalBinaryWrite(message.RestrictionLinks[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.ListRestrictionLinksResponse
|
|
*/
|
|
export const ListRestrictionLinksResponse = new ListRestrictionLinksResponse$Type();
|
|
// @generated message type with reflection information, may provide speed optimized methods
|
|
class SetUserActorsRequest$Type extends MessageType<SetUserActorsRequest> {
|
|
constructor() {
|
|
super("api.SetUserActorsRequest", [
|
|
{ no: 1, name: "Header", kind: "message", localName: "Header", jsonName: "Header", T: () => RequestProjectHeader, options: { "validate.rules": { message: { required: true } } } },
|
|
{ no: 2, name: "RestrictionID", kind: "scalar", localName: "RestrictionID", jsonName: "RestrictionID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } },
|
|
{ no: 3, name: "UserID", kind: "scalar", localName: "UserID", jsonName: "UserID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } },
|
|
{ no: 4, name: "UserActorIDs", kind: "scalar", localName: "UserActorIDs", jsonName: "UserActorIDs", repeat: 2 /*RepeatType.UNPACKED*/, T: 9 /*ScalarType.STRING*/ }
|
|
], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "RestrictionID", "UserID"] } } });
|
|
}
|
|
create(value?: PartialMessage<SetUserActorsRequest>): SetUserActorsRequest {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
message.RestrictionID = "";
|
|
message.UserID = "";
|
|
message.UserActorIDs = [];
|
|
if (value !== undefined)
|
|
reflectionMergePartial<SetUserActorsRequest>(this, message, value);
|
|
return message;
|
|
}
|
|
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: SetUserActorsRequest): SetUserActorsRequest {
|
|
let message = target ?? this.create(), end = reader.pos + length;
|
|
while (reader.pos < end) {
|
|
let [fieldNo, wireType] = reader.tag();
|
|
switch (fieldNo) {
|
|
case /* api.RequestProjectHeader Header */ 1:
|
|
message.Header = RequestProjectHeader.internalBinaryRead(reader, reader.uint32(), options, message.Header);
|
|
break;
|
|
case /* string RestrictionID */ 2:
|
|
message.RestrictionID = reader.string();
|
|
break;
|
|
case /* string UserID */ 3:
|
|
message.UserID = reader.string();
|
|
break;
|
|
case /* repeated string UserActorIDs */ 4:
|
|
message.UserActorIDs.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: SetUserActorsRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
/* api.RequestProjectHeader Header = 1; */
|
|
if (message.Header)
|
|
RequestProjectHeader.internalBinaryWrite(message.Header, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
/* string RestrictionID = 2; */
|
|
if (message.RestrictionID !== "")
|
|
writer.tag(2, WireType.LengthDelimited).string(message.RestrictionID);
|
|
/* string UserID = 3; */
|
|
if (message.UserID !== "")
|
|
writer.tag(3, WireType.LengthDelimited).string(message.UserID);
|
|
/* repeated string UserActorIDs = 4; */
|
|
for (let i = 0; i < message.UserActorIDs.length; i++)
|
|
writer.tag(4, WireType.LengthDelimited).string(message.UserActorIDs[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.SetUserActorsRequest
|
|
*/
|
|
export const SetUserActorsRequest = new SetUserActorsRequest$Type();
|
|
// @generated message type with reflection information, may provide speed optimized methods
|
|
class SetUserActorsResponse$Type extends MessageType<SetUserActorsResponse> {
|
|
constructor() {
|
|
super("api.SetUserActorsResponse", []);
|
|
}
|
|
create(value?: PartialMessage<SetUserActorsResponse>): SetUserActorsResponse {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
if (value !== undefined)
|
|
reflectionMergePartial<SetUserActorsResponse>(this, message, value);
|
|
return message;
|
|
}
|
|
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: SetUserActorsResponse): SetUserActorsResponse {
|
|
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: SetUserActorsResponse, 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.SetUserActorsResponse
|
|
*/
|
|
export const SetUserActorsResponse = new SetUserActorsResponse$Type();
|
|
// @generated message type with reflection information, may provide speed optimized methods
|
|
class DeleteForProjectRestrictionLinkRequest$Type extends MessageType<DeleteForProjectRestrictionLinkRequest> {
|
|
constructor() {
|
|
super("api.DeleteForProjectRestrictionLinkRequest", [
|
|
{ no: 1, name: "Header", kind: "message", localName: "Header", jsonName: "Header", T: () => RequestProjectHeader, options: { "validate.rules": { message: { required: true } } } }
|
|
], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "RestrictionID"] } } });
|
|
}
|
|
create(value?: PartialMessage<DeleteForProjectRestrictionLinkRequest>): DeleteForProjectRestrictionLinkRequest {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
if (value !== undefined)
|
|
reflectionMergePartial<DeleteForProjectRestrictionLinkRequest>(this, message, value);
|
|
return message;
|
|
}
|
|
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: DeleteForProjectRestrictionLinkRequest): DeleteForProjectRestrictionLinkRequest {
|
|
let message = target ?? this.create(), end = reader.pos + length;
|
|
while (reader.pos < end) {
|
|
let [fieldNo, wireType] = reader.tag();
|
|
switch (fieldNo) {
|
|
case /* api.RequestProjectHeader Header */ 1:
|
|
message.Header = RequestProjectHeader.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: DeleteForProjectRestrictionLinkRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
/* api.RequestProjectHeader Header = 1; */
|
|
if (message.Header)
|
|
RequestProjectHeader.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.DeleteForProjectRestrictionLinkRequest
|
|
*/
|
|
export const DeleteForProjectRestrictionLinkRequest = new DeleteForProjectRestrictionLinkRequest$Type();
|
|
// @generated message type with reflection information, may provide speed optimized methods
|
|
class DeleteForProjectRestrictionLinkResponse$Type extends MessageType<DeleteForProjectRestrictionLinkResponse> {
|
|
constructor() {
|
|
super("api.DeleteForProjectRestrictionLinkResponse", []);
|
|
}
|
|
create(value?: PartialMessage<DeleteForProjectRestrictionLinkResponse>): DeleteForProjectRestrictionLinkResponse {
|
|
const message = globalThis.Object.create((this.messagePrototype!));
|
|
if (value !== undefined)
|
|
reflectionMergePartial<DeleteForProjectRestrictionLinkResponse>(this, message, value);
|
|
return message;
|
|
}
|
|
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: DeleteForProjectRestrictionLinkResponse): DeleteForProjectRestrictionLinkResponse {
|
|
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: DeleteForProjectRestrictionLinkResponse, 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.DeleteForProjectRestrictionLinkResponse
|
|
*/
|
|
export const DeleteForProjectRestrictionLinkResponse = new DeleteForProjectRestrictionLinkResponse$Type();
|
|
/**
|
|
* @generated ServiceType for protobuf service api.RestrictionLinkService
|
|
*/
|
|
export const RestrictionLinkService = new ServiceType("api.RestrictionLinkService", [
|
|
{ name: "Create", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Restriction Link"], description: "Create a link between a restriction and a user or a partner" }, "api.rscType": "Project", "api.roles": "", "google.api.method_visibility": { restriction: "SDK" } }, I: CreateRestrictionLinkRequest, O: CreateRestrictionLinkResponse },
|
|
{ name: "Update", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Restriction Link"], description: "Update a link between a restriction and a user or a partner" }, "api.rscType": "Project", "api.roles": "", "google.api.method_visibility": { restriction: "SDK" } }, I: UpdateRestrictionLinkRequest, O: UpdateRestrictionLinkResponse },
|
|
{ name: "Delete", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Restriction Link"], description: "Delete a restriction link" }, "api.rscType": "Project", "api.roles": "Platform.Project-Rule", "google.api.method_visibility": { restriction: "SDK" } }, I: DeleteRestrictionLinkRequest, O: DeleteRestrictionLinkResponse },
|
|
{ name: "Get", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Restriction Link"], description: "Get a restriction link" }, "api.rscType": "Project", "api.roles": "", "google.api.method_visibility": { restriction: "SDK" } }, I: GetRestrictionLinkRequest, O: GetRestrictionLinkResponse },
|
|
{ name: "List", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Restriction Link"], description: "List restriction links" }, "api.rscType": "Project", "api.roles": "Platform.Project-Rule", "google.api.method_visibility": { restriction: "SDK" } }, I: ListRestrictionLinksRequest, O: ListRestrictionLinksResponse },
|
|
{ name: "SetUserActors", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Restriction Link"], description: "Set user's actors for a restriction. Once applied on the user, the restriction will use that list of actors if needed." }, "api.rscType": "Project", "api.roles": "", "google.api.method_visibility": { restriction: "SDK" } }, I: SetUserActorsRequest, O: SetUserActorsResponse },
|
|
{ name: "DeleteForProject", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Restriction"], description: "Delete all restriction link in project" }, "api.rscType": "Project", "api.roles": "Platform.Project-Rule", "google.api.method_visibility": { restriction: "SDK" } }, I: DeleteForProjectRestrictionLinkRequest, O: DeleteForProjectRestrictionLinkResponse }
|
|
], { "api.k8sService": "rule-server" });
|