Class ImagesResource
The "images" collection of methods.
Inherited Members
Namespace: Google.Apis.Compute.beta
Assembly: Google.Apis.Compute.beta.dll
Syntax
public class ImagesResource
Constructors
ImagesResource(IClientService)
Constructs a new resource.
Declaration
public ImagesResource(IClientService service)
Parameters
Type | Name | Description |
---|---|---|
IClientService | service |
Methods
Delete(string, string)
Deletes the specified image.
Declaration
public virtual ImagesResource.DeleteRequest Delete(string project, string image)
Parameters
Type | Name | Description |
---|---|---|
string | project | Project ID for this request. |
string | image | Name of the image resource to delete. |
Returns
Type | Description |
---|---|
ImagesResource.DeleteRequest |
Deprecate(DeprecationStatus, string, string)
Sets the deprecation status of an image. If an empty request body is given, clears the deprecation status instead.
Declaration
public virtual ImagesResource.DeprecateRequest Deprecate(DeprecationStatus body, string project, string image)
Parameters
Type | Name | Description |
---|---|---|
DeprecationStatus | body | The body of the request. |
string | project | Project ID for this request. |
string | image | Image name. |
Returns
Type | Description |
---|---|
ImagesResource.DeprecateRequest |
Get(string, string)
Returns the specified image.
Declaration
public virtual ImagesResource.GetRequest Get(string project, string image)
Parameters
Type | Name | Description |
---|---|---|
string | project | Project ID for this request. |
string | image | Name of the image resource to return. |
Returns
Type | Description |
---|---|
ImagesResource.GetRequest |
GetFromFamily(string, string)
Returns the latest image that is part of an image family and is not deprecated. For more information on image families, see Public image families documentation.
Declaration
public virtual ImagesResource.GetFromFamilyRequest GetFromFamily(string project, string family)
Parameters
Type | Name | Description |
---|---|---|
string | project | The image project that the image belongs to. For example, to get a CentOS image, specify centos-cloud as the image project. |
string | family | Name of the image family to search for. |
Returns
Type | Description |
---|---|
ImagesResource.GetFromFamilyRequest |
GetIamPolicy(string, string)
Gets the access control policy for a resource. May be empty if no such policy or resource exists.
Declaration
public virtual ImagesResource.GetIamPolicyRequest GetIamPolicy(string project, string resource)
Parameters
Type | Name | Description |
---|---|---|
string | project | Project ID for this request. |
string | resource | Name or id of the resource for this request. |
Returns
Type | Description |
---|---|
ImagesResource.GetIamPolicyRequest |
Insert(Image, string)
Creates an image in the specified project using the data included in the request.
Declaration
public virtual ImagesResource.InsertRequest Insert(Image body, string project)
Parameters
Type | Name | Description |
---|---|---|
Image | body | The body of the request. |
string | project | Project ID for this request. |
Returns
Type | Description |
---|---|
ImagesResource.InsertRequest |
List(string)
Retrieves the list of custom images available to the specified project. Custom images are images you create that belong to your project. This method does not get any images that belong to other projects, including publicly-available images, like Debian 8. If you want to get a list of publicly-available images, use this method to make a request to the respective image project, such as debian-cloud or windows-cloud.
Declaration
public virtual ImagesResource.ListRequest List(string project)
Parameters
Type | Name | Description |
---|---|---|
string | project | Project ID for this request. |
Returns
Type | Description |
---|---|
ImagesResource.ListRequest |
Patch(Image, string, string)
Patches the specified image with the data included in the request. Only the following fields can be modified: family, description, deprecation status.
Declaration
public virtual ImagesResource.PatchRequest Patch(Image body, string project, string image)
Parameters
Type | Name | Description |
---|---|---|
Image | body | The body of the request. |
string | project | Project ID for this request. |
string | image | Name of the image resource to patch. |
Returns
Type | Description |
---|---|
ImagesResource.PatchRequest |
SetIamPolicy(GlobalSetPolicyRequest, string, string)
Sets the access control policy on the specified resource. Replaces any existing policy.
Declaration
public virtual ImagesResource.SetIamPolicyRequest SetIamPolicy(GlobalSetPolicyRequest body, string project, string resource)
Parameters
Type | Name | Description |
---|---|---|
GlobalSetPolicyRequest | body | The body of the request. |
string | project | Project ID for this request. |
string | resource | Name or id of the resource for this request. |
Returns
Type | Description |
---|---|
ImagesResource.SetIamPolicyRequest |
SetLabels(GlobalSetLabelsRequest, string, string)
Sets the labels on an image. To learn more about labels, read the Labeling Resources documentation.
Declaration
public virtual ImagesResource.SetLabelsRequest SetLabels(GlobalSetLabelsRequest body, string project, string resource)
Parameters
Type | Name | Description |
---|---|---|
GlobalSetLabelsRequest | body | The body of the request. |
string | project | Project ID for this request. |
string | resource | Name or id of the resource for this request. |
Returns
Type | Description |
---|---|
ImagesResource.SetLabelsRequest |
TestIamPermissions(TestPermissionsRequest, string, string)
Returns permissions that a caller has on the specified resource.
Declaration
public virtual ImagesResource.TestIamPermissionsRequest TestIamPermissions(TestPermissionsRequest body, string project, string resource)
Parameters
Type | Name | Description |
---|---|---|
TestPermissionsRequest | body | The body of the request. |
string | project | Project ID for this request. |
string | resource | Name or id of the resource for this request. |
Returns
Type | Description |
---|---|
ImagesResource.TestIamPermissionsRequest |