Address Checkstyle violations

This commit requires temporarily disabling some checks.
This commit is contained in:
Andrew Gaul 2013-04-17 15:45:25 -07:00
parent ae3cafdeef
commit fff2fa6e05
146 changed files with 182 additions and 183 deletions

View File

@ -225,8 +225,8 @@ public class AtmosAsyncBlobStore extends BaseAsyncBlobStore {
ListenableFuture<BoundedSet<? extends DirectoryEntry>> returnVal = async.listDirectory(container, nativeOptions); ListenableFuture<BoundedSet<? extends DirectoryEntry>> returnVal = async.listDirectory(container, nativeOptions);
ListenableFuture<PageSet<? extends StorageMetadata>> list = transform(returnVal, container2ResourceList, ListenableFuture<PageSet<? extends StorageMetadata>> list = transform(returnVal, container2ResourceList,
userExecutor); userExecutor);
return (options.isDetailed() ? transform(list, return options.isDetailed() ? transform(list,
fetchBlobMetadataProvider.get().setContainerName(container)) : list); fetchBlobMetadataProvider.get().setContainerName(container)) : list;
} }
/** /**

View File

@ -48,6 +48,7 @@ import org.jclouds.logging.Logger;
import com.google.common.base.Predicate; import com.google.common.base.Predicate;
import com.google.common.base.Supplier; import com.google.common.base.Supplier;
import com.google.common.util.concurrent.Atomics;
import com.google.common.util.concurrent.ListenableFuture; import com.google.common.util.concurrent.ListenableFuture;
import com.google.common.util.concurrent.ListeningExecutorService; import com.google.common.util.concurrent.ListeningExecutorService;
import com.google.common.util.concurrent.UncheckedTimeoutException; import com.google.common.util.concurrent.UncheckedTimeoutException;
@ -97,7 +98,7 @@ public class CloudServersImageExtension implements ImageExtension {
org.jclouds.cloudservers.domain.Image csImage = client.createImageFromServer(cloneTemplate.getName(), org.jclouds.cloudservers.domain.Image csImage = client.createImageFromServer(cloneTemplate.getName(),
Integer.parseInt(cloneTemplate.getSourceNodeId())); Integer.parseInt(cloneTemplate.getSourceNodeId()));
final AtomicReference<Image> image = new AtomicReference<Image>(new ImageBuilder() final AtomicReference<Image> image = Atomics.newReference(new ImageBuilder()
.location(location.get()) .location(location.get())
.ids(csImage.getId() + "") .ids(csImage.getId() + "")
.description(cloneTemplate.getName()) .description(cloneTemplate.getName())

View File

@ -38,7 +38,7 @@ public final class EncryptedPasswordAndPrivateKey {
return builder().fromEncryptedPasswordAndPrivateKey(this); return builder().fromEncryptedPasswordAndPrivateKey(this);
} }
public final static class Builder { public static final class Builder {
protected String encryptedPassword; protected String encryptedPassword;
protected String privateKey; protected String privateKey;

View File

@ -93,7 +93,7 @@ public class EC2ApiMetadata extends BaseRestApiMetadata {
return properties; return properties;
} }
public static abstract class Builder<T extends Builder<T>> extends BaseRestApiMetadata.Builder<T> { public abstract static class Builder<T extends Builder<T>> extends BaseRestApiMetadata.Builder<T> {
@SuppressWarnings("deprecation") @SuppressWarnings("deprecation")
protected Builder() { protected Builder() {
this(EC2Client.class, EC2AsyncClient.class); this(EC2Client.class, EC2AsyncClient.class);

View File

@ -50,4 +50,4 @@ public final class EC2Fallbacks {
throw propagate(t); throw propagate(t);
} }
} }
} }

View File

@ -55,6 +55,7 @@ import org.jclouds.logging.Logger;
import com.google.common.base.Predicate; import com.google.common.base.Predicate;
import com.google.common.base.Supplier; import com.google.common.base.Supplier;
import com.google.common.util.concurrent.Atomics;
import com.google.common.util.concurrent.ListenableFuture; import com.google.common.util.concurrent.ListenableFuture;
import com.google.common.util.concurrent.ListeningExecutorService; import com.google.common.util.concurrent.ListeningExecutorService;
import com.google.common.util.concurrent.UncheckedTimeoutException; import com.google.common.util.concurrent.UncheckedTimeoutException;
@ -110,7 +111,7 @@ public class EC2ImageExtension implements ImageExtension {
String imageId = ec2Client.getAMIServices().createImageInRegion(region, cloneTemplate.getName(), instanceId, String imageId = ec2Client.getAMIServices().createImageInRegion(region, cloneTemplate.getName(), instanceId,
CreateImageOptions.NONE); CreateImageOptions.NONE);
final AtomicReference<Image> image = new AtomicReference<Image>(new ImageBuilder() final AtomicReference<Image> image = Atomics.newReference(new ImageBuilder()
.location(find(locations.get(), idEquals(region))) .location(find(locations.get(), idEquals(region)))
.id(region + "/" + imageId) .id(region + "/" + imageId)
.providerId(imageId) .providerId(imageId)

View File

@ -161,7 +161,7 @@ public final class Subnet {
return builder().from(this); return builder().from(this);
} }
public final static class Builder { public static final class Builder {
private String subnetId; private String subnetId;
private State subnetState; private State subnetState;
private String vpcId; private String vpcId;

View File

@ -38,4 +38,4 @@ public class BindResourceIdsToIndexedFormParamsTest {
HttpRequest request = HttpRequest.builder().method("GET").endpoint("http://momma").build(); HttpRequest request = HttpRequest.builder().method("GET").endpoint("http://momma").build();
binder.bindToRequest(request, null); binder.bindToRequest(request, null);
} }
} }

View File

@ -61,4 +61,4 @@ public class BindTagsToIndexedFormParamsTest {
HttpRequest request = HttpRequest.builder().method("GET").endpoint("http://momma").build(); HttpRequest request = HttpRequest.builder().method("GET").endpoint("http://momma").build();
binder.bindToRequest(request, null); binder.bindToRequest(request, null);
} }
} }

View File

@ -135,4 +135,4 @@ public class SnapshotPredicates {
return snapshotApi.get(snapshot.getId()) == null; return snapshotApi.get(snapshot.getId()) == null;
} }
} }
} }

View File

@ -146,4 +146,4 @@ public class VolumePredicates {
return volumeApi.get(volume.getId()) == null; return volumeApi.get(volume.getId()) == null;
} }
} }
} }

View File

@ -73,7 +73,7 @@ public class KeystoneApiMetadata extends BaseRestApiMetadata {
return properties; return properties;
} }
public static abstract class Builder<T extends Builder<T>> extends BaseRestApiMetadata.Builder<T> { public abstract static class Builder<T extends Builder<T>> extends BaseRestApiMetadata.Builder<T> {
@SuppressWarnings("deprecation") @SuppressWarnings("deprecation")
protected Builder() { protected Builder() {
this(KeystoneApi.class, KeystoneAsyncApi.class); this(KeystoneApi.class, KeystoneAsyncApi.class);

View File

@ -48,4 +48,4 @@ public final class KeystoneFallbacks {
} }
} }
} }

View File

@ -178,4 +178,4 @@ public class ProviderModuleExpectTest extends BaseRestApiExpectTest<ProviderModu
return responseWithKeystoneAccess; return responseWithKeystoneAccess;
} }
} }
} }

View File

@ -46,4 +46,4 @@ public class BindKeyPairToJsonPayload extends BindToJsonPayload {
public <R extends HttpRequest> R bindToRequest(R request, Map<String, Object> postParams) { public <R extends HttpRequest> R bindToRequest(R request, Map<String, Object> postParams) {
return bindToRequest(request, (Object) ImmutableMap.of("keypair", ImmutableSortedMap.copyOf(postParams))); return bindToRequest(request, (Object) ImmutableMap.of("keypair", ImmutableSortedMap.copyOf(postParams)));
} }
} }

View File

@ -53,6 +53,7 @@ import org.jclouds.openstack.nova.v2_0.domain.zonescoped.ZoneAndId;
import com.google.common.base.Predicate; import com.google.common.base.Predicate;
import com.google.common.base.Supplier; import com.google.common.base.Supplier;
import com.google.common.util.concurrent.Atomics;
import com.google.common.util.concurrent.ListenableFuture; import com.google.common.util.concurrent.ListenableFuture;
import com.google.common.util.concurrent.ListeningExecutorService; import com.google.common.util.concurrent.ListeningExecutorService;
import com.google.common.util.concurrent.UncheckedTimeoutException; import com.google.common.util.concurrent.UncheckedTimeoutException;
@ -109,7 +110,7 @@ public class NovaImageExtension implements ImageExtension {
logger.info(">> Registered new Image %s, waiting for it to become available.", newImageId); logger.info(">> Registered new Image %s, waiting for it to become available.", newImageId);
final AtomicReference<Image> image = new AtomicReference<Image>(new ImageBuilder() final AtomicReference<Image> image = Atomics.newReference(new ImageBuilder()
.location(find(locations.get(), idEquals(targetImageZoneAndId.getZone()))) .location(find(locations.get(), idEquals(targetImageZoneAndId.getZone())))
.id(targetImageZoneAndId.slashEncode()) .id(targetImageZoneAndId.slashEncode())
.providerId(targetImageZoneAndId.getId()) .providerId(targetImageZoneAndId.getId())

View File

@ -47,7 +47,7 @@ public class ServerCreated extends Resource {
return builder().fromServerCreated(this); return builder().fromServerCreated(this);
} }
public final static class Builder extends Resource.Builder<Builder> { public static final class Builder extends Resource.Builder<Builder> {
protected String adminPass; protected String adminPass;
/** /**

View File

@ -86,4 +86,4 @@ public interface VolumeAttachmentApi {
* @return true if successful * @return true if successful
*/ */
boolean detachVolumeFromServer(String volumeId, String serverId); boolean detachVolumeFromServer(String volumeId, String serverId);
} }

