diff --git a/java-datastore/google-cloud-datastore/src/main/java/com/google/cloud/datastore/DatastoreBatchWriter.java b/java-datastore/google-cloud-datastore/src/main/java/com/google/cloud/datastore/DatastoreBatchWriter.java index 28d2569b6a89..ae5ea820ff69 100644 --- a/java-datastore/google-cloud-datastore/src/main/java/com/google/cloud/datastore/DatastoreBatchWriter.java +++ b/java-datastore/google-cloud-datastore/src/main/java/com/google/cloud/datastore/DatastoreBatchWriter.java @@ -37,7 +37,7 @@ public interface DatastoreBatchWriter extends DatastoreWriter { /** * Datastore add operation. This method will also allocate id for any entity with an incomplete - * key. As opposed to {@link #add(FullEntity)} and {@link #add(FullEntity...)}, this method will + * key. As opposed to {@link #add(FullEntity)} and {@link #add(FullEntity[])}, this method will * defer any necessary id allocation to submit time. * * @throws IllegalArgumentException if any of the given entities is missing a key @@ -88,7 +88,7 @@ public interface DatastoreBatchWriter extends DatastoreWriter { /** * Datastore put operation. This method will also allocate id for any entity with an incomplete - * key. As opposed to {@link #put(FullEntity)} and {@link #put(FullEntity...)}, this method will + * key. As opposed to {@link #put(FullEntity)} and {@link #put(FullEntity[])}, this method will * defer any necessary id allocation to submit time. * * @throws IllegalArgumentException if any of the given entities is missing a key diff --git a/java-datastore/google-cloud-datastore/src/main/java/com/google/cloud/datastore/DatastoreReader.java b/java-datastore/google-cloud-datastore/src/main/java/com/google/cloud/datastore/DatastoreReader.java index c3137a9a7ce6..030b09b56ee4 100644 --- a/java-datastore/google-cloud-datastore/src/main/java/com/google/cloud/datastore/DatastoreReader.java +++ b/java-datastore/google-cloud-datastore/src/main/java/com/google/cloud/datastore/DatastoreReader.java @@ -46,7 +46,7 @@ public interface DatastoreReader { /** * Returns a list with a value for each given key (ordered by input). {@code null} values are - * returned for nonexistent keys. When possible prefer using {@link #get(Key...)} to avoid eagerly + * returned for nonexistent keys. When possible prefer using {@link #get(Key[])} to avoid eagerly * loading the results. */ List fetch(Key... keys); diff --git a/java-datastore/google-cloud-datastore/src/main/java/com/google/cloud/datastore/Transaction.java b/java-datastore/google-cloud-datastore/src/main/java/com/google/cloud/datastore/Transaction.java index 76a19d4981a8..201fc0e64c92 100644 --- a/java-datastore/google-cloud-datastore/src/main/java/com/google/cloud/datastore/Transaction.java +++ b/java-datastore/google-cloud-datastore/src/main/java/com/google/cloud/datastore/Transaction.java @@ -185,7 +185,7 @@ interface Response { /** * Datastore add operation. This method will also allocate id for any entity with an incomplete - * key. As opposed to {@link #add(FullEntity)} and {@link #add(FullEntity...)}, this method will + * key. As opposed to {@link #add(FullEntity)} and {@link #add(FullEntity[])}, this method will * defer any necessary id allocation to commit time. * *

Example of adding multiple entities with deferred id allocation. @@ -312,7 +312,7 @@ interface Response { /** * Datastore put operation. This method will also allocate id for any entity with an incomplete - * key. As opposed to {@link #put(FullEntity)} and {@link #put(FullEntity...)}, this method will + * key. As opposed to {@link #put(FullEntity)} and {@link #put(FullEntity[])}, this method will * defer any necessary id allocation to commit time. * *

Example of putting multiple entities with deferred id allocation. diff --git a/java-dns/src/main/java/com/google/cloud/dns/DnsBatch.java b/java-dns/src/main/java/com/google/cloud/dns/DnsBatch.java index cd3e22813430..8c02757eba37 100644 --- a/java-dns/src/main/java/com/google/cloud/dns/DnsBatch.java +++ b/java-dns/src/main/java/com/google/cloud/dns/DnsBatch.java @@ -81,9 +81,9 @@ public DnsBatchResult> listZones(Dns.ZoneListOption... options) { /** * Adds a request representing the "create zone" operation to this batch. The {@code options} can - * be used to restrict the fields returned in the same way as for {@link Dns#create(ZoneInfo, - * Dns.ZoneOption...)}. Calling {@link DnsBatchResult#get()} on the return value yields the - * created {@link Zone} if successful and throws a {@link DnsException} otherwise. + * be used to restrict the fields returned as for {@link Dns#create(ZoneInfo, Dns.ZoneOption[])}. + * Calling {@link DnsBatchResult#get()} on the return value yields the created {@link Zone} if + * successful and throws a {@link DnsException} otherwise. */ public DnsBatchResult createZone(ZoneInfo zone, Dns.ZoneOption... options) { DnsBatchResult result = new DnsBatchResult<>(); @@ -108,10 +108,10 @@ public DnsBatchResult deleteZone(String zoneName) { /** * Adds a request representing the "get zone" operation to this batch. The {@code options} can be - * used to restrict the fields returned in the same way as for {@link Dns#getZone(String, - * Dns.ZoneOption...)}. Calling {@link DnsBatchResult#get()} on the return value yields the - * requested {@link Zone} if successful, {@code null} if no such zone exists, or throws a {@link - * DnsException} if the operation failed. + * used to restrict the fields returned as for {@link Dns#getZone(String, Dns.ZoneOption[])}. + * Calling {@link DnsBatchResult#get()} on the return value yields the requested {@link Zone} if + * successful, {@code null} if no such zone exists, or throws a {@link DnsException} if the + * operation failed. */ public DnsBatchResult getZone(String zoneName, Dns.ZoneOption... options) { DnsBatchResult result = new DnsBatchResult<>(); @@ -139,10 +139,10 @@ public DnsBatchResult getProject(Dns.ProjectOption... options) { /** * Adds a request representing the "list record sets" operation in the zone specified by {@code * zoneName} to this batch. The {@code options} can be used to restrict the fields returned or - * provide page size limits in the same way as for {@link Dns#listRecordSets(String, - * Dns.RecordSetListOption...)}. Calling {@link DnsBatchResult#get()} on the return value yields a - * page of record sets if successful and throws a {@link DnsException} if the operation failed or - * the zone does not exist. + * provide page size limits as in {@link Dns#listRecordSets(String, Dns.RecordSetListOption[])}. + * Calling {@link DnsBatchResult#get()} on the return value yields a page of record sets if + * successful and throws a {@link DnsException} if the operation failed or the zone does not + * exist. */ public DnsBatchResult> listRecordSets( String zoneName, Dns.RecordSetListOption... options) { @@ -157,10 +157,10 @@ public DnsBatchResult> listRecordSets( /** * Adds a request representing the "list change requests" operation in the zone specified by * {@code zoneName} to this batch. The {@code options} can be used to restrict the fields returned - * or provide page size limits in the same way as for {@link Dns#listChangeRequests(String, - * Dns.ChangeRequestListOption...)}. Calling {@link DnsBatchResult#get()} on the return value - * yields a page of change requests if successful and throws a {@link DnsException} if the - * operation failed or the zone does not exist. + * or limit page size as in {@link Dns#listChangeRequests(String, Dns.ChangeRequestListOption[])}. + * Calling {@link DnsBatchResult#get()} on the return value yields a page of change requests if + * successful and throws a {@link DnsException} if the operation failed or the zone does not + * exist. */ public DnsBatchResult> listChangeRequests( String zoneName, Dns.ChangeRequestListOption... options) { @@ -191,11 +191,10 @@ public DnsBatchResult getChangeRequest( /** * Adds a request representing the "apply change request" operation to the zone specified by - * {@code zoneName} to this batch. The {@code options} can be used to restrict the fields returned - * in the same way as for {@link Dns#applyChangeRequest(String, ChangeRequestInfo, - * Dns.ChangeRequestOption...)}. Calling {@link DnsBatchResult#get()} on the return value yields - * the created {@link ChangeRequest} if successful or throws a {@link DnsException} if the - * operation failed or the zone does not exist. + * {@code zoneName} to this batch. The {@code options} can restrict returned fields as for {@link + * Dns#applyChangeRequest(String, ChangeRequestInfo, Dns.ChangeRequestOption[])}. Calling {@link + * DnsBatchResult#get()} on the return value yields the created {@link ChangeRequest} if + * successful or throws a {@link DnsException} if the operation failed or the zone does not exist. */ public DnsBatchResult applyChangeRequest( String zoneName, ChangeRequestInfo changeRequest, Dns.ChangeRequestOption... options) { diff --git a/java-translate/google-cloud-translate/src/main/java/com/google/cloud/translate/TranslateOptions.java b/java-translate/google-cloud-translate/src/main/java/com/google/cloud/translate/TranslateOptions.java index e94d9a6dc3e6..598b12fd2def 100644 --- a/java-translate/google-cloud-translate/src/main/java/com/google/cloud/translate/TranslateOptions.java +++ b/java-translate/google-cloud-translate/src/main/java/com/google/cloud/translate/TranslateOptions.java @@ -122,8 +122,8 @@ public Builder setApiKey(String apiKey) { /** * Sets the code for the default target language. If not set, English ({@code en}) is used. - * Calls to {@link Translate#translate(List, TranslateOption...)} and {@link - * Translate#translate(String, TranslateOption...)} will use this value unless an option from + * Calls to {@link Translate#translate(List, Translate.TranslateOption[])} and {@link + * Translate#translate(String, Translate.TranslateOption[])} will use this value unless an * {@link TranslateOption#targetLanguage(String)} is explicitly provided. * * @return the builder diff --git a/java-translate/google-cloud-translate/src/main/java/com/google/cloud/translate/Translation.java b/java-translate/google-cloud-translate/src/main/java/com/google/cloud/translate/Translation.java index 8522921b06ce..e3f593b159ca 100644 --- a/java-translate/google-cloud-translate/src/main/java/com/google/cloud/translate/Translation.java +++ b/java-translate/google-cloud-translate/src/main/java/com/google/cloud/translate/Translation.java @@ -68,7 +68,7 @@ public String getSourceLanguage() { /** * Returns the translation model used to translate the text. This value is only available if a * result from {@link Translate.TranslateOption#model(String)} was passed to {@link - * Translate#translate(List, Translate.TranslateOption...)}. + * Translate#translate(List, Translate.TranslateOption[])}. * *

Please note that you must be whitelisted to use the {@link * Translate.TranslateOption#model(String)} option, otherwise translation will fail. diff --git a/java-translate/google-cloud-translate/src/main/java/com/google/cloud/translate/testing/RemoteTranslateHelper.java b/java-translate/google-cloud-translate/src/main/java/com/google/cloud/translate/testing/RemoteTranslateHelper.java index 9a5d20659b69..400088278473 100644 --- a/java-translate/google-cloud-translate/src/main/java/com/google/cloud/translate/testing/RemoteTranslateHelper.java +++ b/java-translate/google-cloud-translate/src/main/java/com/google/cloud/translate/testing/RemoteTranslateHelper.java @@ -29,7 +29,7 @@ /** * Utility to create a remote translate configuration for testing. Translate options can be obtained - * via the {@link #getOptions()} ()} method. Returned options have custom {@link + * via the {@link #getOptions()} method. Returned options have custom {@link * TranslateOptions#getRetrySettings()}: {@link RetrySettings#getMaxAttempts()} is {@code 10}, * {@link RetrySettings#getMaxRetryDelay()} is {@code 30000}, {@link * RetrySettings#getTotalTimeout()} is {@code 120000} and {@link @@ -52,8 +52,8 @@ public TranslateOptions getOptions() { } /** - * This method is obsolete because of a potential security risk. Use the {@link #create(String, - * GoogleCredentials)} method instead. + * Obsolete due to a potential security risk. Use {@link #create(String, GoogleCredentials)} + * instead. * *

If you know that you will be loading credential configurations of a specific type, it is * recommended to use a credential-type-specific `fromStream()` method. This will ensure that an @@ -68,8 +68,8 @@ public TranslateOptions getOptions() { *

Regardless of the method used, it is always your responsibility to validate configurations * received from external sources. * - *

See the {@link documentation} + *

See the documentation * for more details. * *

Creates a {@code RemoteTranslateHelper} object for the given project id and JSON key input diff --git a/sdk-platform-java/api-common-java/src/main/java/com/google/api/core/ApiFutures.java b/sdk-platform-java/api-common-java/src/main/java/com/google/api/core/ApiFutures.java index 780c50a783f6..9d00a1384646 100644 --- a/sdk-platform-java/api-common-java/src/main/java/com/google/api/core/ApiFutures.java +++ b/sdk-platform-java/api-common-java/src/main/java/com/google/api/core/ApiFutures.java @@ -51,8 +51,8 @@ private ApiFutures() {} * * @param future The future attach the callback to * @param callback The callback to invoke when future is completed - * @deprecated Use {@linkplain #addCallback(ApiFuture, ApiFutureCallback, Executor) the overload - * that requires an executor}. For identical behavior, pass {@link + * @deprecated Use {@linkplain #addCallback(ApiFuture, ApiFutureCallback, Executor)}, the overload + * that requires an executor. For identical behavior, pass {@link * com.google.common.util.concurrent.MoreExecutors#directExecutor}, but consider whether * another executor would be safer. */ @@ -102,8 +102,8 @@ public void onSuccess(V v) { * type * @return A future whose result is taken either from the given {@code input} or by the {@code * callback} - * @deprecated Use {@linkplain #catching(ApiFuture, Class, ApiFunction, Executor) the overload - * that requires an executor}. For identical behavior, pass {@link + * @deprecated Use {@linkplain #catching(ApiFuture, Class, ApiFunction, Executor)}, the overload + * that requires an executor. For identical behavior, pass {@link * com.google.common.util.concurrent.MoreExecutors#directExecutor}, but consider whether * another executor would be safer. */ @@ -228,8 +228,8 @@ public static ApiFuture immediateCancelledFuture() { * @param function A Function to transform the results of the provided future to the results of * the returned future * @return A future that holds result of the transformation - * @deprecated Use {@linkplain #transform(ApiFuture, ApiFunction, Executor) the overload that - * requires an executor}. For identical behavior, pass {@link + * @deprecated Use {@linkplain #transform(ApiFuture, ApiFunction, Executor)}, the overload that + * requires an executor. For identical behavior, pass {@link * com.google.common.util.concurrent.MoreExecutors#directExecutor}, but consider whether * another executor would be safer. */ diff --git a/sdk-platform-java/gax-java/gax/src/main/java/com/google/api/gax/retrying/DirectRetryingExecutor.java b/sdk-platform-java/gax-java/gax/src/main/java/com/google/api/gax/retrying/DirectRetryingExecutor.java index bdcc4b03a2fd..7a43448c70bb 100644 --- a/sdk-platform-java/gax-java/gax/src/main/java/com/google/api/gax/retrying/DirectRetryingExecutor.java +++ b/sdk-platform-java/gax-java/gax/src/main/java/com/google/api/gax/retrying/DirectRetryingExecutor.java @@ -93,8 +93,7 @@ public RetryingFuture createFuture( * the specified by the {@link RetryingFuture#getAttemptSettings()} amount of time. As result, * this method completes execution only after the specified {@code retryingFuture} completes. * - * @param retryingFuture the future previously returned by {@link #createFuture(Callable, - * RetryingContext)} + * @param retryingFuture the future returned by {@link #createFuture(Callable, RetryingContext)} * @return returns completed {@code retryingFuture} */ @Override diff --git a/sdk-platform-java/gax-java/gax/src/main/java/com/google/api/gax/retrying/ResultRetryAlgorithm.java b/sdk-platform-java/gax-java/gax/src/main/java/com/google/api/gax/retrying/ResultRetryAlgorithm.java index 3f1a67554722..bec3181d1f3c 100644 --- a/sdk-platform-java/gax-java/gax/src/main/java/com/google/api/gax/retrying/ResultRetryAlgorithm.java +++ b/sdk-platform-java/gax-java/gax/src/main/java/com/google/api/gax/retrying/ResultRetryAlgorithm.java @@ -40,11 +40,11 @@ @NullMarked public interface ResultRetryAlgorithm { /** - * Same as {@link ResultRetryAlgorithmWithContext#createNextAttempt(RetryingContext, Throwable, - * Object, TimedAttemptSettings)}, but without a {@link RetryingContext}. + * Same as {@link ResultRetryAlgorithmWithContext#createNextAttempt}, but without a {@link + * RetryingContext}. * - *

Use {@link ResultRetryAlgorithmWithContext#createNextAttempt(RetryingContext, Throwable, - * Object, TimedAttemptSettings)} instead of this method when possible. + *

Use {@link ResultRetryAlgorithmWithContext#createNextAttempt} instead of this method when + * possible. */ TimedAttemptSettings createNextAttempt( Throwable prevThrowable, ResponseT prevResponse, TimedAttemptSettings prevSettings); diff --git a/sdk-platform-java/gax-java/gax/src/main/java/com/google/api/gax/retrying/RetryAlgorithm.java b/sdk-platform-java/gax-java/gax/src/main/java/com/google/api/gax/retrying/RetryAlgorithm.java index d851b09349a6..5ebdbfbbee27 100644 --- a/sdk-platform-java/gax-java/gax/src/main/java/com/google/api/gax/retrying/RetryAlgorithm.java +++ b/sdk-platform-java/gax-java/gax/src/main/java/com/google/api/gax/retrying/RetryAlgorithm.java @@ -63,8 +63,8 @@ public class RetryAlgorithm { * * @param resultAlgorithm result algorithm to use * @param timedAlgorithm timed algorithm to use - * @deprecated use {@link RetryAlgorithm#RetryAlgorithm(ResultRetryAlgorithmWithContext, - * TimedRetryAlgorithmWithContext)} instead + * @deprecated Ignores {@link RetryingContext}. Instead, use {@link + * #RetryAlgorithm(ResultRetryAlgorithmWithContext, TimedRetryAlgorithmWithContext)}. */ @Deprecated public RetryAlgorithm( @@ -127,8 +127,8 @@ public TimedAttemptSettings createFirstAttempt(@Nullable RetryingContext context * thrown instead * @param previousSettings previous attempt settings * @return next attempt settings, can be {@code null}, if no there should be no new attempt - * @deprecated use {@link #createNextAttempt(RetryingContext, Throwable, Object, - * TimedAttemptSettings)} instead + * @deprecated Ignores {@link RetryingContext}. Instead, use {@link + * #createNextAttempt(RetryingContext, Throwable, Object, TimedAttemptSettings)}. */ @Deprecated public TimedAttemptSettings createNextAttempt( diff --git a/sdk-platform-java/gax-java/gax/src/main/java/com/google/api/gax/retrying/ScheduledRetryingExecutor.java b/sdk-platform-java/gax-java/gax/src/main/java/com/google/api/gax/retrying/ScheduledRetryingExecutor.java index 91a21fb9ff68..11606e2fd524 100644 --- a/sdk-platform-java/gax-java/gax/src/main/java/com/google/api/gax/retrying/ScheduledRetryingExecutor.java +++ b/sdk-platform-java/gax-java/gax/src/main/java/com/google/api/gax/retrying/ScheduledRetryingExecutor.java @@ -107,8 +107,7 @@ public RetryingFuture createFuture( /** * Submits an attempt for execution in a different thread. * - * @param retryingFuture the future previously returned by {@link #createFuture(Callable, - * RetryingContext)} + * @param retryingFuture the future returned by {@link #createFuture(Callable, RetryingContext)} * @return submitted attempt future */ @Override diff --git a/sdk-platform-java/gax-java/gax/src/main/java/com/google/api/gax/retrying/StreamingRetryAlgorithm.java b/sdk-platform-java/gax-java/gax/src/main/java/com/google/api/gax/retrying/StreamingRetryAlgorithm.java index 2ad0f6180e6c..c22450ede420 100644 --- a/sdk-platform-java/gax-java/gax/src/main/java/com/google/api/gax/retrying/StreamingRetryAlgorithm.java +++ b/sdk-platform-java/gax-java/gax/src/main/java/com/google/api/gax/retrying/StreamingRetryAlgorithm.java @@ -53,8 +53,8 @@ public final class StreamingRetryAlgorithm extends RetryAlgorithmUse {@link TimedRetryAlgorithmWithContext#createNextAttempt(RetryingContext, - * TimedAttemptSettings)} instead of this method when possible. + *

Use {@link TimedRetryAlgorithmWithContext#createNextAttempt} instead of this method when + * possible. */ TimedAttemptSettings createNextAttempt(TimedAttemptSettings prevSettings); /** - * Same as {@link TimedRetryAlgorithmWithContext#shouldRetry(RetryingContext, - * TimedAttemptSettings)}, but without a {@link RetryingContext}. + * Same as {@link TimedRetryAlgorithmWithContext#shouldRetry}, but without a {@link + * RetryingContext}. * - *

Use {@link TimedRetryAlgorithmWithContext#shouldRetry(RetryingContext, - * TimedAttemptSettings)} instead of this method when possible. + *

Use {@link TimedRetryAlgorithmWithContext#shouldRetry} instead of this method when possible. */ boolean shouldRetry(TimedAttemptSettings nextAttemptSettings) throws CancellationException; } diff --git a/sdk-platform-java/gax-java/gax/src/main/java/com/google/api/gax/rpc/Watchdog.java b/sdk-platform-java/gax-java/gax/src/main/java/com/google/api/gax/rpc/Watchdog.java index 1e0a12f0c816..d1e59c2d6cf4 100644 --- a/sdk-platform-java/gax-java/gax/src/main/java/com/google/api/gax/rpc/Watchdog.java +++ b/sdk-platform-java/gax-java/gax/src/main/java/com/google/api/gax/rpc/Watchdog.java @@ -80,10 +80,7 @@ public final class Watchdog implements Runnable, BackgroundResource { private final ScheduledExecutorService executor; private ScheduledFuture future; - /** - * This method is obsolete. Use {@link #createDuration(ApiClock, java.time.Duration, - * ScheduledExecutorService)} instead. - */ + /** This method is obsolete. Use {@link #createDuration} instead. */ @ObsoleteApi("Use createDuration(ApiClock, java.time.Duration, ScheduledExecutorService) instead") public static Watchdog create( ApiClock clock, @@ -113,10 +110,7 @@ private void start() { this, scheduleInterval.toMillis(), scheduleInterval.toMillis(), TimeUnit.MILLISECONDS); } - /** - * This method is obsolete. Use {@link #watchDuration(ResponseObserver, java.time.Duration, - * java.time.Duration)} instead. - */ + /** This method is obsolete. Use {@link #watchDuration} instead. */ @ObsoleteApi( "Use watchDuration(ResponseObserver, java.time.Duration, java.time.Duration) instead") public ResponseObserver watch( diff --git a/sdk-platform-java/java-core/google-cloud-core/src/main/java/com/google/cloud/RetryOption.java b/sdk-platform-java/java-core/google-cloud-core/src/main/java/com/google/cloud/RetryOption.java index f69b0d1c7654..b30dabd4d417 100644 --- a/sdk-platform-java/java-core/google-cloud-core/src/main/java/com/google/cloud/RetryOption.java +++ b/sdk-platform-java/java-core/google-cloud-core/src/main/java/com/google/cloud/RetryOption.java @@ -95,7 +95,7 @@ public static RetryOption maxAttempts(int maxAttempts) { return new RetryOption(OptionType.MAX_ATTEMPTS, maxAttempts); } - /** See {@link RetrySettings#isJittered()} ()}. */ + /** See {@link RetrySettings#isJittered()}. */ public static RetryOption jittered(boolean jittered) { return new RetryOption(OptionType.JITTERED, jittered); }