All Downloads are FREE. Search and download functionalities are using the official Maven repository.

target.apidocs.com.google.api.services.compute.Compute.Images.html Maven / Gradle / Ivy

The newest version!






Compute.Images (Compute Engine API v1-rev20250320-2.0.0)












com.google.api.services.compute

Class Compute.Images

  • Enclosing class:
    Compute


    public class Compute.Images
    extends Object
    The "images" collection of methods.
    • Constructor Detail

      • Images

        public Images()
    • Method Detail

      • delete

        public Compute.Images.Delete delete(String project,
                                            String image)
                                     throws IOException
        Deletes the specified image. Create a request for the method "images.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.
        image - Name of the image resource to delete.
        Returns:
        the request
        Throws:
        IOException
      • deprecate

        public Compute.Images.Deprecate deprecate(String project,
                                                  String image,
                                                  DeprecationStatus content)
                                           throws IOException
        Sets the deprecation status of an image. If an empty request body is given, clears the deprecation status instead. Create a request for the method "images.deprecate". 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.
        image - Image name.
        content - the DeprecationStatus
        Returns:
        the request
        Throws:
        IOException
      • get

        public Compute.Images.Get get(String project,
                                      String image)
                               throws IOException
        Returns the specified image. Create a request for the method "images.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.
        image - Name of the image resource to return.
        Returns:
        the request
        Throws:
        IOException
      • getFromFamily

        public Compute.Images.GetFromFamily getFromFamily(String project,
                                                          String family)
                                                   throws IOException
        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. Create a request for the method "images.getFromFamily". 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 - The image project that the image belongs to. For example, to get a CentOS image, specify centos- cloud as the image project.
        family - Name of the image family to search for.
        Returns:
        the request
        Throws:
        IOException
      • getIamPolicy

        public Compute.Images.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 "images.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.Images.Insert insert(String project,
                                            Image content)
                                     throws IOException
        Creates an image in the specified project using the data included in the request. Create a request for the method "images.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 Image
        Returns:
        the request
        Throws:
        IOException
      • list

        public Compute.Images.List list(String project)
                                 throws IOException
        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. Create a request for the method "images.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
      • patch

        public Compute.Images.Patch patch(String project,
                                          String image,
                                          Image content)
                                   throws IOException
        Patches the specified image with the data included in the request. Only the following fields can be modified: family, description, deprecation status. Create a request for the method "images.patch". 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.
        image - Name of the image resource to patch.
        content - the Image
        Returns:
        the request
        Throws:
        IOException
      • setIamPolicy

        public Compute.Images.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 "images.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.Images.SetLabels setLabels(String project,
                                                  String resource,
                                                  GlobalSetLabelsRequest content)
                                           throws IOException
        Sets the labels on an image. To learn more about labels, read the Labeling Resources documentation. Create a request for the method "images.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.Images.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 "images.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–2025 Google. All rights reserved.





© 2015 - 2025 Weber Informatics LLC | Privacy Policy