Secure Source Manager API v1 - Package cloud.google.com/go/securesourcemanager/apiv1 (v1.4.0)

Package securesourcemanager is an auto-generated package for the Secure Source Manager API.

Regionally deployed, single-tenant managed source code repository hosted on Google Cloud.

General documentation

For information that is relevant for all client libraries please reference https://pkg.go.dev/cloud.google.com/go#pkg-overview. Some information on this page includes:

Example usage

To get started with this package, create a client.

// go get cloud.google.com/go/securesourcemanager/apiv1@latest
ctx := context.Background()
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in:
//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
c, err := securesourcemanager.NewClient(ctx)
if err != nil {
    // TODO: Handle error.
}
defer c.Close()

The client will use your default application credentials. Clients should be reused instead of created as needed. The methods of Client are safe for concurrent use by multiple goroutines. The returned client must be Closed when it is done being used.

Using the Client

The following is an example of making an API call with the newly created client, mentioned above.

req := &securesourcemanagerpb.BatchCreatePullRequestCommentsRequest{
    // TODO: Fill request struct fields.
    // See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#BatchCreatePullRequestCommentsRequest.
}
op, err := c.BatchCreatePullRequestComments(ctx, req)
if err != nil {
    // TODO: Handle error.
}

resp, err := op.Wait(ctx)
if err != nil {
    // TODO: Handle error.
}
// TODO: Use resp.
_ = resp

Use of Context

The ctx passed to NewClient is used for authentication requests and for creating the underlying connection, but is not used for subsequent calls. Individual methods on the client use the ctx given to them.

To close the open connection, use the Close() method.

Functions

func DefaultAuthScopes

func DefaultAuthScopes() []string

DefaultAuthScopes reports the default set of authentication scopes to use with this package.

BatchCreatePullRequestCommentsOperation

type BatchCreatePullRequestCommentsOperation struct {
	// contains filtered or unexported fields
}

BatchCreatePullRequestCommentsOperation manages a long-running operation from BatchCreatePullRequestComments.

func (*BatchCreatePullRequestCommentsOperation) Done

Done reports whether the long-running operation has completed.

func (*BatchCreatePullRequestCommentsOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*BatchCreatePullRequestCommentsOperation) Name

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*BatchCreatePullRequestCommentsOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*BatchCreatePullRequestCommentsOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

BranchRuleIterator

type BranchRuleIterator struct {

	// Response is the raw response for the current page.
	// It must be cast to the RPC response type.
	// Calling Next() or InternalFetch() updates this value.
	Response interface{}

	// InternalFetch is for use by the Google Cloud Libraries only.
	// It is not part of the stable interface of this package.
	//
	// InternalFetch returns results from a single call to the underlying RPC.
	// The number of results is no greater than pageSize.
	// If there are no more results, nextPageToken is empty and err is nil.
	InternalFetch func(pageSize int, pageToken string) (results []*securesourcemanagerpb.BranchRule, nextPageToken string, err error)
	// contains filtered or unexported fields
}

BranchRuleIterator manages a stream of *securesourcemanagerpb.BranchRule.

func (*BranchRuleIterator) All

func (it *BranchRuleIterator) All() iter.Seq2[*securesourcemanagerpb.BranchRule, error]

All returns an iterator. If an error is returned by the iterator, the iterator will stop after that iteration.

func (*BranchRuleIterator) Next

Next returns the next result. Its second return value is iterator.Done if there are no more results. Once Next returns Done, all subsequent calls will return Done.

func (*BranchRuleIterator) PageInfo

func (it *BranchRuleIterator) PageInfo() *iterator.PageInfo

PageInfo supports pagination. See the [google.golang.org/api/iterator] package for details.

CallOptions

type CallOptions struct {
	ListInstances                  []gax.CallOption
	GetInstance                    []gax.CallOption
	CreateInstance                 []gax.CallOption
	DeleteInstance                 []gax.CallOption
	ListRepositories               []gax.CallOption
	GetRepository                  []gax.CallOption
	CreateRepository               []gax.CallOption
	UpdateRepository               []gax.CallOption
	DeleteRepository               []gax.CallOption
	ListHooks                      []gax.CallOption
	GetHook                        []gax.CallOption
	CreateHook                     []gax.CallOption
	UpdateHook                     []gax.CallOption
	DeleteHook                     []gax.CallOption
	GetIamPolicyRepo               []gax.CallOption
	SetIamPolicyRepo               []gax.CallOption
	TestIamPermissionsRepo         []gax.CallOption
	CreateBranchRule               []gax.CallOption
	ListBranchRules                []gax.CallOption
	GetBranchRule                  []gax.CallOption
	UpdateBranchRule               []gax.CallOption
	DeleteBranchRule               []gax.CallOption
	CreatePullRequest              []gax.CallOption
	GetPullRequest                 []gax.CallOption
	ListPullRequests               []gax.CallOption
	UpdatePullRequest              []gax.CallOption
	MergePullRequest               []gax.CallOption
	OpenPullRequest                []gax.CallOption
	ClosePullRequest               []gax.CallOption
	ListPullRequestFileDiffs       []gax.CallOption
	FetchTree                      []gax.CallOption
	FetchBlob                      []gax.CallOption
	CreateIssue                    []gax.CallOption
	GetIssue                       []gax.CallOption
	ListIssues                     []gax.CallOption
	UpdateIssue                    []gax.CallOption
	DeleteIssue                    []gax.CallOption
	OpenIssue                      []gax.CallOption
	CloseIssue                     []gax.CallOption
	GetPullRequestComment          []gax.CallOption
	ListPullRequestComments        []gax.CallOption
	CreatePullRequestComment       []gax.CallOption
	UpdatePullRequestComment       []gax.CallOption
	DeletePullRequestComment       []gax.CallOption
	BatchCreatePullRequestComments []gax.CallOption
	ResolvePullRequestComments     []gax.CallOption
	UnresolvePullRequestComments   []gax.CallOption
	CreateIssueComment             []gax.CallOption
	GetIssueComment                []gax.CallOption
	ListIssueComments              []gax.CallOption
	UpdateIssueComment             []gax.CallOption
	DeleteIssueComment             []gax.CallOption
	GetLocation                    []gax.CallOption
	ListLocations                  []gax.CallOption
	GetIamPolicy                   []gax.CallOption
	SetIamPolicy                   []gax.CallOption
	TestIamPermissions             []gax.CallOption
	CancelOperation                []gax.CallOption
	DeleteOperation                []gax.CallOption
	GetOperation                   []gax.CallOption
	ListOperations                 []gax.CallOption
}

CallOptions contains the retry settings for each method of Client.

Client

type Client struct {

	// The call options for this service.
	CallOptions *CallOptions

	// LROClient is used internally to handle long-running operations.
	// It is exposed so that its CallOptions can be modified if required.
	// Users should not Close this client.
	LROClient *lroauto.OperationsClient
	// contains filtered or unexported fields
}

Client is a client for interacting with Secure Source Manager API. Methods, except Close, may be called concurrently. However, fields must not be modified concurrently with method calls.

Secure Source Manager API

Access Secure Source Manager instances, resources, and repositories.

func NewClient

func NewClient(ctx context.Context, opts ...option.ClientOption) (*Client, error)

NewClient creates a new secure source manager client based on gRPC. The returned client must be Closed when it is done being used to clean up its underlying connections.

Secure Source Manager API

Access Secure Source Manager instances, resources, and repositories.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	// TODO: Use client.
	_ = c
}

func NewRESTClient

func NewRESTClient(ctx context.Context, opts ...option.ClientOption) (*Client, error)

NewRESTClient creates a new secure source manager rest client.

Secure Source Manager API

Access Secure Source Manager instances, resources, and repositories.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewRESTClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	// TODO: Use client.
	_ = c
}

func (*Client) BatchCreatePullRequestComments

BatchCreatePullRequestComments batch creates pull request comments.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.BatchCreatePullRequestCommentsRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#BatchCreatePullRequestCommentsRequest.
	}
	op, err := c.BatchCreatePullRequestComments(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) BatchCreatePullRequestCommentsOperation

func (c *Client) BatchCreatePullRequestCommentsOperation(name string) *BatchCreatePullRequestCommentsOperation

BatchCreatePullRequestCommentsOperation returns a new BatchCreatePullRequestCommentsOperation from a given name. The name must be that of a previously created BatchCreatePullRequestCommentsOperation, possibly from a different process.

func (*Client) CancelOperation

func (c *Client) CancelOperation(ctx context.Context, req *longrunningpb.CancelOperationRequest, opts ...gax.CallOption) error

CancelOperation is a utility method from google.longrunning.Operations.

Example

package main

