Skip to content

Commit 8cca008

Browse files
author
Ajay Kannan
committed
Link to specific package of javadoc from README
1 parent 2171251 commit 8cca008

4 files changed

Lines changed: 52 additions & 22 deletions

File tree

gcloud-java-core/README.md

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,15 @@
1-
Google Cloud Java Client
2-
==========================
1+
Google Cloud Java Client -- Core Services
2+
=========================================
33

4-
Java idiomatic client for [Google Cloud Platform][cloud-platform] services.
4+
This module provides common functionality required by service-specific modules of this library.
55

66
[![Build Status](https://travis-ci.org/GoogleCloudPlatform/gcloud-java.svg?branch=master)](https://travis-ci.org/GoogleCloudPlatform/gcloud-java)
77
[![Coverage Status](https://coveralls.io/repos/GoogleCloudPlatform/gcloud-java/badge.svg?branch=master)](https://coveralls.io/r/GoogleCloudPlatform/gcloud-java?branch=master)
88

99
- [Homepage] (https://googlecloudplatform.github.io/gcloud-java/)
10-
- [API Documentation] (http://googlecloudplatform.github.io/gcloud-java/apidocs)
10+
- [API Documentation] (http://googlecloudplatform.github.io/gcloud-java/apidocs/index.html?com/google/gcloud/package-summary.html)
1111
- [Examples] (http://googlecloudplatform.github.io/gcloud-java/apidocs/index.html?com/google/gcloud/examples/package-summary.html)
1212

13-
This module provides common functionality and is required by the other service specific modules.
14-
1513
Quickstart
1614
----------
1715
Add this to your pom.xml file

gcloud-java-datastore/README.md

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,15 @@
1-
Google Cloud Java Client
2-
==========================
1+
Google Cloud Java Client for Datastore
2+
======================================
33

4-
Java idiomatic client for [Google Cloud Platform][cloud-platform] services.
4+
Java idiomatic client for [Google Cloud Datastore] (https://cloud.google.com/datastore/).
55

66
[![Build Status](https://travis-ci.org/GoogleCloudPlatform/gcloud-java.svg?branch=master)](https://travis-ci.org/GoogleCloudPlatform/gcloud-java)
77
[![Coverage Status](https://coveralls.io/repos/GoogleCloudPlatform/gcloud-java/badge.svg?branch=master)](https://coveralls.io/r/GoogleCloudPlatform/gcloud-java?branch=master)
88

99
- [Homepage] (https://googlecloudplatform.github.io/gcloud-java/)
10-
- [API Documentation] (http://googlecloudplatform.github.io/gcloud-java/apidocs)
10+
- [API Documentation] (http://googlecloudplatform.github.io/gcloud-java/apidocs/index.html?com/google/gcloud/datastore/package-summary.html)
1111
- [Examples] (http://googlecloudplatform.github.io/gcloud-java/apidocs/index.html?com/google/gcloud/examples/package-summary.html)
1212

13-
This client supports [Google Cloud Datastore] (https://cloud.google.com/datastore/)
14-
15-
1613
> Note: This client is a work-in-progress, and may occasionally
1714
> make backwards-incompatible changes.
1815

gcloud-java-examples/README.md

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,8 @@ Examples for gcloud-java (Java idiomatic client for [Google Cloud Platform][clou
77
[![Coverage Status](https://coveralls.io/repos/GoogleCloudPlatform/gcloud-java/badge.svg?branch=master)](https://coveralls.io/r/GoogleCloudPlatform/gcloud-java?branch=master)
88

99
- [Homepage] (https://googlecloudplatform.github.io/gcloud-java/)
10-
- [API Documentation] (http://googlecloudplatform.github.io/gcloud-java/apidocs)
1110
- [Examples] (http://googlecloudplatform.github.io/gcloud-java/apidocs/index.html?com/google/gcloud/examples/package-summary.html)
1211

13-
1412
Quickstart
1513
----------
1614
Add this to your pom.xml file
@@ -22,7 +20,6 @@ Add this to your pom.xml file
2220
</dependency>
2321
```
2422

25-
2623
Contributing
2724
------------
2825

gcloud-java-storage/README.md

Lines changed: 44 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,15 @@
1-
Google Cloud Java Client
2-
==========================
1+
Google Cloud Java Client for Storage
2+
====================================
33

4-
Java idiomatic client for [Google Cloud Platform][cloud-platform] services.
4+
Java idiomatic client for [Google Cloud Storage] (https://cloud.google.com/storage/).
55

66
[![Build Status](https://travis-ci.org/GoogleCloudPlatform/gcloud-java.svg?branch=master)](https://travis-ci.org/GoogleCloudPlatform/gcloud-java)
77
[![Coverage Status](https://coveralls.io/repos/GoogleCloudPlatform/gcloud-java/badge.svg?branch=master)](https://coveralls.io/r/GoogleCloudPlatform/gcloud-java?branch=master)
88

99
- [Homepage] (https://googlecloudplatform.github.io/gcloud-java/)
10-
- [API Documentation] (http://googlecloudplatform.github.io/gcloud-java/apidocs)
10+
- [API Documentation] (http://googlecloudplatform.github.io/gcloud-java/apidocs/index.html?com/google/gcloud/storage/package-summary.html)
1111
- [Examples] (http://googlecloudplatform.github.io/gcloud-java/apidocs/index.html?com/google/gcloud/examples/package-summary.html)
1212

13-
This client supports the [Google Cloud Storage] (https://cloud.google.com/storage/)
14-
1513
> Note: This client is a work-in-progress, and may occasionally
1614
> make backwards-incompatible changes.
1715
@@ -26,6 +24,45 @@ Add this to your pom.xml file
2624
</dependency>
2725
```
2826

27+
Google Cloud Storage
28+
----------------------
29+
30+
[Google Cloud Storage][cloud-storage] is a durable and highly available
31+
object storage service. Google Cloud Storage is almost infinitely scalable
32+
and guarantees consistency: when a write succeeds, the latest copy of the
33+
object will be returned to any GET, globally.
34+
35+
See the [Google Cloud Storage docs][cloud-storage-activation] for more details on how to activate
36+
Cloud Storage for your project.
37+
38+
See the ``gcloud-java`` API [storage documentation][storage-api] to learn how to interact
39+
with the Cloud Storage using this Client Library.
40+
41+
```java
42+
import static java.nio.charset.StandardCharsets.UTF_8;
43+
44+
import com.google.gcloud.storage.Blob;
45+
import com.google.gcloud.storage.Storage;
46+
import com.google.gcloud.storage.StorageFactory;
47+
import com.google.gcloud.storage.StorageOptions;
48+
49+
import java.nio.ByteBuffer;
50+
import java.nio.channels.WritableByteChannel;
51+
52+
StorageOptions options = StorageOptions.builder().projectId(PROJECT_ID).build();
53+
Storage storage = StorageFactory.instance().get(options);
54+
Blob blob = new Blob(storage, "bucket", "blob_name");
55+
if (!blob.exists()) {
56+
storage2.create(blob.info(), "Hello, Cloud Storage!".getBytes(UTF_8));
57+
} else {
58+
System.out.println("Updating content for " + blob.info().name());
59+
byte[] prevContent = blob.content();
60+
System.out.println(new String(prevContent, UTF_8));
61+
WritableByteChannel channel = blob.writer();
62+
channel.write(ByteBuffer.wrap("Updated content".getBytes(UTF_8)));
63+
channel.close();
64+
}
65+
```
2966

3067
Contributing
3168
------------
@@ -61,3 +98,4 @@ Apache 2.0 - See [LICENSE] for more information.
6198
[cloud-storage]: https://cloud.google.com/storage/
6299
[cloud-storage-docs]: https://cloud.google.com/storage/docs/overview
63100
[cloud-storage-create-bucket]: https://cloud.google.com/storage/docs/cloud-console#_creatingbuckets
101+
[storage-api]: http://googlecloudplatform.github.io/gcloud-java/apidocs/index.html?com/google/gcloud/storage/package-summary.html

0 commit comments

Comments
 (0)