removed unused variables, imports, fixed compiler warnings

This commit is contained in:
Adrian Cole 2012-01-04 14:32:53 -08:00
parent 5f37331a4b
commit f1135db892
22 changed files with 107 additions and 114 deletions

View File

@ -1,6 +1,5 @@
package org.jclouds.glesys.domain;
import com.google.common.base.Joiner;
import com.google.common.base.Objects;
import com.google.gson.annotations.SerializedName;
@ -101,7 +100,6 @@ public class EmailOverviewSummary {
@Override
public String toString() {
Joiner commaJoiner = Joiner.on(", ");
return String.format("accounts=%d, maxAccounts=%d, aliases=%d, maxAliases=%d", accounts, maxAccounts, aliases, maxAliases);
}

View File

@ -3,13 +3,13 @@ package org.jclouds.glesys.domain;
import static com.google.common.base.Preconditions.checkNotNull;
import java.util.Arrays;
import java.util.Collections;
import java.util.List;
import org.jclouds.javax.annotation.Nullable;
import com.google.common.base.Objects;
import com.google.common.collect.ImmutableList;
import com.google.gson.annotations.SerializedName;
import org.jclouds.javax.annotation.Nullable;
/**
* Connection information to connect to a server with VNC.

View File

@ -20,7 +20,6 @@ package org.jclouds.glesys.domain;
import static com.google.common.base.Preconditions.checkNotNull;
import com.google.common.base.Objects;
import com.google.gson.annotations.SerializedName;
/**

View File

@ -18,8 +18,16 @@
*/
package org.jclouds.glesys.features;
import com.google.common.util.concurrent.ListenableFuture;
import org.jclouds.glesys.domain.*;
import java.util.Set;
import javax.ws.rs.Consumes;
import javax.ws.rs.FormParam;
import javax.ws.rs.POST;
import javax.ws.rs.Path;
import javax.ws.rs.core.MediaType;
import org.jclouds.glesys.domain.Email;
import org.jclouds.glesys.domain.EmailOverview;
import org.jclouds.glesys.options.EmailCreateOptions;
import org.jclouds.glesys.options.EmailEditOptions;
import org.jclouds.http.filters.BasicAuthentication;
@ -27,11 +35,8 @@ import org.jclouds.rest.annotations.ExceptionParser;
import org.jclouds.rest.annotations.RequestFilters;
import org.jclouds.rest.annotations.SelectJson;
import org.jclouds.rest.functions.ReturnEmptySetOnNotFoundOr404;
import org.jclouds.rest.functions.ReturnNullOnNotFoundOr404;
import javax.ws.rs.*;
import javax.ws.rs.core.MediaType;
import java.util.Set;
import com.google.common.util.concurrent.ListenableFuture;
/**
* Provides asynchronous access to E-Mail data via the Glesys REST API.

View File

@ -18,16 +18,15 @@
*/
package org.jclouds.glesys.features;
import java.util.Set;
import java.util.concurrent.TimeUnit;
import org.jclouds.concurrent.Timeout;
import org.jclouds.glesys.domain.Email;
import org.jclouds.glesys.domain.EmailOverview;
import org.jclouds.glesys.options.EmailCreateOptions;
import org.jclouds.glesys.options.EmailEditOptions;
import javax.ws.rs.FormParam;
import java.util.Set;
import java.util.concurrent.TimeUnit;
/**
* Provides synchronous access to E-Mail requests.
* <p/>

View File

@ -18,16 +18,28 @@
*/
package org.jclouds.glesys.features;
import org.jclouds.concurrent.Timeout;
import org.jclouds.glesys.domain.*;
import org.jclouds.glesys.options.*;
import org.jclouds.javax.annotation.Nullable;
import javax.ws.rs.FormParam;
import java.util.Map;
import java.util.Set;
import java.util.concurrent.TimeUnit;
import javax.ws.rs.FormParam;
import org.jclouds.concurrent.Timeout;
import org.jclouds.glesys.domain.Server;
import org.jclouds.glesys.domain.ServerAllowedArguments;
import org.jclouds.glesys.domain.ServerConsole;
import org.jclouds.glesys.domain.ServerCreated;
import org.jclouds.glesys.domain.ServerDetails;
import org.jclouds.glesys.domain.ServerLimit;
import org.jclouds.glesys.domain.ServerStatus;
import org.jclouds.glesys.domain.ServerTemplate;
import org.jclouds.glesys.options.ServerCloneOptions;
import org.jclouds.glesys.options.ServerCreateOptions;
import org.jclouds.glesys.options.ServerDestroyOptions;
import org.jclouds.glesys.options.ServerEditOptions;
import org.jclouds.glesys.options.ServerStatusOptions;
import org.jclouds.glesys.options.ServerStopOptions;
/**
* Provides synchronous access to Server.
* <p/>

View File

@ -1,12 +1,7 @@
package org.jclouds.glesys.options;
import com.google.common.base.Joiner;
import com.google.common.base.Objects;
import com.google.gson.annotations.SerializedName;
import org.jclouds.http.options.BaseHttpRequestOptions;
import java.util.Date;
/**
* @author Adam Lowe
* @see <a href="https://customer.glesys.com/api.php?a=doc#email_createaccount" />

View File

@ -1,6 +1,5 @@
package org.jclouds.glesys.options;
import org.jclouds.http.options.BaseHttpRequestOptions;
/**
* @author Adam Lowe

View File

@ -1,6 +1,5 @@
package org.jclouds.glesys.options;
import com.google.common.collect.Iterables;
import org.jclouds.http.options.BaseHttpRequestOptions;
/**

View File

@ -18,15 +18,15 @@
*/
package org.jclouds.glesys.features;
import com.google.inject.TypeLiteral;
import java.util.Map;
import org.jclouds.rest.functions.MapHttp4xxCodesToExceptions;
import org.jclouds.rest.functions.ReturnEmptySetOnNotFoundOr404;
import org.jclouds.rest.functions.ReturnNullOnNotFoundOr404;
import org.jclouds.rest.internal.RestAnnotationProcessor;
import org.testng.annotations.Test;
import javax.ws.rs.FormParam;
import java.util.Map;
import com.google.inject.TypeLiteral;
/**
* Tests annotation parsing of {@code ArchiveAsyncClient}

View File

@ -18,21 +18,20 @@
*/
package org.jclouds.glesys.features;
import com.google.common.base.Predicate;
import com.google.common.base.Predicates;
import org.jclouds.glesys.domain.*;
import static org.testng.Assert.assertEquals;
import static org.testng.Assert.assertNotNull;
import static org.testng.Assert.assertTrue;
import java.util.concurrent.TimeUnit;
import org.jclouds.glesys.domain.ArchiveAllowedArguments;
import org.jclouds.glesys.domain.ArchiveDetails;
import org.jclouds.predicates.RetryablePredicate;
import org.testng.annotations.AfterGroups;
import org.testng.annotations.BeforeGroups;
import org.testng.annotations.Test;
import java.util.List;
import java.util.Map;
import java.util.Set;
import java.util.concurrent.TimeUnit;
import static com.google.common.base.Predicates.equalTo;
import static org.testng.Assert.*;
import com.google.common.base.Predicate;
/**
* Tests behavior of {@code ArchiveClient}

View File

@ -83,6 +83,7 @@ public abstract class BaseGleSYSAsyncClientTest<T> extends RestClientTest<T> {
args);
}
@SuppressWarnings("unchecked")
protected void testMethod(String localMethod, String remoteCall, String httpMethod, boolean expectResponse, Class<?> responseParser, Class<?> exceptionParser, Object... args) throws Exception {
List<String> argStrings = new ArrayList<String>();
List<Object> argValues = new ArrayList<Object>();

View File

@ -18,15 +18,15 @@
*/
package org.jclouds.glesys.features;
import com.google.inject.TypeLiteral;
import java.util.Map;
import org.jclouds.glesys.options.DomainOptions;
import org.jclouds.rest.functions.MapHttp4xxCodesToExceptions;
import org.jclouds.rest.functions.ReturnEmptySetOnNotFoundOr404;
import org.jclouds.rest.functions.ReturnNullOnNotFoundOr404;
import org.jclouds.rest.internal.RestAnnotationProcessor;
import org.testng.annotations.Test;
import java.util.Map;
import com.google.inject.TypeLiteral;
/**
* Tests annotation parsing of {@code DomainAsyncClient}

View File

@ -18,17 +18,18 @@
*/
package org.jclouds.glesys.features;
import com.google.common.base.Predicate;
import static org.testng.Assert.assertTrue;
import java.util.Set;
import java.util.concurrent.TimeUnit;
import org.jclouds.glesys.domain.DomainRecord;
import org.jclouds.predicates.RetryablePredicate;
import org.testng.annotations.AfterGroups;
import org.testng.annotations.BeforeGroups;
import org.testng.annotations.Test;
import java.util.Set;
import java.util.concurrent.TimeUnit;
import static org.testng.Assert.assertTrue;
import com.google.common.base.Predicate;
/**
* Tests behavior of {@code DomainClient}
@ -75,7 +76,6 @@ public class DomainClientLiveTest extends BaseGleSYSClientLiveTest {
}
private DomainClient client;
private String testRecordId;
private RetryablePredicate<Integer> domainCounter;
private RetryablePredicate<Integer> recordCounter;

View File

@ -18,14 +18,12 @@
*/
package org.jclouds.glesys.features;
import com.google.inject.TypeLiteral;
import org.jclouds.rest.functions.MapHttp4xxCodesToExceptions;
import org.jclouds.rest.functions.ReturnEmptySetOnNotFoundOr404;
import org.jclouds.rest.functions.ReturnNullOnNotFoundOr404;
import org.jclouds.rest.internal.RestAnnotationProcessor;
import org.testng.annotations.Test;
import java.util.Map;
import com.google.inject.TypeLiteral;
/**
* Tests annotation parsing of {@code ArchiveAsyncClient}

View File

@ -19,20 +19,18 @@
package org.jclouds.glesys.parse;
import com.google.inject.Guice;
import com.google.inject.Injector;
import javax.ws.rs.Consumes;
import javax.ws.rs.core.MediaType;
import org.jclouds.glesys.config.GleSYSParserModule;
import org.jclouds.glesys.domain.ArchiveAllowedArguments;
import org.jclouds.glesys.domain.ServerAllowedArguments;
import org.jclouds.json.BaseItemParserTest;
import org.jclouds.json.config.GsonModule;
import org.jclouds.rest.annotations.SelectJson;
import org.testng.annotations.Test;
import javax.ws.rs.Consumes;
import javax.ws.rs.core.MediaType;
import java.util.LinkedHashMap;
import java.util.Map;
import com.google.inject.Guice;
import com.google.inject.Injector;
/**
* @author Adam Lowe

View File

@ -18,22 +18,18 @@
*/
package org.jclouds.glesys.parse;
import com.google.common.collect.ImmutableSet;
import com.google.inject.Guice;
import com.google.inject.Injector;
import javax.ws.rs.Consumes;
import javax.ws.rs.core.MediaType;
import org.jclouds.glesys.config.GleSYSParserModule;
import org.jclouds.glesys.domain.Archive;
import org.jclouds.glesys.domain.ArchiveDetails;
import org.jclouds.json.BaseItemParserTest;
import org.jclouds.json.BaseParserTest;
import org.jclouds.json.BaseSetParserTest;
import org.jclouds.json.config.GsonModule;
import org.jclouds.rest.annotations.SelectJson;
import org.testng.annotations.Test;
import javax.ws.rs.Consumes;
import javax.ws.rs.core.MediaType;
import java.util.Set;
import com.google.inject.Guice;
import com.google.inject.Injector;
/**
*

View File

@ -18,20 +18,21 @@
*/
package org.jclouds.glesys.parse;
import com.google.common.collect.ImmutableSet;
import com.google.inject.Guice;
import com.google.inject.Injector;
import java.util.Set;
import javax.ws.rs.Consumes;
import javax.ws.rs.core.MediaType;
import org.jclouds.glesys.config.GleSYSParserModule;
import org.jclouds.glesys.domain.Archive;
import org.jclouds.glesys.domain.Server;
import org.jclouds.json.BaseSetParserTest;
import org.jclouds.json.config.GsonModule;
import org.jclouds.rest.annotations.SelectJson;
import org.testng.annotations.Test;
import javax.ws.rs.Consumes;
import javax.ws.rs.core.MediaType;
import java.util.Set;
import com.google.common.collect.ImmutableSet;
import com.google.inject.Guice;
import com.google.inject.Injector;
/**
*

View File

@ -19,9 +19,16 @@
package org.jclouds.glesys.parse;
import com.google.common.collect.Sets;
import com.google.inject.Guice;
import com.google.inject.Injector;
import static org.testng.Assert.fail;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.Set;
import javax.ws.rs.Consumes;
import javax.ws.rs.core.MediaType;
import org.jclouds.glesys.config.GleSYSParserModule;
import org.jclouds.glesys.domain.Domain;
import org.jclouds.json.BaseSetParserTest;
@ -29,15 +36,9 @@ import org.jclouds.json.config.GsonModule;
import org.jclouds.rest.annotations.SelectJson;
import org.testng.annotations.Test;
import javax.ws.rs.Consumes;
import javax.ws.rs.core.MediaType;
import java.text.DateFormat;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.Set;
import static org.testng.Assert.fail;
import com.google.common.collect.Sets;
import com.google.inject.Guice;
import com.google.inject.Injector;
/**
* @author Adam Lowe

View File

@ -19,27 +19,22 @@
package org.jclouds.glesys.parse;
import com.google.common.collect.ImmutableSortedSet;
import com.google.common.collect.Sets;
import com.google.inject.Guice;
import com.google.inject.Injector;
import java.util.Arrays;
import java.util.Set;
import javax.ws.rs.Consumes;
import javax.ws.rs.core.MediaType;
import org.jclouds.glesys.config.GleSYSParserModule;
import org.jclouds.glesys.domain.Domain;
import org.jclouds.glesys.domain.DomainRecord;
import org.jclouds.json.BaseSetParserTest;
import org.jclouds.json.config.GsonModule;
import org.jclouds.rest.annotations.SelectJson;
import org.testng.annotations.Test;
import javax.ws.rs.Consumes;
import javax.ws.rs.core.MediaType;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Arrays;
import java.util.Date;
import java.util.Set;
import static org.testng.Assert.fail;
import com.google.common.collect.ImmutableSortedSet;
import com.google.inject.Guice;
import com.google.inject.Injector;
/**
* @author Adam Lowe

View File

@ -19,19 +19,18 @@
package org.jclouds.glesys.parse;
import com.google.inject.Guice;
import com.google.inject.Injector;
import javax.ws.rs.Consumes;
import javax.ws.rs.core.MediaType;
import org.jclouds.glesys.config.GleSYSParserModule;
import org.jclouds.glesys.domain.ServerConsole;
import org.jclouds.glesys.domain.ServerCreated;
import org.jclouds.glesys.domain.ServerCreatedIp;
import org.jclouds.json.BaseItemParserTest;
import org.jclouds.json.config.GsonModule;
import org.jclouds.rest.annotations.SelectJson;
import org.testng.annotations.Test;
import javax.ws.rs.Consumes;
import javax.ws.rs.core.MediaType;
import com.google.inject.Guice;
import com.google.inject.Injector;
/**
* @author Adam Lowe

View File

@ -19,15 +19,14 @@
package org.jclouds.glesys.parse;
import com.google.inject.Guice;
import com.google.inject.Injector;
import javax.ws.rs.Consumes;
import javax.ws.rs.core.MediaType;
import org.jclouds.glesys.config.GleSYSParserModule;
import org.jclouds.glesys.domain.Bandwidth;
import org.jclouds.glesys.domain.Cost;
import org.jclouds.glesys.domain.Cpu;
import org.jclouds.glesys.domain.Disk;
import org.jclouds.glesys.domain.Memory;
import org.jclouds.glesys.domain.ServerDetails;
import org.jclouds.glesys.domain.ServerState;
import org.jclouds.glesys.domain.ServerStatus;
import org.jclouds.json.BaseItemParserTest;
@ -35,8 +34,8 @@ import org.jclouds.json.config.GsonModule;
import org.jclouds.rest.annotations.SelectJson;
import org.testng.annotations.Test;
import javax.ws.rs.Consumes;
import javax.ws.rs.core.MediaType;
import com.google.inject.Guice;
import com.google.inject.Injector;
/**
* @author Adam Lowe