File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ refs/heads/master: 689bbb466df4b2d5d2483d6edb8ac5c7c7f7c6fa
33refs/heads/travis: e21ee7b88a5edc3f3d8c71f90c3fc32abf7e8dd6
44refs/heads/gh-pages: 4e0561bb4504bf647db669a14417b2b2c87ba45d
55refs/heads/bigquery: 762fa5830e6c398c0396177e3e7fd243bd62cfc3
6- refs/heads/pubsub-alpha: 4ecd84042d0c3f22270cfa670c802d08eb4ad7d3
6+ refs/heads/pubsub-alpha: 93da8a9cde7af69c0ac21694266c5d238cbd6d70
77refs/heads/resource-manager: ebf4adc5ee835cd2086c4ac5b4e78d01a5a005a7
88refs/heads/update-datastore: 482954f2c5055231e5b3122ea91d2ba00ce8187c
99refs/tags/0.0.9: 22f1839238f66c39e67ed4dfdcd273b1ae2e8444
Original file line number Diff line number Diff line change @@ -164,8 +164,7 @@ import com.google.gcloud.storage.StorageOptions;
164164import java.nio.ByteBuffer;
165165import java.nio.channels.WritableByteChannel;
166166
167- StorageOptions options = StorageOptions.builder().projectId("project").build ();
168- Storage storage = options.service ();
167+ Storage storage = StorageOptions.defaultInstance().service ();
169168BlobId blobId = BlobId.of(" bucket" , " blob_name" );
170169Blob blob = Blob.load(storage, blobId);
171170if (blob == null) {
Original file line number Diff line number Diff line change @@ -68,7 +68,7 @@ import com.google.gcloud.storage.StorageOptions;
6868import java.nio.ByteBuffer ;
6969import java.nio.channels.WritableByteChannel ;
7070
71- Storage storage = StorageOptions . getDefaultInstance (). service();
71+ Storage storage = StorageOptions . defaultInstance (). service();
7272Blob blob = new Blob (storage, " bucket" , " blob_name" );
7373if (! blob. exists()) {
7474 storage2. create(blob. info(), " Hello, Cloud Storage!" . getBytes(UTF_8 ));
You can’t perform that action at this time.
0 commit comments