Skip to content

Commit 51bfef6

Browse files
committed
Add javadoc to ServiceOptions.Builder methods
1 parent 77bfdd7 commit 51bfef6

1 file changed

Lines changed: 44 additions & 0 deletions

File tree

gcloud-java-core/src/main/java/com/google/gcloud/ServiceOptions.java

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -126,41 +126,85 @@ protected B self() {
126126
return (B) this;
127127
}
128128

129+
/**
130+
* Sets project id.
131+
*
132+
* @return the builder.
133+
*/
129134
public B projectId(String projectId) {
130135
this.projectId = projectId;
131136
return self();
132137
}
133138

139+
/**
140+
* Sets service host.
141+
*
142+
* @return the builder.
143+
*/
134144
public B host(String host) {
135145
this.host = host;
136146
return self();
137147
}
138148

149+
/**
150+
* Sets the transport factory.
151+
*
152+
* @return the builder.
153+
*/
139154
public B httpTransportFactory(HttpTransportFactory httpTransportFactory) {
140155
this.httpTransportFactory = httpTransportFactory;
141156
return self();
142157
}
143158

159+
/**
160+
* Sets the service authentication credentials.
161+
*
162+
* @return the builder.
163+
*/
144164
public B authCredentials(AuthCredentials authCredentials) {
145165
this.authCredentials = authCredentials;
146166
return self();
147167
}
148168

169+
/**
170+
* Sets configuration parameters for request retries.
171+
*
172+
* @return the builder.
173+
*/
149174
public B retryParams(RetryParams retryParams) {
150175
this.retryParams = retryParams;
151176
return self();
152177
}
153178

179+
/**
180+
* Sets the factory for rpc services.
181+
*
182+
* @return the builder
183+
*/
154184
public B serviceRpcFactory(ServiceRpcFactory<ServiceRpcT, OptionsT> serviceRpcFactory) {
155185
this.serviceRpcFactory = serviceRpcFactory;
156186
return self();
157187
}
158188

189+
/**
190+
* Sets the timeout in milliseconds to establish a connection.
191+
*
192+
* @param connectTimeout connection timeout in milliseconds. 0 for an infinite timeout, a
193+
* negative number for the default value (20000).
194+
* @return the builder.
195+
*/
159196
public B connectTimeout(int connectTimeout) {
160197
this.connectTimeout = connectTimeout;
161198
return self();
162199
}
163200

201+
/**
202+
* Sets the timeout in milliseconds to read data from an established connection.
203+
*
204+
* @param readTimeout read timeout in milliseconds. 0 for an infinite timeout, a
205+
* negative number for the default value (20000).
206+
* @return the builder.
207+
*/
164208
public B readTimeout(int readTimeout) {
165209
this.readTimeout = readTimeout;
166210
return self();

0 commit comments

Comments
 (0)