This interface defines virtual methods for each of the user-facing overload sets in ProjectsClient. This allows users to inject custom behavior (e.g., with a Google Mock object) when writing tests that use objects of type ProjectsClient.
To create a concrete instance, see MakeProjectsConnection().
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-14 UTC."],[[["\u003cp\u003eThis webpage details the \u003ccode\u003eProjectsConnection\u003c/code\u003e interface for the \u003ccode\u003eProjectsClient\u003c/code\u003e in the Google Cloud C++ Compute library, allowing users to inject custom behavior for testing.\u003c/p\u003e\n"],["\u003cp\u003eThe content provides links to documentation for multiple versions of the library, ranging from version 2.15.1 to the latest release candidate 2.37.0-rc.\u003c/p\u003e\n"],["\u003cp\u003eThe interface defines various virtual methods corresponding to user-facing overload sets in \u003ccode\u003eProjectsClient\u003c/code\u003e, including operations like \u003ccode\u003eDisableXpnHost\u003c/code\u003e, \u003ccode\u003eEnableXpnResource\u003c/code\u003e, \u003ccode\u003eGetProject\u003c/code\u003e, and more.\u003c/p\u003e\n"],["\u003cp\u003eFunctions such as \u003ccode\u003eMakeProjectsConnection()\u003c/code\u003e and \u003ccode\u003eMockProjectsConnection\u003c/code\u003e are mentioned for creating concrete instances and mocking the connection for testing, respectively.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eProjectsConnection\u003c/code\u003e interface provides options to perform different operations, such as enabling and disabling XPN resources, moving disks or instances, setting common metadata and usage export buckets, in the context of the user's GCP project.\u003c/p\u003e\n"]]],[],null,[]]