()
| 99 | } |
| 100 | |
| 101 | func ExampleOpenCollection() { |
| 102 | ctx := context.Background() |
| 103 | // Open a collection using the gcpfirestore package. |
| 104 | // You will need to blank-import the package for this to work: |
| 105 | // import _ "gocloud.dev/docstore/gcpfirestore" |
| 106 | coll, err := docstore.OpenCollection(ctx, "firestore://my-collection") |
| 107 | if err != nil { |
| 108 | log.Fatal(err) |
| 109 | } |
| 110 | defer coll.Close() |
| 111 | |
| 112 | _ = coll // Use the collection. |
| 113 | } |
| 114 | |
| 115 | func ExampleCollection_As() { |
| 116 | // This example is specific to the gcpfirestore implementation; it demonstrates |
nothing calls this directly
no test coverage detected