This interface defines pure-virtual methods for each of the user-facing overload sets in Client. That is, all of Client's Read() overloads will forward to the one pure-virtual Read() method declared in this interface, and similar for Client's other methods. This allows users to inject custom behavior (e.g., with a Google Mock object) in a Client object for use in their own tests.
To create a concrete instance that connects you to a real Spanner database, see MakeConnection().
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-04-09 UTC."],[[["This document details the `Connection` interface for interacting with a Spanner database, providing pure-virtual methods corresponding to each user-facing method in the `Client` class."],["The `Connection` interface enables users to inject custom behavior, such as with a Google Mock object, into a `Client` object for testing purposes, allowing for tailored interactions."],["A real connection to Spanner can be established using the `MakeConnection()` function, as per the provided documentation."],["The `Connection` interface includes methods like `Read`, `ExecuteQuery`, `ExecuteDml`, `Commit`, and `Rollback`, among others, which are used to perform various database operations."],["The document contains links to previous versions of the documentation, allowing users to navigate and locate specific information related to older releases of the client."]]],[]]