View File

@ -91,4 +91,4 @@ public class OverLimitParser implements Function<String, Map<String, String>> {
return ImmutableMap.of(); return ImmutableMap.of();
} }
} }
} }

View File

@ -167,4 +167,4 @@ public class VolumeAttachmentApiExpectTest extends BaseNovaApiExpectTest {
protected VolumeAttachment testAttachment() { protected VolumeAttachment testAttachment() {
return VolumeAttachment.builder().device("/dev/vdc").serverId("b4785058-cb80-491b-baa3-e4ee6546450e").id("1").volumeId("1").build(); return VolumeAttachment.builder().device("/dev/vdc").serverId("b4785058-cb80-491b-baa3-e4ee6546450e").id("1").volumeId("1").build();
} }
} }

View File

@ -155,4 +155,4 @@ public class VolumeAttachmentApiLiveTest extends BaseNovaApiLiveTest {
} }
} }
} }

View File

@ -30,4 +30,4 @@ public enum SessionPersistence {
return UNRECOGNIZED; return UNRECOGNIZED;
} }
} }
} }

View File

@ -109,4 +109,4 @@ public interface AccessRuleApi {
@Path("/accesslist") @Path("/accesslist")
@Consumes("*/*") @Consumes("*/*")
boolean deleteAll(); boolean deleteAll();
} }

View File

@ -118,4 +118,4 @@ public interface ConnectionApi {
@Payload("{\"connectionLogging\":{\"enabled\":false}}") @Payload("{\"connectionLogging\":{\"enabled\":false}}")
@Path("/connectionlogging") @Path("/connectionlogging")
void disableConnectionLogging(); void disableConnectionLogging();
} }

View File

@ -81,4 +81,4 @@ public interface ContentCachingApi {
@Payload("{\"contentCaching\":{\"enabled\":false}}") @Payload("{\"contentCaching\":{\"enabled\":false}}")
@Path("/contentcaching") @Path("/contentcaching")
void disable(); void disable();
} }

View File

@ -81,4 +81,4 @@ public interface ErrorPageApi {
@Fallback(FalseOnNotFoundOr404.class) @Fallback(FalseOnNotFoundOr404.class)
@Path("/errorpage") @Path("/errorpage")
boolean delete(); boolean delete();
} }

View File

@ -83,4 +83,4 @@ public interface HealthMonitorApi {
@Path("/healthmonitor") @Path("/healthmonitor")
@Consumes("*/*") @Consumes("*/*")
boolean delete(); boolean delete();
} }

View File

@ -167,4 +167,4 @@ public interface ReportApi {
@Fallback(NullOnNotFoundOr404.class) @Fallback(NullOnNotFoundOr404.class)
@Path("/loadbalancers/algorithms") @Path("/loadbalancers/algorithms")
Iterable<String> listAlgorithms(); Iterable<String> listAlgorithms();
} }

View File

@ -116,4 +116,4 @@ public interface SSLTerminationApi {
@Path("/ssltermination") @Path("/ssltermination")
@Consumes("*/*") @Consumes("*/*")
boolean delete(); boolean delete();
} }

View File

@ -86,4 +86,4 @@ public interface SessionPersistenceApi {
@Fallback(VoidOnNotFoundOr404.class) @Fallback(VoidOnNotFoundOr404.class)
@Path("/sessionpersistence") @Path("/sessionpersistence")
void delete(); void delete();
} }

View File

@ -102,4 +102,4 @@ public interface VirtualIPApi {
@Path("/virtualips") @Path("/virtualips")
@Consumes("*/*") @Consumes("*/*")
boolean delete(@QueryParam("id") Iterable<Integer> ids); boolean delete(@QueryParam("id") Iterable<Integer> ids);
} }

View File

@ -135,4 +135,4 @@ public class LoadBalancerPredicates {
} }
} }
} }
} }

View File

@ -133,7 +133,7 @@ public class ChangeBatch extends ForwardingList<ActionOnResourceRecordSet> {
return new Builder(); return new Builder();
} }
public final static class Builder { public static final class Builder {
private Optional<String> comment = Optional.absent(); private Optional<String> comment = Optional.absent();
private ImmutableList.Builder<ActionOnResourceRecordSet> changes = ImmutableList.builder(); private ImmutableList.Builder<ActionOnResourceRecordSet> changes = ImmutableList.builder();

View File

@ -108,7 +108,7 @@ public final class HostedZone {
return builder().from(this); return builder().from(this);
} }
public final static class Builder { public static final class Builder {
private String id; private String id;
private String name; private String name;
private String callerReference; private String callerReference;

View File

@ -95,7 +95,7 @@ public class ResourceRecordSet {
/** /**
* A portion of a RRs who share the same name and type * A portion of a RRs who share the same name and type
*/ */
public static abstract class RecordSubset extends ResourceRecordSet { public abstract static class RecordSubset extends ResourceRecordSet {
public static final class Weighted extends RecordSubset { public static final class Weighted extends RecordSubset {
private final int weight; private final int weight;
@ -261,7 +261,7 @@ public class ResourceRecordSet {
return builder().from(this); return builder().from(this);
} }
public final static class Builder { public static final class Builder {
private String id; private String id;
private String name; private String name;
private String type; private String type;

View File

@ -94,7 +94,7 @@ public class S3ApiMetadata extends BaseRestApiMetadata {
return properties; return properties;
} }
public static abstract class Builder<T extends Builder<T>> extends BaseRestApiMetadata.Builder<T> { public abstract static class Builder<T extends Builder<T>> extends BaseRestApiMetadata.Builder<T> {
@SuppressWarnings("deprecation") @SuppressWarnings("deprecation")
protected Builder() { protected Builder() {
this(S3Client.class, S3AsyncClient.class); this(S3Client.class, S3AsyncClient.class);

View File

@ -51,4 +51,4 @@ public final class S3Fallbacks {
throw propagate(t); throw propagate(t);
} }
} }
} }

View File

@ -109,7 +109,7 @@ public final class SessionCredentials extends Credentials {
return builder().from(this); return builder().from(this);
} }
public final static class Builder extends Credentials.Builder<SessionCredentials> { public static final class Builder extends Credentials.Builder<SessionCredentials> {
private String accessKeyId; private String accessKeyId;
private String secretAccessKey; private String secretAccessKey;
private String sessionToken; private String sessionToken;

View File

@ -26,7 +26,8 @@ import static com.google.common.io.BaseEncoding.base64;
import static com.google.common.io.ByteStreams.readBytes; import static com.google.common.io.ByteStreams.readBytes;
import static org.jclouds.aws.reference.FormParameters.ACTION; import static org.jclouds.aws.reference.FormParameters.ACTION;
import static org.jclouds.aws.reference.FormParameters.AWS_ACCESS_KEY_ID; import static org.jclouds.aws.reference.FormParameters.AWS_ACCESS_KEY_ID;
import static org.jclouds.aws.reference.FormParameters.*; import static org.jclouds.aws.reference.FormParameters.SECURITY_TOKEN;
import static org.jclouds.aws.reference.FormParameters.SIGNATURE;
import static org.jclouds.aws.reference.FormParameters.SIGNATURE_METHOD; import static org.jclouds.aws.reference.FormParameters.SIGNATURE_METHOD;
import static org.jclouds.aws.reference.FormParameters.SIGNATURE_VERSION; import static org.jclouds.aws.reference.FormParameters.SIGNATURE_VERSION;
import static org.jclouds.aws.reference.FormParameters.TIMESTAMP; import static org.jclouds.aws.reference.FormParameters.TIMESTAMP;

View File

@ -37,7 +37,7 @@ public final class UserAndSessionCredentials {
return builder().from(this); return builder().from(this);
} }
public final static class Builder { public static final class Builder {
private User user; private User user;
private SessionCredentials credentials; private SessionCredentials credentials;
private int packedPolicySize; private int packedPolicySize;

View File

@ -78,7 +78,7 @@ public class SwiftApiMetadata extends BaseRestApiMetadata {
return properties; return properties;
} }
public static abstract class Builder<T extends Builder<T>> extends BaseRestApiMetadata.Builder<T> { public abstract static class Builder<T extends Builder<T>> extends BaseRestApiMetadata.Builder<T> {
@SuppressWarnings("deprecation") @SuppressWarnings("deprecation")
protected Builder() { protected Builder() {
this(SwiftClient.class, SwiftAsyncClient.class); this(SwiftClient.class, SwiftAsyncClient.class);

View File

@ -75,7 +75,7 @@ public class SwiftKeystoneApiMetadata extends SwiftApiMetadata {
return properties; return properties;
} }
public static abstract class Builder<T extends Builder<T>> extends SwiftApiMetadata.Builder<T> { public abstract static class Builder<T extends Builder<T>> extends SwiftApiMetadata.Builder<T> {
protected Builder() { protected Builder() {
this(SwiftKeystoneClient.class, SwiftKeystoneAsyncClient.class); this(SwiftKeystoneClient.class, SwiftKeystoneAsyncClient.class);
} }

View File

@ -53,4 +53,4 @@ public class BasePayloadTest {
throw Throwables.propagate(e); throw Throwables.propagate(e);
} }
} }
} }

View File

@ -50,4 +50,4 @@ public class BasePayloadTest {
throw Throwables.propagate(e); throw Throwables.propagate(e);
} }
} }
} }

View File

@ -63,4 +63,4 @@ public final class TerremarkVCloudFallbacks {
} }
} }
} }

View File

@ -39,4 +39,4 @@ public class BasePayloadTest {
throw Throwables.propagate(e); throw Throwables.propagate(e);
} }
} }
} }

View File

@ -20,7 +20,8 @@ package org.jclouds.compute.domain;
import static com.google.common.base.Preconditions.checkNotNull; import static com.google.common.base.Preconditions.checkNotNull;
import static com.google.common.base.CaseFormat.*; import static com.google.common.base.CaseFormat.LOWER_HYPHEN;
import static com.google.common.base.CaseFormat.UPPER_UNDERSCORE;
/** /**
* Running Operating system * Running Operating system

View File

@ -42,4 +42,4 @@ public interface Fallback<V> extends FutureFallback<V> {
* the exception that made the call fail. * the exception that made the call fail.
*/ */
V createOrPropagate(Throwable t) throws Exception; V createOrPropagate(Throwable t) throws Exception;
} }

View File

@ -204,4 +204,4 @@ public final class Fallbacks {
return getFirstThrowableOfType(from, ResourceNotFoundException.class) != null; return getFirstThrowableOfType(from, ResourceNotFoundException.class) != null;
} }
} }

View File

@ -77,7 +77,7 @@ public abstract class BaseApiMetadata implements ApiMetadata {
return props; return props;
} }
public static abstract class Builder<T extends Builder<T>> implements ApiMetadata.Builder<T> { public abstract static class Builder<T extends Builder<T>> implements ApiMetadata.Builder<T> {
protected abstract T self(); protected abstract T self();
private String id; private String id;

View File

@ -88,7 +88,7 @@ public class IterableWithMarkers {
} }
} }
private static abstract class ForwardingIterableWithMarker<T> extends IterableWithMarker<T> { private abstract static class ForwardingIterableWithMarker<T> extends IterableWithMarker<T> {
protected abstract IterableWithMarker<T> delegate(); protected abstract IterableWithMarker<T> delegate();

View File

@ -97,7 +97,7 @@ public abstract class Arg0ToPagedIterable<T, I extends Arg0ToPagedIterable<T, I>
* *
* @author Adrian Cole * @author Adrian Cole
*/ */
public static abstract class FromCaller<T, I extends FromCaller<T, I>> extends Arg0ToPagedIterable<T, I> { public abstract static class FromCaller<T, I extends FromCaller<T, I>> extends Arg0ToPagedIterable<T, I> {
@Override @Override
protected List<Object> getArgs(GeneratedHttpRequest request) { protected List<Object> getArgs(GeneratedHttpRequest request) {
return request.getCaller().get().getArgs(); return request.getCaller().get().getArgs();

View File

@ -113,7 +113,7 @@ public class WithSubmissionTrace {
} }
} }
private final static Set<String> stackTracesToTrim = ImmutableSet.of(WithSubmissionTrace.class.getName(), private static final Set<String> stackTracesToTrim = ImmutableSet.of(WithSubmissionTrace.class.getName(),
ListeningExecutorService.class.getName(), ListenableFuture.class.getName(), ListeningExecutorService.class.getName(), ListenableFuture.class.getName(),
ListeningScheduledExecutorService.class.getName(), ScheduledFuture.class.getName()); ListeningScheduledExecutorService.class.getName(), ScheduledFuture.class.getName());

View File

@ -123,4 +123,4 @@ public final class HeaderToRetryAfterException implements PropagateIfRetryAfter
return Optional.absent(); return Optional.absent();
} }
} }

View File

@ -37,4 +37,4 @@ public interface PropagateIfRetryAfter extends FutureFallback<Object> {
@Override @Override
ListenableFuture<Object> create(Throwable t); ListenableFuture<Object> create(Throwable t);
} }

View File

@ -18,7 +18,7 @@
*/ */
package org.jclouds.http; package org.jclouds.http;
import static com.google.common.base.Preconditions.*; import static com.google.common.base.Preconditions.checkNotNull;
import java.util.Map; import java.util.Map;
@ -72,4 +72,4 @@ public class UriTemplates {
} }
return builder.toString(); return builder.toString();
} }
} }

View File

@ -199,7 +199,7 @@ public class NamingStrategies {
/** /**
* Determines field naming from constructor annotations * Determines field naming from constructor annotations
*/ */
public final static class AnnotationConstructorNamingStrategy extends AnnotationBasedNamingStrategy { public static final class AnnotationConstructorNamingStrategy extends AnnotationBasedNamingStrategy {
private final Predicate<Invokable<?, ?>> hasMarker; private final Predicate<Invokable<?, ?>> hasMarker;
private final Collection<? extends Class<? extends Annotation>> markers; private final Collection<? extends Class<? extends Annotation>> markers;

View File

@ -59,4 +59,4 @@ public interface ProxyConfig {
*/ */
Optional<Credentials> getCredentials(); Optional<Credentials> getCredentials();
} }

View File

@ -144,4 +144,4 @@ public final class FunctionalReflection {
return invocationFunction.toString(); return invocationFunction.toString();
} }
} }
} }

View File

@ -306,8 +306,8 @@ public class Reflection2 {
return false; return false;
} }
String packageName = clazzPackage.getName(); String packageName = clazzPackage.getName();
return (packageName.startsWith("com.sun.") || packageName.startsWith("java.") return packageName.startsWith("com.sun.") || packageName.startsWith("java.")
|| packageName.startsWith("javax.") || packageName.startsWith("sun.")); || packageName.startsWith("javax.") || packageName.startsWith("sun.");
} }
/** /**
@ -322,4 +322,4 @@ public class Reflection2 {
throw propagate(e.getCause()); throw propagate(e.getCause());
} }
} }
} }

View File

@ -42,4 +42,4 @@ public class Types2 {
"unbound type variable: %s, use ctor that explicitly assigns this", type); "unbound type variable: %s, use ctor that explicitly assigns this", type);
return type; return type;
} }
} }

View File

@ -52,4 +52,4 @@ public interface InvocationConfig {
* fallback used for Sync or Async commands. * fallback used for Sync or Async commands.
*/ */
Fallback<?> getFallback(Invocation invocation); Fallback<?> getFallback(Invocation invocation);
} }

View File

@ -115,4 +115,4 @@ public class ReadAnnotationsAndProperties implements InvocationConfig {
} }
}); });
} }
} }

View File

@ -147,4 +147,4 @@ public class SyncToAsyncHttpInvocationModule extends AbstractModule {
} }
}), Class.class); }), Class.class);
} }
} }

View File

@ -61,7 +61,7 @@ public abstract class BaseHttpApiMetadata<A> extends BaseApiMetadata implements
}, apiToken); }, apiToken);
} }
public static abstract class Builder<A, T extends Builder<A, T>> extends BaseApiMetadata.Builder<T> implements public abstract static class Builder<A, T extends Builder<A, T>> extends BaseApiMetadata.Builder<T> implements
HttpApiMetadata.Builder<A, T> { HttpApiMetadata.Builder<A, T> {
protected Class<A> api; protected Class<A> api;

View File

@ -64,7 +64,7 @@ public abstract class BaseRestApiMetadata extends BaseApiMetadata implements Res
}, asyncApiToken); }, asyncApiToken);
} }
public static abstract class Builder<T extends Builder<T>> extends BaseApiMetadata.Builder<T> implements RestApiMetadata.Builder<T> { public abstract static class Builder<T extends Builder<T>> extends BaseApiMetadata.Builder<T> implements RestApiMetadata.Builder<T> {
protected Class<?> api; protected Class<?> api;
protected Class<?> asyncApi; protected Class<?> asyncApi;

View File

@ -272,4 +272,4 @@ public class DelegatesToInvocationFunction<S, F extends Function<Invocation, Obj
return Objects.toStringHelper("").omitNullValues().add("ownerType", ownerType.getRawType().getSimpleName()) return Objects.toStringHelper("").omitNullValues().add("ownerType", ownerType.getRawType().getSimpleName())
.add("methodInvoker", methodInvoker).toString(); .add("methodInvoker", methodInvoker).toString();
} }
} }

View File

@ -71,4 +71,4 @@ public final class DelegatesToPotentiallySyncToAsyncInvocationFunction<S, F exte
} }
return super.methodInvokerFor(returnType); return super.methodInvokerFor(returnType);
} }
} }

View File

@ -45,7 +45,7 @@ public final class GeneratedHttpRequest extends HttpRequest {
return new Builder().fromGeneratedHttpRequest(this); return new Builder().fromGeneratedHttpRequest(this);
} }
public final static class Builder extends HttpRequest.Builder<Builder> { public static final class Builder extends HttpRequest.Builder<Builder> {
private Invocation invocation; private Invocation invocation;
private Optional<Invocation> caller = Optional.absent(); private Optional<Invocation> caller = Optional.absent();

View File

@ -36,4 +36,4 @@ class GetAcceptHeaders implements Function<Invocation, Set<String>> {
Optional.fromNullable(invocation.getInvokable().getOwnerType().getRawType().getAnnotation(Consumes.class))); Optional.fromNullable(invocation.getInvokable().getOwnerType().getRawType().getAnnotation(Consumes.class)));
return (accept.isPresent()) ? ImmutableSet.copyOf(accept.get().value()) : ImmutableSet.<String> of(); return (accept.isPresent()) ? ImmutableSet.copyOf(accept.get().value()) : ImmutableSet.<String> of();
} }
} }

View File

@ -223,4 +223,4 @@ public class InvokeHttpMethod implements Function<Invocation, Object> {
public String toString() { public String toString() {
return Objects.toStringHelper("").omitNullValues().add("annotationParser", annotationProcessor).toString(); return Objects.toStringHelper("").omitNullValues().add("annotationParser", annotationProcessor).toString();
} }
} }

View File

@ -274,4 +274,4 @@ public class InvokeSyncToAsyncHttpMethod implements Function<Invocation, Object>
public String toString() { public String toString() {
return Objects.toStringHelper("").omitNullValues().add("annotationParser", annotationProcessor).toString(); return Objects.toStringHelper("").omitNullValues().add("annotationParser", annotationProcessor).toString();
} }
} }

View File

@ -572,8 +572,8 @@ public class RestAnnotationProcessor implements Function<Invocation, HttpRequest
} }
private boolean shouldAddHostHeader(Invocation invocation) { private boolean shouldAddHostHeader(Invocation invocation) {
return (invocation.getInvokable().getOwnerType().getRawType().isAnnotationPresent(VirtualHost.class) || invocation return invocation.getInvokable().getOwnerType().getRawType().isAnnotationPresent(VirtualHost.class) || invocation
.getInvokable().isAnnotationPresent(VirtualHost.class)); .getInvokable().isAnnotationPresent(VirtualHost.class);
} }
private GeneratedHttpRequest decorateRequest(GeneratedHttpRequest request) throws NegativeArraySizeException { private GeneratedHttpRequest decorateRequest(GeneratedHttpRequest request) throws NegativeArraySizeException {

View File

@ -225,4 +225,4 @@ public class TransformerForRequest implements Function<HttpRequest, Function<Htt
} }
return null; return null;
} }
} }

View File

