gcp

package
v1.35.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 25, 2024 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DisksDeleteCall added in v1.20.0

type DisksDeleteCall interface {
	// Do executes the delete call.
	Do(opts ...googleapi.CallOption) (*compute.Operation, error)
	// Context sets the context for the delete call.
	Context(context.Context) DisksDeleteCall
}

DisksDeleteCall is a delete call to the Disks service.

type DisksGetCall added in v1.20.0

type DisksGetCall interface {
	// Do executes the get call.
	Do(opts ...googleapi.CallOption) (*compute.Disk, error)
	// Context sets the context for the get call.
	Context(context.Context) DisksGetCall
}

DisksGetCall is a get call to the Disks service.

type DisksInsertCall added in v1.20.0

type DisksInsertCall interface {
	// Do executes the deletion call.
	Do(opts ...googleapi.CallOption) (*compute.Operation, error)
	// Context sets the context for the deletion call.
	Context(context.Context) DisksInsertCall
}

DisksInsertCall is a insert call to the Disks service.

type DisksService added in v1.20.0

type DisksService interface {
	// Get initiates a DisksServiceCall
	Get(projectID string, zone string, disk string) DisksGetCall
	// Delete initiates a DisksDeleteCall
	Delete(project string, zone string, disk string) DisksDeleteCall
	// Insert initiates a DisksServiceCall
	Insert(projectID string, zone string, disk *compute.Disk) DisksInsertCall
}

DisksService is the interface for the GCP Disks service.

type FirewallsDeleteCall

type FirewallsDeleteCall interface {
	// Do executes the deletion call.
	Do(opts ...googleapi.CallOption) (*compute.Operation, error)
	// Context sets the context for the deletion call.
	Context(context.Context) FirewallsDeleteCall
}

FirewallsDeleteCall is a delete call to the firewalls service.

type FirewallsGetCall added in v1.20.0

type FirewallsGetCall interface {
	// Do executes the get call.
	Do(opts ...googleapi.CallOption) (*compute.Firewall, error)

	// Context sets the context for get call.
	Context(context.Context) FirewallsGetCall
}

FirewallsGetCall is a get call to the firewalls service.

type FirewallsInsertCall added in v1.20.0

type FirewallsInsertCall interface {
	// Do executes the insert call.
	Do(opts ...googleapi.CallOption) (*compute.Operation, error)

	// Context sets the context for Insert call.
	Context(context.Context) FirewallsInsertCall
}

FirewallsInsertCall is a insert call to the firewalls service.

type FirewallsListCall

type FirewallsListCall interface {
	// Pages runs the given function on the paginated result of listing the firewalls.
	Pages(context.Context, func(*compute.FirewallList) error) error
}

FirewallsListCall is a list call to the firewalls service.

type FirewallsPatchCall added in v1.20.0

type FirewallsPatchCall interface {
	// Do executes the patch call.
	Do(opts ...googleapi.CallOption) (*compute.Operation, error)

	// Context sets the context for patch call.
	Context(context.Context) FirewallsPatchCall
}

FirewallsPatchCall is a patch call to the firewalls service.

type FirewallsService

type FirewallsService interface {
	// List initiates a FirewallsListCall.
	List(projectID string) FirewallsListCall
	// Delete initiates a FirewallsDeleteCall.
	Delete(projectID, firewall string) FirewallsDeleteCall
	// Get initiates a FirewallsGetCall.
	Get(projectID, firewall string) FirewallsGetCall
	// Insert initiates a FirewallsInsertCall.
	Insert(projectID string, rb *compute.Firewall) FirewallsInsertCall
	// Patch initiates a FirewallsPatchCall.
	Patch(projectID string, firewall string, rb *compute.Firewall) FirewallsPatchCall
}

FirewallsService is the interface for the GCP firewalls service.

type ImagesListCall added in v1.30.0

type ImagesListCall interface {
	// Do executes the image list call.
	Do(opts ...googleapi.CallOption) (*compute.ImageList, error)
	// Fields allows partial responses to be retrieved.
	Fields(s ...googleapi.Field) *compute.ImagesListCall
	// OrderBy sets the optional parameter "orderBy": Sorts list results by a certain order.
	OrderBy(orderBy string) *compute.ImagesListCall
}

