![JAR search and dependency download from the Maven repository](/logo.png)
target.apidocs.com.google.api.services.compute.Compute.Snapshots.html Maven / Gradle / Ivy
Compute.Snapshots (Compute Engine API beta-rev20220312-1.32.1)
com.google.api.services.compute
Class Compute.Snapshots
- java.lang.Object
-
- com.google.api.services.compute.Compute.Snapshots
-
-
Nested Class Summary
Nested Classes
Modifier and Type
Class and Description
class
Compute.Snapshots.Delete
class
Compute.Snapshots.Get
class
Compute.Snapshots.GetIamPolicy
class
Compute.Snapshots.Insert
class
Compute.Snapshots.List
class
Compute.Snapshots.SetIamPolicy
class
Compute.Snapshots.SetLabels
class
Compute.Snapshots.TestIamPermissions
-
Constructor Summary
Constructors
Constructor and Description
Snapshots()
-
Method Summary
All Methods Instance Methods Concrete Methods
Modifier and Type
Method and Description
Compute.Snapshots.Delete
delete(String project,
String snapshot)
Deletes the specified Snapshot resource.
Compute.Snapshots.Get
get(String project,
String snapshot)
Returns the specified Snapshot resource.
Compute.Snapshots.GetIamPolicy
getIamPolicy(String project,
String resource)
Gets the access control policy for a resource.
Compute.Snapshots.Insert
insert(String project,
Snapshot content)
Creates a snapshot in the specified project using the data included in the request.
Compute.Snapshots.List
list(String project)
Retrieves the list of Snapshot resources contained within the specified project.
Compute.Snapshots.SetIamPolicy
setIamPolicy(String project,
String resource,
GlobalSetPolicyRequest content)
Sets the access control policy on the specified resource.
Compute.Snapshots.SetLabels
setLabels(String project,
String resource,
GlobalSetLabelsRequest content)
Sets the labels on a snapshot.
Compute.Snapshots.TestIamPermissions
testIamPermissions(String project,
String resource,
TestPermissionsRequest content)
Returns permissions that a caller has on the specified resource.
-
-
Method Detail
-
delete
public Compute.Snapshots.Delete delete(String project,
String snapshot)
throws IOException
Deletes the specified Snapshot resource. Keep in mind that deleting a single snapshot might not
necessarily delete all the data on that snapshot. If any data on the snapshot that is marked for
deletion is needed for subsequent snapshots, the data will be moved to the next corresponding
snapshot. For more information, see Deleting snapshots.
Create a request for the method "snapshots.delete".
This request holds the parameters needed by the compute server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
project
- Project ID for this request.
snapshot
- Name of the Snapshot resource to delete.
- Returns:
- the request
- Throws:
IOException
-
get
public Compute.Snapshots.Get get(String project,
String snapshot)
throws IOException
Returns the specified Snapshot resource. Gets a list of available snapshots by making a list()
request.
Create a request for the method "snapshots.get".
This request holds the parameters needed by the compute server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
project
- Project ID for this request.
snapshot
- Name of the Snapshot resource to return.
- Returns:
- the request
- Throws:
IOException
-
getIamPolicy
public Compute.Snapshots.GetIamPolicy getIamPolicy(String project,
String resource)
throws IOException
Gets the access control policy for a resource. May be empty if no such policy or resource exists.
Create a request for the method "snapshots.getIamPolicy".
This request holds the parameters needed by the compute server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
project
- Project ID for this request.
resource
- Name or id of the resource for this request.
- Returns:
- the request
- Throws:
IOException
-
insert
public Compute.Snapshots.Insert insert(String project,
Snapshot content)
throws IOException
Creates a snapshot in the specified project using the data included in the request. For regular
snapshot creation, consider using this method instead of disks.createSnapshot, as this method
supports more features, such as creating snapshots in a project different from the source disk
project.
Create a request for the method "snapshots.insert".
This request holds the parameters needed by the compute server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
project
- Project ID for this request.
content
- the Snapshot
- Returns:
- the request
- Throws:
IOException
-
list
public Compute.Snapshots.List list(String project)
throws IOException
Retrieves the list of Snapshot resources contained within the specified project.
Create a request for the method "snapshots.list".
This request holds the parameters needed by the compute server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
project
- Project ID for this request.
- Returns:
- the request
- Throws:
IOException
-
setIamPolicy
public Compute.Snapshots.SetIamPolicy setIamPolicy(String project,
String resource,
GlobalSetPolicyRequest content)
throws IOException
Sets the access control policy on the specified resource. Replaces any existing policy.
Create a request for the method "snapshots.setIamPolicy".
This request holds the parameters needed by the compute server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
project
- Project ID for this request.
resource
- Name or id of the resource for this request.
content
- the GlobalSetPolicyRequest
- Returns:
- the request
- Throws:
IOException
-
setLabels
public Compute.Snapshots.SetLabels setLabels(String project,
String resource,
GlobalSetLabelsRequest content)
throws IOException
Sets the labels on a snapshot. To learn more about labels, read the Labeling Resources
documentation.
Create a request for the method "snapshots.setLabels".
This request holds the parameters needed by the compute server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
project
- Project ID for this request.
resource
- Name or id of the resource for this request.
content
- the GlobalSetLabelsRequest
- Returns:
- the request
- Throws:
IOException
-
testIamPermissions
public Compute.Snapshots.TestIamPermissions testIamPermissions(String project,
String resource,
TestPermissionsRequest content)
throws IOException
Returns permissions that a caller has on the specified resource.
Create a request for the method "snapshots.testIamPermissions".
This request holds the parameters needed by the compute server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation.
- Parameters:
project
- Project ID for this request.
resource
- Name or id of the resource for this request.
content
- the TestPermissionsRequest
- Returns:
- the request
- Throws:
IOException
Copyright © 2011–2022 Google. All rights reserved.
© 2015 - 2025 Weber Informatics LLC | Privacy Policy