| 1 |
// Copyright 2025 Google LLC |
| 2 |
// |
| 3 |
// Licensed under the Apache License, Version 2.0 (the "License"); |
| 4 |
// you may not use this file except in compliance with the License. |
| 5 |
// You may obtain a copy of the License at |
| 6 |
// |
| 7 |
// http://www.apache.org/licenses/LICENSE-2.0 |
| 8 |
// |
| 9 |
// Unless required by applicable law or agreed to in writing, software |
| 10 |
// distributed under the License is distributed on an "AS IS" BASIS, |
| 11 |
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 12 |
// See the License for the specific language governing permissions and |
| 13 |
// limitations under the License. |
| 14 |
|
| 15 |
// Code generated by protoc-gen-go-grpc. DO NOT EDIT. |
| 16 |
// versions: |
| 17 |
// - protoc-gen-go-grpc v1.3.0 |
| 18 |
// - protoc v4.25.7 |
| 19 |
// source: google/cloud/apihub/v1/apihub_service.proto |
| 20 |
|
| 21 |
package apihubpb |
| 22 |
|
| 23 |
import ( |
| 24 |
context "context" |
| 25 |
grpc "google.golang.org/grpc" |
| 26 |
codes "google.golang.org/grpc/codes" |
| 27 |
status "google.golang.org/grpc/status" |
| 28 |
emptypb "google.golang.org/protobuf/types/known/emptypb" |
| 29 |
) |
| 30 |
|
| 31 |
// This is a compile-time assertion to ensure that this generated file |
| 32 |
// is compatible with the grpc package it is being compiled against. |
| 33 |
// Requires gRPC-Go v1.32.0 or later. |
| 34 |
const _ = grpc.SupportPackageIsVersion7 |
| 35 |
|
| 36 |
const ( |
| 37 |
ApiHub_CreateApi_FullMethodName = "/google.cloud.apihub.v1.ApiHub/CreateApi" |
| 38 |
ApiHub_GetApi_FullMethodName = "/google.cloud.apihub.v1.ApiHub/GetApi" |
| 39 |
ApiHub_ListApis_FullMethodName = "/google.cloud.apihub.v1.ApiHub/ListApis" |
| 40 |
ApiHub_UpdateApi_FullMethodName = "/google.cloud.apihub.v1.ApiHub/UpdateApi" |
| 41 |
ApiHub_DeleteApi_FullMethodName = "/google.cloud.apihub.v1.ApiHub/DeleteApi" |
| 42 |
ApiHub_CreateVersion_FullMethodName = "/google.cloud.apihub.v1.ApiHub/CreateVersion" |
| 43 |
ApiHub_GetVersion_FullMethodName = "/google.cloud.apihub.v1.ApiHub/GetVersion" |
| 44 |
ApiHub_ListVersions_FullMethodName = "/google.cloud.apihub.v1.ApiHub/ListVersions" |
| 45 |
ApiHub_UpdateVersion_FullMethodName = "/google.cloud.apihub.v1.ApiHub/UpdateVersion" |
| 46 |
ApiHub_DeleteVersion_FullMethodName = "/google.cloud.apihub.v1.ApiHub/DeleteVersion" |
| 47 |
ApiHub_CreateSpec_FullMethodName = "/google.cloud.apihub.v1.ApiHub/CreateSpec" |
| 48 |
ApiHub_GetSpec_FullMethodName = "/google.cloud.apihub.v1.ApiHub/GetSpec" |
| 49 |
ApiHub_GetSpecContents_FullMethodName = "/google.cloud.apihub.v1.ApiHub/GetSpecContents" |
| 50 |
ApiHub_ListSpecs_FullMethodName = "/google.cloud.apihub.v1.ApiHub/ListSpecs" |
| 51 |
ApiHub_UpdateSpec_FullMethodName = "/google.cloud.apihub.v1.ApiHub/UpdateSpec" |
| 52 |
ApiHub_DeleteSpec_FullMethodName = "/google.cloud.apihub.v1.ApiHub/DeleteSpec" |
| 53 |
ApiHub_CreateApiOperation_FullMethodName = "/google.cloud.apihub.v1.ApiHub/CreateApiOperation" |
| 54 |
ApiHub_GetApiOperation_FullMethodName = "/google.cloud.apihub.v1.ApiHub/GetApiOperation" |
| 55 |
ApiHub_ListApiOperations_FullMethodName = "/google.cloud.apihub.v1.ApiHub/ListApiOperations" |
| 56 |
ApiHub_UpdateApiOperation_FullMethodName = "/google.cloud.apihub.v1.ApiHub/UpdateApiOperation" |
| 57 |
ApiHub_DeleteApiOperation_FullMethodName = "/google.cloud.apihub.v1.ApiHub/DeleteApiOperation" |
| 58 |
ApiHub_GetDefinition_FullMethodName = "/google.cloud.apihub.v1.ApiHub/GetDefinition" |
| 59 |
ApiHub_CreateDeployment_FullMethodName = "/google.cloud.apihub.v1.ApiHub/CreateDeployment" |
| 60 |
ApiHub_GetDeployment_FullMethodName = "/google.cloud.apihub.v1.ApiHub/GetDeployment" |
| 61 |
ApiHub_ListDeployments_FullMethodName = "/google.cloud.apihub.v1.ApiHub/ListDeployments" |
| 62 |
ApiHub_UpdateDeployment_FullMethodName = "/google.cloud.apihub.v1.ApiHub/UpdateDeployment" |
| 63 |
ApiHub_DeleteDeployment_FullMethodName = "/google.cloud.apihub.v1.ApiHub/DeleteDeployment" |
| 64 |
ApiHub_CreateAttribute_FullMethodName = "/google.cloud.apihub.v1.ApiHub/CreateAttribute" |
| 65 |
ApiHub_GetAttribute_FullMethodName = "/google.cloud.apihub.v1.ApiHub/GetAttribute" |
| 66 |
ApiHub_UpdateAttribute_FullMethodName = "/google.cloud.apihub.v1.ApiHub/UpdateAttribute" |
| 67 |
ApiHub_DeleteAttribute_FullMethodName = "/google.cloud.apihub.v1.ApiHub/DeleteAttribute" |
| 68 |
ApiHub_ListAttributes_FullMethodName = "/google.cloud.apihub.v1.ApiHub/ListAttributes" |
| 69 |
ApiHub_SearchResources_FullMethodName = "/google.cloud.apihub.v1.ApiHub/SearchResources" |
| 70 |
ApiHub_CreateExternalApi_FullMethodName = "/google.cloud.apihub.v1.ApiHub/CreateExternalApi" |
| 71 |
ApiHub_GetExternalApi_FullMethodName = "/google.cloud.apihub.v1.ApiHub/GetExternalApi" |
| 72 |
ApiHub_UpdateExternalApi_FullMethodName = "/google.cloud.apihub.v1.ApiHub/UpdateExternalApi" |
| 73 |
ApiHub_DeleteExternalApi_FullMethodName = "/google.cloud.apihub.v1.ApiHub/DeleteExternalApi" |
| 74 |
ApiHub_ListExternalApis_FullMethodName = "/google.cloud.apihub.v1.ApiHub/ListExternalApis" |
| 75 |
) |
| 76 |
|
| 77 |
// ApiHubClient is the client API for ApiHub service. |
| 78 |
// |
| 79 |
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. |
| 80 |
type ApiHubClient interface { |
| 81 |
// Create an API resource in the API hub. |
| 82 |
// Once an API resource is created, versions can be added to it. |
| 83 |
CreateApi(ctx context.Context, in *CreateApiRequest, opts ...grpc.CallOption) (*Api, error) |
| 84 |
// Get API resource details including the API versions contained in it. |
| 85 |
GetApi(ctx context.Context, in *GetApiRequest, opts ...grpc.CallOption) (*Api, error) |
| 86 |
// List API resources in the API hub. |
| 87 |
ListApis(ctx context.Context, in *ListApisRequest, opts ...grpc.CallOption) (*ListApisResponse, error) |
| 88 |
// Update an API resource in the API hub. The following fields in the |
| 89 |
// [API][google.cloud.apihub.v1.Api] can be updated: |
| 90 |
// |
| 91 |
// * [display_name][google.cloud.apihub.v1.Api.display_name] |
| 92 |
// * [description][google.cloud.apihub.v1.Api.description] |
| 93 |
// * [owner][google.cloud.apihub.v1.Api.owner] |
| 94 |
// * [documentation][google.cloud.apihub.v1.Api.documentation] |
| 95 |
// * [target_user][google.cloud.apihub.v1.Api.target_user] |
| 96 |
// * [team][google.cloud.apihub.v1.Api.team] |
| 97 |
// * [business_unit][google.cloud.apihub.v1.Api.business_unit] |
| 98 |
// * [maturity_level][google.cloud.apihub.v1.Api.maturity_level] |
| 99 |
// * [api_style][google.cloud.apihub.v1.Api.api_style] |
| 100 |
// * [attributes][google.cloud.apihub.v1.Api.attributes] |
| 101 |
// |
| 102 |
// The |
| 103 |
// [update_mask][google.cloud.apihub.v1.UpdateApiRequest.update_mask] |
| 104 |
// should be used to specify the fields being updated. |
| 105 |
// |
| 106 |
// Updating the owner field requires complete owner message |
| 107 |
// and updates both owner and email fields. |
| 108 |
UpdateApi(ctx context.Context, in *UpdateApiRequest, opts ...grpc.CallOption) (*Api, error) |
| 109 |
// Delete an API resource in the API hub. API can only be deleted if all |
| 110 |
// underlying versions are deleted. |
| 111 |
DeleteApi(ctx context.Context, in *DeleteApiRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) |
| 112 |
// Create an API version for an API resource in the API hub. |
| 113 |
CreateVersion(ctx context.Context, in *CreateVersionRequest, opts ...grpc.CallOption) (*Version, error) |
| 114 |
// Get details about the API version of an API resource. This will include |
| 115 |
// information about the specs and operations present in the API |
| 116 |
// version as well as the deployments linked to it. |
| 117 |
GetVersion(ctx context.Context, in *GetVersionRequest, opts ...grpc.CallOption) (*Version, error) |
| 118 |
// List API versions of an API resource in the API hub. |
| 119 |
ListVersions(ctx context.Context, in *ListVersionsRequest, opts ...grpc.CallOption) (*ListVersionsResponse, error) |
| 120 |
// Update API version. The following fields in the |
| 121 |
// [version][google.cloud.apihub.v1.Version] can be updated currently: |
| 122 |
// |
| 123 |
// * [display_name][google.cloud.apihub.v1.Version.display_name] |
| 124 |
// * [description][google.cloud.apihub.v1.Version.description] |
| 125 |
// * [documentation][google.cloud.apihub.v1.Version.documentation] |
| 126 |
// * [deployments][google.cloud.apihub.v1.Version.deployments] |
| 127 |
// * [lifecycle][google.cloud.apihub.v1.Version.lifecycle] |
| 128 |
// * [compliance][google.cloud.apihub.v1.Version.compliance] |
| 129 |
// * [accreditation][google.cloud.apihub.v1.Version.accreditation] |
| 130 |
// * [attributes][google.cloud.apihub.v1.Version.attributes] |
| 131 |
// |
| 132 |
// The |
| 133 |
// [update_mask][google.cloud.apihub.v1.UpdateVersionRequest.update_mask] |
| 134 |
// should be used to specify the fields being updated. |
| 135 |
UpdateVersion(ctx context.Context, in *UpdateVersionRequest, opts ...grpc.CallOption) (*Version, error) |
| 136 |
// Delete an API version. Version can only be deleted if all underlying specs, |
| 137 |
// operations, definitions and linked deployments are deleted. |
| 138 |
DeleteVersion(ctx context.Context, in *DeleteVersionRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) |
| 139 |
// Add a spec to an API version in the API hub. |
| 140 |
// Multiple specs can be added to an API version. |
| 141 |
// Note, while adding a spec, at least one of `contents` or `source_uri` must |
| 142 |
// be provided. If `contents` is provided, then `spec_type` must also be |
| 143 |
// provided. |
| 144 |
// |
| 145 |
// On adding a spec with contents to the version, the operations present in it |
| 146 |
// will be added to the version.Note that the file contents in the spec should |
| 147 |
// be of the same type as defined in the |
| 148 |
// `projects/{project}/locations/{location}/attributes/system-spec-type` |
| 149 |
// attribute associated with spec resource. Note that specs of various types |
| 150 |
// can be uploaded, however parsing of details is supported for OpenAPI spec |
| 151 |
// currently. |
| 152 |
// |
| 153 |
// In order to access the information parsed from the spec, use the |
| 154 |
// [GetSpec][google.cloud.apihub.v1.ApiHub.GetSpec] method. |
| 155 |
// In order to access the raw contents for a particular spec, use the |
| 156 |
// [GetSpecContents][google.cloud.apihub.v1.ApiHub.GetSpecContents] method. |
| 157 |
// In order to access the operations parsed from the spec, use the |
| 158 |
// [ListAPIOperations][google.cloud.apihub.v1.ApiHub.ListApiOperations] |
| 159 |
// method. |
| 160 |
CreateSpec(ctx context.Context, in *CreateSpecRequest, opts ...grpc.CallOption) (*Spec, error) |
| 161 |
// Get details about the information parsed from a spec. |
| 162 |
// Note that this method does not return the raw spec contents. |
| 163 |
// Use [GetSpecContents][google.cloud.apihub.v1.ApiHub.GetSpecContents] method |
| 164 |
// to retrieve the same. |
| 165 |
GetSpec(ctx context.Context, in *GetSpecRequest, opts ...grpc.CallOption) (*Spec, error) |
| 166 |
// Get spec contents. |
| 167 |
GetSpecContents(ctx context.Context, in *GetSpecContentsRequest, opts ...grpc.CallOption) (*SpecContents, error) |
| 168 |
// List specs corresponding to a particular API resource. |
| 169 |
ListSpecs(ctx context.Context, in *ListSpecsRequest, opts ...grpc.CallOption) (*ListSpecsResponse, error) |
| 170 |
// Update spec. The following fields in the |
| 171 |
// [spec][google.cloud.apihub.v1.Spec] can be updated: |
| 172 |
// |
| 173 |
// * [display_name][google.cloud.apihub.v1.Spec.display_name] |
| 174 |
// * [source_uri][google.cloud.apihub.v1.Spec.source_uri] |
| 175 |
// * [lint_response][google.cloud.apihub.v1.Spec.lint_response] |
| 176 |
// * [attributes][google.cloud.apihub.v1.Spec.attributes] |
| 177 |
// * [contents][google.cloud.apihub.v1.Spec.contents] |
| 178 |
// * [spec_type][google.cloud.apihub.v1.Spec.spec_type] |
| 179 |
// |
| 180 |
// In case of an OAS spec, updating spec contents can lead to: |
| 181 |
// 1. Creation, deletion and update of operations. |
| 182 |
// 2. Creation, deletion and update of definitions. |
| 183 |
// 3. Update of other info parsed out from the new spec. |
| 184 |
// |
| 185 |
// In case of contents or source_uri being present in update mask, spec_type |
| 186 |
// must also be present. Also, spec_type can not be present in update mask if |
| 187 |
// contents or source_uri is not present. |
| 188 |
// |
| 189 |
// The |
| 190 |
// [update_mask][google.cloud.apihub.v1.UpdateSpecRequest.update_mask] |
| 191 |
// should be used to specify the fields being updated. |
| 192 |
UpdateSpec(ctx context.Context, in *UpdateSpecRequest, opts ...grpc.CallOption) (*Spec, error) |
| 193 |
// Delete a spec. |
| 194 |
// Deleting a spec will also delete the associated operations from the |
| 195 |
// version. |
| 196 |
DeleteSpec(ctx context.Context, in *DeleteSpecRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) |
| 197 |
// Create an apiOperation in an API version. |
| 198 |
// An apiOperation can be created only if the version has no apiOperations |
| 199 |
// which were created by parsing a spec. |
| 200 |
CreateApiOperation(ctx context.Context, in *CreateApiOperationRequest, opts ...grpc.CallOption) (*ApiOperation, error) |
| 201 |
// Get details about a particular operation in API version. |
| 202 |
GetApiOperation(ctx context.Context, in *GetApiOperationRequest, opts ...grpc.CallOption) (*ApiOperation, error) |
| 203 |
// List operations in an API version. |
| 204 |
ListApiOperations(ctx context.Context, in *ListApiOperationsRequest, opts ...grpc.CallOption) (*ListApiOperationsResponse, error) |
| 205 |
// Update an operation in an API version. The following fields in the |
| 206 |
// [ApiOperation resource][google.cloud.apihub.v1.ApiOperation] can be |
| 207 |
// updated: |
| 208 |
// |
| 209 |
// * [details.description][ApiOperation.details.description] |
| 210 |
// * [details.documentation][ApiOperation.details.documentation] |
| 211 |
// * [details.http_operation.path][ApiOperation.details.http_operation.path.path] |
| 212 |
// * [details.http_operation.method][ApiOperation.details.http_operation.method] |
| 213 |
// * [details.deprecated][ApiOperation.details.deprecated] |
| 214 |
// * [attributes][google.cloud.apihub.v1.ApiOperation.attributes] |
| 215 |
// |
| 216 |
// The |
| 217 |
// [update_mask][google.cloud.apihub.v1.UpdateApiOperationRequest.update_mask] |
| 218 |
// should be used to specify the fields being updated. |
| 219 |
// |
| 220 |
// An operation can be updated only if the operation was created via |
| 221 |
// [CreateApiOperation][google.cloud.apihub.v1.ApiHub.CreateApiOperation] API. |
| 222 |
// If the operation was created by parsing the spec, then it can be edited by |
| 223 |
// updating the spec. |
| 224 |
UpdateApiOperation(ctx context.Context, in *UpdateApiOperationRequest, opts ...grpc.CallOption) (*ApiOperation, error) |
| 225 |
// Delete an operation in an API version and we can delete only the |
| 226 |
// operations created via create API. If the operation was created by parsing |
| 227 |
// the spec, then it can be deleted by editing or deleting the spec. |
| 228 |
DeleteApiOperation(ctx context.Context, in *DeleteApiOperationRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) |
| 229 |
// Get details about a definition in an API version. |
| 230 |
GetDefinition(ctx context.Context, in *GetDefinitionRequest, opts ...grpc.CallOption) (*Definition, error) |
| 231 |
// Create a deployment resource in the API hub. |
| 232 |
// Once a deployment resource is created, it can be associated with API |
| 233 |
// versions. |
| 234 |
CreateDeployment(ctx context.Context, in *CreateDeploymentRequest, opts ...grpc.CallOption) (*Deployment, error) |
| 235 |
// Get details about a deployment and the API versions linked to it. |
| 236 |
GetDeployment(ctx context.Context, in *GetDeploymentRequest, opts ...grpc.CallOption) (*Deployment, error) |
| 237 |
// List deployment resources in the API hub. |
| 238 |
ListDeployments(ctx context.Context, in *ListDeploymentsRequest, opts ...grpc.CallOption) (*ListDeploymentsResponse, error) |
| 239 |
// Update a deployment resource in the API hub. The following fields in the |
| 240 |
// [deployment resource][google.cloud.apihub.v1.Deployment] can be |
| 241 |
// updated: |
| 242 |
// |
| 243 |
// * [display_name][google.cloud.apihub.v1.Deployment.display_name] |
| 244 |
// * [description][google.cloud.apihub.v1.Deployment.description] |
| 245 |
// * [documentation][google.cloud.apihub.v1.Deployment.documentation] |
| 246 |
// * [deployment_type][google.cloud.apihub.v1.Deployment.deployment_type] |
| 247 |
// * [resource_uri][google.cloud.apihub.v1.Deployment.resource_uri] |
| 248 |
// * [endpoints][google.cloud.apihub.v1.Deployment.endpoints] |
| 249 |
// * [slo][google.cloud.apihub.v1.Deployment.slo] |
| 250 |
// * [environment][google.cloud.apihub.v1.Deployment.environment] |
| 251 |
// * [attributes][google.cloud.apihub.v1.Deployment.attributes] |
| 252 |
// * [source_project] [google.cloud.apihub.v1.Deployment.source_project] |
| 253 |
// * [source_environment] |
| 254 |
// [google.cloud.apihub.v1.Deployment.source_environment] |
| 255 |
// * [management_url][google.cloud.apihub.v1.Deployment.management_url] |
| 256 |
// * [source_uri][google.cloud.apihub.v1.Deployment.source_uri] |
| 257 |
// The |
| 258 |
// [update_mask][google.cloud.apihub.v1.UpdateDeploymentRequest.update_mask] |
| 259 |
// should be used to specify the fields being updated. |
| 260 |
UpdateDeployment(ctx context.Context, in *UpdateDeploymentRequest, opts ...grpc.CallOption) (*Deployment, error) |
| 261 |
// Delete a deployment resource in the API hub. |
| 262 |
DeleteDeployment(ctx context.Context, in *DeleteDeploymentRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) |
| 263 |
// Create a user defined attribute. |
| 264 |
// |
| 265 |
// Certain pre defined attributes are already created by the API hub. These |
| 266 |
// attributes will have type as `SYSTEM_DEFINED` and can be listed via |
| 267 |
// [ListAttributes][google.cloud.apihub.v1.ApiHub.ListAttributes] method. |
| 268 |
// Allowed values for the same can be updated via |
| 269 |
// [UpdateAttribute][google.cloud.apihub.v1.ApiHub.UpdateAttribute] method. |
| 270 |
CreateAttribute(ctx context.Context, in *CreateAttributeRequest, opts ...grpc.CallOption) (*Attribute, error) |
| 271 |
// Get details about the attribute. |
| 272 |
GetAttribute(ctx context.Context, in *GetAttributeRequest, opts ...grpc.CallOption) (*Attribute, error) |
| 273 |
// Update the attribute. The following fields in the |
| 274 |
// [Attribute resource][google.cloud.apihub.v1.Attribute] can be updated: |
| 275 |
// |
| 276 |
// * [display_name][google.cloud.apihub.v1.Attribute.display_name] |
| 277 |
// The display name can be updated for user defined attributes only. |
| 278 |
// * [description][google.cloud.apihub.v1.Attribute.description] |
| 279 |
// The description can be updated for user defined attributes only. |
| 280 |
// * [allowed_values][google.cloud.apihub.v1.Attribute.allowed_values] |
| 281 |
// To update the list of allowed values, clients need to use the fetched list |
| 282 |
// of allowed values and add or remove values to or from the same list. |
| 283 |
// The mutable allowed values can be updated for both user defined and System |
| 284 |
// defined attributes. The immutable allowed values cannot be updated or |
| 285 |
// deleted. The updated list of allowed values cannot be empty. If an allowed |
| 286 |
// value that is already used by some resource's attribute is deleted, then |
| 287 |
// the association between the resource and the attribute value will also be |
| 288 |
// deleted. |
| 289 |
// * [cardinality][google.cloud.apihub.v1.Attribute.cardinality] |
| 290 |
// The cardinality can be updated for user defined attributes only. |
| 291 |
// Cardinality can only be increased during an update. |
| 292 |
// |
| 293 |
// The |
| 294 |
// [update_mask][google.cloud.apihub.v1.UpdateAttributeRequest.update_mask] |
| 295 |
// should be used to specify the fields being updated. |
| 296 |
UpdateAttribute(ctx context.Context, in *UpdateAttributeRequest, opts ...grpc.CallOption) (*Attribute, error) |
| 297 |
// Delete an attribute. |
| 298 |
// |
| 299 |
// Note: System defined attributes cannot be deleted. All |
| 300 |
// associations of the attribute being deleted with any API hub resource will |
| 301 |
// also get deleted. |
| 302 |
DeleteAttribute(ctx context.Context, in *DeleteAttributeRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) |
| 303 |
// List all attributes. |
| 304 |
ListAttributes(ctx context.Context, in *ListAttributesRequest, opts ...grpc.CallOption) (*ListAttributesResponse, error) |
| 305 |
// Search across API-Hub resources. |
| 306 |
SearchResources(ctx context.Context, in *SearchResourcesRequest, opts ...grpc.CallOption) (*SearchResourcesResponse, error) |
| 307 |
// Create an External API resource in the API hub. |
| 308 |
CreateExternalApi(ctx context.Context, in *CreateExternalApiRequest, opts ...grpc.CallOption) (*ExternalApi, error) |
| 309 |
// Get details about an External API resource in the API hub. |
| 310 |
GetExternalApi(ctx context.Context, in *GetExternalApiRequest, opts ...grpc.CallOption) (*ExternalApi, error) |
| 311 |
// Update an External API resource in the API hub. The following fields can be |
| 312 |
// updated: |
| 313 |
// |
| 314 |
// * [display_name][google.cloud.apihub.v1.ExternalApi.display_name] |
| 315 |
// * [description][google.cloud.apihub.v1.ExternalApi.description] |
| 316 |
// * [documentation][google.cloud.apihub.v1.ExternalApi.documentation] |
| 317 |
// * [endpoints][google.cloud.apihub.v1.ExternalApi.endpoints] |
| 318 |
// * [paths][google.cloud.apihub.v1.ExternalApi.paths] |
| 319 |
// |
| 320 |
// The |
| 321 |
// [update_mask][google.cloud.apihub.v1.UpdateExternalApiRequest.update_mask] |
| 322 |
// should be used to specify the fields being updated. |
| 323 |
UpdateExternalApi(ctx context.Context, in *UpdateExternalApiRequest, opts ...grpc.CallOption) (*ExternalApi, error) |
| 324 |
// Delete an External API resource in the API hub. |
| 325 |
DeleteExternalApi(ctx context.Context, in *DeleteExternalApiRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) |
| 326 |
// List External API resources in the API hub. |
| 327 |
ListExternalApis(ctx context.Context, in *ListExternalApisRequest, opts ...grpc.CallOption) (*ListExternalApisResponse, error) |
| 328 |
} |
| 329 |
|
| 330 |
type apiHubClient struct { |
| 331 |
cc grpc.ClientConnInterface |
| 332 |
} |
| 333 |
|
| 334 |
func NewApiHubClient(cc grpc.ClientConnInterface) ApiHubClient { |
| 335 |
return &apiHubClient{cc} |
| 336 |
} |
| 337 |
|
| 338 |
func (c *apiHubClient) CreateApi(ctx context.Context, in *CreateApiRequest, opts ...grpc.CallOption) (*Api, error) { |
| 339 |
out := new(Api) |
| 340 |
err := c.cc.Invoke(ctx, ApiHub_CreateApi_FullMethodName, in, out, opts...) |
| 341 |
if err != nil { |
| 342 |
return nil, err |
| 343 |
} |
| 344 |
return out, nil |
| 345 |
} |
| 346 |
|
| 347 |
func (c *apiHubClient) GetApi(ctx context.Context, in *GetApiRequest, opts ...grpc.CallOption) (*Api, error) { |
| 348 |
out := new(Api) |
| 349 |
err := c.cc.Invoke(ctx, ApiHub_GetApi_FullMethodName, in, out, opts...) |
| 350 |
if err != nil { |
| 351 |
return nil, err |
| 352 |
} |
| 353 |
return out, nil |
| 354 |
} |
| 355 |
|
| 356 |
func (c *apiHubClient) ListApis(ctx context.Context, in *ListApisRequest, opts ...grpc.CallOption) (*ListApisResponse, error) { |
| 357 |
out := new(ListApisResponse) |
| 358 |
err := c.cc.Invoke(ctx, ApiHub_ListApis_FullMethodName, in, out, opts...) |
| 359 |
if err != nil { |
| 360 |
return nil, err |
| 361 |
} |
| 362 |
return out, nil |
| 363 |
} |
| 364 |
|
| 365 |
func (c *apiHubClient) UpdateApi(ctx context.Context, in *UpdateApiRequest, opts ...grpc.CallOption) (*Api, error) { |
| 366 |
out := new(Api) |
| 367 |
err := c.cc.Invoke(ctx, ApiHub_UpdateApi_FullMethodName, in, out, opts...) |
| 368 |
if err != nil { |
| 369 |
return nil, err |
| 370 |
} |
| 371 |
return out, nil |
| 372 |
} |
| 373 |
|
| 374 |
func (c *apiHubClient) DeleteApi(ctx context.Context, in *DeleteApiRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { |
| 375 |
out := new(emptypb.Empty) |
| 376 |
err := c.cc.Invoke(ctx, ApiHub_DeleteApi_FullMethodName, in, out, opts...) |
| 377 |
if err != nil { |
| 378 |
return nil, err |
| 379 |
} |
| 380 |
return out, nil |
| 381 |
} |
| 382 |
|
| 383 |
func (c *apiHubClient) CreateVersion(ctx context.Context, in *CreateVersionRequest, opts ...grpc.CallOption) (*Version, error) { |
| 384 |
out := new(Version) |
| 385 |
err := c.cc.Invoke(ctx, ApiHub_CreateVersion_FullMethodName, in, out, opts...) |
| 386 |
if err != nil { |
| 387 |
return nil, err |
| 388 |
} |
| 389 |
return out, nil |
| 390 |
} |
| 391 |
|
| 392 |
func (c *apiHubClient) GetVersion(ctx context.Context, in *GetVersionRequest, opts ...grpc.CallOption) (*Version, error) { |
| 393 |
out := new(Version) |
| 394 |
err := c.cc.Invoke(ctx, ApiHub_GetVersion_FullMethodName, in, out, opts...) |
| 395 |
if err != nil { |
| 396 |
return nil, err |
| 397 |
} |
| 398 |
return out, nil |
| 399 |
} |
| 400 |
|
| 401 |
func (c *apiHubClient) ListVersions(ctx context.Context, in *ListVersionsRequest, opts ...grpc.CallOption) (*ListVersionsResponse, error) { |
| 402 |
out := new(ListVersionsResponse) |
| 403 |
err := c.cc.Invoke(ctx, ApiHub_ListVersions_FullMethodName, in, out, opts...) |
| 404 |
if err != nil { |
| 405 |
return nil, err |
| 406 |
} |
| 407 |
return out, nil |
| 408 |
} |
| 409 |
|
| 410 |
func (c *apiHubClient) UpdateVersion(ctx context.Context, in *UpdateVersionRequest, opts ...grpc.CallOption) (*Version, error) { |
| 411 |
out := new(Version) |
| 412 |
err := c.cc.Invoke(ctx, ApiHub_UpdateVersion_FullMethodName, in, out, opts...) |
| 413 |
if err != nil { |
| 414 |
return nil, err |
| 415 |
} |
| 416 |
return out, nil |
| 417 |
} |
| 418 |
|
| 419 |
func (c *apiHubClient) DeleteVersion(ctx context.Context, in *DeleteVersionRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { |
| 420 |
out := new(emptypb.Empty) |
| 421 |
err := c.cc.Invoke(ctx, ApiHub_DeleteVersion_FullMethodName, in, out, opts...) |
| 422 |
if err != nil { |
| 423 |
return nil, err |
| 424 |
} |
| 425 |
return out, nil |
| 426 |
} |
| 427 |
|
| 428 |
func (c *apiHubClient) CreateSpec(ctx context.Context, in *CreateSpecRequest, opts ...grpc.CallOption) (*Spec, error) { |
| 429 |
out := new(Spec) |
| 430 |
err := c.cc.Invoke(ctx, ApiHub_CreateSpec_FullMethodName, in, out, opts...) |
| 431 |
if err != nil { |
| 432 |
return nil, err |
| 433 |
} |
| 434 |
return out, nil |
| 435 |
} |
| 436 |
|
| 437 |
func (c *apiHubClient) GetSpec(ctx context.Context, in *GetSpecRequest, opts ...grpc.CallOption) (*Spec, error) { |
| 438 |
out := new(Spec) |
| 439 |
err := c.cc.Invoke(ctx, ApiHub_GetSpec_FullMethodName, in, out, opts...) |
| 440 |
if err != nil { |
| 441 |
return nil, err |
| 442 |
} |
| 443 |
return out, nil |
| 444 |
} |
| 445 |
|
| 446 |
func (c *apiHubClient) GetSpecContents(ctx context.Context, in *GetSpecContentsRequest, opts ...grpc.CallOption) (*SpecContents, error) { |
| 447 |
out := new(SpecContents) |
| 448 |
err := c.cc.Invoke(ctx, ApiHub_GetSpecContents_FullMethodName, in, out, opts...) |
| 449 |
if err != nil { |
| 450 |
return nil, err |
| 451 |
} |
| 452 |
return out, nil |
| 453 |
} |
| 454 |
|
| 455 |
func (c *apiHubClient) ListSpecs(ctx context.Context, in *ListSpecsRequest, opts ...grpc.CallOption) (*ListSpecsResponse, error) { |
| 456 |
out := new(ListSpecsResponse) |
| 457 |
err := c.cc.Invoke(ctx, ApiHub_ListSpecs_FullMethodName, in, out, opts...) |
| 458 |
if err != nil { |
| 459 |
return nil, err |
| 460 |
} |
| 461 |
return out, nil |
| 462 |
} |
| 463 |
|
| 464 |
func (c *apiHubClient) UpdateSpec(ctx context.Context, in *UpdateSpecRequest, opts ...grpc.CallOption) (*Spec, error) { |
| 465 |
out := new(Spec) |
| 466 |
err := c.cc.Invoke(ctx, ApiHub_UpdateSpec_FullMethodName, in, out, opts...) |
| 467 |
if err != nil { |
| 468 |
return nil, err |
| 469 |
} |
| 470 |
return out, nil |
| 471 |
} |
| 472 |
|
| 473 |
func (c *apiHubClient) DeleteSpec(ctx context.Context, in *DeleteSpecRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { |
| 474 |
out := new(emptypb.Empty) |
| 475 |
err := c.cc.Invoke(ctx, ApiHub_DeleteSpec_FullMethodName, in, out, opts...) |
| 476 |
if err != nil { |
| 477 |
return nil, err |
| 478 |
} |
| 479 |
return out, nil |
| 480 |
} |
| 481 |
|
| 482 |
func (c *apiHubClient) CreateApiOperation(ctx context.Context, in *CreateApiOperationRequest, opts ...grpc.CallOption) (*ApiOperation, error) { |
| 483 |
out := new(ApiOperation) |
| 484 |
err := c.cc.Invoke(ctx, ApiHub_CreateApiOperation_FullMethodName, in, out, opts...) |
| 485 |
if err != nil { |
| 486 |
return nil, err |
| 487 |
} |
| 488 |
return out, nil |
| 489 |
} |
| 490 |
|
| 491 |
func (c *apiHubClient) GetApiOperation(ctx context.Context, in *GetApiOperationRequest, opts ...grpc.CallOption) (*ApiOperation, error) { |
| 492 |
out := new(ApiOperation) |
| 493 |
err := c.cc.Invoke(ctx, ApiHub_GetApiOperation_FullMethodName, in, out, opts...) |
| 494 |
if err != nil { |
| 495 |
return nil, err |
| 496 |
} |
| 497 |
return out, nil |
| 498 |
} |
| 499 |
|
| 500 |
func (c *apiHubClient) ListApiOperations(ctx context.Context, in *ListApiOperationsRequest, opts ...grpc.CallOption) (*ListApiOperationsResponse, error) { |
| 501 |
out := new(ListApiOperationsResponse) |
| 502 |
err := c.cc.Invoke(ctx, ApiHub_ListApiOperations_FullMethodName, in, out, opts...) |
| 503 |
if err != nil { |
| 504 |
return nil, err |
| 505 |
} |
| 506 |
return out, nil |
| 507 |
} |
| 508 |
|
| 509 |
func (c *apiHubClient) UpdateApiOperation(ctx context.Context, in *UpdateApiOperationRequest, opts ...grpc.CallOption) (*ApiOperation, error) { |
| 510 |
out := new(ApiOperation) |
| 511 |
err := c.cc.Invoke(ctx, ApiHub_UpdateApiOperation_FullMethodName, in, out, opts...) |
| 512 |
if err != nil { |
| 513 |
return nil, err |
| 514 |
} |
| 515 |
return out, nil |
| 516 |
} |
| 517 |
|
| 518 |
func (c *apiHubClient) DeleteApiOperation(ctx context.Context, in *DeleteApiOperationRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { |
| 519 |
out := new(emptypb.Empty) |
| 520 |
err := c.cc.Invoke(ctx, ApiHub_DeleteApiOperation_FullMethodName, in, out, opts...) |
| 521 |
if err != nil { |
| 522 |
return nil, err |
| 523 |
} |
| 524 |
return out, nil |
| 525 |
} |
| 526 |
|
| 527 |
func (c *apiHubClient) GetDefinition(ctx context.Context, in *GetDefinitionRequest, opts ...grpc.CallOption) (*Definition, error) { |
| 528 |
out := new(Definition) |
| 529 |
err := c.cc.Invoke(ctx, ApiHub_GetDefinition_FullMethodName, in, out, opts...) |
| 530 |
if err != nil { |
| 531 |
return nil, err |
| 532 |
} |
| 533 |
return out, nil |
| 534 |
} |
| 535 |
|
| 536 |
func (c *apiHubClient) CreateDeployment(ctx context.Context, in *CreateDeploymentRequest, opts ...grpc.CallOption) (*Deployment, error) { |
| 537 |
out := new(Deployment) |
| 538 |
err := c.cc.Invoke(ctx, ApiHub_CreateDeployment_FullMethodName, in, out, opts...) |
| 539 |
if err != nil { |
| 540 |
return nil, err |
| 541 |
} |
| 542 |
return out, nil |
| 543 |
} |
| 544 |
|
| 545 |
func (c *apiHubClient) GetDeployment(ctx context.Context, in *GetDeploymentRequest, opts ...grpc.CallOption) (*Deployment, error) { |
| 546 |
out := new(Deployment) |
| 547 |
err := c.cc.Invoke(ctx, ApiHub_GetDeployment_FullMethodName, in, out, opts...) |
| 548 |
if err != nil { |
| 549 |
return nil, err |
| 550 |
} |
| 551 |
return out, nil |
| 552 |
} |
| 553 |
|
| 554 |
func (c *apiHubClient) ListDeployments(ctx context.Context, in *ListDeploymentsRequest, opts ...grpc.CallOption) (*ListDeploymentsResponse, error) { |
| 555 |
out := new(ListDeploymentsResponse) |
| 556 |
err := c.cc.Invoke(ctx, ApiHub_ListDeployments_FullMethodName, in, out, opts...) |
| 557 |
if err != nil { |
| 558 |
return nil, err |
| 559 |
} |
| 560 |
return out, nil |
| 561 |
} |
| 562 |
|
| 563 |
func (c *apiHubClient) UpdateDeployment(ctx context.Context, in *UpdateDeploymentRequest, opts ...grpc.CallOption) (*Deployment, error) { |
| 564 |
out := new(Deployment) |
| 565 |
err := c.cc.Invoke(ctx, ApiHub_UpdateDeployment_FullMethodName, in, out, opts...) |
| 566 |
if err != nil { |
| 567 |
return nil, err |
| 568 |
} |
| 569 |
return out, nil |
| 570 |
} |
| 571 |
|
| 572 |
func (c *apiHubClient) DeleteDeployment(ctx context.Context, in *DeleteDeploymentRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { |
| 573 |
out := new(emptypb.Empty) |
| 574 |
err := c.cc.Invoke(ctx, ApiHub_DeleteDeployment_FullMethodName, in, out, opts...) |
| 575 |
if err != nil { |
| 576 |
return nil, err |
| 577 |
} |
| 578 |
return out, nil |
| 579 |
} |
| 580 |
|
| 581 |
func (c *apiHubClient) CreateAttribute(ctx context.Context, in *CreateAttributeRequest, opts ...grpc.CallOption) (*Attribute, error) { |
| 582 |
out := new(Attribute) |
| 583 |
err := c.cc.Invoke(ctx, ApiHub_CreateAttribute_FullMethodName, in, out, opts...) |
| 584 |
if err != nil { |
| 585 |
return nil, err |
| 586 |
} |
| 587 |
return out, nil |
| 588 |
} |
| 589 |
|
| 590 |
func (c *apiHubClient) GetAttribute(ctx context.Context, in *GetAttributeRequest, opts ...grpc.CallOption) (*Attribute, error) { |
| 591 |
out := new(Attribute) |
| 592 |
err := c.cc.Invoke(ctx, ApiHub_GetAttribute_FullMethodName, in, out, opts...) |
| 593 |
if err != nil { |
| 594 |
return nil, err |
| 595 |
} |
| 596 |
return out, nil |
| 597 |
} |
| 598 |
|
| 599 |
func (c *apiHubClient) UpdateAttribute(ctx context.Context, in *UpdateAttributeRequest, opts ...grpc.CallOption) (*Attribute, error) { |
| 600 |
out := new(Attribute) |
| 601 |
err := c.cc.Invoke(ctx, ApiHub_UpdateAttribute_FullMethodName, in, out, opts...) |
| 602 |
if err != nil { |
| 603 |
return nil, err |
| 604 |
} |
| 605 |
return out, nil |
| 606 |
} |
| 607 |
|
| 608 |
func (c *apiHubClient) DeleteAttribute(ctx context.Context, in *DeleteAttributeRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { |
| 609 |
out := new(emptypb.Empty) |
| 610 |
err := c.cc.Invoke(ctx, ApiHub_DeleteAttribute_FullMethodName, in, out, opts...) |
| 611 |
if err != nil { |
| 612 |
return nil, err |
| 613 |
} |
| 614 |
return out, nil |
| 615 |
} |
| 616 |
|
| 617 |
func (c *apiHubClient) ListAttributes(ctx context.Context, in *ListAttributesRequest, opts ...grpc.CallOption) (*ListAttributesResponse, error) { |
| 618 |
out := new(ListAttributesResponse) |
| 619 |
err := c.cc.Invoke(ctx, ApiHub_ListAttributes_FullMethodName, in, out, opts...) |
| 620 |
if err != nil { |
| 621 |
return nil, err |
| 622 |
} |
| 623 |
return out, nil |
| 624 |
} |
| 625 |
|
| 626 |
func (c *apiHubClient) SearchResources(ctx context.Context, in *SearchResourcesRequest, opts ...grpc.CallOption) (*SearchResourcesResponse, error) { |
| 627 |
out := new(SearchResourcesResponse) |
| 628 |
err := c.cc.Invoke(ctx, ApiHub_SearchResources_FullMethodName, in, out, opts...) |
| 629 |
if err != nil { |
| 630 |
return nil, err |
| 631 |
} |
| 632 |
return out, nil |
| 633 |
} |
| 634 |
|
| 635 |
func (c *apiHubClient) CreateExternalApi(ctx context.Context, in *CreateExternalApiRequest, opts ...grpc.CallOption) (*ExternalApi, error) { |
| 636 |
out := new(ExternalApi) |
| 637 |
err := c.cc.Invoke(ctx, ApiHub_CreateExternalApi_FullMethodName, in, out, opts...) |
| 638 |
if err != nil { |
| 639 |
return nil, err |
| 640 |
} |
| 641 |
return out, nil |
| 642 |
} |
| 643 |
|
| 644 |
func (c *apiHubClient) GetExternalApi(ctx context.Context, in *GetExternalApiRequest, opts ...grpc.CallOption) (*ExternalApi, error) { |
| 645 |
out := new(ExternalApi) |
| 646 |
err := c.cc.Invoke(ctx, ApiHub_GetExternalApi_FullMethodName, in, out, opts...) |
| 647 |
if err != nil { |
| 648 |
return nil, err |
| 649 |
} |
| 650 |
return out, nil |
| 651 |
} |
| 652 |
|
| 653 |
func (c *apiHubClient) UpdateExternalApi(ctx context.Context, in *UpdateExternalApiRequest, opts ...grpc.CallOption) (*ExternalApi, error) { |
| 654 |
out := new(ExternalApi) |
| 655 |
err := c.cc.Invoke(ctx, ApiHub_UpdateExternalApi_FullMethodName, in, out, opts...) |
| 656 |
if err != nil { |
| 657 |
return nil, err |
| 658 |
} |
| 659 |
return out, nil |
| 660 |
} |
| 661 |
|
| 662 |
func (c *apiHubClient) DeleteExternalApi(ctx context.Context, in *DeleteExternalApiRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { |
| 663 |
out := new(emptypb.Empty) |
| 664 |
err := c.cc.Invoke(ctx, ApiHub_DeleteExternalApi_FullMethodName, in, out, opts...) |
| 665 |
if err != nil { |
| 666 |
return nil, err |
| 667 |
} |
| 668 |
return out, nil |
| 669 |
} |
| 670 |
|
| 671 |
func (c *apiHubClient) ListExternalApis(ctx context.Context, in *ListExternalApisRequest, opts ...grpc.CallOption) (*ListExternalApisResponse, error) { |
| 672 |
out := new(ListExternalApisResponse) |
| 673 |
err := c.cc.Invoke(ctx, ApiHub_ListExternalApis_FullMethodName, in, out, opts...) |
| 674 |
if err != nil { |
| 675 |
return nil, err |
| 676 |
} |
| 677 |
return out, nil |
| 678 |
} |
| 679 |
|
| 680 |
// ApiHubServer is the server API for ApiHub service. |
| 681 |
// All implementations should embed UnimplementedApiHubServer |
| 682 |
// for forward compatibility |
| 683 |
type ApiHubServer interface { |
| 684 |
// Create an API resource in the API hub. |
| 685 |
// Once an API resource is created, versions can be added to it. |
| 686 |
CreateApi(context.Context, *CreateApiRequest) (*Api, error) |
| 687 |
// Get API resource details including the API versions contained in it. |
| 688 |
GetApi(context.Context, *GetApiRequest) (*Api, error) |
| 689 |
// List API resources in the API hub. |
| 690 |
ListApis(context.Context, *ListApisRequest) (*ListApisResponse, error) |
| 691 |
// Update an API resource in the API hub. The following fields in the |
| 692 |
// [API][google.cloud.apihub.v1.Api] can be updated: |
| 693 |
// |
| 694 |
// * [display_name][google.cloud.apihub.v1.Api.display_name] |
| 695 |
// * [description][google.cloud.apihub.v1.Api.description] |
| 696 |
// * [owner][google.cloud.apihub.v1.Api.owner] |
| 697 |
// * [documentation][google.cloud.apihub.v1.Api.documentation] |
| 698 |
// * [target_user][google.cloud.apihub.v1.Api.target_user] |
| 699 |
// * [team][google.cloud.apihub.v1.Api.team] |
| 700 |
// * [business_unit][google.cloud.apihub.v1.Api.business_unit] |
| 701 |
// * [maturity_level][google.cloud.apihub.v1.Api.maturity_level] |
| 702 |
// * [api_style][google.cloud.apihub.v1.Api.api_style] |
| 703 |
// * [attributes][google.cloud.apihub.v1.Api.attributes] |
| 704 |
// |
| 705 |
// The |
| 706 |
// [update_mask][google.cloud.apihub.v1.UpdateApiRequest.update_mask] |
| 707 |
// should be used to specify the fields being updated. |
| 708 |
// |
| 709 |
// Updating the owner field requires complete owner message |
| 710 |
// and updates both owner and email fields. |
| 711 |
UpdateApi(context.Context, *UpdateApiRequest) (*Api, error) |
| 712 |
// Delete an API resource in the API hub. API can only be deleted if all |
| 713 |
// underlying versions are deleted. |
| 714 |
DeleteApi(context.Context, *DeleteApiRequest) (*emptypb.Empty, error) |
| 715 |
// Create an API version for an API resource in the API hub. |
| 716 |
CreateVersion(context.Context, *CreateVersionRequest) (*Version, error) |
| 717 |
// Get details about the API version of an API resource. This will include |
| 718 |
// information about the specs and operations present in the API |
| 719 |
// version as well as the deployments linked to it. |
| 720 |
GetVersion(context.Context, *GetVersionRequest) (*Version, error) |
| 721 |
// List API versions of an API resource in the API hub. |
| 722 |
ListVersions(context.Context, *ListVersionsRequest) (*ListVersionsResponse, error) |
| 723 |
// Update API version. The following fields in the |
| 724 |
// [version][google.cloud.apihub.v1.Version] can be updated currently: |
| 725 |
// |
| 726 |
// * [display_name][google.cloud.apihub.v1.Version.display_name] |
| 727 |
// * [description][google.cloud.apihub.v1.Version.description] |
| 728 |
// * [documentation][google.cloud.apihub.v1.Version.documentation] |
| 729 |
// * [deployments][google.cloud.apihub.v1.Version.deployments] |
| 730 |
// * [lifecycle][google.cloud.apihub.v1.Version.lifecycle] |
| 731 |
// * [compliance][google.cloud.apihub.v1.Version.compliance] |
| 732 |
// * [accreditation][google.cloud.apihub.v1.Version.accreditation] |
| 733 |
// * [attributes][google.cloud.apihub.v1.Version.attributes] |
| 734 |
// |
| 735 |
// The |
| 736 |
// [update_mask][google.cloud.apihub.v1.UpdateVersionRequest.update_mask] |
| 737 |
// should be used to specify the fields being updated. |
| 738 |
UpdateVersion(context.Context, *UpdateVersionRequest) (*Version, error) |
| 739 |
// Delete an API version. Version can only be deleted if all underlying specs, |
| 740 |
// operations, definitions and linked deployments are deleted. |
| 741 |
DeleteVersion(context.Context, *DeleteVersionRequest) (*emptypb.Empty, error) |
| 742 |
// Add a spec to an API version in the API hub. |
| 743 |
// Multiple specs can be added to an API version. |
| 744 |
// Note, while adding a spec, at least one of `contents` or `source_uri` must |
| 745 |
// be provided. If `contents` is provided, then `spec_type` must also be |
| 746 |
// provided. |
| 747 |
// |
| 748 |
// On adding a spec with contents to the version, the operations present in it |
| 749 |
// will be added to the version.Note that the file contents in the spec should |
| 750 |
// be of the same type as defined in the |
| 751 |
// `projects/{project}/locations/{location}/attributes/system-spec-type` |
| 752 |
// attribute associated with spec resource. Note that specs of various types |
| 753 |
// can be uploaded, however parsing of details is supported for OpenAPI spec |
| 754 |
// currently. |
| 755 |
// |
| 756 |
// In order to access the information parsed from the spec, use the |
| 757 |
// [GetSpec][google.cloud.apihub.v1.ApiHub.GetSpec] method. |
| 758 |
// In order to access the raw contents for a particular spec, use the |
| 759 |
// [GetSpecContents][google.cloud.apihub.v1.ApiHub.GetSpecContents] method. |
| 760 |
// In order to access the operations parsed from the spec, use the |
| 761 |
// [ListAPIOperations][google.cloud.apihub.v1.ApiHub.ListApiOperations] |
| 762 |
// method. |
| 763 |
CreateSpec(context.Context, *CreateSpecRequest) (*Spec, error) |
| 764 |
// Get details about the information parsed from a spec. |
| 765 |
// Note that this method does not return the raw spec contents. |
| 766 |
// Use [GetSpecContents][google.cloud.apihub.v1.ApiHub.GetSpecContents] method |
| 767 |
// to retrieve the same. |
| 768 |
GetSpec(context.Context, *GetSpecRequest) (*Spec, error) |
| 769 |
// Get spec contents. |
| 770 |
GetSpecContents(context.Context, *GetSpecContentsRequest) (*SpecContents, error) |
| 771 |
// List specs corresponding to a particular API resource. |
| 772 |
ListSpecs(context.Context, *ListSpecsRequest) (*ListSpecsResponse, error) |
| 773 |
// Update spec. The following fields in the |
| 774 |
// [spec][google.cloud.apihub.v1.Spec] can be updated: |
| 775 |
// |
| 776 |
// * [display_name][google.cloud.apihub.v1.Spec.display_name] |
| 777 |
// * [source_uri][google.cloud.apihub.v1.Spec.source_uri] |
| 778 |
// * [lint_response][google.cloud.apihub.v1.Spec.lint_response] |
| 779 |
// * [attributes][google.cloud.apihub.v1.Spec.attributes] |
| 780 |
// * [contents][google.cloud.apihub.v1.Spec.contents] |
| 781 |
// * [spec_type][google.cloud.apihub.v1.Spec.spec_type] |
| 782 |
// |
| 783 |
// In case of an OAS spec, updating spec contents can lead to: |
| 784 |
// 1. Creation, deletion and update of operations. |
| 785 |
// 2. Creation, deletion and update of definitions. |
| 786 |
// 3. Update of other info parsed out from the new spec. |
| 787 |
// |
| 788 |
// In case of contents or source_uri being present in update mask, spec_type |
| 789 |
// must also be present. Also, spec_type can not be present in update mask if |
| 790 |
// contents or source_uri is not present. |
| 791 |
// |
| 792 |
// The |
| 793 |
// [update_mask][google.cloud.apihub.v1.UpdateSpecRequest.update_mask] |
| 794 |
// should be used to specify the fields being updated. |
| 795 |
UpdateSpec(context.Context, *UpdateSpecRequest) (*Spec, error) |
| 796 |
// Delete a spec. |
| 797 |
// Deleting a spec will also delete the associated operations from the |
| 798 |
// version. |
| 799 |
DeleteSpec(context.Context, *DeleteSpecRequest) (*emptypb.Empty, error) |
| 800 |
// Create an apiOperation in an API version. |
| 801 |
// An apiOperation can be created only if the version has no apiOperations |
| 802 |
// which were created by parsing a spec. |
| 803 |
CreateApiOperation(context.Context, *CreateApiOperationRequest) (*ApiOperation, error) |
| 804 |
// Get details about a particular operation in API version. |
| 805 |
GetApiOperation(context.Context, *GetApiOperationRequest) (*ApiOperation, error) |
| 806 |
// List operations in an API version. |
| 807 |
ListApiOperations(context.Context, *ListApiOperationsRequest) (*ListApiOperationsResponse, error) |
| 808 |
// Update an operation in an API version. The following fields in the |
| 809 |
// [ApiOperation resource][google.cloud.apihub.v1.ApiOperation] can be |
| 810 |
// updated: |
| 811 |
// |
| 812 |
// * [details.description][ApiOperation.details.description] |
| 813 |
// * [details.documentation][ApiOperation.details.documentation] |
| 814 |
// * [details.http_operation.path][ApiOperation.details.http_operation.path.path] |
| 815 |
// * [details.http_operation.method][ApiOperation.details.http_operation.method] |
| 816 |
// * [details.deprecated][ApiOperation.details.deprecated] |
| 817 |
// * [attributes][google.cloud.apihub.v1.ApiOperation.attributes] |
| 818 |
// |
| 819 |
// The |
| 820 |
// [update_mask][google.cloud.apihub.v1.UpdateApiOperationRequest.update_mask] |
| 821 |
// should be used to specify the fields being updated. |
| 822 |
// |
| 823 |
// An operation can be updated only if the operation was created via |
| 824 |
// [CreateApiOperation][google.cloud.apihub.v1.ApiHub.CreateApiOperation] API. |
| 825 |
// If the operation was created by parsing the spec, then it can be edited by |
| 826 |
// updating the spec. |
| 827 |
UpdateApiOperation(context.Context, *UpdateApiOperationRequest) (*ApiOperation, error) |
| 828 |
// Delete an operation in an API version and we can delete only the |
| 829 |
// operations created via create API. If the operation was created by parsing |
| 830 |
// the spec, then it can be deleted by editing or deleting the spec. |
| 831 |
DeleteApiOperation(context.Context, *DeleteApiOperationRequest) (*emptypb.Empty, error) |
| 832 |
// Get details about a definition in an API version. |
| 833 |
GetDefinition(context.Context, *GetDefinitionRequest) (*Definition, error) |
| 834 |
// Create a deployment resource in the API hub. |
| 835 |
// Once a deployment resource is created, it can be associated with API |
| 836 |
// versions. |
| 837 |
CreateDeployment(context.Context, *CreateDeploymentRequest) (*Deployment, error) |
| 838 |
// Get details about a deployment and the API versions linked to it. |
| 839 |
GetDeployment(context.Context, *GetDeploymentRequest) (*Deployment, error) |
| 840 |
// List deployment resources in the API hub. |
| 841 |
ListDeployments(context.Context, *ListDeploymentsRequest) (*ListDeploymentsResponse, error) |
| 842 |
// Update a deployment resource in the API hub. The following fields in the |
| 843 |
// [deployment resource][google.cloud.apihub.v1.Deployment] can be |
| 844 |
// updated: |
| 845 |
// |
| 846 |
// * [display_name][google.cloud.apihub.v1.Deployment.display_name] |
| 847 |
// * [description][google.cloud.apihub.v1.Deployment.description] |
| 848 |
// * [documentation][google.cloud.apihub.v1.Deployment.documentation] |
| 849 |
// * [deployment_type][google.cloud.apihub.v1.Deployment.deployment_type] |
| 850 |
// * [resource_uri][google.cloud.apihub.v1.Deployment.resource_uri] |
| 851 |
// * [endpoints][google.cloud.apihub.v1.Deployment.endpoints] |
| 852 |
// * [slo][google.cloud.apihub.v1.Deployment.slo] |
| 853 |
// * [environment][google.cloud.apihub.v1.Deployment.environment] |
| 854 |
// * [attributes][google.cloud.apihub.v1.Deployment.attributes] |
| 855 |
// * [source_project] [google.cloud.apihub.v1.Deployment.source_project] |
| 856 |
// * [source_environment] |
| 857 |
// [google.cloud.apihub.v1.Deployment.source_environment] |
| 858 |
// * [management_url][google.cloud.apihub.v1.Deployment.management_url] |
| 859 |
// * [source_uri][google.cloud.apihub.v1.Deployment.source_uri] |
| 860 |
// The |
| 861 |
// [update_mask][google.cloud.apihub.v1.UpdateDeploymentRequest.update_mask] |
| 862 |
// should be used to specify the fields being updated. |
| 863 |
UpdateDeployment(context.Context, *UpdateDeploymentRequest) (*Deployment, error) |
| 864 |
// Delete a deployment resource in the API hub. |
| 865 |
DeleteDeployment(context.Context, *DeleteDeploymentRequest) (*emptypb.Empty, error) |
| 866 |
// Create a user defined attribute. |
| 867 |
// |
| 868 |
// Certain pre defined attributes are already created by the API hub. These |
| 869 |
// attributes will have type as `SYSTEM_DEFINED` and can be listed via |
| 870 |
// [ListAttributes][google.cloud.apihub.v1.ApiHub.ListAttributes] method. |
| 871 |
// Allowed values for the same can be updated via |
| 872 |
// [UpdateAttribute][google.cloud.apihub.v1.ApiHub.UpdateAttribute] method. |
| 873 |
CreateAttribute(context.Context, *CreateAttributeRequest) (*Attribute, error) |
| 874 |
// Get details about the attribute. |
| 875 |
GetAttribute(context.Context, *GetAttributeRequest) (*Attribute, error) |
| 876 |
// Update the attribute. The following fields in the |
| 877 |
// [Attribute resource][google.cloud.apihub.v1.Attribute] can be updated: |
| 878 |
// |
| 879 |
// * [display_name][google.cloud.apihub.v1.Attribute.display_name] |
| 880 |
// The display name can be updated for user defined attributes only. |
| 881 |
// * [description][google.cloud.apihub.v1.Attribute.description] |
| 882 |
// The description can be updated for user defined attributes only. |
| 883 |
// * [allowed_values][google.cloud.apihub.v1.Attribute.allowed_values] |
| 884 |
// To update the list of allowed values, clients need to use the fetched list |
| 885 |
// of allowed values and add or remove values to or from the same list. |
| 886 |
// The mutable allowed values can be updated for both user defined and System |
| 887 |
// defined attributes. The immutable allowed values cannot be updated or |
| 888 |
// deleted. The updated list of allowed values cannot be empty. If an allowed |
| 889 |
// value that is already used by some resource's attribute is deleted, then |
| 890 |
// the association between the resource and the attribute value will also be |
| 891 |
// deleted. |
| 892 |
// * [cardinality][google.cloud.apihub.v1.Attribute.cardinality] |
| 893 |
// The cardinality can be updated for user defined attributes only. |
| 894 |
// Cardinality can only be increased during an update. |
| 895 |
// |
| 896 |
// The |
| 897 |
// [update_mask][google.cloud.apihub.v1.UpdateAttributeRequest.update_mask] |
| 898 |
// should be used to specify the fields being updated. |
| 899 |
UpdateAttribute(context.Context, *UpdateAttributeRequest) (*Attribute, error) |
| 900 |
// Delete an attribute. |
| 901 |
// |
| 902 |
// Note: System defined attributes cannot be deleted. All |
| 903 |
// associations of the attribute being deleted with any API hub resource will |
| 904 |
// also get deleted. |
| 905 |
DeleteAttribute(context.Context, *DeleteAttributeRequest) (*emptypb.Empty, error) |
| 906 |
// List all attributes. |
| 907 |
ListAttributes(context.Context, *ListAttributesRequest) (*ListAttributesResponse, error) |
| 908 |
// Search across API-Hub resources. |
| 909 |
SearchResources(context.Context, *SearchResourcesRequest) (*SearchResourcesResponse, error) |
| 910 |
// Create an External API resource in the API hub. |
| 911 |
CreateExternalApi(context.Context, *CreateExternalApiRequest) (*ExternalApi, error) |
| 912 |
// Get details about an External API resource in the API hub. |
| 913 |
GetExternalApi(context.Context, *GetExternalApiRequest) (*ExternalApi, error) |
| 914 |
// Update an External API resource in the API hub. The following fields can be |
| 915 |
// updated: |
| 916 |
// |
| 917 |
// * [display_name][google.cloud.apihub.v1.ExternalApi.display_name] |
| 918 |
// * [description][google.cloud.apihub.v1.ExternalApi.description] |
| 919 |
// * [documentation][google.cloud.apihub.v1.ExternalApi.documentation] |
| 920 |
// * [endpoints][google.cloud.apihub.v1.ExternalApi.endpoints] |
| 921 |
// * [paths][google.cloud.apihub.v1.ExternalApi.paths] |
| 922 |
// |
| 923 |
// The |
| 924 |
// [update_mask][google.cloud.apihub.v1.UpdateExternalApiRequest.update_mask] |
| 925 |
// should be used to specify the fields being updated. |
| 926 |
UpdateExternalApi(context.Context, *UpdateExternalApiRequest) (*ExternalApi, error) |
| 927 |
// Delete an External API resource in the API hub. |
| 928 |
DeleteExternalApi(context.Context, *DeleteExternalApiRequest) (*emptypb.Empty, error) |
| 929 |
// List External API resources in the API hub. |
| 930 |
ListExternalApis(context.Context, *ListExternalApisRequest) (*ListExternalApisResponse, error) |
| 931 |
} |
| 932 |
|
| 933 |
// UnimplementedApiHubServer should be embedded to have forward compatible implementations. |
| 934 |
type UnimplementedApiHubServer struct { |
| 935 |
} |
| 936 |
|
| 937 |
func (UnimplementedApiHubServer) CreateApi(context.Context, *CreateApiRequest) (*Api, error) { |
| 938 |
return nil, status.Errorf(codes.Unimplemented, "method CreateApi not implemented") |
| 939 |
} |
| 940 |
func (UnimplementedApiHubServer) GetApi(context.Context, *GetApiRequest) (*Api, error) { |
| 941 |
return nil, status.Errorf(codes.Unimplemented, "method GetApi not implemented") |
| 942 |
} |
| 943 |
func (UnimplementedApiHubServer) ListApis(context.Context, *ListApisRequest) (*ListApisResponse, error) { |
| 944 |
return nil, status.Errorf(codes.Unimplemented, "method ListApis not implemented") |
| 945 |
} |
| 946 |
func (UnimplementedApiHubServer) UpdateApi(context.Context, *UpdateApiRequest) (*Api, error) { |
| 947 |
return nil, status.Errorf(codes.Unimplemented, "method UpdateApi not implemented") |
| 948 |
} |
| 949 |
func (UnimplementedApiHubServer) DeleteApi(context.Context, *DeleteApiRequest) (*emptypb.Empty, error) { |
| 950 |
return nil, status.Errorf(codes.Unimplemented, "method DeleteApi not implemented") |
| 951 |
} |
| 952 |
func (UnimplementedApiHubServer) CreateVersion(context.Context, *CreateVersionRequest) (*Version, error) { |
| 953 |
return nil, status.Errorf(codes.Unimplemented, "method CreateVersion not implemented") |
| 954 |
} |
| 955 |
func (UnimplementedApiHubServer) GetVersion(context.Context, *GetVersionRequest) (*Version, error) { |
| 956 |
return nil, status.Errorf(codes.Unimplemented, "method GetVersion not implemented") |
| 957 |
} |
| 958 |
func (UnimplementedApiHubServer) ListVersions(context.Context, *ListVersionsRequest) (*ListVersionsResponse, error) { |
| 959 |
return nil, status.Errorf(codes.Unimplemented, "method ListVersions not implemented") |
| 960 |
} |
| 961 |
func (UnimplementedApiHubServer) UpdateVersion(context.Context, *UpdateVersionRequest) (*Version, error) { |
| 962 |
return nil, status.Errorf(codes.Unimplemented, "method UpdateVersion not implemented") |
| 963 |
} |
| 964 |
func (UnimplementedApiHubServer) DeleteVersion(context.Context, *DeleteVersionRequest) (*emptypb.Empty, error) { |
| 965 |
return nil, status.Errorf(codes.Unimplemented, "method DeleteVersion not implemented") |
| 966 |
} |
| 967 |
func (UnimplementedApiHubServer) CreateSpec(context.Context, *CreateSpecRequest) (*Spec, error) { |
| 968 |
return nil, status.Errorf(codes.Unimplemented, "method CreateSpec not implemented") |
| 969 |
} |
| 970 |
func (UnimplementedApiHubServer) GetSpec(context.Context, *GetSpecRequest) (*Spec, error) { |
| 971 |
return nil, status.Errorf(codes.Unimplemented, "method GetSpec not implemented") |
| 972 |
} |
| 973 |
func (UnimplementedApiHubServer) GetSpecContents(context.Context, *GetSpecContentsRequest) (*SpecContents, error) { |
| 974 |
return nil, status.Errorf(codes.Unimplemented, "method GetSpecContents not implemented") |
| 975 |
} |
| 976 |
func (UnimplementedApiHubServer) ListSpecs(context.Context, *ListSpecsRequest) (*ListSpecsResponse, error) { |
| 977 |
return nil, status.Errorf(codes.Unimplemented, "method ListSpecs not implemented") |
| 978 |
} |
| 979 |
func (UnimplementedApiHubServer) UpdateSpec(context.Context, *UpdateSpecRequest) (*Spec, error) { |
| 980 |
return nil, status.Errorf(codes.Unimplemented, "method UpdateSpec not implemented") |
| 981 |
} |
| 982 |
func (UnimplementedApiHubServer) DeleteSpec(context.Context, *DeleteSpecRequest) (*emptypb.Empty, error) { |
| 983 |
return nil, status.Errorf(codes.Unimplemented, "method DeleteSpec not implemented") |
| 984 |
} |
| 985 |
func (UnimplementedApiHubServer) CreateApiOperation(context.Context, *CreateApiOperationRequest) (*ApiOperation, error) { |
| 986 |
return nil, status.Errorf(codes.Unimplemented, "method CreateApiOperation not implemented") |
| 987 |
} |
| 988 |
func (UnimplementedApiHubServer) GetApiOperation(context.Context, *GetApiOperationRequest) (*ApiOperation, error) { |
| 989 |
return nil, status.Errorf(codes.Unimplemented, "method GetApiOperation not implemented") |
| 990 |
} |
| 991 |
func (UnimplementedApiHubServer) ListApiOperations(context.Context, *ListApiOperationsRequest) (*ListApiOperationsResponse, error) { |
| 992 |
return nil, status.Errorf(codes.Unimplemented, "method ListApiOperations not implemented") |
| 993 |
} |
| 994 |
func (UnimplementedApiHubServer) UpdateApiOperation(context.Context, *UpdateApiOperationRequest) (*ApiOperation, error) { |
| 995 |
return nil, status.Errorf(codes.Unimplemented, "method UpdateApiOperation not implemented") |
| 996 |
} |
| 997 |
func (UnimplementedApiHubServer) DeleteApiOperation(context.Context, *DeleteApiOperationRequest) (*emptypb.Empty, error) { |
| 998 |
return nil, status.Errorf(codes.Unimplemented, "method DeleteApiOperation not implemented") |
| 999 |
} |
| 1000 |
func (UnimplementedApiHubServer) GetDefinition(context.Context, *GetDefinitionRequest) (*Definition, error) { |
| 1001 |
return nil, status.Errorf(codes.Unimplemented, "method GetDefinition not implemented") |
| 1002 |
} |
| 1003 |
func (UnimplementedApiHubServer) CreateDeployment(context.Context, *CreateDeploymentRequest) (*Deployment, error) { |
| 1004 |
return nil, status.Errorf(codes.Unimplemented, "method CreateDeployment not implemented") |
| 1005 |
} |
| 1006 |
func (UnimplementedApiHubServer) GetDeployment(context.Context, *GetDeploymentRequest) (*Deployment, error) { |
| 1007 |
return nil, status.Errorf(codes.Unimplemented, "method GetDeployment not implemented") |
| 1008 |
} |
| 1009 |
func (UnimplementedApiHubServer) ListDeployments(context.Context, *ListDeploymentsRequest) (*ListDeploymentsResponse, error) { |
| 1010 |
return nil, status.Errorf(codes.Unimplemented, "method ListDeployments not implemented") |
| 1011 |
} |
| 1012 |
func (UnimplementedApiHubServer) UpdateDeployment(context.Context, *UpdateDeploymentRequest) (*Deployment, error) { |
| 1013 |
return nil, status.Errorf(codes.Unimplemented, "method UpdateDeployment not implemented") |
| 1014 |
} |
| 1015 |
func (UnimplementedApiHubServer) DeleteDeployment(context.Context, *DeleteDeploymentRequest) (*emptypb.Empty, error) { |
| 1016 |
return nil, status.Errorf(codes.Unimplemented, "method DeleteDeployment not implemented") |
| 1017 |
} |
| 1018 |
func (UnimplementedApiHubServer) CreateAttribute(context.Context, *CreateAttributeRequest) (*Attribute, error) { |
| 1019 |
return nil, status.Errorf(codes.Unimplemented, "method CreateAttribute not implemented") |
| 1020 |
} |
| 1021 |
func (UnimplementedApiHubServer) GetAttribute(context.Context, *GetAttributeRequest) (*Attribute, error) { |
| 1022 |
return nil, status.Errorf(codes.Unimplemented, "method GetAttribute not implemented") |
| 1023 |
} |
| 1024 |
func (UnimplementedApiHubServer) UpdateAttribute(context.Context, *UpdateAttributeRequest) (*Attribute, error) { |
| 1025 |
return nil, status.Errorf(codes.Unimplemented, "method UpdateAttribute not implemented") |
| 1026 |
} |
| 1027 |
func (UnimplementedApiHubServer) DeleteAttribute(context.Context, *DeleteAttributeRequest) (*emptypb.Empty, error) { |
| 1028 |
return nil, status.Errorf(codes.Unimplemented, "method DeleteAttribute not implemented") |
| 1029 |
} |
| 1030 |
func (UnimplementedApiHubServer) ListAttributes(context.Context, *ListAttributesRequest) (*ListAttributesResponse, error) { |
| 1031 |
return nil, status.Errorf(codes.Unimplemented, "method ListAttributes not implemented") |
| 1032 |
} |
| 1033 |
func (UnimplementedApiHubServer) SearchResources(context.Context, *SearchResourcesRequest) (*SearchResourcesResponse, error) { |
| 1034 |
return nil, status.Errorf(codes.Unimplemented, "method SearchResources not implemented") |
| 1035 |
} |
| 1036 |
func (UnimplementedApiHubServer) CreateExternalApi(context.Context, *CreateExternalApiRequest) (*ExternalApi, error) { |
| 1037 |
return nil, status.Errorf(codes.Unimplemented, "method CreateExternalApi not implemented") |
| 1038 |
} |
| 1039 |
func (UnimplementedApiHubServer) GetExternalApi(context.Context, *GetExternalApiRequest) (*ExternalApi, error) { |
| 1040 |
return nil, status.Errorf(codes.Unimplemented, "method GetExternalApi not implemented") |
| 1041 |
} |
| 1042 |
func (UnimplementedApiHubServer) UpdateExternalApi(context.Context, *UpdateExternalApiRequest) (*ExternalApi, error) { |
| 1043 |
return nil, status.Errorf(codes.Unimplemented, "method UpdateExternalApi not implemented") |
| 1044 |
} |
| 1045 |
func (UnimplementedApiHubServer) DeleteExternalApi(context.Context, *DeleteExternalApiRequest) (*emptypb.Empty, error) { |
| 1046 |
return nil, status.Errorf(codes.Unimplemented, "method DeleteExternalApi not implemented") |
| 1047 |
} |
| 1048 |
func (UnimplementedApiHubServer) ListExternalApis(context.Context, *ListExternalApisRequest) (*ListExternalApisResponse, error) { |
| 1049 |
return nil, status.Errorf(codes.Unimplemented, "method ListExternalApis not implemented") |
| 1050 |
} |
| 1051 |
|
| 1052 |
// UnsafeApiHubServer may be embedded to opt out of forward compatibility for this service. |
| 1053 |
// Use of this interface is not recommended, as added methods to ApiHubServer will |
| 1054 |
// result in compilation errors. |
| 1055 |
type UnsafeApiHubServer interface { |
| 1056 |
mustEmbedUnimplementedApiHubServer() |
| 1057 |
} |
| 1058 |
|
| 1059 |
func RegisterApiHubServer(s grpc.ServiceRegistrar, srv ApiHubServer) { |
| 1060 |
s.RegisterService(&ApiHub_ServiceDesc, srv) |
| 1061 |
} |
| 1062 |
|
| 1063 |
func _ApiHub_CreateApi_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1064 |
in := new(CreateApiRequest) |
| 1065 |
if err := dec(in); err != nil { |
| 1066 |
return nil, err |
| 1067 |
} |
| 1068 |
if interceptor == nil { |
| 1069 |
return srv.(ApiHubServer).CreateApi(ctx, in) |
| 1070 |
} |
| 1071 |
info := &grpc.UnaryServerInfo{ |
| 1072 |
Server: srv, |
| 1073 |
FullMethod: ApiHub_CreateApi_FullMethodName, |
| 1074 |
} |
| 1075 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1076 |
return srv.(ApiHubServer).CreateApi(ctx, req.(*CreateApiRequest)) |
| 1077 |
} |
| 1078 |
return interceptor(ctx, in, info, handler) |
| 1079 |
} |
| 1080 |
|
| 1081 |
func _ApiHub_GetApi_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1082 |
in := new(GetApiRequest) |
| 1083 |
if err := dec(in); err != nil { |
| 1084 |
return nil, err |
| 1085 |
} |
| 1086 |
if interceptor == nil { |
| 1087 |
return srv.(ApiHubServer).GetApi(ctx, in) |
| 1088 |
} |
| 1089 |
info := &grpc.UnaryServerInfo{ |
| 1090 |
Server: srv, |
| 1091 |
FullMethod: ApiHub_GetApi_FullMethodName, |
| 1092 |
} |
| 1093 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1094 |
return srv.(ApiHubServer).GetApi(ctx, req.(*GetApiRequest)) |
| 1095 |
} |
| 1096 |
return interceptor(ctx, in, info, handler) |
| 1097 |
} |
| 1098 |
|
| 1099 |
func _ApiHub_ListApis_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1100 |
in := new(ListApisRequest) |
| 1101 |
if err := dec(in); err != nil { |
| 1102 |
return nil, err |
| 1103 |
} |
| 1104 |
if interceptor == nil { |
| 1105 |
return srv.(ApiHubServer).ListApis(ctx, in) |
| 1106 |
} |
| 1107 |
info := &grpc.UnaryServerInfo{ |
| 1108 |
Server: srv, |
| 1109 |
FullMethod: ApiHub_ListApis_FullMethodName, |
| 1110 |
} |
| 1111 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1112 |
return srv.(ApiHubServer).ListApis(ctx, req.(*ListApisRequest)) |
| 1113 |
} |
| 1114 |
return interceptor(ctx, in, info, handler) |
| 1115 |
} |
| 1116 |
|
| 1117 |
func _ApiHub_UpdateApi_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1118 |
in := new(UpdateApiRequest) |
| 1119 |
if err := dec(in); err != nil { |
| 1120 |
return nil, err |
| 1121 |
} |
| 1122 |
if interceptor == nil { |
| 1123 |
return srv.(ApiHubServer).UpdateApi(ctx, in) |
| 1124 |
} |
| 1125 |
info := &grpc.UnaryServerInfo{ |
| 1126 |
Server: srv, |
| 1127 |
FullMethod: ApiHub_UpdateApi_FullMethodName, |
| 1128 |
} |
| 1129 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1130 |
return srv.(ApiHubServer).UpdateApi(ctx, req.(*UpdateApiRequest)) |
| 1131 |
} |
| 1132 |
return interceptor(ctx, in, info, handler) |
| 1133 |
} |
| 1134 |
|
| 1135 |
func _ApiHub_DeleteApi_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1136 |
in := new(DeleteApiRequest) |
| 1137 |
if err := dec(in); err != nil { |
| 1138 |
return nil, err |
| 1139 |
} |
| 1140 |
if interceptor == nil { |
| 1141 |
return srv.(ApiHubServer).DeleteApi(ctx, in) |
| 1142 |
} |
| 1143 |
info := &grpc.UnaryServerInfo{ |
| 1144 |
Server: srv, |
| 1145 |
FullMethod: ApiHub_DeleteApi_FullMethodName, |
| 1146 |
} |
| 1147 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1148 |
return srv.(ApiHubServer).DeleteApi(ctx, req.(*DeleteApiRequest)) |
| 1149 |
} |
| 1150 |
return interceptor(ctx, in, info, handler) |
| 1151 |
} |
| 1152 |
|
| 1153 |
func _ApiHub_CreateVersion_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1154 |
in := new(CreateVersionRequest) |
| 1155 |
if err := dec(in); err != nil { |
| 1156 |
return nil, err |
| 1157 |
} |
| 1158 |
if interceptor == nil { |
| 1159 |
return srv.(ApiHubServer).CreateVersion(ctx, in) |
| 1160 |
} |
| 1161 |
info := &grpc.UnaryServerInfo{ |
| 1162 |
Server: srv, |
| 1163 |
FullMethod: ApiHub_CreateVersion_FullMethodName, |
| 1164 |
} |
| 1165 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1166 |
return srv.(ApiHubServer).CreateVersion(ctx, req.(*CreateVersionRequest)) |
| 1167 |
} |
| 1168 |
return interceptor(ctx, in, info, handler) |
| 1169 |
} |
| 1170 |
|
| 1171 |
func _ApiHub_GetVersion_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1172 |
in := new(GetVersionRequest) |
| 1173 |
if err := dec(in); err != nil { |
| 1174 |
return nil, err |
| 1175 |
} |
| 1176 |
if interceptor == nil { |
| 1177 |
return srv.(ApiHubServer).GetVersion(ctx, in) |
| 1178 |
} |
| 1179 |
info := &grpc.UnaryServerInfo{ |
| 1180 |
Server: srv, |
| 1181 |
FullMethod: ApiHub_GetVersion_FullMethodName, |
| 1182 |
} |
| 1183 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1184 |
return srv.(ApiHubServer).GetVersion(ctx, req.(*GetVersionRequest)) |
| 1185 |
} |
| 1186 |
return interceptor(ctx, in, info, handler) |
| 1187 |
} |
| 1188 |
|
| 1189 |
func _ApiHub_ListVersions_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1190 |
in := new(ListVersionsRequest) |
| 1191 |
if err := dec(in); err != nil { |
| 1192 |
return nil, err |
| 1193 |
} |
| 1194 |
if interceptor == nil { |
| 1195 |
return srv.(ApiHubServer).ListVersions(ctx, in) |
| 1196 |
} |
| 1197 |
info := &grpc.UnaryServerInfo{ |
| 1198 |
Server: srv, |
| 1199 |
FullMethod: ApiHub_ListVersions_FullMethodName, |
| 1200 |
} |
| 1201 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1202 |
return srv.(ApiHubServer).ListVersions(ctx, req.(*ListVersionsRequest)) |
| 1203 |
} |
| 1204 |
return interceptor(ctx, in, info, handler) |
| 1205 |
} |
| 1206 |
|
| 1207 |
func _ApiHub_UpdateVersion_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1208 |
in := new(UpdateVersionRequest) |
| 1209 |
if err := dec(in); err != nil { |
| 1210 |
return nil, err |
| 1211 |
} |
| 1212 |
if interceptor == nil { |
| 1213 |
return srv.(ApiHubServer).UpdateVersion(ctx, in) |
| 1214 |
} |
| 1215 |
info := &grpc.UnaryServerInfo{ |
| 1216 |
Server: srv, |
| 1217 |
FullMethod: ApiHub_UpdateVersion_FullMethodName, |
| 1218 |
} |
| 1219 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1220 |
return srv.(ApiHubServer).UpdateVersion(ctx, req.(*UpdateVersionRequest)) |
| 1221 |
} |
| 1222 |
return interceptor(ctx, in, info, handler) |
| 1223 |
} |
| 1224 |
|
| 1225 |
func _ApiHub_DeleteVersion_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1226 |
in := new(DeleteVersionRequest) |
| 1227 |
if err := dec(in); err != nil { |
| 1228 |
return nil, err |
| 1229 |
} |
| 1230 |
if interceptor == nil { |
| 1231 |
return srv.(ApiHubServer).DeleteVersion(ctx, in) |
| 1232 |
} |
| 1233 |
info := &grpc.UnaryServerInfo{ |
| 1234 |
Server: srv, |
| 1235 |
FullMethod: ApiHub_DeleteVersion_FullMethodName, |
| 1236 |
} |
| 1237 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1238 |
return srv.(ApiHubServer).DeleteVersion(ctx, req.(*DeleteVersionRequest)) |
| 1239 |
} |
| 1240 |
return interceptor(ctx, in, info, handler) |
| 1241 |
} |
| 1242 |
|
| 1243 |
func _ApiHub_CreateSpec_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1244 |
in := new(CreateSpecRequest) |
| 1245 |
if err := dec(in); err != nil { |
| 1246 |
return nil, err |
| 1247 |
} |
| 1248 |
if interceptor == nil { |
| 1249 |
return srv.(ApiHubServer).CreateSpec(ctx, in) |
| 1250 |
} |
| 1251 |
info := &grpc.UnaryServerInfo{ |
| 1252 |
Server: srv, |
| 1253 |
FullMethod: ApiHub_CreateSpec_FullMethodName, |
| 1254 |
} |
| 1255 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1256 |
return srv.(ApiHubServer).CreateSpec(ctx, req.(*CreateSpecRequest)) |
| 1257 |
} |
| 1258 |
return interceptor(ctx, in, info, handler) |
| 1259 |
} |
| 1260 |
|
| 1261 |
func _ApiHub_GetSpec_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1262 |
in := new(GetSpecRequest) |
| 1263 |
if err := dec(in); err != nil { |
| 1264 |
return nil, err |
| 1265 |
} |
| 1266 |
if interceptor == nil { |
| 1267 |
return srv.(ApiHubServer).GetSpec(ctx, in) |
| 1268 |
} |
| 1269 |
info := &grpc.UnaryServerInfo{ |
| 1270 |
Server: srv, |
| 1271 |
FullMethod: ApiHub_GetSpec_FullMethodName, |
| 1272 |
} |
| 1273 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1274 |
return srv.(ApiHubServer).GetSpec(ctx, req.(*GetSpecRequest)) |
| 1275 |
} |
| 1276 |
return interceptor(ctx, in, info, handler) |
| 1277 |
} |
| 1278 |
|
| 1279 |
func _ApiHub_GetSpecContents_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1280 |
in := new(GetSpecContentsRequest) |
| 1281 |
if err := dec(in); err != nil { |
| 1282 |
return nil, err |
| 1283 |
} |
| 1284 |
if interceptor == nil { |
| 1285 |
return srv.(ApiHubServer).GetSpecContents(ctx, in) |
| 1286 |
} |
| 1287 |
info := &grpc.UnaryServerInfo{ |
| 1288 |
Server: srv, |
| 1289 |
FullMethod: ApiHub_GetSpecContents_FullMethodName, |
| 1290 |
} |
| 1291 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1292 |
return srv.(ApiHubServer).GetSpecContents(ctx, req.(*GetSpecContentsRequest)) |
| 1293 |
} |
| 1294 |
return interceptor(ctx, in, info, handler) |
| 1295 |
} |
| 1296 |
|
| 1297 |
func _ApiHub_ListSpecs_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1298 |
in := new(ListSpecsRequest) |
| 1299 |
if err := dec(in); err != nil { |
| 1300 |
return nil, err |
| 1301 |
} |
| 1302 |
if interceptor == nil { |
| 1303 |
return srv.(ApiHubServer).ListSpecs(ctx, in) |
| 1304 |
} |
| 1305 |
info := &grpc.UnaryServerInfo{ |
| 1306 |
Server: srv, |
| 1307 |
FullMethod: ApiHub_ListSpecs_FullMethodName, |
| 1308 |
} |
| 1309 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1310 |
return srv.(ApiHubServer).ListSpecs(ctx, req.(*ListSpecsRequest)) |
| 1311 |
} |
| 1312 |
return interceptor(ctx, in, info, handler) |
| 1313 |
} |
| 1314 |
|
| 1315 |
func _ApiHub_UpdateSpec_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1316 |
in := new(UpdateSpecRequest) |
| 1317 |
if err := dec(in); err != nil { |
| 1318 |
return nil, err |
| 1319 |
} |
| 1320 |
if interceptor == nil { |
| 1321 |
return srv.(ApiHubServer).UpdateSpec(ctx, in) |
| 1322 |
} |
| 1323 |
info := &grpc.UnaryServerInfo{ |
| 1324 |
Server: srv, |
| 1325 |
FullMethod: ApiHub_UpdateSpec_FullMethodName, |
| 1326 |
} |
| 1327 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1328 |
return srv.(ApiHubServer).UpdateSpec(ctx, req.(*UpdateSpecRequest)) |
| 1329 |
} |
| 1330 |
return interceptor(ctx, in, info, handler) |
| 1331 |
} |
| 1332 |
|
| 1333 |
func _ApiHub_DeleteSpec_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1334 |
in := new(DeleteSpecRequest) |
| 1335 |
if err := dec(in); err != nil { |
| 1336 |
return nil, err |
| 1337 |
} |
| 1338 |
if interceptor == nil { |
| 1339 |
return srv.(ApiHubServer).DeleteSpec(ctx, in) |
| 1340 |
} |
| 1341 |
info := &grpc.UnaryServerInfo{ |
| 1342 |
Server: srv, |
| 1343 |
FullMethod: ApiHub_DeleteSpec_FullMethodName, |
| 1344 |
} |
| 1345 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1346 |
return srv.(ApiHubServer).DeleteSpec(ctx, req.(*DeleteSpecRequest)) |
| 1347 |
} |
| 1348 |
return interceptor(ctx, in, info, handler) |
| 1349 |
} |
| 1350 |
|
| 1351 |
func _ApiHub_CreateApiOperation_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1352 |
in := new(CreateApiOperationRequest) |
| 1353 |
if err := dec(in); err != nil { |
| 1354 |
return nil, err |
| 1355 |
} |
| 1356 |
if interceptor == nil { |
| 1357 |
return srv.(ApiHubServer).CreateApiOperation(ctx, in) |
| 1358 |
} |
| 1359 |
info := &grpc.UnaryServerInfo{ |
| 1360 |
Server: srv, |
| 1361 |
FullMethod: ApiHub_CreateApiOperation_FullMethodName, |
| 1362 |
} |
| 1363 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1364 |
return srv.(ApiHubServer).CreateApiOperation(ctx, req.(*CreateApiOperationRequest)) |
| 1365 |
} |
| 1366 |
return interceptor(ctx, in, info, handler) |
| 1367 |
} |
| 1368 |
|
| 1369 |
func _ApiHub_GetApiOperation_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1370 |
in := new(GetApiOperationRequest) |
| 1371 |
if err := dec(in); err != nil { |
| 1372 |
return nil, err |
| 1373 |
} |
| 1374 |
if interceptor == nil { |
| 1375 |
return srv.(ApiHubServer).GetApiOperation(ctx, in) |
| 1376 |
} |
| 1377 |
info := &grpc.UnaryServerInfo{ |
| 1378 |
Server: srv, |
| 1379 |
FullMethod: ApiHub_GetApiOperation_FullMethodName, |
| 1380 |
} |
| 1381 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1382 |
return srv.(ApiHubServer).GetApiOperation(ctx, req.(*GetApiOperationRequest)) |
| 1383 |
} |
| 1384 |
return interceptor(ctx, in, info, handler) |
| 1385 |
} |
| 1386 |
|
| 1387 |
func _ApiHub_ListApiOperations_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1388 |
in := new(ListApiOperationsRequest) |
| 1389 |
if err := dec(in); err != nil { |
| 1390 |
return nil, err |
| 1391 |
} |
| 1392 |
if interceptor == nil { |
| 1393 |
return srv.(ApiHubServer).ListApiOperations(ctx, in) |
| 1394 |
} |
| 1395 |
info := &grpc.UnaryServerInfo{ |
| 1396 |
Server: srv, |
| 1397 |
FullMethod: ApiHub_ListApiOperations_FullMethodName, |
| 1398 |
} |
| 1399 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1400 |
return srv.(ApiHubServer).ListApiOperations(ctx, req.(*ListApiOperationsRequest)) |
| 1401 |
} |
| 1402 |
return interceptor(ctx, in, info, handler) |
| 1403 |
} |
| 1404 |
|
| 1405 |
func _ApiHub_UpdateApiOperation_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1406 |
in := new(UpdateApiOperationRequest) |
| 1407 |
if err := dec(in); err != nil { |
| 1408 |
return nil, err |
| 1409 |
} |
| 1410 |
if interceptor == nil { |
| 1411 |
return srv.(ApiHubServer).UpdateApiOperation(ctx, in) |
| 1412 |
} |
| 1413 |
info := &grpc.UnaryServerInfo{ |
| 1414 |
Server: srv, |
| 1415 |
FullMethod: ApiHub_UpdateApiOperation_FullMethodName, |
| 1416 |
} |
| 1417 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1418 |
return srv.(ApiHubServer).UpdateApiOperation(ctx, req.(*UpdateApiOperationRequest)) |
| 1419 |
} |
| 1420 |
return interceptor(ctx, in, info, handler) |
| 1421 |
} |
| 1422 |
|
| 1423 |
func _ApiHub_DeleteApiOperation_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1424 |
in := new(DeleteApiOperationRequest) |
| 1425 |
if err := dec(in); err != nil { |
| 1426 |
return nil, err |
| 1427 |
} |
| 1428 |
if interceptor == nil { |
| 1429 |
return srv.(ApiHubServer).DeleteApiOperation(ctx, in) |
| 1430 |
} |
| 1431 |
info := &grpc.UnaryServerInfo{ |
| 1432 |
Server: srv, |
| 1433 |
FullMethod: ApiHub_DeleteApiOperation_FullMethodName, |
| 1434 |
} |
| 1435 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1436 |
return srv.(ApiHubServer).DeleteApiOperation(ctx, req.(*DeleteApiOperationRequest)) |
| 1437 |
} |
| 1438 |
return interceptor(ctx, in, info, handler) |
| 1439 |
} |
| 1440 |
|
| 1441 |
func _ApiHub_GetDefinition_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1442 |
in := new(GetDefinitionRequest) |
| 1443 |
if err := dec(in); err != nil { |
| 1444 |
return nil, err |
| 1445 |
} |
| 1446 |
if interceptor == nil { |
| 1447 |
return srv.(ApiHubServer).GetDefinition(ctx, in) |
| 1448 |
} |
| 1449 |
info := &grpc.UnaryServerInfo{ |
| 1450 |
Server: srv, |
| 1451 |
FullMethod: ApiHub_GetDefinition_FullMethodName, |
| 1452 |
} |
| 1453 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1454 |
return srv.(ApiHubServer).GetDefinition(ctx, req.(*GetDefinitionRequest)) |
| 1455 |
} |
| 1456 |
return interceptor(ctx, in, info, handler) |
| 1457 |
} |
| 1458 |
|
| 1459 |
func _ApiHub_CreateDeployment_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1460 |
in := new(CreateDeploymentRequest) |
| 1461 |
if err := dec(in); err != nil { |
| 1462 |
return nil, err |
| 1463 |
} |
| 1464 |
if interceptor == nil { |
| 1465 |
return srv.(ApiHubServer).CreateDeployment(ctx, in) |
| 1466 |
} |
| 1467 |
info := &grpc.UnaryServerInfo{ |
| 1468 |
Server: srv, |
| 1469 |
FullMethod: ApiHub_CreateDeployment_FullMethodName, |
| 1470 |
} |
| 1471 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1472 |
return srv.(ApiHubServer).CreateDeployment(ctx, req.(*CreateDeploymentRequest)) |
| 1473 |
} |
| 1474 |
return interceptor(ctx, in, info, handler) |
| 1475 |
} |
| 1476 |
|
| 1477 |
func _ApiHub_GetDeployment_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1478 |
in := new(GetDeploymentRequest) |
| 1479 |
if err := dec(in); err != nil { |
| 1480 |
return nil, err |
| 1481 |
} |
| 1482 |
if interceptor == nil { |
| 1483 |
return srv.(ApiHubServer).GetDeployment(ctx, in) |
| 1484 |
} |
| 1485 |
info := &grpc.UnaryServerInfo{ |
| 1486 |
Server: srv, |
| 1487 |
FullMethod: ApiHub_GetDeployment_FullMethodName, |
| 1488 |
} |
| 1489 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1490 |
return srv.(ApiHubServer).GetDeployment(ctx, req.(*GetDeploymentRequest)) |
| 1491 |
} |
| 1492 |
return interceptor(ctx, in, info, handler) |
| 1493 |
} |
| 1494 |
|
| 1495 |
func _ApiHub_ListDeployments_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1496 |
in := new(ListDeploymentsRequest) |
| 1497 |
if err := dec(in); err != nil { |
| 1498 |
return nil, err |
| 1499 |
} |
| 1500 |
if interceptor == nil { |
| 1501 |
return srv.(ApiHubServer).ListDeployments(ctx, in) |
| 1502 |
} |
| 1503 |
info := &grpc.UnaryServerInfo{ |
| 1504 |
Server: srv, |
| 1505 |
FullMethod: ApiHub_ListDeployments_FullMethodName, |
| 1506 |
} |
| 1507 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1508 |
return srv.(ApiHubServer).ListDeployments(ctx, req.(*ListDeploymentsRequest)) |
| 1509 |
} |
| 1510 |
return interceptor(ctx, in, info, handler) |
| 1511 |
} |
| 1512 |
|
| 1513 |
func _ApiHub_UpdateDeployment_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1514 |
in := new(UpdateDeploymentRequest) |
| 1515 |
if err := dec(in); err != nil { |
| 1516 |
return nil, err |
| 1517 |
} |
| 1518 |
if interceptor == nil { |
| 1519 |
return srv.(ApiHubServer).UpdateDeployment(ctx, in) |
| 1520 |
} |
| 1521 |
info := &grpc.UnaryServerInfo{ |
| 1522 |
Server: srv, |
| 1523 |
FullMethod: ApiHub_UpdateDeployment_FullMethodName, |
| 1524 |
} |
| 1525 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1526 |
return srv.(ApiHubServer).UpdateDeployment(ctx, req.(*UpdateDeploymentRequest)) |
| 1527 |
} |
| 1528 |
return interceptor(ctx, in, info, handler) |
| 1529 |
} |
| 1530 |
|
| 1531 |
func _ApiHub_DeleteDeployment_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1532 |
in := new(DeleteDeploymentRequest) |
| 1533 |
if err := dec(in); err != nil { |
| 1534 |
return nil, err |
| 1535 |
} |
| 1536 |
if interceptor == nil { |
| 1537 |
return srv.(ApiHubServer).DeleteDeployment(ctx, in) |
| 1538 |
} |
| 1539 |
info := &grpc.UnaryServerInfo{ |
| 1540 |
Server: srv, |
| 1541 |
FullMethod: ApiHub_DeleteDeployment_FullMethodName, |
| 1542 |
} |
| 1543 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1544 |
return srv.(ApiHubServer).DeleteDeployment(ctx, req.(*DeleteDeploymentRequest)) |
| 1545 |
} |
| 1546 |
return interceptor(ctx, in, info, handler) |
| 1547 |
} |
| 1548 |
|
| 1549 |
func _ApiHub_CreateAttribute_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1550 |
in := new(CreateAttributeRequest) |
| 1551 |
if err := dec(in); err != nil { |
| 1552 |
return nil, err |
| 1553 |
} |
| 1554 |
if interceptor == nil { |
| 1555 |
return srv.(ApiHubServer).CreateAttribute(ctx, in) |
| 1556 |
} |
| 1557 |
info := &grpc.UnaryServerInfo{ |
| 1558 |
Server: srv, |
| 1559 |
FullMethod: ApiHub_CreateAttribute_FullMethodName, |
| 1560 |
} |
| 1561 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1562 |
return srv.(ApiHubServer).CreateAttribute(ctx, req.(*CreateAttributeRequest)) |
| 1563 |
} |
| 1564 |
return interceptor(ctx, in, info, handler) |
| 1565 |
} |
| 1566 |
|
| 1567 |
func _ApiHub_GetAttribute_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1568 |
in := new(GetAttributeRequest) |
| 1569 |
if err := dec(in); err != nil { |
| 1570 |
return nil, err |
| 1571 |
} |
| 1572 |
if interceptor == nil { |
| 1573 |
return srv.(ApiHubServer).GetAttribute(ctx, in) |
| 1574 |
} |
| 1575 |
info := &grpc.UnaryServerInfo{ |
| 1576 |
Server: srv, |
| 1577 |
FullMethod: ApiHub_GetAttribute_FullMethodName, |
| 1578 |
} |
| 1579 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1580 |
return srv.(ApiHubServer).GetAttribute(ctx, req.(*GetAttributeRequest)) |
| 1581 |
} |
| 1582 |
return interceptor(ctx, in, info, handler) |
| 1583 |
} |
| 1584 |
|
| 1585 |
func _ApiHub_UpdateAttribute_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1586 |
in := new(UpdateAttributeRequest) |
| 1587 |
if err := dec(in); err != nil { |
| 1588 |
return nil, err |
| 1589 |
} |
| 1590 |
if interceptor == nil { |
| 1591 |
return srv.(ApiHubServer).UpdateAttribute(ctx, in) |
| 1592 |
} |
| 1593 |
info := &grpc.UnaryServerInfo{ |
| 1594 |
Server: srv, |
| 1595 |
FullMethod: ApiHub_UpdateAttribute_FullMethodName, |
| 1596 |
} |
| 1597 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1598 |
return srv.(ApiHubServer).UpdateAttribute(ctx, req.(*UpdateAttributeRequest)) |
| 1599 |
} |
| 1600 |
return interceptor(ctx, in, info, handler) |
| 1601 |
} |
| 1602 |
|
| 1603 |
func _ApiHub_DeleteAttribute_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1604 |
in := new(DeleteAttributeRequest) |
| 1605 |
if err := dec(in); err != nil { |
| 1606 |
return nil, err |
| 1607 |
} |
| 1608 |
if interceptor == nil { |
| 1609 |
return srv.(ApiHubServer).DeleteAttribute(ctx, in) |
| 1610 |
} |
| 1611 |
info := &grpc.UnaryServerInfo{ |
| 1612 |
Server: srv, |
| 1613 |
FullMethod: ApiHub_DeleteAttribute_FullMethodName, |
| 1614 |
} |
| 1615 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1616 |
return srv.(ApiHubServer).DeleteAttribute(ctx, req.(*DeleteAttributeRequest)) |
| 1617 |
} |
| 1618 |
return interceptor(ctx, in, info, handler) |
| 1619 |
} |
| 1620 |
|
| 1621 |
func _ApiHub_ListAttributes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1622 |
in := new(ListAttributesRequest) |
| 1623 |
if err := dec(in); err != nil { |
| 1624 |
return nil, err |
| 1625 |
} |
| 1626 |
if interceptor == nil { |
| 1627 |
return srv.(ApiHubServer).ListAttributes(ctx, in) |
| 1628 |
} |
| 1629 |
info := &grpc.UnaryServerInfo{ |
| 1630 |
Server: srv, |
| 1631 |
FullMethod: ApiHub_ListAttributes_FullMethodName, |
| 1632 |
} |
| 1633 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1634 |
return srv.(ApiHubServer).ListAttributes(ctx, req.(*ListAttributesRequest)) |
| 1635 |
} |
| 1636 |
return interceptor(ctx, in, info, handler) |
| 1637 |
} |
| 1638 |
|
| 1639 |
func _ApiHub_SearchResources_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1640 |
in := new(SearchResourcesRequest) |
| 1641 |
if err := dec(in); err != nil { |
| 1642 |
return nil, err |
| 1643 |
} |
| 1644 |
if interceptor == nil { |
| 1645 |
return srv.(ApiHubServer).SearchResources(ctx, in) |
| 1646 |
} |
| 1647 |
info := &grpc.UnaryServerInfo{ |
| 1648 |
Server: srv, |
| 1649 |
FullMethod: ApiHub_SearchResources_FullMethodName, |
| 1650 |
} |
| 1651 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1652 |
return srv.(ApiHubServer).SearchResources(ctx, req.(*SearchResourcesRequest)) |
| 1653 |
} |
| 1654 |
return interceptor(ctx, in, info, handler) |
| 1655 |
} |
| 1656 |
|
| 1657 |
func _ApiHub_CreateExternalApi_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1658 |
in := new(CreateExternalApiRequest) |
| 1659 |
if err := dec(in); err != nil { |
| 1660 |
return nil, err |
| 1661 |
} |
| 1662 |
if interceptor == nil { |
| 1663 |
return srv.(ApiHubServer).CreateExternalApi(ctx, in) |
| 1664 |
} |
| 1665 |
info := &grpc.UnaryServerInfo{ |
| 1666 |
Server: srv, |
| 1667 |
FullMethod: ApiHub_CreateExternalApi_FullMethodName, |
| 1668 |
} |
| 1669 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1670 |
return srv.(ApiHubServer).CreateExternalApi(ctx, req.(*CreateExternalApiRequest)) |
| 1671 |
} |
| 1672 |
return interceptor(ctx, in, info, handler) |
| 1673 |
} |
| 1674 |
|
| 1675 |
func _ApiHub_GetExternalApi_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1676 |
in := new(GetExternalApiRequest) |
| 1677 |
if err := dec(in); err != nil { |
| 1678 |
return nil, err |
| 1679 |
} |
| 1680 |
if interceptor == nil { |
| 1681 |
return srv.(ApiHubServer).GetExternalApi(ctx, in) |
| 1682 |
} |
| 1683 |
info := &grpc.UnaryServerInfo{ |
| 1684 |
Server: srv, |
| 1685 |
FullMethod: ApiHub_GetExternalApi_FullMethodName, |
| 1686 |
} |
| 1687 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1688 |
return srv.(ApiHubServer).GetExternalApi(ctx, req.(*GetExternalApiRequest)) |
| 1689 |
} |
| 1690 |
return interceptor(ctx, in, info, handler) |
| 1691 |
} |
| 1692 |
|
| 1693 |
func _ApiHub_UpdateExternalApi_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1694 |
in := new(UpdateExternalApiRequest) |
| 1695 |
if err := dec(in); err != nil { |
| 1696 |
return nil, err |
| 1697 |
} |
| 1698 |
if interceptor == nil { |
| 1699 |
return srv.(ApiHubServer).UpdateExternalApi(ctx, in) |
| 1700 |
} |
| 1701 |
info := &grpc.UnaryServerInfo{ |
| 1702 |
Server: srv, |
| 1703 |
FullMethod: ApiHub_UpdateExternalApi_FullMethodName, |
| 1704 |
} |
| 1705 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1706 |
return srv.(ApiHubServer).UpdateExternalApi(ctx, req.(*UpdateExternalApiRequest)) |
| 1707 |
} |
| 1708 |
return interceptor(ctx, in, info, handler) |
| 1709 |
} |
| 1710 |
|
| 1711 |
func _ApiHub_DeleteExternalApi_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1712 |
in := new(DeleteExternalApiRequest) |
| 1713 |
if err := dec(in); err != nil { |
| 1714 |
return nil, err |
| 1715 |
} |
| 1716 |
if interceptor == nil { |
| 1717 |
return srv.(ApiHubServer).DeleteExternalApi(ctx, in) |
| 1718 |
} |
| 1719 |
info := &grpc.UnaryServerInfo{ |
| 1720 |
Server: srv, |
| 1721 |
FullMethod: ApiHub_DeleteExternalApi_FullMethodName, |
| 1722 |
} |
| 1723 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1724 |
return srv.(ApiHubServer).DeleteExternalApi(ctx, req.(*DeleteExternalApiRequest)) |
| 1725 |
} |
| 1726 |
return interceptor(ctx, in, info, handler) |
| 1727 |
} |
| 1728 |
|
| 1729 |
func _ApiHub_ListExternalApis_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 1730 |
in := new(ListExternalApisRequest) |
| 1731 |
if err := dec(in); err != nil { |
| 1732 |
return nil, err |
| 1733 |
} |
| 1734 |
if interceptor == nil { |
| 1735 |
return srv.(ApiHubServer).ListExternalApis(ctx, in) |
| 1736 |
} |
| 1737 |
info := &grpc.UnaryServerInfo{ |
| 1738 |
Server: srv, |
| 1739 |
FullMethod: ApiHub_ListExternalApis_FullMethodName, |
| 1740 |
} |
| 1741 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 1742 |
return srv.(ApiHubServer).ListExternalApis(ctx, req.(*ListExternalApisRequest)) |
| 1743 |
} |
| 1744 |
return interceptor(ctx, in, info, handler) |
| 1745 |
} |
| 1746 |
|
| 1747 |
// ApiHub_ServiceDesc is the grpc.ServiceDesc for ApiHub service. |
| 1748 |
// It's only intended for direct use with grpc.RegisterService, |
| 1749 |
// and not to be introspected or modified (even as a copy) |
| 1750 |
var ApiHub_ServiceDesc = grpc.ServiceDesc{ |
| 1751 |
ServiceName: "google.cloud.apihub.v1.ApiHub", |
| 1752 |
HandlerType: (*ApiHubServer)(nil), |
| 1753 |
Methods: []grpc.MethodDesc{ |
| 1754 |
{ |
| 1755 |
MethodName: "CreateApi", |
| 1756 |
Handler: _ApiHub_CreateApi_Handler, |
| 1757 |
}, |
| 1758 |
{ |
| 1759 |
MethodName: "GetApi", |
| 1760 |
Handler: _ApiHub_GetApi_Handler, |
| 1761 |
}, |
| 1762 |
{ |
| 1763 |
MethodName: "ListApis", |
| 1764 |
Handler: _ApiHub_ListApis_Handler, |
| 1765 |
}, |
| 1766 |
{ |
| 1767 |
MethodName: "UpdateApi", |
| 1768 |
Handler: _ApiHub_UpdateApi_Handler, |
| 1769 |
}, |
| 1770 |
{ |
| 1771 |
MethodName: "DeleteApi", |
| 1772 |
Handler: _ApiHub_DeleteApi_Handler, |
| 1773 |
}, |
| 1774 |
{ |
| 1775 |
MethodName: "CreateVersion", |
| 1776 |
Handler: _ApiHub_CreateVersion_Handler, |
| 1777 |
}, |
| 1778 |
{ |
| 1779 |
MethodName: "GetVersion", |
| 1780 |
Handler: _ApiHub_GetVersion_Handler, |
| 1781 |
}, |
| 1782 |
{ |
| 1783 |
MethodName: "ListVersions", |
| 1784 |
Handler: _ApiHub_ListVersions_Handler, |
| 1785 |
}, |
| 1786 |
{ |
| 1787 |
MethodName: "UpdateVersion", |
| 1788 |
Handler: _ApiHub_UpdateVersion_Handler, |
| 1789 |
}, |
| 1790 |
{ |
| 1791 |
MethodName: "DeleteVersion", |
| 1792 |
Handler: _ApiHub_DeleteVersion_Handler, |
| 1793 |
}, |
| 1794 |
{ |
| 1795 |
MethodName: "CreateSpec", |
| 1796 |
Handler: _ApiHub_CreateSpec_Handler, |
| 1797 |
}, |
| 1798 |
{ |
| 1799 |
MethodName: "GetSpec", |
| 1800 |
Handler: _ApiHub_GetSpec_Handler, |
| 1801 |
}, |
| 1802 |
{ |
| 1803 |
MethodName: "GetSpecContents", |
| 1804 |
Handler: _ApiHub_GetSpecContents_Handler, |
| 1805 |
}, |
| 1806 |
{ |
| 1807 |
MethodName: "ListSpecs", |
| 1808 |
Handler: _ApiHub_ListSpecs_Handler, |
| 1809 |
}, |
| 1810 |
{ |
| 1811 |
MethodName: "UpdateSpec", |
| 1812 |
Handler: _ApiHub_UpdateSpec_Handler, |
| 1813 |
}, |
| 1814 |
{ |
| 1815 |
MethodName: "DeleteSpec", |
| 1816 |
Handler: _ApiHub_DeleteSpec_Handler, |
| 1817 |
}, |
| 1818 |
{ |
| 1819 |
MethodName: "CreateApiOperation", |
| 1820 |
Handler: _ApiHub_CreateApiOperation_Handler, |
| 1821 |
}, |
| 1822 |
{ |
| 1823 |
MethodName: "GetApiOperation", |
| 1824 |
Handler: _ApiHub_GetApiOperation_Handler, |
| 1825 |
}, |
| 1826 |
{ |
| 1827 |
MethodName: "ListApiOperations", |
| 1828 |
Handler: _ApiHub_ListApiOperations_Handler, |
| 1829 |
}, |
| 1830 |
{ |
| 1831 |
MethodName: "UpdateApiOperation", |
| 1832 |
Handler: _ApiHub_UpdateApiOperation_Handler, |
| 1833 |
}, |
| 1834 |
{ |
| 1835 |
MethodName: "DeleteApiOperation", |
| 1836 |
Handler: _ApiHub_DeleteApiOperation_Handler, |
| 1837 |
}, |
| 1838 |
{ |
| 1839 |
MethodName: "GetDefinition", |
| 1840 |
Handler: _ApiHub_GetDefinition_Handler, |
| 1841 |
}, |
| 1842 |
{ |
| 1843 |
MethodName: "CreateDeployment", |
| 1844 |
Handler: _ApiHub_CreateDeployment_Handler, |
| 1845 |
}, |
| 1846 |
{ |
| 1847 |
MethodName: "GetDeployment", |
| 1848 |
Handler: _ApiHub_GetDeployment_Handler, |
| 1849 |
}, |
| 1850 |
{ |
| 1851 |
MethodName: "ListDeployments", |
| 1852 |
Handler: _ApiHub_ListDeployments_Handler, |
| 1853 |
}, |
| 1854 |
{ |
| 1855 |
MethodName: "UpdateDeployment", |
| 1856 |
Handler: _ApiHub_UpdateDeployment_Handler, |
| 1857 |
}, |
| 1858 |
{ |
| 1859 |
MethodName: "DeleteDeployment", |
| 1860 |
Handler: _ApiHub_DeleteDeployment_Handler, |
| 1861 |
}, |
| 1862 |
{ |
| 1863 |
MethodName: "CreateAttribute", |
| 1864 |
Handler: _ApiHub_CreateAttribute_Handler, |
| 1865 |
}, |
| 1866 |
{ |
| 1867 |
MethodName: "GetAttribute", |
| 1868 |
Handler: _ApiHub_GetAttribute_Handler, |
| 1869 |
}, |
| 1870 |
{ |
| 1871 |
MethodName: "UpdateAttribute", |
| 1872 |
Handler: _ApiHub_UpdateAttribute_Handler, |
| 1873 |
}, |
| 1874 |
{ |
| 1875 |
MethodName: "DeleteAttribute", |
| 1876 |
Handler: _ApiHub_DeleteAttribute_Handler, |
| 1877 |
}, |
| 1878 |
{ |
| 1879 |
MethodName: "ListAttributes", |
| 1880 |
Handler: _ApiHub_ListAttributes_Handler, |
| 1881 |
}, |
| 1882 |
{ |
| 1883 |
MethodName: "SearchResources", |
| 1884 |
Handler: _ApiHub_SearchResources_Handler, |
| 1885 |
}, |
| 1886 |
{ |
| 1887 |
MethodName: "CreateExternalApi", |
| 1888 |
Handler: _ApiHub_CreateExternalApi_Handler, |
| 1889 |
}, |
| 1890 |
{ |
| 1891 |
MethodName: "GetExternalApi", |
| 1892 |
Handler: _ApiHub_GetExternalApi_Handler, |
| 1893 |
}, |
| 1894 |
{ |
| 1895 |
MethodName: "UpdateExternalApi", |
| 1896 |
Handler: _ApiHub_UpdateExternalApi_Handler, |
| 1897 |
}, |
| 1898 |
{ |
| 1899 |
MethodName: "DeleteExternalApi", |
| 1900 |
Handler: _ApiHub_DeleteExternalApi_Handler, |
| 1901 |
}, |
| 1902 |
{ |
| 1903 |
MethodName: "ListExternalApis", |
| 1904 |
Handler: _ApiHub_ListExternalApis_Handler, |
| 1905 |
}, |
| 1906 |
}, |
| 1907 |
Streams: []grpc.StreamDesc{}, |
| 1908 |
Metadata: "google/cloud/apihub/v1/apihub_service.proto", |
| 1909 |
} |
| 1910 |
|
| 1911 |
const ( |
| 1912 |
ApiHubDependencies_CreateDependency_FullMethodName = "/google.cloud.apihub.v1.ApiHubDependencies/CreateDependency" |
| 1913 |
ApiHubDependencies_GetDependency_FullMethodName = "/google.cloud.apihub.v1.ApiHubDependencies/GetDependency" |
| 1914 |
ApiHubDependencies_UpdateDependency_FullMethodName = "/google.cloud.apihub.v1.ApiHubDependencies/UpdateDependency" |
| 1915 |
ApiHubDependencies_DeleteDependency_FullMethodName = "/google.cloud.apihub.v1.ApiHubDependencies/DeleteDependency" |
| 1916 |
ApiHubDependencies_ListDependencies_FullMethodName = "/google.cloud.apihub.v1.ApiHubDependencies/ListDependencies" |
| 1917 |
) |
| 1918 |
|
| 1919 |
// ApiHubDependenciesClient is the client API for ApiHubDependencies service. |
| 1920 |
// |
| 1921 |
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. |
| 1922 |
type ApiHubDependenciesClient interface { |
| 1923 |
// Create a dependency between two entities in the API hub. |
| 1924 |
CreateDependency(ctx context.Context, in *CreateDependencyRequest, opts ...grpc.CallOption) (*Dependency, error) |
| 1925 |
// Get details about a dependency resource in the API hub. |
| 1926 |
GetDependency(ctx context.Context, in *GetDependencyRequest, opts ...grpc.CallOption) (*Dependency, error) |
| 1927 |
// Update a dependency based on the |
| 1928 |
// [update_mask][google.cloud.apihub.v1.UpdateDependencyRequest.update_mask] |
| 1929 |
// provided in the request. |
| 1930 |
// |
| 1931 |
// The following fields in the [dependency][google.cloud.apihub.v1.Dependency] |
| 1932 |
// can be updated: |
| 1933 |
// * [description][google.cloud.apihub.v1.Dependency.description] |
| 1934 |
UpdateDependency(ctx context.Context, in *UpdateDependencyRequest, opts ...grpc.CallOption) (*Dependency, error) |
| 1935 |
// Delete the dependency resource. |
| 1936 |
DeleteDependency(ctx context.Context, in *DeleteDependencyRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) |
| 1937 |
// List dependencies based on the provided filter and pagination parameters. |
| 1938 |
ListDependencies(ctx context.Context, in *ListDependenciesRequest, opts ...grpc.CallOption) (*ListDependenciesResponse, error) |
| 1939 |
} |
| 1940 |
|
| 1941 |
type apiHubDependenciesClient struct { |
| 1942 |
cc grpc.ClientConnInterface |
| 1943 |
} |
| 1944 |
|
| 1945 |
func NewApiHubDependenciesClient(cc grpc.ClientConnInterface) ApiHubDependenciesClient { |
| 1946 |
return &apiHubDependenciesClient{cc} |
| 1947 |
} |
| 1948 |
|
| 1949 |
func (c *apiHubDependenciesClient) CreateDependency(ctx context.Context, in *CreateDependencyRequest, opts ...grpc.CallOption) (*Dependency, error) { |
| 1950 |
out := new(Dependency) |
| 1951 |
err := c.cc.Invoke(ctx, ApiHubDependencies_CreateDependency_FullMethodName, in, out, opts...) |
| 1952 |
if err != nil { |
| 1953 |
return nil, err |
| 1954 |
} |
| 1955 |
return out, nil |
| 1956 |
} |
| 1957 |
|
| 1958 |
func (c *apiHubDependenciesClient) GetDependency(ctx context.Context, in *GetDependencyRequest, opts ...grpc.CallOption) (*Dependency, error) { |
| 1959 |
out := new(Dependency) |
| 1960 |
err := c.cc.Invoke(ctx, ApiHubDependencies_GetDependency_FullMethodName, in, out, opts...) |
| 1961 |
if err != nil { |
| 1962 |
return nil, err |
| 1963 |
} |
| 1964 |
return out, nil |
| 1965 |
} |
| 1966 |
|
| 1967 |
func (c *apiHubDependenciesClient) UpdateDependency(ctx context.Context, in *UpdateDependencyRequest, opts ...grpc.CallOption) (*Dependency, error) { |
| 1968 |
out := new(Dependency) |
| 1969 |
err := c.cc.Invoke(ctx, ApiHubDependencies_UpdateDependency_FullMethodName, in, out, opts...) |
| 1970 |
if err != nil { |
| 1971 |
return nil, err |
| 1972 |
} |
| 1973 |
return out, nil |
| 1974 |
} |
| 1975 |
|
| 1976 |
func (c *apiHubDependenciesClient) DeleteDependency(ctx context.Context, in *DeleteDependencyRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { |
| 1977 |
out := new(emptypb.Empty) |
| 1978 |
err := c.cc.Invoke(ctx, ApiHubDependencies_DeleteDependency_FullMethodName, in, out, opts...) |
| 1979 |
if err != nil { |
| 1980 |
return nil, err |
| 1981 |
} |
| 1982 |
return out, nil |
| 1983 |
} |
| 1984 |
|
| 1985 |
func (c *apiHubDependenciesClient) ListDependencies(ctx context.Context, in *ListDependenciesRequest, opts ...grpc.CallOption) (*ListDependenciesResponse, error) { |
| 1986 |
out := new(ListDependenciesResponse) |
| 1987 |
err := c.cc.Invoke(ctx, ApiHubDependencies_ListDependencies_FullMethodName, in, out, opts...) |
| 1988 |
if err != nil { |
| 1989 |
return nil, err |
| 1990 |
} |
| 1991 |
return out, nil |
| 1992 |
} |
| 1993 |
|
| 1994 |
// ApiHubDependenciesServer is the server API for ApiHubDependencies service. |
| 1995 |
// All implementations should embed UnimplementedApiHubDependenciesServer |
| 1996 |
// for forward compatibility |
| 1997 |
type ApiHubDependenciesServer interface { |
| 1998 |
// Create a dependency between two entities in the API hub. |
| 1999 |
CreateDependency(context.Context, *CreateDependencyRequest) (*Dependency, error) |
| 2000 |
// Get details about a dependency resource in the API hub. |
| 2001 |
GetDependency(context.Context, *GetDependencyRequest) (*Dependency, error) |
| 2002 |
// Update a dependency based on the |
| 2003 |
// [update_mask][google.cloud.apihub.v1.UpdateDependencyRequest.update_mask] |
| 2004 |
// provided in the request. |
| 2005 |
// |
| 2006 |
// The following fields in the [dependency][google.cloud.apihub.v1.Dependency] |
| 2007 |
// can be updated: |
| 2008 |
// * [description][google.cloud.apihub.v1.Dependency.description] |
| 2009 |
UpdateDependency(context.Context, *UpdateDependencyRequest) (*Dependency, error) |
| 2010 |
// Delete the dependency resource. |
| 2011 |
DeleteDependency(context.Context, *DeleteDependencyRequest) (*emptypb.Empty, error) |
| 2012 |
// List dependencies based on the provided filter and pagination parameters. |
| 2013 |
ListDependencies(context.Context, *ListDependenciesRequest) (*ListDependenciesResponse, error) |
| 2014 |
} |
| 2015 |
|
| 2016 |
// UnimplementedApiHubDependenciesServer should be embedded to have forward compatible implementations. |
| 2017 |
type UnimplementedApiHubDependenciesServer struct { |
| 2018 |
} |
| 2019 |
|
| 2020 |
func (UnimplementedApiHubDependenciesServer) CreateDependency(context.Context, *CreateDependencyRequest) (*Dependency, error) { |
| 2021 |
return nil, status.Errorf(codes.Unimplemented, "method CreateDependency not implemented") |
| 2022 |
} |
| 2023 |
func (UnimplementedApiHubDependenciesServer) GetDependency(context.Context, *GetDependencyRequest) (*Dependency, error) { |
| 2024 |
return nil, status.Errorf(codes.Unimplemented, "method GetDependency not implemented") |
| 2025 |
} |
| 2026 |
func (UnimplementedApiHubDependenciesServer) UpdateDependency(context.Context, *UpdateDependencyRequest) (*Dependency, error) { |
| 2027 |
return nil, status.Errorf(codes.Unimplemented, "method UpdateDependency not implemented") |
| 2028 |
} |
| 2029 |
func (UnimplementedApiHubDependenciesServer) DeleteDependency(context.Context, *DeleteDependencyRequest) (*emptypb.Empty, error) { |
| 2030 |
return nil, status.Errorf(codes.Unimplemented, "method DeleteDependency not implemented") |
| 2031 |
} |
| 2032 |
func (UnimplementedApiHubDependenciesServer) ListDependencies(context.Context, *ListDependenciesRequest) (*ListDependenciesResponse, error) { |
| 2033 |
return nil, status.Errorf(codes.Unimplemented, "method ListDependencies not implemented") |
| 2034 |
} |
| 2035 |
|
| 2036 |
// UnsafeApiHubDependenciesServer may be embedded to opt out of forward compatibility for this service. |
| 2037 |
// Use of this interface is not recommended, as added methods to ApiHubDependenciesServer will |
| 2038 |
// result in compilation errors. |
| 2039 |
type UnsafeApiHubDependenciesServer interface { |
| 2040 |
mustEmbedUnimplementedApiHubDependenciesServer() |
| 2041 |
} |
| 2042 |
|
| 2043 |
func RegisterApiHubDependenciesServer(s grpc.ServiceRegistrar, srv ApiHubDependenciesServer) { |
| 2044 |
s.RegisterService(&ApiHubDependencies_ServiceDesc, srv) |
| 2045 |
} |
| 2046 |
|
| 2047 |
func _ApiHubDependencies_CreateDependency_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 2048 |
in := new(CreateDependencyRequest) |
| 2049 |
if err := dec(in); err != nil { |
| 2050 |
return nil, err |
| 2051 |
} |
| 2052 |
if interceptor == nil { |
| 2053 |
return srv.(ApiHubDependenciesServer).CreateDependency(ctx, in) |
| 2054 |
} |
| 2055 |
info := &grpc.UnaryServerInfo{ |
| 2056 |
Server: srv, |
| 2057 |
FullMethod: ApiHubDependencies_CreateDependency_FullMethodName, |
| 2058 |
} |
| 2059 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 2060 |
return srv.(ApiHubDependenciesServer).CreateDependency(ctx, req.(*CreateDependencyRequest)) |
| 2061 |
} |
| 2062 |
return interceptor(ctx, in, info, handler) |
| 2063 |
} |
| 2064 |
|
| 2065 |
func _ApiHubDependencies_GetDependency_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 2066 |
in := new(GetDependencyRequest) |
| 2067 |
if err := dec(in); err != nil { |
| 2068 |
return nil, err |
| 2069 |
} |
| 2070 |
if interceptor == nil { |
| 2071 |
return srv.(ApiHubDependenciesServer).GetDependency(ctx, in) |
| 2072 |
} |
| 2073 |
info := &grpc.UnaryServerInfo{ |
| 2074 |
Server: srv, |
| 2075 |
FullMethod: ApiHubDependencies_GetDependency_FullMethodName, |
| 2076 |
} |
| 2077 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 2078 |
return srv.(ApiHubDependenciesServer).GetDependency(ctx, req.(*GetDependencyRequest)) |
| 2079 |
} |
| 2080 |
return interceptor(ctx, in, info, handler) |
| 2081 |
} |
| 2082 |
|
| 2083 |
func _ApiHubDependencies_UpdateDependency_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 2084 |
in := new(UpdateDependencyRequest) |
| 2085 |
if err := dec(in); err != nil { |
| 2086 |
return nil, err |
| 2087 |
} |
| 2088 |
if interceptor == nil { |
| 2089 |
return srv.(ApiHubDependenciesServer).UpdateDependency(ctx, in) |
| 2090 |
} |
| 2091 |
info := &grpc.UnaryServerInfo{ |
| 2092 |
Server: srv, |
| 2093 |
FullMethod: ApiHubDependencies_UpdateDependency_FullMethodName, |
| 2094 |
} |
| 2095 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 2096 |
return srv.(ApiHubDependenciesServer).UpdateDependency(ctx, req.(*UpdateDependencyRequest)) |
| 2097 |
} |
| 2098 |
return interceptor(ctx, in, info, handler) |
| 2099 |
} |
| 2100 |
|
| 2101 |
func _ApiHubDependencies_DeleteDependency_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 2102 |
in := new(DeleteDependencyRequest) |
| 2103 |
if err := dec(in); err != nil { |
| 2104 |
return nil, err |
| 2105 |
} |
| 2106 |
if interceptor == nil { |
| 2107 |
return srv.(ApiHubDependenciesServer).DeleteDependency(ctx, in) |
| 2108 |
} |
| 2109 |
info := &grpc.UnaryServerInfo{ |
| 2110 |
Server: srv, |
| 2111 |
FullMethod: ApiHubDependencies_DeleteDependency_FullMethodName, |
| 2112 |
} |
| 2113 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 2114 |
return srv.(ApiHubDependenciesServer).DeleteDependency(ctx, req.(*DeleteDependencyRequest)) |
| 2115 |
} |
| 2116 |
return interceptor(ctx, in, info, handler) |
| 2117 |
} |
| 2118 |
|
| 2119 |
func _ApiHubDependencies_ListDependencies_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
| 2120 |
in := new(ListDependenciesRequest) |
| 2121 |
if err := dec(in); err != nil { |
| 2122 |
return nil, err |
| 2123 |
} |
| 2124 |
if interceptor == nil { |
| 2125 |
return srv.(ApiHubDependenciesServer).ListDependencies(ctx, in) |
| 2126 |
} |
| 2127 |
info := &grpc.UnaryServerInfo{ |
| 2128 |
Server: srv, |
| 2129 |
FullMethod: ApiHubDependencies_ListDependencies_FullMethodName, |
| 2130 |
} |
| 2131 |
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
| 2132 |
return srv.(ApiHubDependenciesServer).ListDependencies(ctx, req.(*ListDependenciesRequest)) |
| 2133 |
} |
| 2134 |
return interceptor(ctx, in, info, handler) |
| 2135 |
} |
| 2136 |
|
| 2137 |
// ApiHubDependencies_ServiceDesc is the grpc.ServiceDesc for ApiHubDependencies service. |
| 2138 |
// It's only intended for direct use with grpc.RegisterService, |
| 2139 |
// and not to be introspected or modified (even as a copy) |
| 2140 |
var ApiHubDependencies_ServiceDesc = grpc.ServiceDesc{ |
| 2141 |
ServiceName: "google.cloud.apihub.v1.ApiHubDependencies", |
| 2142 |
HandlerType: (*ApiHubDependenciesServer)(nil), |
| 2143 |
Methods: []grpc.MethodDesc{ |
| 2144 |
{ |
| 2145 |
MethodName: "CreateDependency", |
| 2146 |
Handler: _ApiHubDependencies_CreateDependency_Handler, |
| 2147 |
}, |
| 2148 |
{ |
| 2149 |
MethodName: "GetDependency", |
| 2150 |
Handler: _ApiHubDependencies_GetDependency_Handler, |
| 2151 |
}, |
| 2152 |
{ |
| 2153 |
MethodName: "UpdateDependency", |
| 2154 |
Handler: _ApiHubDependencies_UpdateDependency_Handler, |
| 2155 |
}, |
| 2156 |
{ |
| 2157 |
MethodName: "DeleteDependency", |
| 2158 |
Handler: _ApiHubDependencies_DeleteDependency_Handler, |
| 2159 |
}, |
| 2160 |
{ |
| 2161 |
MethodName: "ListDependencies", |
| 2162 |
Handler: _ApiHubDependencies_ListDependencies_Handler, |
| 2163 |
}, |
| 2164 |
}, |
| 2165 |
Streams: []grpc.StreamDesc{}, |
| 2166 |
Metadata: "google/cloud/apihub/v1/apihub_service.proto", |
| 2167 |
} |