ImagesListCall is a list call to the Image service.

type ImagesService added in v1.30.0

type ImagesService interface {
	// List initiates a ImagesListCall
	List(projectID string) ImagesListCall
}

ImagesService is the interface for the GCP Image service.

type InstancesDeleteCall added in v1.20.0

type InstancesDeleteCall interface {
	// Do executes the deletion call.
	Do(opts ...googleapi.CallOption) (*compute.Operation, error)
	// Context sets the context for the deletion call.
	Context(context.Context) InstancesDeleteCall
}

InstancesDeleteCall is a deletion call to the instances service.

type InstancesGetCall added in v1.20.0

type InstancesGetCall interface {
	// Do executes the get call.
	Do(opts ...googleapi.CallOption) (*compute.Instance, error)
	// Context sets the context for the deletion call.
	Context(context.Context) InstancesGetCall
}

InstancesGetCall is a get call to the instances service.

type InstancesInsertCall added in v1.20.0

type InstancesInsertCall interface {
	// Do executes the deletion call.
	Do(opts ...googleapi.CallOption) (*compute.Operation, error)
	// Context sets the context for the deletion call.
	Context(context.Context) InstancesInsertCall
}

InstancesInsertCall is a insert call to the instances service.

type InstancesService added in v1.20.0

type InstancesService interface {
	// Get initiates a InstancesGetCall
	Get(projectID string, zone string, instance string) InstancesGetCall
	// Delete initiates a InstancesDeleteCall
	Delete(projectID string, zone string, instance string) InstancesDeleteCall
	// Insert initiates a InstancesInsertCall
	Insert(projectID string, zone string, instance *compute.Instance) InstancesInsertCall
}

InstancesService is the interface for the GCP Instances service.

type Interface

type Interface interface {
	// Firewalls retrieves the GCP firewalls service.
	Firewalls() FirewallsService
	// Routes retrieves the GCP routes service.
	Routes() RoutesService
	// Instances retrieves the GCP instances Service
	Instances() InstancesService
	// Disks retrieves the GCP Disks Service
	Disks() DisksService
	// Regions retrieves the GCP Regions Service
	Regions() RegionsService
	// Images retrieves the GCP Images Service
	Images() ImagesService
}

Interface is the interface for the GCP client.

func New

func New(compute *compute.Service) Interface

New creates a new client backed by the given compute service.

func NewFromServiceAccount

func NewFromServiceAccount(ctx context.Context, serviceAccount []byte) (Interface, error)

NewFromServiceAccount creates a new client from the given service account.

type RegionsGetCall added in v1.20.0

type RegionsGetCall interface {
	// Do executes the get call.
	Do(opts ...googleapi.CallOption) (*compute.Region, error)
	// Context sets the context for the get call.
	Context(context.Context) RegionsGetCall
}

RegionsGetCall is a get call to the Region service.

type RegionsService added in v1.20.0

type RegionsService interface {
	// Get initiates a RegionsServiceCall
	Get(projectID string, region string) RegionsGetCall
}

RegionsService is the interface for the GCP Regions service.

type RoutesDeleteCall

type RoutesDeleteCall interface {
	// Do executes the deletion call.
	Do(opts ...googleapi.CallOption) (*compute.Operation, error)
	// Context sets the context for the deletion call.
	Context(context.Context) RoutesDeleteCall
}

RoutesDeleteCall is a delete call to the routes service.

type RoutesListCall

type RoutesListCall interface {
	// Pages runs the given function on the paginated result of listing the routes.
	Pages(context.Context, func(*compute.RouteList) error) error
}

RoutesListCall is a list call to the routes service.

type RoutesService

type RoutesService interface {
	// List initiates a RoutesListCall.
	List(projectID string) RoutesListCall
	// Delete initiates a RoutesDeleteCall.
	Delete(projectID, route string) RoutesDeleteCall
}

RoutesService is the interface for the GCP routes service.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL