Make javadoc <p> style guide compliant

This led to confusion for an open source contributor about how to format
code. We don't want to be like, "do as I say, not as I do."

https://google.github.io/styleguide/javaguide.html#s7.1.2-javadoc-paragraphs
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=122589700
This commit is contained in:
Justine Tunney 2016-05-17 18:56:33 -07:00
parent 4854f875b0
commit 6f4b059cc9
79 changed files with 395 additions and 386 deletions

View file

@ -26,22 +26,22 @@ import java.util.concurrent.TimeUnit;
/**
* A factory for {@link TimeLimiter} instances that use request threads, which carry the namespace
* and live only as long as the request that spawned them.
* <p>
* It is safe to reuse instances of this class, but there is no benefit in doing so over creating a
* fresh instance each time.
*
* <p>It is safe to reuse instances of this class, but there is no benefit in doing so over creating
* a fresh instance each time.
*/
public class AppEngineTimeLimiter {
/**
* An {@code ExecutorService} that uses a new thread for every task.
* <p>
* We need to use fresh threads for each request so that we can use App Engine's request threads.
* If we cached these threads in a thread pool (and if we were executing on a backend, where there
* is no time limit on requests) the caching would cause the thread to keep the task that opened
* it alive even after returning an http response, and would also cause the namespace that the
* original thread was created in to leak out to later reuses of the thread.
* <p>
* Since there are no cached resources, this class doesn't have to support being shutdown.
*
* <p>We need to use fresh threads for each request so that we can use App Engine's request
* threads. If we cached these threads in a thread pool (and if we were executing on a backend,
* where there is no time limit on requests) the caching would cause the thread to keep the task
* that opened it alive even after returning an http response, and would also cause the namespace
* that the original thread was created in to leak out to later reuses of the thread.
*
* <p>Since there are no cached resources, this class doesn't have to support being shutdown.
*/
private static class NewRequestThreadExecutorService extends AbstractExecutorService {

View file

@ -113,9 +113,9 @@ public class CollectionUtils {
/**
* Turns an empty collection into a null collection.
* <p>
* This is unwise in the general case (nulls are bad; empties are good) but occasionally needed to
* cause JAXB not to emit a field, or to avoid saving something to datastore. The method name
*
* <p>This is unwise in the general case (nulls are bad; empties are good) but occasionally needed
* to cause JAXB not to emit a field, or to avoid saving something to datastore. The method name
* includes "force" to indicate that you should think twice before using it.
*/
@Nullable

View file

@ -31,10 +31,10 @@ public class DateTimeUtils {
/**
* A date in the far future that we can treat as infinity.
* <p>
* This value is (2^63-1)/1000 rounded down. AppEngine stores dates as 64 bit microseconds, but
* Java uses milliseconds, so this is the largest representable date that will survive
* a round-trip through the datastore.
*
* <p>This value is (2^63-1)/1000 rounded down. AppEngine stores dates as 64 bit microseconds, but
* Java uses milliseconds, so this is the largest representable date that will survive a
* round-trip through the datastore.
*/
public static final DateTime END_OF_TIME = new DateTime(Long.MAX_VALUE / 1000, DateTimeZone.UTC);

View file

@ -53,9 +53,9 @@ public final class X509Utils {
/**
* Parse the encoded certificate and return a base64 encoded string (without padding) of the
* SHA-256 digest of the certificate.
* <p>
* Note that this must match the method used by the GFE to generate the client certificate hash so
* that the two will match when we check against the whitelist.
*
* <p>Note that this must match the method used by the GFE to generate the client certificate hash
* so that the two will match when we check against the whitelist.
*/
public static String getCertificateHash(X509Certificate cert) {
try {