tree: 871d9d58b8534715fe9602ea3312603023a55784 [path history] [tgz]
  1. internal/
  2. acl.go
  3. acl_test.go
  4. bucket.go
  5. bucket_test.go
  6. CHANGES.md
  7. conformance_test.go
  8. copy.go
  9. copy_test.go
  10. doc.go
  11. example_test.go
  12. go.mod
  13. go.sum
  14. go110.go
  15. go_mod_tidy_hack.go
  16. hmac.go
  17. hmac_test.go
  18. iam.go
  19. integration_test.go
  20. invoke.go
  21. invoke_test.go
  22. mock_test.go
  23. not_go110.go
  24. notifications.go
  25. notifications_test.go
  26. oc_test.go
  27. reader.go
  28. reader_test.go
  29. README.md
  30. retry_test.go
  31. storage.go
  32. storage.replay
  33. storage_test.go
  34. writer.go
  35. writer_test.go
storage/README.md

Cloud Storage GoDoc

Example Usage

First create a storage.Client to use throughout your application:

client, err := storage.NewClient(ctx)
if err != nil {
	log.Fatal(err)
}
// Read the object1 from bucket.
rc, err := client.Bucket("bucket").Object("object1").NewReader(ctx)
if err != nil {
	log.Fatal(err)
}
defer rc.Close()
body, err := ioutil.ReadAll(rc)
if err != nil {
	log.Fatal(err)
}