@ -41,7 +41,7 @@ import com.google.common.reflect.Invokable;
@Test(testName = "Arg0ToPagedIterableTest") @Test(testName = "Arg0ToPagedIterableTest")
public class Arg0ToPagedIterableTest { public class Arg0ToPagedIterableTest {
private static abstract class TestArg0 extends Arg0ToPagedIterable<String, TestArg0> { private abstract static class TestArg0 extends Arg0ToPagedIterable<String, TestArg0> {
private TestArg0(GeneratedHttpRequest in) { private TestArg0(GeneratedHttpRequest in) {
this.setContext(in); this.setContext(in);
} }
@ -112,7 +112,7 @@ public class Arg0ToPagedIterableTest {
} }
} }
private static abstract class TestCallerArg0 extends Arg0ToPagedIterable.FromCaller<String, TestCallerArg0> { private abstract static class TestCallerArg0 extends Arg0ToPagedIterable.FromCaller<String, TestCallerArg0> {
private TestCallerArg0(GeneratedHttpRequest in) { private TestCallerArg0(GeneratedHttpRequest in) {
this.setContext(in); this.setContext(in);
} }

View File

@ -42,7 +42,7 @@ public final class SessionConnection implements Connection<Session> {
return new Builder(); return new Builder();
} }
public final static class Builder { public static final class Builder {
private HostAndPort hostAndPort; private HostAndPort hostAndPort;
private LoginCredentials loginCredentials; private LoginCredentials loginCredentials;

View File

@ -83,4 +83,4 @@ public interface DynECTApi extends Closeable {
*/ */
@Delegate @Delegate
RecordApi getRecordApiForZone(@PathParam("zone") String zone); RecordApi getRecordApiForZone(@PathParam("zone") String zone);
} }

View File

@ -46,4 +46,4 @@ public interface DynECTExceptions {
super(message, cause); super(message, cause);
} }
} }
} }

View File

@ -42,4 +42,4 @@ public class RecordIdBinder implements Binder {
.put("id", valueToAppend.getId()).build()); .put("id", valueToAppend.getId()).build());
return (R) request.toBuilder().endpoint(path).build(); return (R) request.toBuilder().endpoint(path).build();
} }
} }

View File

@ -118,7 +118,7 @@ public class DynECTHttpApiModule extends HttpApiModule<DynECTApi> {
* synchronized to prevent multiple callers from overlapping requests on the same session * synchronized to prevent multiple callers from overlapping requests on the same session
*/ */
@Override @Override
synchronized protected HttpResponse invoke(HttpURLConnection connection) throws IOException, InterruptedException { protected synchronized HttpResponse invoke(HttpURLConnection connection) throws IOException, InterruptedException {
HttpResponse response = super.invoke(connection); HttpResponse response = super.invoke(connection);
if (response.getStatusCode() == 200) { if (response.getStatusCode() == 200) {
byte[] data = closeClientButKeepContentStream(response); byte[] data = closeClientButKeepContentStream(response);

View File

@ -106,7 +106,7 @@ public final class CreatePrimaryZone {
return builder().from(this); return builder().from(this);
} }
public final static class Builder { public static final class Builder {
private String fqdn; private String fqdn;
private String contact; private String contact;
private int defaultTTL = 3600; private int defaultTTL = 3600;
@ -158,4 +158,4 @@ public final class CreatePrimaryZone {
return CreatePrimaryZone.class.cast(in).getFQDN(); return CreatePrimaryZone.class.cast(in).getFQDN();
} }
} }
} }

View File

@ -155,4 +155,4 @@ public class CreateRecord<D extends Map<String, Object>> {
return fqdn(in.getFQDN()).type(in.getType()).ttl(in.getTTL()).rdata(in.getRData()); return fqdn(in.getFQDN()).type(in.getType()).ttl(in.getTTL()).rdata(in.getRData());
} }
} }
} }

View File

@ -114,4 +114,4 @@ public class Record<D extends Map<String, Object>> extends RecordId {
return this; return this;
} }
} }
} }

View File

@ -163,4 +163,4 @@ public class RecordId {
return this; return this;
} }
} }
} }

View File

@ -66,7 +66,7 @@ public final class SOARecord extends Record<SOAData> {
return builder().from(this); return builder().from(this);
} }
public final static class Builder extends Record.Builder<SOAData, Builder> { public static final class Builder extends Record.Builder<SOAData, Builder> {
private SerialStyle serialStyle; private SerialStyle serialStyle;
@ -96,4 +96,4 @@ public final class SOARecord extends Record<SOAData> {
return this; return this;
} }
} }
} }

View File

@ -26,7 +26,7 @@ public final class SessionCredentials extends Credentials {
return builder().from(this); return builder().from(this);
} }
public final static class Builder extends Credentials.Builder<SessionCredentials> { public static final class Builder extends Credentials.Builder<SessionCredentials> {
private String customerName; private String customerName;
private String userName; private String userName;
private String password; private String password;

View File

@ -156,7 +156,7 @@ public final class Zone {
return builder().from(this); return builder().from(this);
} }
public final static class Builder { public static final class Builder {
private String fqdn; private String fqdn;
private Type type; private Type type;
private int serial; private int serial;
@ -202,4 +202,4 @@ public final class Zone {
return this.fqdn(in.fqdn).type(in.type).serial(in.serial).serialStyle(in.serialStyle); return this.fqdn(in.fqdn).type(in.type).serial(in.serial).serialStyle(in.serialStyle);
} }
} }
} }

View File