import (
	"context"

	longrunningpb "cloud.google.com/go/longrunning/autogen/longrunningpb"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &longrunningpb.CancelOperationRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/longrunning/autogen/longrunningpb#CancelOperationRequest.
	}
	err = c.CancelOperation(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
}

func (*Client) Close

func (c *Client) Close() error

Close closes the connection to the API service. The user should invoke this when the client is no longer required.

func (*Client) CloseIssue

CloseIssue closes an issue.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.CloseIssueRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#CloseIssueRequest.
	}
	op, err := c.CloseIssue(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) CloseIssueOperation

func (c *Client) CloseIssueOperation(name string) *CloseIssueOperation

CloseIssueOperation returns a new CloseIssueOperation from a given name. The name must be that of a previously created CloseIssueOperation, possibly from a different process.

func (*Client) ClosePullRequest

ClosePullRequest closes a pull request without merging.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.ClosePullRequestRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#ClosePullRequestRequest.
	}
	op, err := c.ClosePullRequest(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) ClosePullRequestOperation

func (c *Client) ClosePullRequestOperation(name string) *ClosePullRequestOperation

ClosePullRequestOperation returns a new ClosePullRequestOperation from a given name. The name must be that of a previously created ClosePullRequestOperation, possibly from a different process.

func (*Client) Connection (deprecated)

func (c *Client) Connection() *grpc.ClientConn

Connection returns a connection to the API service.

Deprecated: Connections are now pooled so this method does not always return the same resource.

func (*Client) CreateBranchRule

CreateBranchRule createBranchRule creates a branch rule in a given repository.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.CreateBranchRuleRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#CreateBranchRuleRequest.
	}
	op, err := c.CreateBranchRule(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) CreateBranchRuleOperation

func (c *Client) CreateBranchRuleOperation(name string) *CreateBranchRuleOperation

CreateBranchRuleOperation returns a new CreateBranchRuleOperation from a given name. The name must be that of a previously created CreateBranchRuleOperation, possibly from a different process.

func (*Client) CreateHook

CreateHook creates a new hook in a given repository.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.CreateHookRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#CreateHookRequest.
	}
	op, err := c.CreateHook(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) CreateHookOperation

func (c *Client) CreateHookOperation(name string) *CreateHookOperation

CreateHookOperation returns a new CreateHookOperation from a given name. The name must be that of a previously created CreateHookOperation, possibly from a different process.

func (*Client) CreateInstance

CreateInstance creates a new instance in a given project and location.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.CreateInstanceRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#CreateInstanceRequest.
	}
	op, err := c.CreateInstance(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) CreateInstanceOperation

func (c *Client) CreateInstanceOperation(name string) *CreateInstanceOperation

CreateInstanceOperation returns a new CreateInstanceOperation from a given name. The name must be that of a previously created CreateInstanceOperation, possibly from a different process.

func (*Client) CreateIssue

CreateIssue creates an issue.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.CreateIssueRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#CreateIssueRequest.
	}
	op, err := c.CreateIssue(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) CreateIssueComment

CreateIssueComment creates an issue comment.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.CreateIssueCommentRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#CreateIssueCommentRequest.
	}
	op, err := c.CreateIssueComment(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) CreateIssueCommentOperation

func (c *Client) CreateIssueCommentOperation(name string) *CreateIssueCommentOperation

CreateIssueCommentOperation returns a new CreateIssueCommentOperation from a given name. The name must be that of a previously created CreateIssueCommentOperation, possibly from a different process.

func (*Client) CreateIssueOperation

func (c *Client) CreateIssueOperation(name string) *CreateIssueOperation

CreateIssueOperation returns a new CreateIssueOperation from a given name. The name must be that of a previously created CreateIssueOperation, possibly from a different process.

func (*Client) CreatePullRequest

CreatePullRequest creates a pull request.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.CreatePullRequestRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#CreatePullRequestRequest.
	}
	op, err := c.CreatePullRequest(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) CreatePullRequestComment

CreatePullRequestComment creates a pull request comment.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.CreatePullRequestCommentRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#CreatePullRequestCommentRequest.
	}
	op, err := c.CreatePullRequestComment(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) CreatePullRequestCommentOperation

func (c *Client) CreatePullRequestCommentOperation(name string) *CreatePullRequestCommentOperation

CreatePullRequestCommentOperation returns a new CreatePullRequestCommentOperation from a given name. The name must be that of a previously created CreatePullRequestCommentOperation, possibly from a different process.

func (*Client) CreatePullRequestOperation

func (c *Client) CreatePullRequestOperation(name string) *CreatePullRequestOperation

CreatePullRequestOperation returns a new CreatePullRequestOperation from a given name. The name must be that of a previously created CreatePullRequestOperation, possibly from a different process.

func (*Client) CreateRepository

CreateRepository creates a new repository in a given project and location.

The Repository.Instance field is required in the request body for requests using the securesourcemanager.googleapis.com (at http://securesourcemanager.googleapis.com) endpoint.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.CreateRepositoryRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#CreateRepositoryRequest.
	}
	op, err := c.CreateRepository(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) CreateRepositoryOperation

func (c *Client) CreateRepositoryOperation(name string) *CreateRepositoryOperation

CreateRepositoryOperation returns a new CreateRepositoryOperation from a given name. The name must be that of a previously created CreateRepositoryOperation, possibly from a different process.

func (*Client) DeleteBranchRule

DeleteBranchRule deleteBranchRule deletes a branch rule.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.DeleteBranchRuleRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#DeleteBranchRuleRequest.
	}
	op, err := c.DeleteBranchRule(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	err = op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
}

func (*Client) DeleteBranchRuleOperation

func (c *Client) DeleteBranchRuleOperation(name string) *DeleteBranchRuleOperation

DeleteBranchRuleOperation returns a new DeleteBranchRuleOperation from a given name. The name must be that of a previously created DeleteBranchRuleOperation, possibly from a different process.

func (*Client) DeleteHook

DeleteHook deletes a Hook.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.DeleteHookRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#DeleteHookRequest.
	}
	op, err := c.DeleteHook(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	err = op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
}

func (*Client) DeleteHookOperation

func (c *Client) DeleteHookOperation(name string) *DeleteHookOperation

DeleteHookOperation returns a new DeleteHookOperation from a given name. The name must be that of a previously created DeleteHookOperation, possibly from a different process.

func (*Client) DeleteInstance

DeleteInstance deletes a single instance.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.DeleteInstanceRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#DeleteInstanceRequest.
	}
	op, err := c.DeleteInstance(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	err = op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
}

func (*Client) DeleteInstanceOperation

func (c *Client) DeleteInstanceOperation(name string) *DeleteInstanceOperation

DeleteInstanceOperation returns a new DeleteInstanceOperation from a given name. The name must be that of a previously created DeleteInstanceOperation, possibly from a different process.

func (*Client) DeleteIssue

DeleteIssue deletes an issue.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.DeleteIssueRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#DeleteIssueRequest.
	}
	op, err := c.DeleteIssue(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	err = op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
}

func (*Client) DeleteIssueComment

DeleteIssueComment deletes an issue comment.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.DeleteIssueCommentRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#DeleteIssueCommentRequest.
	}
	op, err := c.DeleteIssueComment(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	err = op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
}

func (*Client) DeleteIssueCommentOperation

func (c *Client) DeleteIssueCommentOperation(name string) *DeleteIssueCommentOperation

DeleteIssueCommentOperation returns a new DeleteIssueCommentOperation from a given name. The name must be that of a previously created DeleteIssueCommentOperation, possibly from a different process.

func (*Client) DeleteIssueOperation

func (c *Client) DeleteIssueOperation(name string) *DeleteIssueOperation

DeleteIssueOperation returns a new DeleteIssueOperation from a given name. The name must be that of a previously created DeleteIssueOperation, possibly from a different process.

func (*Client) DeleteOperation

func (c *Client) DeleteOperation(ctx context.Context, req *longrunningpb.DeleteOperationRequest, opts ...gax.CallOption) error

DeleteOperation is a utility method from google.longrunning.Operations.

Example

package main

import (
	"context"

	longrunningpb "cloud.google.com/go/longrunning/autogen/longrunningpb"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &longrunningpb.DeleteOperationRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/longrunning/autogen/longrunningpb#DeleteOperationRequest.
	}
	err = c.DeleteOperation(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
}

func (*Client) DeletePullRequestComment

DeletePullRequestComment deletes a pull request comment.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.DeletePullRequestCommentRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#DeletePullRequestCommentRequest.
	}
	op, err := c.DeletePullRequestComment(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	err = op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
}

func (*Client) DeletePullRequestCommentOperation

func (c *Client) DeletePullRequestCommentOperation(name string) *DeletePullRequestCommentOperation

