Documentation ¶
Overview ¶
Package resourceviews provides access to the Resource Views API.
See https://developers.google.com/compute/
Usage example:
import "code.google.com/p/google-api-go-client/resourceviews/v1beta2" ... resourceviewsService, err := resourceviews.New(oauthHttpClient)
Index ¶
- Constants
- type Label
- type ListResourceResponseItem
- type ListResourceResponseItemEndpoints
- type Operation
- type OperationError
- type OperationErrorErrors
- type OperationList
- type OperationWarnings
- type OperationWarningsData
- type ResourceView
- type Service
- type ServiceEndpoint
- type ZoneOperationsGetCall
- type ZoneOperationsListCall
- func (c *ZoneOperationsListCall) Do() (*OperationList, error)
- func (c *ZoneOperationsListCall) Fields(s ...googleapi.Field) *ZoneOperationsListCall
- func (c *ZoneOperationsListCall) Filter(filter string) *ZoneOperationsListCall
- func (c *ZoneOperationsListCall) MaxResults(maxResults int64) *ZoneOperationsListCall
- func (c *ZoneOperationsListCall) PageToken(pageToken string) *ZoneOperationsListCall
- type ZoneOperationsService
- type ZoneViewsAddResourcesCall
- type ZoneViewsAddResourcesRequest
- type ZoneViewsDeleteCall
- type ZoneViewsGetCall
- type ZoneViewsGetServiceCall
- type ZoneViewsGetServiceResponse
- type ZoneViewsInsertCall
- type ZoneViewsList
- type ZoneViewsListCall
- type ZoneViewsListResourcesCall
- func (c *ZoneViewsListResourcesCall) Do() (*ZoneViewsListResourcesResponse, error)
- func (c *ZoneViewsListResourcesCall) Fields(s ...googleapi.Field) *ZoneViewsListResourcesCall
- func (c *ZoneViewsListResourcesCall) Format(format string) *ZoneViewsListResourcesCall
- func (c *ZoneViewsListResourcesCall) ListState(listState string) *ZoneViewsListResourcesCall
- func (c *ZoneViewsListResourcesCall) MaxResults(maxResults int64) *ZoneViewsListResourcesCall
- func (c *ZoneViewsListResourcesCall) PageToken(pageToken string) *ZoneViewsListResourcesCall
- func (c *ZoneViewsListResourcesCall) ServiceName(serviceName string) *ZoneViewsListResourcesCall
- type ZoneViewsListResourcesResponse
- type ZoneViewsRemoveResourcesCall
- type ZoneViewsRemoveResourcesRequest
- type ZoneViewsService
- func (r *ZoneViewsService) AddResources(project string, zone string, resourceView string, ...) *ZoneViewsAddResourcesCall
- func (r *ZoneViewsService) Delete(project string, zone string, resourceView string) *ZoneViewsDeleteCall
- func (r *ZoneViewsService) Get(project string, zone string, resourceView string) *ZoneViewsGetCall
- func (r *ZoneViewsService) GetService(project string, zone string, resourceView string) *ZoneViewsGetServiceCall
- func (r *ZoneViewsService) Insert(project string, zone string, resourceview *ResourceView) *ZoneViewsInsertCall
- func (r *ZoneViewsService) List(project string, zone string) *ZoneViewsListCall
- func (r *ZoneViewsService) ListResources(project string, zone string, resourceView string) *ZoneViewsListResourcesCall
- func (r *ZoneViewsService) RemoveResources(project string, zone string, resourceView string, ...) *ZoneViewsRemoveResourcesCall
- func (r *ZoneViewsService) SetService(project string, zone string, resourceView string, ...) *ZoneViewsSetServiceCall
- type ZoneViewsSetServiceCall
- type ZoneViewsSetServiceRequest
Constants ¶
const ( // View and manage your data across Google Cloud Platform services CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform" // View and manage your Google Compute Engine resources ComputeScope = "https://www.googleapis.com/auth/compute" // View your Google Compute Engine resources ComputeReadonlyScope = "https://www.googleapis.com/auth/compute.readonly" // View and manage your Google Cloud Platform management resources and // deployment status information NdevCloudmanScope = "https://www.googleapis.com/auth/ndev.cloudman" // View your Google Cloud Platform management resources and deployment // status information NdevCloudmanReadonlyScope = "https://www.googleapis.com/auth/ndev.cloudman.readonly" )
OAuth2 scopes used by this API.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ListResourceResponseItem ¶
type ListResourceResponseItem struct { // Endpoints: The list of service end points on the resource. Endpoints *ListResourceResponseItemEndpoints `json:"endpoints,omitempty"` // Resource: The full URL of the resource. Resource string `json:"resource,omitempty"` }
type ListResourceResponseItemEndpoints ¶
type ListResourceResponseItemEndpoints struct { }
type Operation ¶
type Operation struct { // ClientOperationId: [Output only] An optional identifier specified by // the client when the mutation was initiated. Must be unique for all // operation resources in the project. ClientOperationId string `json:"clientOperationId,omitempty"` // CreationTimestamp: [Output Only] The time that this operation was // requested, in RFC3339 text format. CreationTimestamp string `json:"creationTimestamp,omitempty"` // EndTime: [Output Only] The time that this operation was completed, in // RFC3339 text format. EndTime string `json:"endTime,omitempty"` // Error: [Output Only] If errors occurred during processing of this // operation, this field will be populated. Error *OperationError `json:"error,omitempty"` // HttpErrorMessage: [Output only] If operation fails, the HTTP error // message returned. HttpErrorMessage string `json:"httpErrorMessage,omitempty"` // HttpErrorStatusCode: [Output only] If operation fails, the HTTP error // status code returned. HttpErrorStatusCode int64 `json:"httpErrorStatusCode,omitempty"` // Id: [Output Only] Unique identifier for the resource, generated by // the server. Id uint64 `json:"id,omitempty,string"` // InsertTime: [Output Only] The time that this operation was requested, // in RFC3339 text format. InsertTime string `json:"insertTime,omitempty"` // Kind: [Output only] Type of the resource. Kind string `json:"kind,omitempty"` // Name: [Output Only] Name of the resource. Name string `json:"name,omitempty"` // OperationType: [Output only] Type of the operation. Operations // include insert, update, and delete. OperationType string `json:"operationType,omitempty"` // Progress: [Output only] An optional progress indicator that ranges // from 0 to 100. There is no requirement that this be linear or support // any granularity of operations. This should not be used to guess at // when the operation will be complete. This number should be // monotonically increasing as the operation progresses. Progress int64 `json:"progress,omitempty"` // Region: [Output Only] URL of the region where the operation resides. // Only available when performing regional operations. Region string `json:"region,omitempty"` // SelfLink: [Output Only] Server-defined fully-qualified URL for this // resource. SelfLink string `json:"selfLink,omitempty"` // StartTime: [Output Only] The time that this operation was started by // the server, in RFC3339 text format. StartTime string `json:"startTime,omitempty"` // Status: [Output Only] Status of the operation. Status string `json:"status,omitempty"` // StatusMessage: [Output Only] An optional textual description of the // current status of the operation. StatusMessage string `json:"statusMessage,omitempty"` // TargetId: [Output Only] Unique target ID which identifies a // particular incarnation of the target. TargetId uint64 `json:"targetId,omitempty,string"` // TargetLink: [Output only] URL of the resource the operation is // mutating. TargetLink string `json:"targetLink,omitempty"` // User: [Output Only] User who requested the operation, for example: // user@example.com. User string `json:"user,omitempty"` // Warnings: [Output Only] If there are issues with this operation, a // warning is returned. Warnings []*OperationWarnings `json:"warnings,omitempty"` // Zone: [Output Only] URL of the zone where the operation resides. Only // available when performing per-zone operations. Zone string `json:"zone,omitempty"` }
type OperationError ¶
type OperationError struct { // Errors: [Output Only] The array of errors encountered while // processing this operation. Errors []*OperationErrorErrors `json:"errors,omitempty"` }
type OperationErrorErrors ¶
type OperationErrorErrors struct { // Code: [Output Only] The error type identifier for this error. Code string `json:"code,omitempty"` // Location: [Output Only] Indicates the field in the request which // caused the error. This property is optional. Location string `json:"location,omitempty"` // Message: [Output Only] An optional, human-readable error message. Message string `json:"message,omitempty"` }
type OperationList ¶
type OperationList struct { // Id: Unique identifier for the resource; defined by the server (output // only). Id string `json:"id,omitempty"` // Items: The operation resources. Items []*Operation `json:"items,omitempty"` // Kind: Type of resource. Kind string `json:"kind,omitempty"` // NextPageToken: A token used to continue a truncated list request // (output only). NextPageToken string `json:"nextPageToken,omitempty"` // SelfLink: Server defined URL for this resource (output only). SelfLink string `json:"selfLink,omitempty"` }
type OperationWarnings ¶
type OperationWarnings struct { // Code: [Output only] The warning type identifier for this warning. Code string `json:"code,omitempty"` // Data: [Output only] Metadata for this warning in key:value format. Data []*OperationWarningsData `json:"data,omitempty"` // Message: [Output only] Optional human-readable details for this // warning. Message string `json:"message,omitempty"` }
type OperationWarningsData ¶
type ResourceView ¶
type ResourceView struct { // CreationTimestamp: The creation time of the resource view. CreationTimestamp string `json:"creationTimestamp,omitempty"` // Description: The detailed description of the resource view. Description string `json:"description,omitempty"` // Endpoints: Services endpoint information. Endpoints []*ServiceEndpoint `json:"endpoints,omitempty"` // Fingerprint: The fingerprint of the service endpoint information. Fingerprint string `json:"fingerprint,omitempty"` // Id: [Output Only] The ID of the resource view. Id string `json:"id,omitempty"` // Kind: Type of the resource. Kind string `json:"kind,omitempty"` // Labels: The labels for events. Labels []*Label `json:"labels,omitempty"` // Name: The name of the resource view. Name string `json:"name,omitempty"` // Network: The URL of a Compute Engine network to which the resources // in the view belong. Network string `json:"network,omitempty"` // Resources: A list of all resources in the resource view. Resources []string `json:"resources,omitempty"` // SelfLink: [Output Only] A self-link to the resource view. SelfLink string `json:"selfLink,omitempty"` // Size: The total number of resources in the resource view. Size int64 `json:"size,omitempty"` }
type Service ¶
type Service struct { BasePath string // API endpoint base URL ZoneOperations *ZoneOperationsService ZoneViews *ZoneViewsService // contains filtered or unexported fields }
type ServiceEndpoint ¶
type ZoneOperationsGetCall ¶
type ZoneOperationsGetCall struct {
// contains filtered or unexported fields
}
func (*ZoneOperationsGetCall) Do ¶
func (c *ZoneOperationsGetCall) Do() (*Operation, error)
func (*ZoneOperationsGetCall) Fields ¶
func (c *ZoneOperationsGetCall) Fields(s ...googleapi.Field) *ZoneOperationsGetCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
type ZoneOperationsListCall ¶
type ZoneOperationsListCall struct {
// contains filtered or unexported fields
}
func (*ZoneOperationsListCall) Do ¶
func (c *ZoneOperationsListCall) Do() (*OperationList, error)
func (*ZoneOperationsListCall) Fields ¶
func (c *ZoneOperationsListCall) Fields(s ...googleapi.Field) *ZoneOperationsListCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ZoneOperationsListCall) Filter ¶
func (c *ZoneOperationsListCall) Filter(filter string) *ZoneOperationsListCall
Filter sets the optional parameter "filter": Filter expression for filtering listed resources.
func (*ZoneOperationsListCall) MaxResults ¶
func (c *ZoneOperationsListCall) MaxResults(maxResults int64) *ZoneOperationsListCall
MaxResults sets the optional parameter "maxResults": Maximum count of results to be returned. Maximum value is 500 and default value is 500.
func (*ZoneOperationsListCall) PageToken ¶
func (c *ZoneOperationsListCall) PageToken(pageToken string) *ZoneOperationsListCall
PageToken sets the optional parameter "pageToken": Tag returned by a previous list request truncated by maxResults. Used to continue a previous list request.
type ZoneOperationsService ¶
type ZoneOperationsService struct {
// contains filtered or unexported fields
}
func NewZoneOperationsService ¶
func NewZoneOperationsService(s *Service) *ZoneOperationsService
func (*ZoneOperationsService) Get ¶
func (r *ZoneOperationsService) Get(project string, zone string, operation string) *ZoneOperationsGetCall
Get: Retrieves the specified zone-specific operation resource.
func (*ZoneOperationsService) List ¶
func (r *ZoneOperationsService) List(project string, zone string) *ZoneOperationsListCall
List: Retrieves the list of operation resources contained within the specified zone.
type ZoneViewsAddResourcesCall ¶
type ZoneViewsAddResourcesCall struct {
// contains filtered or unexported fields
}
func (*ZoneViewsAddResourcesCall) Do ¶
func (c *ZoneViewsAddResourcesCall) Do() (*Operation, error)
func (*ZoneViewsAddResourcesCall) Fields ¶
func (c *ZoneViewsAddResourcesCall) Fields(s ...googleapi.Field) *ZoneViewsAddResourcesCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
type ZoneViewsAddResourcesRequest ¶
type ZoneViewsAddResourcesRequest struct { // Resources: The list of resources to be added. Resources []string `json:"resources,omitempty"` }
type ZoneViewsDeleteCall ¶
type ZoneViewsDeleteCall struct {
// contains filtered or unexported fields
}
func (*ZoneViewsDeleteCall) Do ¶
func (c *ZoneViewsDeleteCall) Do() (*Operation, error)
func (*ZoneViewsDeleteCall) Fields ¶
func (c *ZoneViewsDeleteCall) Fields(s ...googleapi.Field) *ZoneViewsDeleteCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
type ZoneViewsGetCall ¶
type ZoneViewsGetCall struct {
// contains filtered or unexported fields
}
func (*ZoneViewsGetCall) Do ¶
func (c *ZoneViewsGetCall) Do() (*ResourceView, error)
func (*ZoneViewsGetCall) Fields ¶
func (c *ZoneViewsGetCall) Fields(s ...googleapi.Field) *ZoneViewsGetCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
type ZoneViewsGetServiceCall ¶
type ZoneViewsGetServiceCall struct {
// contains filtered or unexported fields
}
func (*ZoneViewsGetServiceCall) Do ¶
func (c *ZoneViewsGetServiceCall) Do() (*ZoneViewsGetServiceResponse, error)
func (*ZoneViewsGetServiceCall) Fields ¶
func (c *ZoneViewsGetServiceCall) Fields(s ...googleapi.Field) *ZoneViewsGetServiceCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ZoneViewsGetServiceCall) ResourceName ¶
func (c *ZoneViewsGetServiceCall) ResourceName(resourceName string) *ZoneViewsGetServiceCall
ResourceName sets the optional parameter "resourceName": The name of the resource if user wants to get the service information of the resource.
type ZoneViewsGetServiceResponse ¶
type ZoneViewsGetServiceResponse struct { // Endpoints: The service information. Endpoints []*ServiceEndpoint `json:"endpoints,omitempty"` // Fingerprint: The fingerprint of the service information. Fingerprint string `json:"fingerprint,omitempty"` }
type ZoneViewsInsertCall ¶
type ZoneViewsInsertCall struct {
// contains filtered or unexported fields
}
func (*ZoneViewsInsertCall) Do ¶
func (c *ZoneViewsInsertCall) Do() (*Operation, error)
func (*ZoneViewsInsertCall) Fields ¶
func (c *ZoneViewsInsertCall) Fields(s ...googleapi.Field) *ZoneViewsInsertCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
type ZoneViewsList ¶
type ZoneViewsList struct { // Items: The result that contains all resource views that meet the // criteria. Items []*ResourceView `json:"items,omitempty"` // Kind: Type of resource. Kind string `json:"kind,omitempty"` // NextPageToken: A token used for pagination. NextPageToken string `json:"nextPageToken,omitempty"` // SelfLink: Server defined URL for this resource (output only). SelfLink string `json:"selfLink,omitempty"` }
type ZoneViewsListCall ¶
type ZoneViewsListCall struct {
// contains filtered or unexported fields
}
func (*ZoneViewsListCall) Do ¶
func (c *ZoneViewsListCall) Do() (*ZoneViewsList, error)
func (*ZoneViewsListCall) Fields ¶
func (c *ZoneViewsListCall) Fields(s ...googleapi.Field) *ZoneViewsListCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ZoneViewsListCall) MaxResults ¶
func (c *ZoneViewsListCall) MaxResults(maxResults int64) *ZoneViewsListCall
MaxResults sets the optional parameter "maxResults": Maximum count of results to be returned. Acceptable values are 0 to 5000, inclusive. (Default: 5000)
func (*ZoneViewsListCall) PageToken ¶
func (c *ZoneViewsListCall) PageToken(pageToken string) *ZoneViewsListCall
PageToken sets the optional parameter "pageToken": Specifies a nextPageToken returned by a previous list request. This token can be used to request the next page of results from a previous list request.
type ZoneViewsListResourcesCall ¶
type ZoneViewsListResourcesCall struct {
// contains filtered or unexported fields
}
func (*ZoneViewsListResourcesCall) Do ¶
func (c *ZoneViewsListResourcesCall) Do() (*ZoneViewsListResourcesResponse, error)
func (*ZoneViewsListResourcesCall) Fields ¶
func (c *ZoneViewsListResourcesCall) Fields(s ...googleapi.Field) *ZoneViewsListResourcesCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ZoneViewsListResourcesCall) Format ¶
func (c *ZoneViewsListResourcesCall) Format(format string) *ZoneViewsListResourcesCall
Format sets the optional parameter "format": The requested format of the return value. It can be URL or URL_PORT. A JSON object will be included in the response based on the format. The default format is NONE, which results in no JSON in the response.
func (*ZoneViewsListResourcesCall) ListState ¶
func (c *ZoneViewsListResourcesCall) ListState(listState string) *ZoneViewsListResourcesCall
ListState sets the optional parameter "listState": The state of the instance to list. By default, it lists all instances.
func (*ZoneViewsListResourcesCall) MaxResults ¶
func (c *ZoneViewsListResourcesCall) MaxResults(maxResults int64) *ZoneViewsListResourcesCall
MaxResults sets the optional parameter "maxResults": Maximum count of results to be returned. Acceptable values are 0 to 5000, inclusive. (Default: 5000)
func (*ZoneViewsListResourcesCall) PageToken ¶
func (c *ZoneViewsListResourcesCall) PageToken(pageToken string) *ZoneViewsListResourcesCall
PageToken sets the optional parameter "pageToken": Specifies a nextPageToken returned by a previous list request. This token can be used to request the next page of results from a previous list request.
func (*ZoneViewsListResourcesCall) ServiceName ¶
func (c *ZoneViewsListResourcesCall) ServiceName(serviceName string) *ZoneViewsListResourcesCall
ServiceName sets the optional parameter "serviceName": The service name to return in the response. It is optional and if it is not set, all the service end points will be returned.
type ZoneViewsListResourcesResponse ¶
type ZoneViewsListResourcesResponse struct { // Items: The formatted JSON that is requested by the user. Items []*ListResourceResponseItem `json:"items,omitempty"` // Network: The URL of a Compute Engine network to which the resources // in the view belong. Network string `json:"network,omitempty"` // NextPageToken: A token used for pagination. NextPageToken string `json:"nextPageToken,omitempty"` }
type ZoneViewsRemoveResourcesCall ¶
type ZoneViewsRemoveResourcesCall struct {
// contains filtered or unexported fields
}
func (*ZoneViewsRemoveResourcesCall) Do ¶
func (c *ZoneViewsRemoveResourcesCall) Do() (*Operation, error)
func (*ZoneViewsRemoveResourcesCall) Fields ¶
func (c *ZoneViewsRemoveResourcesCall) Fields(s ...googleapi.Field) *ZoneViewsRemoveResourcesCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
type ZoneViewsRemoveResourcesRequest ¶
type ZoneViewsRemoveResourcesRequest struct { // Resources: The list of resources to be removed. Resources []string `json:"resources,omitempty"` }
type ZoneViewsService ¶
type ZoneViewsService struct {
// contains filtered or unexported fields
}
func NewZoneViewsService ¶
func NewZoneViewsService(s *Service) *ZoneViewsService
func (*ZoneViewsService) AddResources ¶
func (r *ZoneViewsService) AddResources(project string, zone string, resourceView string, zoneviewsaddresourcesrequest *ZoneViewsAddResourcesRequest) *ZoneViewsAddResourcesCall
AddResources: Add resources to the view.
func (*ZoneViewsService) Delete ¶
func (r *ZoneViewsService) Delete(project string, zone string, resourceView string) *ZoneViewsDeleteCall
Delete: Delete a resource view.
func (*ZoneViewsService) Get ¶
func (r *ZoneViewsService) Get(project string, zone string, resourceView string) *ZoneViewsGetCall
Get: Get the information of a zonal resource view.
func (*ZoneViewsService) GetService ¶
func (r *ZoneViewsService) GetService(project string, zone string, resourceView string) *ZoneViewsGetServiceCall
GetService: Get the service information of a resource view or a resource.
func (*ZoneViewsService) Insert ¶
func (r *ZoneViewsService) Insert(project string, zone string, resourceview *ResourceView) *ZoneViewsInsertCall
Insert: Create a resource view.
func (*ZoneViewsService) List ¶
func (r *ZoneViewsService) List(project string, zone string) *ZoneViewsListCall
List: List resource views.
func (*ZoneViewsService) ListResources ¶
func (r *ZoneViewsService) ListResources(project string, zone string, resourceView string) *ZoneViewsListResourcesCall
ListResources: List the resources of the resource view.
func (*ZoneViewsService) RemoveResources ¶
func (r *ZoneViewsService) RemoveResources(project string, zone string, resourceView string, zoneviewsremoveresourcesrequest *ZoneViewsRemoveResourcesRequest) *ZoneViewsRemoveResourcesCall
RemoveResources: Remove resources from the view.
func (*ZoneViewsService) SetService ¶
func (r *ZoneViewsService) SetService(project string, zone string, resourceView string, zoneviewssetservicerequest *ZoneViewsSetServiceRequest) *ZoneViewsSetServiceCall
SetService: Update the service information of a resource view or a resource.
type ZoneViewsSetServiceCall ¶
type ZoneViewsSetServiceCall struct {
// contains filtered or unexported fields
}
func (*ZoneViewsSetServiceCall) Do ¶
func (c *ZoneViewsSetServiceCall) Do() (*Operation, error)
func (*ZoneViewsSetServiceCall) Fields ¶
func (c *ZoneViewsSetServiceCall) Fields(s ...googleapi.Field) *ZoneViewsSetServiceCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
type ZoneViewsSetServiceRequest ¶
type ZoneViewsSetServiceRequest struct { // Endpoints: The service information to be updated. Endpoints []*ServiceEndpoint `json:"endpoints,omitempty"` // Fingerprint: Fingerprint of the service information; a hash of the // contents. This field is used for optimistic locking when updating the // service entries. Fingerprint string `json:"fingerprint,omitempty"` // ResourceName: The name of the resource if user wants to update the // service information of the resource. ResourceName string `json:"resourceName,omitempty"` }