@ -73,7 +73,7 @@ public class AAAAData extends ForwardingMap<String, Object> {
return builder().from(this); return builder().from(this);
} }
public final static class Builder { public static final class Builder {
private String address; private String address;
/** /**
@ -92,4 +92,4 @@ public class AAAAData extends ForwardingMap<String, Object> {
return this.address(in.getAddress()); return this.address(in.getAddress());
} }
} }
} }

View File

@ -74,7 +74,7 @@ public class AData extends ForwardingMap<String, Object> {
return builder().from(this); return builder().from(this);
} }
public final static class Builder { public static final class Builder {
private String address; private String address;
/** /**
@ -93,4 +93,4 @@ public class AData extends ForwardingMap<String, Object> {
return this.address(in.getAddress()); return this.address(in.getAddress());
} }
} }
} }

View File

@ -75,7 +75,7 @@ public class CNAMEData extends ForwardingMap<String, Object> {
return builder().from(this); return builder().from(this);
} }
public final static class Builder { public static final class Builder {
private String cname; private String cname;
/** /**
@ -94,4 +94,4 @@ public class CNAMEData extends ForwardingMap<String, Object> {
return this.cname(in.getCname()); return this.cname(in.getCname());
} }
} }
} }

View File

@ -89,7 +89,7 @@ public class MXData extends ForwardingMap<String, Object> {
return builder().from(this); return builder().from(this);
} }
public final static class Builder { public static final class Builder {
private int preference = -1; private int preference = -1;
private String exchange; private String exchange;
@ -117,4 +117,4 @@ public class MXData extends ForwardingMap<String, Object> {
return this.preference(in.getPreference()).exchange(in.getExchange()); return this.preference(in.getPreference()).exchange(in.getExchange());
} }
} }
} }

View File

@ -75,7 +75,7 @@ public class NSData extends ForwardingMap<String, Object> {
return builder().from(this); return builder().from(this);
} }
public final static class Builder { public static final class Builder {
private String nsdname; private String nsdname;
/** /**
@ -94,4 +94,4 @@ public class NSData extends ForwardingMap<String, Object> {
return this.nsdname(in.getNsdname()); return this.nsdname(in.getNsdname());
} }
} }
} }

View File

@ -74,7 +74,7 @@ public class PTRData extends ForwardingMap<String, Object> {
return builder().from(this); return builder().from(this);
} }
public final static class Builder { public static final class Builder {
private String ptrdname; private String ptrdname;
/** /**
@ -93,4 +93,4 @@ public class PTRData extends ForwardingMap<String, Object> {
return this.ptrdname(in.getPtrdname()); return this.ptrdname(in.getPtrdname());
} }
} }
} }

View File

@ -145,7 +145,7 @@ public class SOAData extends ForwardingMap<String, Object> {
return builder().from(this); return builder().from(this);
} }
public final static class Builder { public static final class Builder {
private String mname; private String mname;
private String rname; private String rname;
private int serial = -1; private int serial = -1;
@ -219,4 +219,4 @@ public class SOAData extends ForwardingMap<String, Object> {
.expire(in.getExpire()).minimum(in.getMinimum()); .expire(in.getExpire()).minimum(in.getMinimum());
} }
} }
} }

View File

@ -113,7 +113,7 @@ public class SRVData extends ForwardingMap<String, Object> {
return builder().from(this); return builder().from(this);
} }
public final static class Builder { public static final class Builder {
private int priority = -1; private int priority = -1;
private int weight = -1; private int weight = -1;
private int port = -1; private int port = -1;
@ -159,4 +159,4 @@ public class SRVData extends ForwardingMap<String, Object> {
return this.priority(in.getPriority()).weight(in.getWeight()).port(in.getPort()).target(in.getTarget()); return this.priority(in.getPriority()).weight(in.getWeight()).port(in.getPort()).target(in.getTarget());
} }
} }
} }

View File

@ -85,7 +85,7 @@ public class SSHFPData extends ForwardingMap<String, Object> {
return fingerprint; return fingerprint;
} }
public final static class Builder { public static final class Builder {
private int algorithm; private int algorithm;
private int fptype; private int fptype;
private String fingerprint; private String fingerprint;

View File

@ -74,7 +74,7 @@ public class TXTData extends ForwardingMap<String, Object> {
return builder().from(this); return builder().from(this);
} }
public final static class Builder { public static final class Builder {
private String txtdata; private String txtdata;
/** /**
@ -93,4 +93,4 @@ public class TXTData extends ForwardingMap<String, Object> {
return this.txtdata(in.getTxtdata()); return this.txtdata(in.getTxtdata());
} }
} }
} }

View File

@ -379,4 +379,4 @@ public interface RecordApi {
@Nullable @Nullable
Record<TXTData> getTXT(@PathParam("fqdn") String fqdn, @PathParam("id") long recordId) Record<TXTData> getTXT(@PathParam("fqdn") String fqdn, @PathParam("id") long recordId)
throws JobStillRunningException; throws JobStillRunningException;
} }

View File

@ -60,4 +60,4 @@ public interface SessionApi {
@Named("DELETE:Session") @Named("DELETE:Session")
@DELETE @DELETE
void logout(@HeaderParam("Auth-Token") String token); void logout(@HeaderParam("Auth-Token") String token);
} }

View File

@ -219,4 +219,4 @@ public interface ZoneApi {
@Payload("{\"thaw\":true}") @Payload("{\"thaw\":true}")
@Consumes(APPLICATION_JSON) @Consumes(APPLICATION_JSON)
Job thaw(@PathParam("fqdn") String fqdn) throws JobStillRunningException; Job thaw(@PathParam("fqdn") String fqdn) throws JobStillRunningException;
} }

Some files were not shown because too many files have changed in this diff Show More