DeletePullRequestCommentOperation returns a new DeletePullRequestCommentOperation from a given name. The name must be that of a previously created DeletePullRequestCommentOperation, possibly from a different process.

func (*Client) DeleteRepository

DeleteRepository deletes a Repository.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.DeleteRepositoryRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#DeleteRepositoryRequest.
	}
	op, err := c.DeleteRepository(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	err = op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
}

func (*Client) DeleteRepositoryOperation

func (c *Client) DeleteRepositoryOperation(name string) *DeleteRepositoryOperation

DeleteRepositoryOperation returns a new DeleteRepositoryOperation from a given name. The name must be that of a previously created DeleteRepositoryOperation, possibly from a different process.

func (*Client) FetchBlob

FetchBlob fetches a blob from a repository.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.FetchBlobRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#FetchBlobRequest.
	}
	resp, err := c.FetchBlob(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) FetchTree

FetchTree fetches a tree from a repository.

Examples

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
	"google.golang.org/api/iterator"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.FetchTreeRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#FetchTreeRequest.
	}
	it := c.FetchTree(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp

		// If you need to access the underlying RPC response,
		// you can do so by casting the `Response` as below.
		// Otherwise, remove this line. Only populated after
		// first call to Next(). Not safe for concurrent access.
		_ = it.Response.(*securesourcemanagerpb.FetchTreeResponse)
	}
}
all
package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.FetchTreeRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#FetchTreeRequest.
	}
	for resp, err := range c.FetchTree(ctx, req).All() {
		if err != nil {
			// TODO: Handle error and break/return/continue. Iteration will stop after any error.
		}
		// TODO: Use resp.
		_ = resp
	}
}

func (*Client) GetBranchRule

GetBranchRule getBranchRule gets a branch rule.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.GetBranchRuleRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#GetBranchRuleRequest.
	}
	resp, err := c.GetBranchRule(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) GetHook

GetHook gets metadata of a hook.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.GetHookRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#GetHookRequest.
	}
	resp, err := c.GetHook(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) GetIamPolicy

func (c *Client) GetIamPolicy(ctx context.Context, req *iampb.GetIamPolicyRequest, opts ...gax.CallOption) (*iampb.Policy, error)

GetIamPolicy gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.

Example

package main

import (
	"context"

	iampb "cloud.google.com/go/iam/apiv1/iampb"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &iampb.GetIamPolicyRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/iam/apiv1/iampb#GetIamPolicyRequest.
	}
	resp, err := c.GetIamPolicy(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) GetIamPolicyRepo

func (c *Client) GetIamPolicyRepo(ctx context.Context, req *iampb.GetIamPolicyRequest, opts ...gax.CallOption) (*iampb.Policy, error)

GetIamPolicyRepo get IAM policy for a repository.

Example

package main

import (
	"context"

	iampb "cloud.google.com/go/iam/apiv1/iampb"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &iampb.GetIamPolicyRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/iam/apiv1/iampb#GetIamPolicyRequest.
	}
	resp, err := c.GetIamPolicyRepo(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) GetInstance

GetInstance gets details of a single instance.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.GetInstanceRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#GetInstanceRequest.
	}
	resp, err := c.GetInstance(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) GetIssue

GetIssue gets an issue.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.GetIssueRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#GetIssueRequest.
	}
	resp, err := c.GetIssue(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) GetIssueComment

GetIssueComment gets an issue comment.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.GetIssueCommentRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#GetIssueCommentRequest.
	}
	resp, err := c.GetIssueComment(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) GetLocation

func (c *Client) GetLocation(ctx context.Context, req *locationpb.GetLocationRequest, opts ...gax.CallOption) (*locationpb.Location, error)

GetLocation gets information about a location.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	locationpb "google.golang.org/genproto/googleapis/cloud/location"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &locationpb.GetLocationRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/location#GetLocationRequest.
	}
	resp, err := c.GetLocation(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) GetOperation

GetOperation is a utility method from google.longrunning.Operations.

Example

package main

import (
	"context"

	longrunningpb "cloud.google.com/go/longrunning/autogen/longrunningpb"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &longrunningpb.GetOperationRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/longrunning/autogen/longrunningpb#GetOperationRequest.
	}
	resp, err := c.GetOperation(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) GetPullRequest

GetPullRequest gets a pull request.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.GetPullRequestRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#GetPullRequestRequest.
	}
	resp, err := c.GetPullRequest(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) GetPullRequestComment

GetPullRequestComment gets a pull request comment.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.GetPullRequestCommentRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#GetPullRequestCommentRequest.
	}
	resp, err := c.GetPullRequestComment(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) GetRepository

GetRepository gets metadata of a repository.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.GetRepositoryRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#GetRepositoryRequest.
	}
	resp, err := c.GetRepository(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) ListBranchRules

ListBranchRules listBranchRules lists branch rules in a given repository.

Examples

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
	"google.golang.org/api/iterator"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.ListBranchRulesRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#ListBranchRulesRequest.
	}
	it := c.ListBranchRules(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp

		// If you need to access the underlying RPC response,
		// you can do so by casting the `Response` as below.
		// Otherwise, remove this line. Only populated after
		// first call to Next(). Not safe for concurrent access.
		_ = it.Response.(*securesourcemanagerpb.ListBranchRulesResponse)
	}
}
all
package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.ListBranchRulesRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#ListBranchRulesRequest.
	}
	for resp, err := range c.ListBranchRules(ctx, req).All() {
		if err != nil {
			// TODO: Handle error and break/return/continue. Iteration will stop after any error.
		}
		// TODO: Use resp.
		_ = resp
	}
}

func (*Client) ListHooks

ListHooks lists hooks in a given repository.

Examples

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
	"google.golang.org/api/iterator"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.ListHooksRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#ListHooksRequest.
	}
	it := c.ListHooks(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp

		// If you need to access the underlying RPC response,
		// you can do so by casting the `Response` as below.
		// Otherwise, remove this line. Only populated after
		// first call to Next(). Not safe for concurrent access.
		_ = it.Response.(*securesourcemanagerpb.ListHooksResponse)
	}
}
all
package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.ListHooksRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#ListHooksRequest.
	}
	for resp, err := range c.ListHooks(ctx, req).All() {
		if err != nil {
			// TODO: Handle error and break/return/continue. Iteration will stop after any error.
		}
		// TODO: Use resp.
		_ = resp
	}
}

func (*Client) ListInstances

ListInstances lists Instances in a given project and location.

Examples

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
	"google.golang.org/api/iterator"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.ListInstancesRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#ListInstancesRequest.
	}
	it := c.ListInstances(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp

		// If you need to access the underlying RPC response,
		// you can do so by casting the `Response` as below.
		// Otherwise, remove this line. Only populated after
		// first call to Next(). Not safe for concurrent access.
		_ = it.Response.(*securesourcemanagerpb.ListInstancesResponse)
	}
}
all
package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.ListInstancesRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#ListInstancesRequest.
	}
	for resp, err := range c.ListInstances(ctx, req).All() {
		if err != nil {
			// TODO: Handle error and break/return/continue. Iteration will stop after any error.
		}
		// TODO: Use resp.
		_ = resp
	}
}

func (*Client) ListIssueComments

ListIssueComments lists comments in an issue.

Examples

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
	"google.golang.org/api/iterator"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.ListIssueCommentsRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#ListIssueCommentsRequest.
	}
	it := c.ListIssueComments(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp

		// If you need to access the underlying RPC response,
		// you can do so by casting the `Response` as below.
		// Otherwise, remove this line. Only populated after
		// first call to Next(). Not safe for concurrent access.
		_ = it.Response.(*securesourcemanagerpb.ListIssueCommentsResponse)
	}
}
all
package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.ListIssueCommentsRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#ListIssueCommentsRequest.
	}
	for resp, err := range c.ListIssueComments(ctx, req).All() {
		if err != nil {
			// TODO: Handle error and break/return/continue. Iteration will stop after any error.
		}
		// TODO: Use resp.
		_ = resp
	}
}

func (*Client) ListIssues

ListIssues lists issues in a repository.

Examples

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
	"google.golang.org/api/iterator"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.ListIssuesRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#ListIssuesRequest.
	}
	it := c.ListIssues(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp

		// If you need to access the underlying RPC response,
		// you can do so by casting the `Response` as below.
		// Otherwise, remove this line. Only populated after
		// first call to Next(). Not safe for concurrent access.
		_ = it.Response.(*securesourcemanagerpb.ListIssuesResponse)
	}
}
all
package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.ListIssuesRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#ListIssuesRequest.
	}
	for resp, err := range c.ListIssues(ctx, req).All() {
		if err != nil {
			// TODO: Handle error and break/return/continue. Iteration will stop after any error.
		}
		// TODO: Use resp.
		_ = resp
	}
}

func (*Client) ListLocations

func (c *Client) ListLocations(ctx context.Context, req *locationpb.ListLocationsRequest, opts ...gax.CallOption) *LocationIterator

ListLocations lists information about the supported locations for this service.

Examples

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"
	"google.golang.org/api/iterator"

	locationpb "google.golang.org/genproto/googleapis/cloud/location"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &locationpb.ListLocationsRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/location#ListLocationsRequest.
	}
	it := c.ListLocations(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp

		// If you need to access the underlying RPC response,
		// you can do so by casting the `Response` as below.
		// Otherwise, remove this line. Only populated after
		// first call to Next(). Not safe for concurrent access.
		_ = it.Response.(*locationpb.ListLocationsResponse)
	}
}
all
package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	locationpb "google.golang.org/genproto/googleapis/cloud/location"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &locationpb.ListLocationsRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/location#ListLocationsRequest.
	}
	for resp, err := range c.ListLocations(ctx, req).All() {
		if err != nil {
			// TODO: Handle error and break/return/continue. Iteration will stop after any error.
		}
		// TODO: Use resp.
		_ = resp
	}
}

func (*Client) ListOperations

ListOperations is a utility method from google.longrunning.Operations.

Examples

package main

import (
	"context"

	longrunningpb "cloud.google.com/go/longrunning/autogen/longrunningpb"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"
	"google.golang.org/api/iterator"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &longrunningpb.ListOperationsRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/longrunning/autogen/longrunningpb#ListOperationsRequest.
	}
	it := c.ListOperations(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp

		// If you need to access the underlying RPC response,
		// you can do so by casting the `Response` as below.
		// Otherwise, remove this line. Only populated after
		// first call to Next(). Not safe for concurrent access.
		_ = it.Response.(*longrunningpb.ListOperationsResponse)
	}
}
all
package main

import (
	"context"

	longrunningpb "cloud.google.com/go/longrunning/autogen/longrunningpb"
	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &longrunningpb.ListOperationsRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/longrunning/autogen/longrunningpb#ListOperationsRequest.
	}
	for resp, err := range c.ListOperations(ctx, req).All() {
		if err != nil {
			// TODO: Handle error and break/return/continue. Iteration will stop after any error.
		}
		// TODO: Use resp.
		_ = resp
	}
}

func (*Client) ListPullRequestComments

ListPullRequestComments lists pull request comments.

Examples

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
	"google.golang.org/api/iterator"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.ListPullRequestCommentsRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#ListPullRequestCommentsRequest.
	}
	it := c.ListPullRequestComments(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp

		// If you need to access the underlying RPC response,
		// you can do so by casting the `Response` as below.
		// Otherwise, remove this line. Only populated after
		// first call to Next(). Not safe for concurrent access.
		_ = it.Response.(*securesourcemanagerpb.ListPullRequestCommentsResponse)
	}
}
all
package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.ListPullRequestCommentsRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#ListPullRequestCommentsRequest.
	}
	for resp, err := range c.ListPullRequestComments(ctx, req).All() {
		if err != nil {
			// TODO: Handle error and break/return/continue. Iteration will stop after any error.
		}
		// TODO: Use resp.
		_ = resp
	}
}

func (*Client) ListPullRequestFileDiffs

ListPullRequestFileDiffs lists a pull request’s file diffs.

Examples

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
	"google.golang.org/api/iterator"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.ListPullRequestFileDiffsRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#ListPullRequestFileDiffsRequest.
	}
	it := c.ListPullRequestFileDiffs(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp

		// If you need to access the underlying RPC response,
		// you can do so by casting the `Response` as below.
		// Otherwise, remove this line. Only populated after
		// first call to Next(). Not safe for concurrent access.
		_ = it.Response.(*securesourcemanagerpb.ListPullRequestFileDiffsResponse)
	}
}
all
package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.ListPullRequestFileDiffsRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#ListPullRequestFileDiffsRequest.
	}
	for resp, err := range c.ListPullRequestFileDiffs(ctx, req).All() {
		if err != nil {
			// TODO: Handle error and break/return/continue. Iteration will stop after any error.
		}
		// TODO: Use resp.
		_ = resp
	}
}

func (*Client) ListPullRequests

ListPullRequests lists pull requests in a repository.

Examples

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
	"google.golang.org/api/iterator"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.ListPullRequestsRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#ListPullRequestsRequest.
	}
	it := c.ListPullRequests(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp

		// If you need to access the underlying RPC response,
		// you can do so by casting the `Response` as below.
		// Otherwise, remove this line. Only populated after
		// first call to Next(). Not safe for concurrent access.
		_ = it.Response.(*securesourcemanagerpb.ListPullRequestsResponse)
	}
}
all
package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.ListPullRequestsRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#ListPullRequestsRequest.
	}
	for resp, err := range c.ListPullRequests(ctx, req).All() {
		if err != nil {
			// TODO: Handle error and break/return/continue. Iteration will stop after any error.
		}
		// TODO: Use resp.
		_ = resp
	}
}

func (*Client) ListRepositories

ListRepositories lists Repositories in a given project and location.

The instance field is required in the query parameter for requests using the securesourcemanager.googleapis.com (at http://securesourcemanager.googleapis.com) endpoint.

Examples

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
	"google.golang.org/api/iterator"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.ListRepositoriesRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#ListRepositoriesRequest.
	}
	it := c.ListRepositories(ctx, req)
	for {
		resp, err := it.Next()
		if err == iterator.Done {
			break
		}
		if err != nil {
			// TODO: Handle error.
		}
		// TODO: Use resp.
		_ = resp

		// If you need to access the underlying RPC response,
		// you can do so by casting the `Response` as below.
		// Otherwise, remove this line. Only populated after
		// first call to Next(). Not safe for concurrent access.
		_ = it.Response.(*securesourcemanagerpb.ListRepositoriesResponse)
	}
}
all
package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.ListRepositoriesRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#ListRepositoriesRequest.
	}
	for resp, err := range c.ListRepositories(ctx, req).All() {
		if err != nil {
			// TODO: Handle error and break/return/continue. Iteration will stop after any error.
		}
		// TODO: Use resp.
		_ = resp
	}
}

func (*Client) MergePullRequest

MergePullRequest merges a pull request.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.MergePullRequestRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#MergePullRequestRequest.
	}
	op, err := c.MergePullRequest(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) MergePullRequestOperation

func (c *Client) MergePullRequestOperation(name string) *MergePullRequestOperation

MergePullRequestOperation returns a new MergePullRequestOperation from a given name. The name must be that of a previously created MergePullRequestOperation, possibly from a different process.

func (*Client) OpenIssue

OpenIssue opens an issue.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.OpenIssueRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#OpenIssueRequest.
	}
	op, err := c.OpenIssue(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) OpenIssueOperation

func (c *Client) OpenIssueOperation(name string) *OpenIssueOperation

OpenIssueOperation returns a new OpenIssueOperation from a given name. The name must be that of a previously created OpenIssueOperation, possibly from a different process.

func (*Client) OpenPullRequest

OpenPullRequest opens a pull request.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.OpenPullRequestRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#OpenPullRequestRequest.
	}
	op, err := c.OpenPullRequest(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) OpenPullRequestOperation

func (c *Client) OpenPullRequestOperation(name string) *OpenPullRequestOperation

OpenPullRequestOperation returns a new OpenPullRequestOperation from a given name. The name must be that of a previously created OpenPullRequestOperation, possibly from a different process.

func (*Client) ResolvePullRequestComments

ResolvePullRequestComments resolves pull request comments.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.ResolvePullRequestCommentsRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#ResolvePullRequestCommentsRequest.
	}
	op, err := c.ResolvePullRequestComments(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) ResolvePullRequestCommentsOperation

func (c *Client) ResolvePullRequestCommentsOperation(name string) *ResolvePullRequestCommentsOperation

ResolvePullRequestCommentsOperation returns a new ResolvePullRequestCommentsOperation from a given name. The name must be that of a previously created ResolvePullRequestCommentsOperation, possibly from a different process.

func (*Client) SetIamPolicy

func (c *Client) SetIamPolicy(ctx context.Context, req *iampb.SetIamPolicyRequest, opts ...gax.CallOption) (*iampb.Policy, error)

SetIamPolicy sets the access control policy on the specified resource. Replaces any existing policy.

Can return NOT_FOUND, INVALID_ARGUMENT, and PERMISSION_DENIED errors.

Example

package main

import (
	"context"

	iampb "cloud.google.com/go/iam/apiv1/iampb"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &iampb.SetIamPolicyRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/iam/apiv1/iampb#SetIamPolicyRequest.
	}
	resp, err := c.SetIamPolicy(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) SetIamPolicyRepo

func (c *Client) SetIamPolicyRepo(ctx context.Context, req *iampb.SetIamPolicyRequest, opts ...gax.CallOption) (*iampb.Policy, error)

SetIamPolicyRepo set IAM policy on a repository.

Example

package main

import (
	"context"

	iampb "cloud.google.com/go/iam/apiv1/iampb"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &iampb.SetIamPolicyRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/iam/apiv1/iampb#SetIamPolicyRequest.
	}
	resp, err := c.SetIamPolicyRepo(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) TestIamPermissions

TestIamPermissions returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a NOT_FOUND error.

Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may “fail open” without warning.

Example

package main

import (
	"context"

	iampb "cloud.google.com/go/iam/apiv1/iampb"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &iampb.TestIamPermissionsRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/iam/apiv1/iampb#TestIamPermissionsRequest.
	}
	resp, err := c.TestIamPermissions(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) TestIamPermissionsRepo

func (c *Client) TestIamPermissionsRepo(ctx context.Context, req *iampb.TestIamPermissionsRequest, opts ...gax.CallOption) (*iampb.TestIamPermissionsResponse, error)

TestIamPermissionsRepo test IAM permissions on a repository. IAM permission checks are not required on this method.

Example

package main

import (
	"context"

	iampb "cloud.google.com/go/iam/apiv1/iampb"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &iampb.TestIamPermissionsRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/iam/apiv1/iampb#TestIamPermissionsRequest.
	}
	resp, err := c.TestIamPermissionsRepo(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) UnresolvePullRequestComments

UnresolvePullRequestComments unresolves pull request comment.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.UnresolvePullRequestCommentsRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#UnresolvePullRequestCommentsRequest.
	}
	op, err := c.UnresolvePullRequestComments(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) UnresolvePullRequestCommentsOperation

func (c *Client) UnresolvePullRequestCommentsOperation(name string) *UnresolvePullRequestCommentsOperation

UnresolvePullRequestCommentsOperation returns a new UnresolvePullRequestCommentsOperation from a given name. The name must be that of a previously created UnresolvePullRequestCommentsOperation, possibly from a different process.

func (*Client) UpdateBranchRule

UpdateBranchRule updateBranchRule updates a branch rule.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.UpdateBranchRuleRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#UpdateBranchRuleRequest.
	}
	op, err := c.UpdateBranchRule(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) UpdateBranchRuleOperation

func (c *Client) UpdateBranchRuleOperation(name string) *UpdateBranchRuleOperation

UpdateBranchRuleOperation returns a new UpdateBranchRuleOperation from a given name. The name must be that of a previously created UpdateBranchRuleOperation, possibly from a different process.

func (*Client) UpdateHook

UpdateHook updates the metadata of a hook.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.UpdateHookRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#UpdateHookRequest.
	}
	op, err := c.UpdateHook(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) UpdateHookOperation

func (c *Client) UpdateHookOperation(name string) *UpdateHookOperation

UpdateHookOperation returns a new UpdateHookOperation from a given name. The name must be that of a previously created UpdateHookOperation, possibly from a different process.

func (*Client) UpdateIssue

UpdateIssue updates a issue.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.UpdateIssueRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#UpdateIssueRequest.
	}
	op, err := c.UpdateIssue(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) UpdateIssueComment

UpdateIssueComment updates an issue comment.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.UpdateIssueCommentRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#UpdateIssueCommentRequest.
	}
	op, err := c.UpdateIssueComment(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) UpdateIssueCommentOperation

func (c *Client) UpdateIssueCommentOperation(name string) *UpdateIssueCommentOperation

UpdateIssueCommentOperation returns a new UpdateIssueCommentOperation from a given name. The name must be that of a previously created UpdateIssueCommentOperation, possibly from a different process.

func (*Client) UpdateIssueOperation

func (c *Client) UpdateIssueOperation(name string) *UpdateIssueOperation

UpdateIssueOperation returns a new UpdateIssueOperation from a given name. The name must be that of a previously created UpdateIssueOperation, possibly from a different process.

func (*Client) UpdatePullRequest

UpdatePullRequest updates a pull request.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.UpdatePullRequestRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#UpdatePullRequestRequest.
	}
	op, err := c.UpdatePullRequest(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) UpdatePullRequestComment

UpdatePullRequestComment updates a pull request comment.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.UpdatePullRequestCommentRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#UpdatePullRequestCommentRequest.
	}
	op, err := c.UpdatePullRequestComment(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) UpdatePullRequestCommentOperation

func (c *Client) UpdatePullRequestCommentOperation(name string) *UpdatePullRequestCommentOperation

UpdatePullRequestCommentOperation returns a new UpdatePullRequestCommentOperation from a given name. The name must be that of a previously created UpdatePullRequestCommentOperation, possibly from a different process.

func (*Client) UpdatePullRequestOperation

func (c *Client) UpdatePullRequestOperation(name string) *UpdatePullRequestOperation

UpdatePullRequestOperation returns a new UpdatePullRequestOperation from a given name. The name must be that of a previously created UpdatePullRequestOperation, possibly from a different process.

func (*Client) UpdateRepository

UpdateRepository updates the metadata of a repository.

Example

package main

import (
	"context"

	securesourcemanager "cloud.google.com/go/securesourcemanager/apiv1"

	securesourcemanagerpb "cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb"
)

func main() {
	ctx := context.Background()
	// This snippet has been automatically generated and should be regarded as a code template only.
	// It will require modifications to work:
	// - It may require correct/in-range values for request initialization.
	// - It may require specifying regional endpoints when creating the service client as shown in:
	//   https://pkg.go.dev/cloud.google.com/go#hdr-Client_Options
	c, err := securesourcemanager.NewClient(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	defer c.Close()

	req := &securesourcemanagerpb.UpdateRepositoryRequest{
		// TODO: Fill request struct fields.
		// See https://pkg.go.dev/cloud.google.com/go/securesourcemanager/apiv1/securesourcemanagerpb#UpdateRepositoryRequest.
	}
	op, err := c.UpdateRepository(ctx, req)
	if err != nil {
		// TODO: Handle error.
	}

	resp, err := op.Wait(ctx)
	if err != nil {
		// TODO: Handle error.
	}
	// TODO: Use resp.
	_ = resp
}

func (*Client) UpdateRepositoryOperation

func (c *Client) UpdateRepositoryOperation(name string) *UpdateRepositoryOperation

UpdateRepositoryOperation returns a new UpdateRepositoryOperation from a given name. The name must be that of a previously created UpdateRepositoryOperation, possibly from a different process.

CloseIssueOperation

type CloseIssueOperation struct {
	// contains filtered or unexported fields
}

CloseIssueOperation manages a long-running operation from CloseIssue.

func (*CloseIssueOperation) Done

func (op *CloseIssueOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*CloseIssueOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*CloseIssueOperation) Name

func (op *CloseIssueOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*CloseIssueOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*CloseIssueOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

ClosePullRequestOperation

type ClosePullRequestOperation struct {
	// contains filtered or unexported fields
}

ClosePullRequestOperation manages a long-running operation from ClosePullRequest.

func (*ClosePullRequestOperation) Done

func (op *ClosePullRequestOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*ClosePullRequestOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*ClosePullRequestOperation) Name

func (op *ClosePullRequestOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*ClosePullRequestOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*ClosePullRequestOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

CreateBranchRuleOperation

type CreateBranchRuleOperation struct {
	// contains filtered or unexported fields
}

CreateBranchRuleOperation manages a long-running operation from CreateBranchRule.

func (*CreateBranchRuleOperation) Done

func (op *CreateBranchRuleOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*CreateBranchRuleOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*CreateBranchRuleOperation) Name

func (op *CreateBranchRuleOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*CreateBranchRuleOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*CreateBranchRuleOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

CreateHookOperation

type CreateHookOperation struct {
	// contains filtered or unexported fields
}

CreateHookOperation manages a long-running operation from CreateHook.

func (*CreateHookOperation) Done

func (op *CreateHookOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*CreateHookOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*CreateHookOperation) Name

func (op *CreateHookOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*CreateHookOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*CreateHookOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

CreateInstanceOperation

type CreateInstanceOperation struct {
	// contains filtered or unexported fields
}

CreateInstanceOperation manages a long-running operation from CreateInstance.

func (*CreateInstanceOperation) Done

func (op *CreateInstanceOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*CreateInstanceOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*CreateInstanceOperation) Name

func (op *CreateInstanceOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*CreateInstanceOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*CreateInstanceOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

CreateIssueCommentOperation

type CreateIssueCommentOperation struct {
	// contains filtered or unexported fields
}

CreateIssueCommentOperation manages a long-running operation from CreateIssueComment.

func (*CreateIssueCommentOperation) Done

func (op *CreateIssueCommentOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*CreateIssueCommentOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*CreateIssueCommentOperation) Name

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*CreateIssueCommentOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*CreateIssueCommentOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

CreateIssueOperation

type CreateIssueOperation struct {
	// contains filtered or unexported fields
}

CreateIssueOperation manages a long-running operation from CreateIssue.

func (*CreateIssueOperation) Done

func (op *CreateIssueOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*CreateIssueOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*CreateIssueOperation) Name

func (op *CreateIssueOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*CreateIssueOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*CreateIssueOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

CreatePullRequestCommentOperation

type CreatePullRequestCommentOperation struct {
	// contains filtered or unexported fields
}

CreatePullRequestCommentOperation manages a long-running operation from CreatePullRequestComment.

func (*CreatePullRequestCommentOperation) Done

Done reports whether the long-running operation has completed.

func (*CreatePullRequestCommentOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*CreatePullRequestCommentOperation) Name

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*CreatePullRequestCommentOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*CreatePullRequestCommentOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

CreatePullRequestOperation

type CreatePullRequestOperation struct {
	// contains filtered or unexported fields
}

CreatePullRequestOperation manages a long-running operation from CreatePullRequest.

func (*CreatePullRequestOperation) Done

func (op *CreatePullRequestOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*CreatePullRequestOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*CreatePullRequestOperation) Name

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*CreatePullRequestOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*CreatePullRequestOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

CreateRepositoryOperation

type CreateRepositoryOperation struct {
	// contains filtered or unexported fields
}

CreateRepositoryOperation manages a long-running operation from CreateRepository.

func (*CreateRepositoryOperation) Done

func (op *CreateRepositoryOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*CreateRepositoryOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*CreateRepositoryOperation) Name

func (op *CreateRepositoryOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*CreateRepositoryOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*CreateRepositoryOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

DeleteBranchRuleOperation

type DeleteBranchRuleOperation struct {
	// contains filtered or unexported fields
}

DeleteBranchRuleOperation manages a long-running operation from DeleteBranchRule.

func (*DeleteBranchRuleOperation) Done

func (op *DeleteBranchRuleOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*DeleteBranchRuleOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*DeleteBranchRuleOperation) Name

func (op *DeleteBranchRuleOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*DeleteBranchRuleOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*DeleteBranchRuleOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

DeleteHookOperation

type DeleteHookOperation struct {
	// contains filtered or unexported fields
}

DeleteHookOperation manages a long-running operation from DeleteHook.

func (*DeleteHookOperation) Done

func (op *DeleteHookOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*DeleteHookOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*DeleteHookOperation) Name

func (op *DeleteHookOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*DeleteHookOperation) Poll

func (op *DeleteHookOperation) Poll(ctx context.Context, opts ...gax.CallOption) error

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*DeleteHookOperation) Wait

func (op *DeleteHookOperation) Wait(ctx context.Context, opts ...gax.CallOption) error

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

DeleteInstanceOperation

type DeleteInstanceOperation struct {
	// contains filtered or unexported fields
}

DeleteInstanceOperation manages a long-running operation from DeleteInstance.

func (*DeleteInstanceOperation) Done

func (op *DeleteInstanceOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*DeleteInstanceOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*DeleteInstanceOperation) Name

func (op *DeleteInstanceOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*DeleteInstanceOperation) Poll

func (op *DeleteInstanceOperation) Poll(ctx context.Context, opts ...gax.CallOption) error

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*DeleteInstanceOperation) Wait

func (op *DeleteInstanceOperation) Wait(ctx context.Context, opts ...gax.CallOption) error

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

DeleteIssueCommentOperation

type DeleteIssueCommentOperation struct {
	// contains filtered or unexported fields
}

DeleteIssueCommentOperation manages a long-running operation from DeleteIssueComment.

func (*DeleteIssueCommentOperation) Done

func (op *DeleteIssueCommentOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*DeleteIssueCommentOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*DeleteIssueCommentOperation) Name

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*DeleteIssueCommentOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*DeleteIssueCommentOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

DeleteIssueOperation

type DeleteIssueOperation struct {
	// contains filtered or unexported fields
}

DeleteIssueOperation manages a long-running operation from DeleteIssue.

func (*DeleteIssueOperation) Done

func (op *DeleteIssueOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*DeleteIssueOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*DeleteIssueOperation) Name

func (op *DeleteIssueOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*DeleteIssueOperation) Poll

func (op *DeleteIssueOperation) Poll(ctx context.Context, opts ...gax.CallOption) error

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*DeleteIssueOperation) Wait

func (op *DeleteIssueOperation) Wait(ctx context.Context, opts ...gax.CallOption) error

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

DeletePullRequestCommentOperation

type DeletePullRequestCommentOperation struct {
	// contains filtered or unexported fields
}

DeletePullRequestCommentOperation manages a long-running operation from DeletePullRequestComment.

func (*DeletePullRequestCommentOperation) Done

Done reports whether the long-running operation has completed.

func (*DeletePullRequestCommentOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*DeletePullRequestCommentOperation) Name

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*DeletePullRequestCommentOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*DeletePullRequestCommentOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

DeleteRepositoryOperation

type DeleteRepositoryOperation struct {
	// contains filtered or unexported fields
}

DeleteRepositoryOperation manages a long-running operation from DeleteRepository.

func (*DeleteRepositoryOperation) Done

func (op *DeleteRepositoryOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*DeleteRepositoryOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*DeleteRepositoryOperation) Name

func (op *DeleteRepositoryOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*DeleteRepositoryOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*DeleteRepositoryOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

FileDiffIterator

type FileDiffIterator struct {

	// Response is the raw response for the current page.
	// It must be cast to the RPC response type.
	// Calling Next() or InternalFetch() updates this value.
	Response interface{}

	// InternalFetch is for use by the Google Cloud Libraries only.
	// It is not part of the stable interface of this package.
	//
	// InternalFetch returns results from a single call to the underlying RPC.
	// The number of results is no greater than pageSize.
	// If there are no more results, nextPageToken is empty and err is nil.
	InternalFetch func(pageSize int, pageToken string) (results []*securesourcemanagerpb.FileDiff, nextPageToken string, err error)
	// contains filtered or unexported fields
}

FileDiffIterator manages a stream of *securesourcemanagerpb.FileDiff.

func (*FileDiffIterator) All

func (it *FileDiffIterator) All() iter.Seq2[*securesourcemanagerpb.FileDiff, error]

All returns an iterator. If an error is returned by the iterator, the iterator will stop after that iteration.

func (*FileDiffIterator) Next

Next returns the next result. Its second return value is iterator.Done if there are no more results. Once Next returns Done, all subsequent calls will return Done.

func (*FileDiffIterator) PageInfo

func (it *FileDiffIterator) PageInfo() *iterator.PageInfo

PageInfo supports pagination. See the [google.golang.org/api/iterator] package for details.

HookIterator

type HookIterator struct {

	// Response is the raw response for the current page.
	// It must be cast to the RPC response type.
	// Calling Next() or InternalFetch() updates this value.
	Response interface{}

	// InternalFetch is for use by the Google Cloud Libraries only.
	// It is not part of the stable interface of this package.
	//
	// InternalFetch returns results from a single call to the underlying RPC.
	// The number of results is no greater than pageSize.
	// If there are no more results, nextPageToken is empty and err is nil.
	InternalFetch func(pageSize int, pageToken string) (results []*securesourcemanagerpb.Hook, nextPageToken string, err error)
	// contains filtered or unexported fields
}

HookIterator manages a stream of *securesourcemanagerpb.Hook.

func (*HookIterator) All

func (it *HookIterator) All() iter.Seq2[*securesourcemanagerpb.Hook, error]

All returns an iterator. If an error is returned by the iterator, the iterator will stop after that iteration.

func (*HookIterator) Next

Next returns the next result. Its second return value is iterator.Done if there are no more results. Once Next returns Done, all subsequent calls will return Done.

func (*HookIterator) PageInfo

func (it *HookIterator) PageInfo() *iterator.PageInfo

PageInfo supports pagination. See the [google.golang.org/api/iterator] package for details.

InstanceIterator

type InstanceIterator struct {

	// Response is the raw response for the current page.
	// It must be cast to the RPC response type.
	// Calling Next() or InternalFetch() updates this value.
	Response interface{}

	// InternalFetch is for use by the Google Cloud Libraries only.
	// It is not part of the stable interface of this package.
	//
	// InternalFetch returns results from a single call to the underlying RPC.
	// The number of results is no greater than pageSize.
	// If there are no more results, nextPageToken is empty and err is nil.
	InternalFetch func(pageSize int, pageToken string) (results []*securesourcemanagerpb.Instance, nextPageToken string, err error)
	// contains filtered or unexported fields
}

InstanceIterator manages a stream of *securesourcemanagerpb.Instance.

func (*InstanceIterator) All

func (it *InstanceIterator) All() iter.Seq2[*securesourcemanagerpb.Instance, error]

All returns an iterator. If an error is returned by the iterator, the iterator will stop after that iteration.

func (*InstanceIterator) Next

Next returns the next result. Its second return value is iterator.Done if there are no more results. Once Next returns Done, all subsequent calls will return Done.

func (*InstanceIterator) PageInfo

func (it *InstanceIterator) PageInfo() *iterator.PageInfo

PageInfo supports pagination. See the [google.golang.org/api/iterator] package for details.

IssueCommentIterator

type IssueCommentIterator struct {

	// Response is the raw response for the current page.
	// It must be cast to the RPC response type.
	// Calling Next() or InternalFetch() updates this value.
	Response interface{}

	// InternalFetch is for use by the Google Cloud Libraries only.
	// It is not part of the stable interface of this package.
	//
	// InternalFetch returns results from a single call to the underlying RPC.
	// The number of results is no greater than pageSize.
	// If there are no more results, nextPageToken is empty and err is nil.
	InternalFetch func(pageSize int, pageToken string) (results []*securesourcemanagerpb.IssueComment, nextPageToken string, err error)
	// contains filtered or unexported fields
}

IssueCommentIterator manages a stream of *securesourcemanagerpb.IssueComment.

func (*IssueCommentIterator) All

func (it *IssueCommentIterator) All() iter.Seq2[*securesourcemanagerpb.IssueComment, error]

All returns an iterator. If an error is returned by the iterator, the iterator will stop after that iteration.

func (*IssueCommentIterator) Next

Next returns the next result. Its second return value is iterator.Done if there are no more results. Once Next returns Done, all subsequent calls will return Done.

func (*IssueCommentIterator) PageInfo

func (it *IssueCommentIterator) PageInfo() *iterator.PageInfo

PageInfo supports pagination. See the [google.golang.org/api/iterator] package for details.

IssueIterator

type IssueIterator struct {

	// Response is the raw response for the current page.
	// It must be cast to the RPC response type.
	// Calling Next() or InternalFetch() updates this value.
	Response interface{}

	// InternalFetch is for use by the Google Cloud Libraries only.
	// It is not part of the stable interface of this package.
	//
	// InternalFetch returns results from a single call to the underlying RPC.
	// The number of results is no greater than pageSize.
	// If there are no more results, nextPageToken is empty and err is nil.
	InternalFetch func(pageSize int, pageToken string) (results []*securesourcemanagerpb.Issue, nextPageToken string, err error)
	// contains filtered or unexported fields
}

IssueIterator manages a stream of *securesourcemanagerpb.Issue.

func (*IssueIterator) All

func (it *IssueIterator) All() iter.Seq2[*securesourcemanagerpb.Issue, error]

All returns an iterator. If an error is returned by the iterator, the iterator will stop after that iteration.

func (*IssueIterator) Next

Next returns the next result. Its second return value is iterator.Done if there are no more results. Once Next returns Done, all subsequent calls will return Done.

func (*IssueIterator) PageInfo

func (it *IssueIterator) PageInfo() *iterator.PageInfo

PageInfo supports pagination. See the [google.golang.org/api/iterator] package for details.

LocationIterator

type LocationIterator struct {

	// Response is the raw response for the current page.
	// It must be cast to the RPC response type.
	// Calling Next() or InternalFetch() updates this value.
	Response interface{}

	// InternalFetch is for use by the Google Cloud Libraries only.
	// It is not part of the stable interface of this package.
	//
	// InternalFetch returns results from a single call to the underlying RPC.
	// The number of results is no greater than pageSize.
	// If there are no more results, nextPageToken is empty and err is nil.
	InternalFetch func(pageSize int, pageToken string) (results []*locationpb.Location, nextPageToken string, err error)
	// contains filtered or unexported fields
}

LocationIterator manages a stream of *locationpb.Location.

func (*LocationIterator) All

func (it *LocationIterator) All() iter.Seq2[*locationpb.Location, error]

All returns an iterator. If an error is returned by the iterator, the iterator will stop after that iteration.

func (*LocationIterator) Next

func (it *LocationIterator) Next() (*locationpb.Location, error)

Next returns the next result. Its second return value is iterator.Done if there are no more results. Once Next returns Done, all subsequent calls will return Done.

func (*LocationIterator) PageInfo

func (it *LocationIterator) PageInfo() *iterator.PageInfo

PageInfo supports pagination. See the [google.golang.org/api/iterator] package for details.

MergePullRequestOperation

type MergePullRequestOperation struct {
	// contains filtered or unexported fields
}

MergePullRequestOperation manages a long-running operation from MergePullRequest.

func (*MergePullRequestOperation) Done

func (op *MergePullRequestOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*MergePullRequestOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*MergePullRequestOperation) Name

func (op *MergePullRequestOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*MergePullRequestOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*MergePullRequestOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

OpenIssueOperation

type OpenIssueOperation struct {
	// contains filtered or unexported fields
}

OpenIssueOperation manages a long-running operation from OpenIssue.

func (*OpenIssueOperation) Done

func (op *OpenIssueOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*OpenIssueOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*OpenIssueOperation) Name

func (op *OpenIssueOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*OpenIssueOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*OpenIssueOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

OpenPullRequestOperation

type OpenPullRequestOperation struct {
	// contains filtered or unexported fields
}

OpenPullRequestOperation manages a long-running operation from OpenPullRequest.

func (*OpenPullRequestOperation) Done

func (op *OpenPullRequestOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*OpenPullRequestOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*OpenPullRequestOperation) Name

func (op *OpenPullRequestOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*OpenPullRequestOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*OpenPullRequestOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

OperationIterator

type OperationIterator struct {

	// Response is the raw response for the current page.
	// It must be cast to the RPC response type.
	// Calling Next() or InternalFetch() updates this value.
	Response interface{}

	// InternalFetch is for use by the Google Cloud Libraries only.
	// It is not part of the stable interface of this package.
	//
	// InternalFetch returns results from a single call to the underlying RPC.
	// The number of results is no greater than pageSize.
	// If there are no more results, nextPageToken is empty and err is nil.
	InternalFetch func(pageSize int, pageToken string) (results []*longrunningpb.Operation, nextPageToken string, err error)
	// contains filtered or unexported fields
}

OperationIterator manages a stream of *longrunningpb.Operation.

func (*OperationIterator) All

func (it *OperationIterator) All() iter.Seq2[*longrunningpb.Operation, error]

All returns an iterator. If an error is returned by the iterator, the iterator will stop after that iteration.

func (*OperationIterator) Next

Next returns the next result. Its second return value is iterator.Done if there are no more results. Once Next returns Done, all subsequent calls will return Done.

func (*OperationIterator) PageInfo

func (it *OperationIterator) PageInfo() *iterator.PageInfo

PageInfo supports pagination. See the [google.golang.org/api/iterator] package for details.

PullRequestCommentIterator

type PullRequestCommentIterator struct {

	// Response is the raw response for the current page.
	// It must be cast to the RPC response type.
	// Calling Next() or InternalFetch() updates this value.
	Response interface{}

	// InternalFetch is for use by the Google Cloud Libraries only.
	// It is not part of the stable interface of this package.
	//
	// InternalFetch returns results from a single call to the underlying RPC.
	// The number of results is no greater than pageSize.
	// If there are no more results, nextPageToken is empty and err is nil.
	InternalFetch func(pageSize int, pageToken string) (results []*securesourcemanagerpb.PullRequestComment, nextPageToken string, err error)
	// contains filtered or unexported fields
}

PullRequestCommentIterator manages a stream of *securesourcemanagerpb.PullRequestComment.

func (*PullRequestCommentIterator) All

func (it *PullRequestCommentIterator) All() iter.Seq2[*securesourcemanagerpb.PullRequestComment, error]

All returns an iterator. If an error is returned by the iterator, the iterator will stop after that iteration.

func (*PullRequestCommentIterator) Next

Next returns the next result. Its second return value is iterator.Done if there are no more results. Once Next returns Done, all subsequent calls will return Done.

func (*PullRequestCommentIterator) PageInfo

func (it *PullRequestCommentIterator) PageInfo() *iterator.PageInfo

PageInfo supports pagination. See the [google.golang.org/api/iterator] package for details.

PullRequestIterator

type PullRequestIterator struct {

	// Response is the raw response for the current page.
	// It must be cast to the RPC response type.
	// Calling Next() or InternalFetch() updates this value.
	Response interface{}

	// InternalFetch is for use by the Google Cloud Libraries only.
	// It is not part of the stable interface of this package.
	//
	// InternalFetch returns results from a single call to the underlying RPC.
	// The number of results is no greater than pageSize.
	// If there are no more results, nextPageToken is empty and err is nil.
	InternalFetch func(pageSize int, pageToken string) (results []*securesourcemanagerpb.PullRequest, nextPageToken string, err error)
	// contains filtered or unexported fields
}

PullRequestIterator manages a stream of *securesourcemanagerpb.PullRequest.

func (*PullRequestIterator) All

func (it *PullRequestIterator) All() iter.Seq2[*securesourcemanagerpb.PullRequest, error]

All returns an iterator. If an error is returned by the iterator, the iterator will stop after that iteration.

func (*PullRequestIterator) Next

Next returns the next result. Its second return value is iterator.Done if there are no more results. Once Next returns Done, all subsequent calls will return Done.

func (*PullRequestIterator) PageInfo

func (it *PullRequestIterator) PageInfo() *iterator.PageInfo

PageInfo supports pagination. See the [google.golang.org/api/iterator] package for details.

RepositoryIterator

type RepositoryIterator struct {

	// Response is the raw response for the current page.
	// It must be cast to the RPC response type.
	// Calling Next() or InternalFetch() updates this value.
	Response interface{}

	// InternalFetch is for use by the Google Cloud Libraries only.
	// It is not part of the stable interface of this package.
	//
	// InternalFetch returns results from a single call to the underlying RPC.
	// The number of results is no greater than pageSize.
	// If there are no more results, nextPageToken is empty and err is nil.
	InternalFetch func(pageSize int, pageToken string) (results []*securesourcemanagerpb.Repository, nextPageToken string, err error)
	// contains filtered or unexported fields
}

RepositoryIterator manages a stream of *securesourcemanagerpb.Repository.

func (*RepositoryIterator) All

func (it *RepositoryIterator) All() iter.Seq2[*securesourcemanagerpb.Repository, error]

All returns an iterator. If an error is returned by the iterator, the iterator will stop after that iteration.

func (*RepositoryIterator) Next

Next returns the next result. Its second return value is iterator.Done if there are no more results. Once Next returns Done, all subsequent calls will return Done.

func (*RepositoryIterator) PageInfo

func (it *RepositoryIterator) PageInfo() *iterator.PageInfo

PageInfo supports pagination. See the [google.golang.org/api/iterator] package for details.

ResolvePullRequestCommentsOperation

type ResolvePullRequestCommentsOperation struct {
	// contains filtered or unexported fields
}

ResolvePullRequestCommentsOperation manages a long-running operation from ResolvePullRequestComments.

func (*ResolvePullRequestCommentsOperation) Done

Done reports whether the long-running operation has completed.

func (*ResolvePullRequestCommentsOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*ResolvePullRequestCommentsOperation) Name

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*ResolvePullRequestCommentsOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*ResolvePullRequestCommentsOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

TreeEntryIterator

type TreeEntryIterator struct {

	// Response is the raw response for the current page.
	// It must be cast to the RPC response type.
	// Calling Next() or InternalFetch() updates this value.
	Response interface{}

	// InternalFetch is for use by the Google Cloud Libraries only.
	// It is not part of the stable interface of this package.
	//
	// InternalFetch returns results from a single call to the underlying RPC.
	// The number of results is no greater than pageSize.
	// If there are no more results, nextPageToken is empty and err is nil.
	InternalFetch func(pageSize int, pageToken string) (results []*securesourcemanagerpb.TreeEntry, nextPageToken string, err error)
	// contains filtered or unexported fields
}

TreeEntryIterator manages a stream of *securesourcemanagerpb.TreeEntry.

func (*TreeEntryIterator) All

func (it *TreeEntryIterator) All() iter.Seq2[*securesourcemanagerpb.TreeEntry, error]

All returns an iterator. If an error is returned by the iterator, the iterator will stop after that iteration.

func (*TreeEntryIterator) Next

Next returns the next result. Its second return value is iterator.Done if there are no more results. Once Next returns Done, all subsequent calls will return Done.

func (*TreeEntryIterator) PageInfo

func (it *TreeEntryIterator) PageInfo() *iterator.PageInfo

PageInfo supports pagination. See the [google.golang.org/api/iterator] package for details.

UnresolvePullRequestCommentsOperation

type UnresolvePullRequestCommentsOperation struct {
	// contains filtered or unexported fields
}

UnresolvePullRequestCommentsOperation manages a long-running operation from UnresolvePullRequestComments.

func (*UnresolvePullRequestCommentsOperation) Done

Done reports whether the long-running operation has completed.

func (*UnresolvePullRequestCommentsOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*UnresolvePullRequestCommentsOperation) Name

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*UnresolvePullRequestCommentsOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*UnresolvePullRequestCommentsOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

UpdateBranchRuleOperation

type UpdateBranchRuleOperation struct {
	// contains filtered or unexported fields
}

UpdateBranchRuleOperation manages a long-running operation from UpdateBranchRule.

func (*UpdateBranchRuleOperation) Done

func (op *UpdateBranchRuleOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*UpdateBranchRuleOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*UpdateBranchRuleOperation) Name

func (op *UpdateBranchRuleOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*UpdateBranchRuleOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*UpdateBranchRuleOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

UpdateHookOperation

type UpdateHookOperation struct {
	// contains filtered or unexported fields
}

UpdateHookOperation manages a long-running operation from UpdateHook.

func (*UpdateHookOperation) Done

func (op *UpdateHookOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*UpdateHookOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*UpdateHookOperation) Name

func (op *UpdateHookOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*UpdateHookOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*UpdateHookOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

UpdateIssueCommentOperation

type UpdateIssueCommentOperation struct {
	// contains filtered or unexported fields
}

UpdateIssueCommentOperation manages a long-running operation from UpdateIssueComment.

func (*UpdateIssueCommentOperation) Done

func (op *UpdateIssueCommentOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*UpdateIssueCommentOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*UpdateIssueCommentOperation) Name

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*UpdateIssueCommentOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*UpdateIssueCommentOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

UpdateIssueOperation

type UpdateIssueOperation struct {
	// contains filtered or unexported fields
}

UpdateIssueOperation manages a long-running operation from UpdateIssue.

func (*UpdateIssueOperation) Done

func (op *UpdateIssueOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*UpdateIssueOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*UpdateIssueOperation) Name

func (op *UpdateIssueOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*UpdateIssueOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*UpdateIssueOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

UpdatePullRequestCommentOperation

type UpdatePullRequestCommentOperation struct {
	// contains filtered or unexported fields
}

UpdatePullRequestCommentOperation manages a long-running operation from UpdatePullRequestComment.

func (*UpdatePullRequestCommentOperation) Done

Done reports whether the long-running operation has completed.

func (*UpdatePullRequestCommentOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*UpdatePullRequestCommentOperation) Name

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*UpdatePullRequestCommentOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*UpdatePullRequestCommentOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

UpdatePullRequestOperation

type UpdatePullRequestOperation struct {
	// contains filtered or unexported fields
}

UpdatePullRequestOperation manages a long-running operation from UpdatePullRequest.

func (*UpdatePullRequestOperation) Done

func (op *UpdatePullRequestOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*UpdatePullRequestOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*UpdatePullRequestOperation) Name

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*UpdatePullRequestOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*UpdatePullRequestOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.

UpdateRepositoryOperation

type UpdateRepositoryOperation struct {
	// contains filtered or unexported fields
}

UpdateRepositoryOperation manages a long-running operation from UpdateRepository.

func (*UpdateRepositoryOperation) Done

func (op *UpdateRepositoryOperation) Done() bool

Done reports whether the long-running operation has completed.

func (*UpdateRepositoryOperation) Metadata

Metadata returns metadata associated with the long-running operation. Metadata itself does not contact the server, but Poll does. To get the latest metadata, call this method after a successful call to Poll. If the metadata is not available, the returned metadata and error are both nil.

func (*UpdateRepositoryOperation) Name

func (op *UpdateRepositoryOperation) Name() string

Name returns the name of the long-running operation. The name is assigned by the server and is unique within the service from which the operation is created.

func (*UpdateRepositoryOperation) Poll

Poll fetches the latest state of the long-running operation.

Poll also fetches the latest metadata, which can be retrieved by Metadata.

If Poll fails, the error is returned and op is unmodified. If Poll succeeds and the operation has completed with failure, the error is returned and op.Done will return true. If Poll succeeds and the operation has completed successfully, op.Done will return true, and the response of the operation is returned. If Poll succeeds and the operation has not completed, the returned response and error are both nil.

func (*UpdateRepositoryOperation) Wait

Wait blocks until the long-running operation is completed, returning the response and any errors encountered.

See documentation of Poll for error-handling information.