Author: aparfonov
Date: 2009-10-13 12:17:02 -0400 (Tue, 13 Oct 2009)
New Revision: 275
Added:
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/DependencyInjector.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/AbstractResourceTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/BaseTest.java
Removed:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/AbstractResourceTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/BaseTest.java
Modified:
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/ApplicationContext.java
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/ResourceBinder.java
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/impl/ApplicationContextImpl.java
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/impl/BaseResourceBinder.java
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/impl/RequestHandlerImpl.java
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/servlet/BaseRestServlet.java
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/servlet/RestInitializedListener.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/RequestDispatcherTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/RequestFilterTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/ResourceBinderTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/ResponseFilterTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/ResponseImplTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/VariantsHandlerTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/AcceptLanguageTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/AcceptMediaTypeTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/AcceptTokenTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/CookieTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/EntityTagTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/HeaderParameterParserTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/LanguageTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/MediaTypeTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/HeadMethodTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/MediaTypeTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/MethodExceptionTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/MethodInvokerFilterTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/MethodReturnTypeTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/OptionsMethodTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/ParametersInjectionTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/ByteEntityProviderTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/ContextResolverTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/ExceptionMapperTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/FileEntityProviderTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/FormEntityTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/InputStreamEntityProviderTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/JAXBEntityProviderTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/JAXBEntityTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/JsonEntityProviderTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/JsonEntityTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/OtherEntityTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/ProviderContextParameterInjectionTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/ReaderEntityProviderTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/SourceEntityProviderTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/StringEntityProviderTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/AcceptResourceTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/AnnotationInheritanceTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/ApplicationTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/ContextParametersInjectionTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/MatchedURIsAndResourcesTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/ResourceDescriptorTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/ResourceDescriptorValidatorTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/uri/UriBuilderTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/uri/UriComponentTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/util/MediaTypeMapTest.java
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/wadl/WadlProcessorTest.java
Log:
EXOJCR-185 :
Modified:
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/ApplicationContext.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/ApplicationContext.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/ApplicationContext.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -41,23 +41,6 @@
{
/**
- * Should be used to pass template values in context by using returned list in
- * matching to @see
- * {@link org.exoplatform.services.rest.uri.UriPattern#match(String, List)}
- * . List will be cleared during matching.
- *
- * @return the list for template values
- */
- List<String> getParameterValues();
-
- /**
- * Pass in context list of path template parameters @see {@link UriPattern}.
- *
- * @param parameterNames list of templates parameters
- */
- void setParameterNames(List<String> parameterNames);
-
- /**
* Add ancestor resource, according to JSR-311:
* <p>
* Entries are ordered according in reverse request URI matching order, with
@@ -89,45 +72,67 @@
Map<String, Object> getAttributes();
/**
- * @return See {@link Request}
+ * @return See {@link GenericContainerRequest}
*/
- Request getRequest();
+ GenericContainerRequest getContainerRequest();
/**
+ * @return See {@link GenericContainerResponse}
+ */
+ GenericContainerResponse getContainerResponse();
+
+
+ DependencyInjector getDependencyInjector();
+
+ /**
* @return See {@link HttpHeaders}
*/
HttpHeaders getHttpHeaders();
+
+ /**
+ * @return {@link InitialProperties}
+ */
+ InitialProperties getInitialProperties();
/**
- * @return {@link InitialProperties}
+ * Should be used to pass template values in context by using returned list in
+ * matching to @see
+ * {@link org.exoplatform.services.rest.uri.UriPattern#match(String, List)}
+ * . List will be cleared during matching.
+ *
+ * @return the list for template values
*/
- InitialProperties getInitialProperties();
+ List<String> getParameterValues();
/**
- * @return See {@link SecurityContext}
+ * @return {@link ProviderBinder}
+ * @see Providers
*/
- SecurityContext getSecurityContext();
+ ProviderBinder getProviders();
/**
- * @return See {@link GenericContainerRequest}
+ * @return See {@link Request}
*/
- GenericContainerRequest getContainerRequest();
+ Request getRequest();
/**
- * @return See {@link UriInfo}
+ * @return See {@link SecurityContext}
*/
- UriInfo getUriInfo();
+ SecurityContext getSecurityContext();
/**
- * @return See {@link GenericContainerResponse}
+ * @return See {@link UriInfo}
*/
- GenericContainerResponse getContainerResponse();
+ UriInfo getUriInfo();
+ void setDependencyInjector(DependencyInjector depInjector);
+
/**
- * @return {@link ProviderBinder}
- * @see Providers
+ * Pass in context list of path template parameters @see {@link UriPattern}.
+ *
+ * @param parameterNames list of templates parameters
*/
- ProviderBinder getProviders();
+ void setParameterNames(List<String> parameterNames);
}
Added:
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/DependencyInjector.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/DependencyInjector.java
(rev 0)
+++
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/DependencyInjector.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -0,0 +1,43 @@
+/*
+ * Copyright (C) 2009 eXo Platform SAS.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
+ */
+package org.exoplatform.services.rest;
+
+import java.lang.reflect.Type;
+
+/**
+ * Implementation of DependencyInjector should be able to provide
+ * objects that required for constructors or fields of Resource or Provider.
+ *
+ * @author <a href="mailto:andrey.parfonov@exoplatform.com">Andrey
Parfonov</a>
+ * @version $Id$
+ */
+public interface DependencyInjector
+{
+
+ /**
+ * Get single parameter of type <code>type</code>.
+ *
+ * @param type class of required parameter
+ * @param the type of object to be produced
+ * @return object of required type or null if instance of
<code>type</code>
+ * may not be produced
+ */
+ Object getInjectableParameter(Class<?> type, Type genericType);
+
+}
Property changes on:
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/DependencyInjector.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Modified:
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/ResourceBinder.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/ResourceBinder.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/ResourceBinder.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -23,6 +23,8 @@
import java.util.List;
/**
+ * Manages root resources.
+ *
* @author <a href="mailto:andrew00x@gmail.com">Andrey
Parfonov</a>
* @version $Id$
*/
Modified:
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/impl/ApplicationContextImpl.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/impl/ApplicationContextImpl.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/impl/ApplicationContextImpl.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -19,6 +19,7 @@
package org.exoplatform.services.rest.impl;
import org.exoplatform.services.rest.ApplicationContext;
+import org.exoplatform.services.rest.DependencyInjector;
import org.exoplatform.services.rest.GenericContainerRequest;
import org.exoplatform.services.rest.GenericContainerResponse;
import org.exoplatform.services.rest.InitialProperties;
@@ -51,6 +52,14 @@
private static ThreadLocal<ApplicationContext> current = new
ThreadLocal<ApplicationContext>();
/**
+ * @return current ApplicationContext.
+ */
+ public static ApplicationContext getCurrent()
+ {
+ return current.get();
+ }
+
+ /**
* Set ApplicationContext for current thread.
*
* @param context the ApplicationContext.
@@ -61,14 +70,6 @@
}
/**
- * @return current ApplicationContext.
- */
- public static ApplicationContext getCurrent()
- {
- return current.get();
- }
-
- /**
* Values of template parameters.
*/
private List<String> parameterValues = new ArrayList<String>();
@@ -114,13 +115,58 @@
protected ProviderBinder providers;
/**
+ * Absolute path, full requested URI without query string and fragment.
+ */
+ private URI absolutePath;
+
+ /**
+ * Decoded relative path.
+ */
+ private String path;
+
+ /**
+ * Not decoded relative path.
+ */
+ private String encodedPath;
+
+ /**
+ * Not decoded path template parameters.
+ */
+ private MultivaluedMap<String, String> encodedPathParameters;
+
+ /**
+ * Decoded path template parameters.
+ */
+ private MultivaluedMap<String, String> pathParameters;
+
+ /**
+ * List of not decoded path segments.
+ */
+ private List<PathSegment> encodedPathSegments;
+
+ /**
+ * Decoded path segments.
+ */
+ private List<PathSegment> pathSegments;
+
+ /**
+ * Not decoded query parameters.
+ */
+ private MultivaluedMap<String, String> encodedQueryParameters;
+
+ /**
+ * Decoded query parameters.
+ */
+ private MultivaluedMap<String, String> queryParameters;
+
+ /**
* Constructs new instance of ApplicationContext.
*
* @param request See {@link GenricContainerRequest}
* @param response See {@link GenericContainerResponse}
* @param providers See {@link ProviderBinder}
*/
- public ApplicationContextImpl(GenericContainerRequest request,
GenericContainerResponse response,
+ /*public */ApplicationContextImpl(GenericContainerRequest request,
GenericContainerResponse response,
ProviderBinder providers)
{
this.request = request;
@@ -131,27 +177,6 @@
/**
* {@inheritDoc}
*/
- public List<String> getParameterValues()
- {
- return parameterValues;
- }
-
- /**
- * {@inheritDoc}
- */
- public void setParameterNames(List<String> parameterNames)
- {
- if (encodedPathParameters == null)
- encodedPathParameters = new MultivaluedMapImpl();
-
- for (int i = 0; i < parameterNames.size(); i++)
- encodedPathParameters.add(parameterNames.get(i), parameterValues.get(i));
-
- }
-
- /**
- * {@inheritDoc}
- */
public void addMatchedResource(Object resource)
{
matchedResources.add(0, resource);
@@ -169,41 +194,44 @@
/**
* {@inheritDoc}
*/
- public Map<String, Object> getAttributes()
+ public URI getAbsolutePath()
{
- return attributes == null ? attributes = new HashMap<String, Object>() :
attributes;
+ if (absolutePath != null)
+ return absolutePath;
+
+ return absolutePath =
getRequestUriBuilder().replaceQuery(null).fragment(null).build();
}
-
+
/**
* {@inheritDoc}
*/
- public Request getRequest()
+ public UriBuilder getAbsolutePathBuilder()
{
- return request;
+ return UriBuilder.fromUri(getAbsolutePath());
}
/**
* {@inheritDoc}
*/
- public HttpHeaders getHttpHeaders()
+ public Map<String, Object> getAttributes()
{
- return request;
+ return attributes == null ? attributes = new HashMap<String, Object>() :
attributes;
}
-
+
/**
* {@inheritDoc}
*/
- public InitialProperties getInitialProperties()
+ public URI getBaseUri()
{
- return this;
+ return request.getBaseUri();
}
/**
* {@inheritDoc}
*/
- public SecurityContext getSecurityContext()
+ public UriBuilder getBaseUriBuilder()
{
- return request;
+ return UriBuilder.fromUri(getBaseUri());
}
/**
@@ -217,114 +245,36 @@
/**
* {@inheritDoc}
*/
- public UriInfo getUriInfo()
- {
- return this;
- }
-
- /**
- * {@inheritDoc}
- */
public GenericContainerResponse getContainerResponse()
{
return response;
}
-
- // InitialProperties
- /**
- * {@inheritDoc}
- */
- public Map<String, String> getProperties()
+ public DependencyInjector getDependencyInjector()
{
- return properties == null ? properties = new HashMap<String, String>() :
properties;
+ // TODO Auto-generated method stub
+ return null;
}
/**
* {@inheritDoc}
*/
- public String getProperty(String name)
+ public HttpHeaders getHttpHeaders()
{
- return getProperties().get(name);
+ return request;
}
/**
* {@inheritDoc}
*/
- public void setProperty(String name, String value)
+ public InitialProperties getInitialProperties()
{
- getProperties().put(name, value);
+ return this;
}
- // UriInfo
-
/**
- * Absolute path, full requested URI without query string and fragment.
- */
- private URI absolutePath;
-
- /**
- * Decoded relative path.
- */
- private String path;
-
- /**
- * Not decoded relative path.
- */
- private String encodedPath;
-
- /**
- * Not decoded path template parameters.
- */
- private MultivaluedMap<String, String> encodedPathParameters;
-
- /**
- * Decoded path template parameters.
- */
- private MultivaluedMap<String, String> pathParameters;
-
- /**
- * List of not decoded path segments.
- */
- private List<PathSegment> encodedPathSegments;
-
- /**
- * Decoded path segments.
- */
- private List<PathSegment> pathSegments;
-
- /**
- * Not decoded query parameters.
- */
- private MultivaluedMap<String, String> encodedQueryParameters;
-
- /**
- * Decoded query parameters.
- */
- private MultivaluedMap<String, String> queryParameters;
-
- /**
* {@inheritDoc}
*/
- public URI getAbsolutePath()
- {
- if (absolutePath != null)
- return absolutePath;
-
- return absolutePath =
getRequestUriBuilder().replaceQuery(null).fragment(null).build();
- }
-
- /**
- * {@inheritDoc}
- */
- public UriBuilder getAbsolutePathBuilder()
- {
- return UriBuilder.fromUri(getAbsolutePath());
- }
-
- /**
- * {@inheritDoc}
- */
public List<Object> getMatchedResources()
{
return matchedResources;
@@ -349,22 +299,14 @@
/**
* {@inheritDoc}
*/
- public URI getBaseUri()
+ public List<String> getParameterValues()
{
- return request.getBaseUri();
+ return parameterValues;
}
/**
* {@inheritDoc}
*/
- public UriBuilder getBaseUriBuilder()
- {
- return UriBuilder.fromUri(getBaseUri());
- }
-
- /**
- * {@inheritDoc}
- */
public String getPath()
{
return getPath(true);
@@ -454,6 +396,30 @@
/**
* {@inheritDoc}
*/
+ public Map<String, String> getProperties()
+ {
+ return properties == null ? properties = new HashMap<String, String>() :
properties;
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public String getProperty(String name)
+ {
+ return getProperties().get(name);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public ProviderBinder getProviders()
+ {
+ return providers;
+ }
+
+ /**
+ * {@inheritDoc}
+ */
public MultivaluedMap<String, String> getQueryParameters()
{
return getQueryParameters(true);
@@ -474,6 +440,14 @@
/**
* {@inheritDoc}
*/
+ public Request getRequest()
+ {
+ return request;
+ }
+
+ /**
+ * {@inheritDoc}
+ */
public URI getRequestUri()
{
return request.getRequestUri();
@@ -490,9 +464,44 @@
/**
* {@inheritDoc}
*/
- public ProviderBinder getProviders()
+ public SecurityContext getSecurityContext()
{
- return providers;
+ return request;
}
+ /**
+ * {@inheritDoc}
+ */
+ public UriInfo getUriInfo()
+ {
+ return this;
+ }
+
+ public void setDependencyInjector(DependencyInjector depInjector)
+ {
+ // TODO Auto-generated method stub
+
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public void setParameterNames(List<String> parameterNames)
+ {
+ if (encodedPathParameters == null)
+ encodedPathParameters = new MultivaluedMapImpl();
+
+ for (int i = 0; i < parameterNames.size(); i++)
+ encodedPathParameters.add(parameterNames.get(i), parameterValues.get(i));
+
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public void setProperty(String name, String value)
+ {
+ getProperties().put(name, value);
+ }
+
}
Modified:
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/impl/BaseResourceBinder.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/impl/BaseResourceBinder.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/impl/BaseResourceBinder.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -50,9 +50,6 @@
import javax.ws.rs.ext.RuntimeDelegate;
/**
- * Lookup for root resource eXo container components at startup and
- * register/unregister resources via specified methods.
- *
* @author <a href="mailto:andrew00x@gmail.com">Andrey
Parfonov</a>
* @version $Id$
*/
Modified:
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/impl/RequestHandlerImpl.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/impl/RequestHandlerImpl.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/impl/RequestHandlerImpl.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,9 +18,22 @@
*/
package org.exoplatform.services.rest.impl;
+import java.io.File;
+import java.io.OutputStream;
+import java.io.PrintWriter;
+import java.util.HashMap;
+import java.util.Map;
+
+import javax.ws.rs.WebApplicationException;
+import javax.ws.rs.core.MediaType;
+import javax.ws.rs.core.Response;
+import javax.ws.rs.core.StreamingOutput;
+import javax.ws.rs.ext.ExceptionMapper;
+
import org.exoplatform.services.log.ExoLogger;
import org.exoplatform.services.log.Log;
import org.exoplatform.services.rest.ApplicationContext;
+import org.exoplatform.services.rest.DependencyInjector;
import org.exoplatform.services.rest.FilterDescriptor;
import org.exoplatform.services.rest.GenericContainerRequest;
import org.exoplatform.services.rest.GenericContainerResponse;
@@ -29,20 +42,7 @@
import org.exoplatform.services.rest.RequestHandler;
import org.exoplatform.services.rest.ResourceBinder;
import org.exoplatform.services.rest.ResponseFilter;
-import org.picocontainer.Startable;
-import java.io.File;
-import java.io.OutputStream;
-import java.io.PrintWriter;
-import java.util.HashMap;
-import java.util.Map;
-
-import javax.ws.rs.WebApplicationException;
-import javax.ws.rs.core.MediaType;
-import javax.ws.rs.core.Response;
-import javax.ws.rs.core.StreamingOutput;
-import javax.ws.rs.ext.ExceptionMapper;
-
/**
* @author <a href="mailto:andrew00x@gmail.com">Andrey
Parfonov</a>
* @version $Id: $
@@ -51,6 +51,37 @@
{
/**
+ * For writing error message.
+ */
+ static class ErrorStreaming implements StreamingOutput
+ {
+
+ /**
+ * Exception which should send to client.
+ */
+ private final Exception e;
+
+ /**
+ * @param e Exception for serialization
+ */
+ ErrorStreaming(Exception e)
+ {
+ this.e = e;
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public void write(OutputStream output)
+ {
+ PrintWriter pw = new PrintWriter(output);
+ e.printStackTrace(pw);
+ pw.flush();
+ }
+
+ }
+
+ /**
* Logger.
*/
private static final Log LOG =
ExoLogger.getLogger(RequestHandlerImpl.class.getName());
@@ -60,11 +91,6 @@
* and may be accessible via method {@link ApplicationContextImpl#getProperties()}.
*/
private static final Map<String, String> properties = new HashMap<String,
String>();
-
- /**
- * See {@link RequestDispatcher}.
- */
- private final RequestDispatcher dispatcher;
public static final String getProperty(String name)
{
@@ -78,23 +104,36 @@
properties.put(name, value);
}
- private final ResourceBinder binder;
+ /**
+ * See {@link RequestDispatcher}.
+ */
+ private final RequestDispatcher dispatcher;
/**
- * Constructs new instance of {@link RequestHandler}.
+ * ResourceBinder.
*/
- public RequestHandlerImpl()
+ private final ResourceBinder binder;
+
+ private final DependencyInjector depInjector;
+
+ public RequestHandlerImpl(DependencyInjector depInjector)
{
this.binder = new BaseResourceBinder();
this.dispatcher = new RequestDispatcher(binder);
+ this.depInjector = depInjector;
}
+ public RequestHandlerImpl(ResourceBinder binder, DependencyInjector depInjector)
+ {
+ this.binder = binder;
+ this.dispatcher = new RequestDispatcher(binder);
+ this.depInjector = depInjector;
+ }
+
public ResourceBinder getBinder()
{
return binder;
}
-
- // RequestHandler
/**
* {@inheritDoc}
@@ -106,6 +145,7 @@
{
ApplicationContext context = new ApplicationContextImpl(request, response,
ProviderBinder.getInstance());
context.getProperties().putAll(properties);
+ context.setDependencyInjector(depInjector);
ApplicationContextImpl.setCurrent(context);
for (ObjectFactory<FilterDescriptor> factory :
ProviderBinder.getInstance().getRequestFilters(
@@ -225,40 +265,7 @@
}
}
- //
-
/**
- * For writing error message.
- */
- static class ErrorStreaming implements StreamingOutput
- {
-
- /**
- * Exception which should send to client.
- */
- private final Exception e;
-
- /**
- * @param e Exception for serialization
- */
- ErrorStreaming(Exception e)
- {
- this.e = e;
- }
-
- /**
- * {@inheritDoc}
- */
- public void write(OutputStream output)
- {
- PrintWriter pw = new PrintWriter(output);
- e.printStackTrace(pw);
- pw.flush();
- }
-
- }
-
- /**
* Startup initialization.
*/
public void init()
Modified:
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/servlet/BaseRestServlet.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/servlet/BaseRestServlet.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/servlet/BaseRestServlet.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -46,6 +46,8 @@
public class BaseRestServlet extends HttpServlet
{
+ private static final long serialVersionUID = -8234561611241680339L;
+
/**
* See {@link ContainerResponseWriter}.
*/
Modified:
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/servlet/RestInitializedListener.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/servlet/RestInitializedListener.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/main/java/org/exoplatform/services/rest/servlet/RestInitializedListener.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,6 +18,7 @@
*/
package org.exoplatform.services.rest.servlet;
+import org.exoplatform.services.rest.DependencyInjector;
import org.exoplatform.services.rest.RequestHandler;
import org.exoplatform.services.rest.impl.RequestHandlerImpl;
@@ -37,8 +38,32 @@
public void contextInitialized(ServletContextEvent event)
{
- RequestHandler handler = new RequestHandlerImpl();
+ String dependencyInjectorFQN =
event.getServletContext().getInitParameter(DependencyInjector.class.getName());
+ DependencyInjector dependencyInjector = null;
+ if (dependencyInjectorFQN != null)
+ {
+ try
+ {
+ Class<?> cl =
Thread.currentThread().getContextClassLoader().loadClass(dependencyInjectorFQN.trim());
+ dependencyInjector = (DependencyInjector)cl.newInstance();
+ }
+ catch (ClassNotFoundException cnfe)
+ {
+ throw new RuntimeException(cnfe);
+ }
+ catch (InstantiationException ie)
+ {
+ throw new RuntimeException(ie);
+ }
+ catch (IllegalAccessException iae)
+ {
+ throw new RuntimeException(iae);
+ }
+ }
+
+ RequestHandler handler = new RequestHandlerImpl(dependencyInjector);
event.getServletContext().setAttribute(RequestHandler.class.getName(), handler);
+ // TODO process for javax.ws.rs.Application
}
}
Deleted:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/AbstractResourceTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/AbstractResourceTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/AbstractResourceTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -1,78 +0,0 @@
-/*
- * Copyright (C) 2009 eXo Platform SAS.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
- */
-package org.exoplatform.services.rest;
-
-import org.exoplatform.services.rest.impl.ContainerRequest;
-import org.exoplatform.services.rest.impl.ContainerResponse;
-import org.exoplatform.services.rest.impl.EnvironmentContext;
-import org.exoplatform.services.rest.impl.InputHeadersMap;
-import org.exoplatform.services.rest.impl.MultivaluedMapImpl;
-import org.exoplatform.services.rest.tools.DummyContainerResponseWriter;
-import org.exoplatform.services.test.mock.MockHttpServletRequest;
-
-import java.io.ByteArrayInputStream;
-import java.net.URI;
-import java.util.List;
-import java.util.Map;
-
-import javax.servlet.http.HttpServletRequest;
-import javax.ws.rs.core.MultivaluedMap;
-
-/**
- * @author <a href="mailto:andrew00x@gmail.com">Andrey
Parfonov</a>
- * @version $Id: $
- */
-public abstract class AbstractResourceTest extends BaseTest
-{
-
- // public void setUp() throws Exception {
- // super.setUp();
- // }
-
- public ContainerResponse service(String method, String requestURI, String baseURI,
- Map<String, List<String>> headers, byte[] data, ContainerResponseWriter
writer) throws Exception
- {
-
- if (headers == null)
- headers = new MultivaluedMapImpl();
-
- ByteArrayInputStream in = null;
- if (data != null)
- in = new ByteArrayInputStream(data);
-
- EnvironmentContext envctx = new EnvironmentContext();
- HttpServletRequest httpRequest =
- new MockHttpServletRequest("", in, in != null ? in.available() : 0,
method, headers);
- envctx.put(HttpServletRequest.class, httpRequest);
- EnvironmentContext.setCurrent(envctx);
- ContainerRequest request =
- new ContainerRequest(method, new URI(requestURI), new URI(baseURI), in, new
InputHeadersMap(headers));
- ContainerResponse response = new ContainerResponse(writer);
- requestHandler.handleRequest(request, response);
- return response;
- }
-
- public ContainerResponse service(String method, String requestURI, String baseURI,
- MultivaluedMap<String, String> headers, byte[] data) throws Exception
- {
- return service(method, requestURI, baseURI, headers, data, new
DummyContainerResponseWriter());
-
- }
-
-}
Deleted:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/BaseTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/BaseTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/BaseTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -1,91 +0,0 @@
-/*
- * Copyright (C) 2009 eXo Platform SAS.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
- */
-package org.exoplatform.services.rest;
-
-import junit.framework.TestCase;
-
-import org.exoplatform.container.StandaloneContainer;
-import org.exoplatform.services.rest.impl.ApplicationContextImpl;
-import org.exoplatform.services.rest.impl.BaseResourceBinder;
-import org.exoplatform.services.rest.impl.ProviderBinder;
-import org.exoplatform.services.rest.impl.RequestHandlerImpl;
-
-/**
- * @author <a href="mailto:andrew00x@gmail.com">Andrey
Parfonov</a>
- * @version $Id: $
- */
-public abstract class BaseTest extends TestCase
-{
-
-// protected StandaloneContainer container;
-
- protected ProviderBinder providers;
-
- protected BaseResourceBinder binder;
-
- protected RequestHandlerImpl requestHandler;
-
- public void setUp() throws Exception
- {
-
StandaloneContainer.setConfigurationPath("src/test/java/conf/standalone/test-configuration.xml");
-// container = StandaloneContainer.getInstance();
-
- requestHandler = new RequestHandlerImpl();
- requestHandler.init();
- binder = (BaseResourceBinder)requestHandler.getBinder();
-
-// binder =
(ResourceBinder)container.getComponentInstanceOfType(ResourceBinder.class);
-// requestHandler =
(RequestHandlerImpl)container.getComponentInstanceOfType(RequestHandlerImpl.class);
- // reset providers to be sure it is clean
- ProviderBinder.setInstance(new ProviderBinder());
- providers = ProviderBinder.getInstance();
- // System.out.println("##########################"+providers);
- ApplicationContextImpl.setCurrent(new ApplicationContextImpl(null, null,
providers));
-// binder.clear();
- }
-
- public void tearDown() throws Exception
- {
- }
-
- public boolean registry(Object resource) throws Exception
- {
- // container.registerComponentInstance(resource);
- return binder.bind(resource);
- }
-
- public boolean registry(Class<?> resourceClass) throws Exception
- {
- // container.registerComponentImplementation(resourceClass.getName(),
resourceClass);
- return binder.bind(resourceClass);
- }
-
- public boolean unregistry(Object resource)
- {
- // container.unregisterComponentByInstance(resource);
- return binder.unbind(resource.getClass());
- }
-
- public boolean unregistry(Class<?> resourceClass)
- {
- // container.unregisterComponent(resourceClass.getName());
- return binder.unbind(resourceClass);
- }
-
-}
Copied:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/AbstractResourceTest.java
(from rev 270,
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/AbstractResourceTest.java)
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/AbstractResourceTest.java
(rev 0)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/AbstractResourceTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -0,0 +1,79 @@
+/*
+ * Copyright (C) 2009 eXo Platform SAS.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
+ */
+package org.exoplatform.services.rest.impl;
+
+import org.exoplatform.services.rest.ContainerResponseWriter;
+import org.exoplatform.services.rest.impl.ContainerRequest;
+import org.exoplatform.services.rest.impl.ContainerResponse;
+import org.exoplatform.services.rest.impl.EnvironmentContext;
+import org.exoplatform.services.rest.impl.InputHeadersMap;
+import org.exoplatform.services.rest.impl.MultivaluedMapImpl;
+import org.exoplatform.services.rest.tools.DummyContainerResponseWriter;
+import org.exoplatform.services.test.mock.MockHttpServletRequest;
+
+import java.io.ByteArrayInputStream;
+import java.net.URI;
+import java.util.List;
+import java.util.Map;
+
+import javax.servlet.http.HttpServletRequest;
+import javax.ws.rs.core.MultivaluedMap;
+
+/**
+ * @author <a href="mailto:andrew00x@gmail.com">Andrey
Parfonov</a>
+ * @version $Id: $
+ */
+public abstract class AbstractResourceTest extends BaseTest
+{
+
+ // public void setUp() throws Exception {
+ // super.setUp();
+ // }
+
+ public ContainerResponse service(String method, String requestURI, String baseURI,
+ Map<String, List<String>> headers, byte[] data, ContainerResponseWriter
writer) throws Exception
+ {
+
+ if (headers == null)
+ headers = new MultivaluedMapImpl();
+
+ ByteArrayInputStream in = null;
+ if (data != null)
+ in = new ByteArrayInputStream(data);
+
+ EnvironmentContext envctx = new EnvironmentContext();
+ HttpServletRequest httpRequest =
+ new MockHttpServletRequest("", in, in != null ? in.available() : 0,
method, headers);
+ envctx.put(HttpServletRequest.class, httpRequest);
+ EnvironmentContext.setCurrent(envctx);
+ ContainerRequest request =
+ new ContainerRequest(method, new URI(requestURI), new URI(baseURI), in, new
InputHeadersMap(headers));
+ ContainerResponse response = new ContainerResponse(writer);
+ requestHandler.handleRequest(request, response);
+ return response;
+ }
+
+ public ContainerResponse service(String method, String requestURI, String baseURI,
+ MultivaluedMap<String, String> headers, byte[] data) throws Exception
+ {
+ return service(method, requestURI, baseURI, headers, data, new
DummyContainerResponseWriter());
+
+ }
+
+}
Copied:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/BaseTest.java
(from rev 274,
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/BaseTest.java)
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/BaseTest.java
(rev 0)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/BaseTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -0,0 +1,89 @@
+/*
+ * Copyright (C) 2009 eXo Platform SAS.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
+ */
+package org.exoplatform.services.rest.impl;
+
+import junit.framework.TestCase;
+
+import org.exoplatform.container.StandaloneContainer;
+import org.exoplatform.services.rest.impl.ApplicationContextImpl;
+import org.exoplatform.services.rest.impl.BaseResourceBinder;
+import org.exoplatform.services.rest.impl.ProviderBinder;
+import org.exoplatform.services.rest.impl.RequestHandlerImpl;
+
+/**
+ * @author <a href="mailto:andrew00x@gmail.com">Andrey
Parfonov</a>
+ * @version $Id: $
+ */
+public abstract class BaseTest extends TestCase
+{
+
+// protected StandaloneContainer container;
+
+ protected ProviderBinder providers;
+
+ protected BaseResourceBinder binder;
+
+ protected RequestHandlerImpl requestHandler;
+
+ public void setUp() throws Exception
+ {
+//
StandaloneContainer.setConfigurationPath("src/test/java/conf/standalone/test-configuration.xml");
+// container = StandaloneContainer.getInstance();
+
+ requestHandler = new RequestHandlerImpl(new SimpleDependencyInjector());
+ requestHandler.init();
+ binder = (BaseResourceBinder)requestHandler.getBinder();
+
+ // reset providers to be sure it is clean
+ ProviderBinder.setInstance(new ProviderBinder());
+ providers = ProviderBinder.getInstance();
+ // Set-up context for tests that are not used full request cycle.
+ // Usually context is set-up in RequestHandler
+ ApplicationContextImpl.setCurrent(new ApplicationContextImpl(null, null,
providers));
+ }
+
+ public void tearDown() throws Exception
+ {
+ }
+
+ public boolean registry(Object resource) throws Exception
+ {
+ // container.registerComponentInstance(resource);
+ return binder.bind(resource);
+ }
+
+ public boolean registry(Class<?> resourceClass) throws Exception
+ {
+ // container.registerComponentImplementation(resourceClass.getName(),
resourceClass);
+ return binder.bind(resourceClass);
+ }
+
+ public boolean unregistry(Object resource)
+ {
+ // container.unregisterComponentByInstance(resource);
+ return binder.unbind(resource.getClass());
+ }
+
+ public boolean unregistry(Class<?> resourceClass)
+ {
+ // container.unregisterComponent(resourceClass.getName());
+ return binder.unbind(resourceClass);
+ }
+
+}
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/RequestDispatcherTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/RequestDispatcherTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/RequestDispatcherTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,6 @@
*/
package org.exoplatform.services.rest.impl;
-import org.exoplatform.services.rest.AbstractResourceTest;
import org.exoplatform.services.rest.GenericContainerResponse;
import org.exoplatform.services.rest.Property;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/RequestFilterTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/RequestFilterTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/RequestFilterTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,6 @@
*/
package org.exoplatform.services.rest.impl;
-import org.exoplatform.services.rest.AbstractResourceTest;
import org.exoplatform.services.rest.Filter;
import org.exoplatform.services.rest.GenericContainerRequest;
import org.exoplatform.services.rest.RequestFilter;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/ResourceBinderTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/ResourceBinderTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/ResourceBinderTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,6 @@
*/
package org.exoplatform.services.rest.impl;
-import org.exoplatform.services.rest.BaseTest;
import javax.ws.rs.GET;
import javax.ws.rs.Path;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/ResponseFilterTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/ResponseFilterTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/ResponseFilterTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,6 @@
*/
package org.exoplatform.services.rest.impl;
-import org.exoplatform.services.rest.AbstractResourceTest;
import org.exoplatform.services.rest.Filter;
import org.exoplatform.services.rest.GenericContainerResponse;
import org.exoplatform.services.rest.ResponseFilter;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/ResponseImplTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/ResponseImplTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/ResponseImplTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,6 @@
*/
package org.exoplatform.services.rest.impl;
-import org.exoplatform.services.rest.BaseTest;
import org.exoplatform.services.rest.impl.header.HeaderHelper;
import java.net.URI;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/VariantsHandlerTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/VariantsHandlerTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/VariantsHandlerTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,6 @@
*/
package org.exoplatform.services.rest.impl;
-import org.exoplatform.services.rest.BaseTest;
import java.util.List;
import java.util.Locale;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/AcceptLanguageTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/AcceptLanguageTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/AcceptLanguageTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.header;
-import org.exoplatform.services.rest.BaseTest;
+import org.exoplatform.services.rest.impl.BaseTest;
import java.util.List;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/AcceptMediaTypeTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/AcceptMediaTypeTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/AcceptMediaTypeTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.header;
-import org.exoplatform.services.rest.BaseTest;
+import org.exoplatform.services.rest.impl.BaseTest;
import java.util.List;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/AcceptTokenTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/AcceptTokenTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/AcceptTokenTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.header;
-import org.exoplatform.services.rest.BaseTest;
+import org.exoplatform.services.rest.impl.BaseTest;
import java.util.List;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/CookieTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/CookieTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/CookieTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.header;
-import org.exoplatform.services.rest.BaseTest;
+import org.exoplatform.services.rest.impl.BaseTest;
import java.util.List;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/EntityTagTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/EntityTagTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/EntityTagTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.header;
-import org.exoplatform.services.rest.BaseTest;
+import org.exoplatform.services.rest.impl.BaseTest;
import javax.ws.rs.core.EntityTag;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/HeaderParameterParserTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/HeaderParameterParserTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/HeaderParameterParserTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.header;
-import org.exoplatform.services.rest.BaseTest;
+import org.exoplatform.services.rest.impl.BaseTest;
import java.text.ParseException;
import java.util.Map;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/LanguageTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/LanguageTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/LanguageTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.header;
-import org.exoplatform.services.rest.BaseTest;
+import org.exoplatform.services.rest.impl.BaseTest;
import java.util.Locale;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/MediaTypeTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/MediaTypeTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/header/MediaTypeTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.header;
-import org.exoplatform.services.rest.BaseTest;
+import org.exoplatform.services.rest.impl.BaseTest;
import java.util.HashMap;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/HeadMethodTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/HeadMethodTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/HeadMethodTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.method;
-import org.exoplatform.services.rest.AbstractResourceTest;
+import org.exoplatform.services.rest.impl.AbstractResourceTest;
import javax.ws.rs.GET;
import javax.ws.rs.HEAD;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/MediaTypeTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/MediaTypeTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/MediaTypeTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.method;
-import org.exoplatform.services.rest.AbstractResourceTest;
+import org.exoplatform.services.rest.impl.AbstractResourceTest;
import org.exoplatform.services.rest.impl.MultivaluedMapImpl;
import javax.ws.rs.Consumes;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/MethodExceptionTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/MethodExceptionTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/MethodExceptionTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.method;
-import org.exoplatform.services.rest.AbstractResourceTest;
+import org.exoplatform.services.rest.impl.AbstractResourceTest;
import org.exoplatform.services.rest.impl.UnhandledException;
import javax.ws.rs.GET;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/MethodInvokerFilterTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/MethodInvokerFilterTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/MethodInvokerFilterTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,8 +18,8 @@
*/
package org.exoplatform.services.rest.impl.method;
-import org.exoplatform.services.rest.AbstractResourceTest;
import org.exoplatform.services.rest.Filter;
+import org.exoplatform.services.rest.impl.AbstractResourceTest;
import org.exoplatform.services.rest.method.MethodInvokerFilter;
import org.exoplatform.services.rest.resource.GenericMethodResource;
import org.exoplatform.services.rest.resource.ResourceMethodDescriptor;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/MethodReturnTypeTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/MethodReturnTypeTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/MethodReturnTypeTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.method;
-import org.exoplatform.services.rest.AbstractResourceTest;
+import org.exoplatform.services.rest.impl.AbstractResourceTest;
import java.util.List;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/OptionsMethodTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/OptionsMethodTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/OptionsMethodTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.method;
-import org.exoplatform.services.rest.AbstractResourceTest;
+import org.exoplatform.services.rest.impl.AbstractResourceTest;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/ParametersInjectionTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/ParametersInjectionTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/method/ParametersInjectionTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,8 +18,8 @@
*/
package org.exoplatform.services.rest.impl.method;
-import org.exoplatform.services.rest.AbstractResourceTest;
import org.exoplatform.services.rest.Property;
+import org.exoplatform.services.rest.impl.AbstractResourceTest;
import org.exoplatform.services.rest.impl.MultivaluedMapImpl;
import org.exoplatform.services.rest.impl.RequestHandlerImpl;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/ByteEntityProviderTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/ByteEntityProviderTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/ByteEntityProviderTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.provider;
-import org.exoplatform.services.rest.BaseTest;
+import org.exoplatform.services.rest.impl.BaseTest;
import org.exoplatform.services.rest.impl.header.MediaTypeHelper;
import java.io.ByteArrayInputStream;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/ContextResolverTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/ContextResolverTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/ContextResolverTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -26,7 +26,7 @@
* @author <a href="mailto:andrew00x@gmail.com">Andrey
Parfonov</a>
* @version $Id: $
*/
-public class ContextResolverTest extends
org.exoplatform.services.rest.AbstractResourceTest
+public class ContextResolverTest extends
org.exoplatform.services.rest.impl.AbstractResourceTest
{
@Provider
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/ExceptionMapperTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/ExceptionMapperTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/ExceptionMapperTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.provider;
-import org.exoplatform.services.rest.AbstractResourceTest;
+import org.exoplatform.services.rest.impl.AbstractResourceTest;
import org.exoplatform.services.rest.impl.ContainerResponse;
import javax.ws.rs.GET;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/FileEntityProviderTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/FileEntityProviderTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/FileEntityProviderTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.provider;
-import org.exoplatform.services.rest.BaseTest;
+import org.exoplatform.services.rest.impl.BaseTest;
import org.exoplatform.services.rest.impl.header.MediaTypeHelper;
import java.io.ByteArrayInputStream;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/FormEntityTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/FormEntityTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/FormEntityTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -19,7 +19,7 @@
package org.exoplatform.services.rest.impl.provider;
import org.apache.commons.fileupload.FileItem;
-import org.exoplatform.services.rest.AbstractResourceTest;
+import org.exoplatform.services.rest.impl.AbstractResourceTest;
import org.exoplatform.services.rest.impl.MultivaluedMapImpl;
import java.io.ByteArrayOutputStream;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/InputStreamEntityProviderTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/InputStreamEntityProviderTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/InputStreamEntityProviderTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.provider;
-import org.exoplatform.services.rest.BaseTest;
+import org.exoplatform.services.rest.impl.BaseTest;
import java.io.ByteArrayInputStream;
import java.io.ByteArrayOutputStream;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/JAXBEntityProviderTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/JAXBEntityProviderTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/JAXBEntityProviderTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,10 +18,10 @@
*/
package org.exoplatform.services.rest.impl.provider;
-import org.exoplatform.services.rest.BaseTest;
import org.exoplatform.services.rest.generated.Book;
import org.exoplatform.services.rest.generated.MemberPrice;
import org.exoplatform.services.rest.generated.Price;
+import org.exoplatform.services.rest.impl.BaseTest;
import org.exoplatform.services.rest.impl.MultivaluedMapImpl;
import java.io.ByteArrayInputStream;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/JAXBEntityTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/JAXBEntityTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/JAXBEntityTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,8 +18,8 @@
*/
package org.exoplatform.services.rest.impl.provider;
-import org.exoplatform.services.rest.AbstractResourceTest;
import org.exoplatform.services.rest.generated.Book;
+import org.exoplatform.services.rest.impl.AbstractResourceTest;
import org.exoplatform.services.rest.impl.ContainerResponse;
import org.exoplatform.services.rest.impl.MultivaluedMapImpl;
import org.exoplatform.services.rest.tools.ByteArrayContainerResponseWriter;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/JsonEntityProviderTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/JsonEntityProviderTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/JsonEntityProviderTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,8 +18,8 @@
*/
package org.exoplatform.services.rest.impl.provider;
-import org.exoplatform.services.rest.BaseTest;
import org.exoplatform.services.rest.RequestHandler;
+import org.exoplatform.services.rest.impl.BaseTest;
import org.exoplatform.services.rest.impl.MultivaluedMapImpl;
import java.io.ByteArrayInputStream;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/JsonEntityTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/JsonEntityTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/JsonEntityTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,8 +18,8 @@
*/
package org.exoplatform.services.rest.impl.provider;
-import org.exoplatform.services.rest.AbstractResourceTest;
import org.exoplatform.services.rest.generated.Book;
+import org.exoplatform.services.rest.impl.AbstractResourceTest;
import org.exoplatform.services.rest.impl.ContainerResponse;
import org.exoplatform.services.rest.impl.MultivaluedMapImpl;
import org.exoplatform.services.rest.tools.ByteArrayContainerResponseWriter;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/OtherEntityTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/OtherEntityTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/OtherEntityTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.provider;
-import org.exoplatform.services.rest.AbstractResourceTest;
+import org.exoplatform.services.rest.impl.AbstractResourceTest;
import org.exoplatform.services.rest.impl.ContainerResponse;
import org.exoplatform.services.rest.impl.MultivaluedMapImpl;
import org.exoplatform.services.rest.tools.ByteArrayContainerResponseWriter;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/ProviderContextParameterInjectionTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/ProviderContextParameterInjectionTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/ProviderContextParameterInjectionTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.provider;
-import org.exoplatform.services.rest.AbstractResourceTest;
+import org.exoplatform.services.rest.impl.AbstractResourceTest;
import org.exoplatform.services.rest.impl.ContainerResponse;
import org.exoplatform.services.rest.provider.EntityProvider;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/ReaderEntityProviderTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/ReaderEntityProviderTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/ReaderEntityProviderTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.provider;
-import org.exoplatform.services.rest.BaseTest;
+import org.exoplatform.services.rest.impl.BaseTest;
import org.exoplatform.services.rest.impl.header.MediaTypeHelper;
import java.io.ByteArrayInputStream;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/SourceEntityProviderTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/SourceEntityProviderTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/SourceEntityProviderTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.provider;
-import org.exoplatform.services.rest.BaseTest;
+import org.exoplatform.services.rest.impl.BaseTest;
import org.exoplatform.services.rest.impl.MultivaluedMapImpl;
import org.w3c.dom.Document;
import org.w3c.dom.Node;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/StringEntityProviderTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/StringEntityProviderTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/provider/StringEntityProviderTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.provider;
-import org.exoplatform.services.rest.BaseTest;
+import org.exoplatform.services.rest.impl.BaseTest;
import java.io.ByteArrayInputStream;
import java.io.ByteArrayOutputStream;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/AcceptResourceTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/AcceptResourceTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/AcceptResourceTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.resource;
-import org.exoplatform.services.rest.AbstractResourceTest;
+import org.exoplatform.services.rest.impl.AbstractResourceTest;
import org.exoplatform.services.rest.impl.MultivaluedMapImpl;
import javax.ws.rs.Consumes;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/AnnotationInheritanceTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/AnnotationInheritanceTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/AnnotationInheritanceTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.resource;
-import org.exoplatform.services.rest.AbstractResourceTest;
+import org.exoplatform.services.rest.impl.AbstractResourceTest;
import javax.ws.rs.GET;
import javax.ws.rs.Path;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/ApplicationTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/ApplicationTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/ApplicationTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,12 +18,12 @@
*/
package org.exoplatform.services.rest.impl.resource;
-import org.exoplatform.services.rest.AbstractResourceTest;
import org.exoplatform.services.rest.Filter;
import org.exoplatform.services.rest.GenericContainerRequest;
import org.exoplatform.services.rest.GenericContainerResponse;
import org.exoplatform.services.rest.RequestFilter;
import org.exoplatform.services.rest.ResponseFilter;
+import org.exoplatform.services.rest.impl.AbstractResourceTest;
import org.exoplatform.services.rest.impl.ContainerResponse;
import org.exoplatform.services.rest.method.MethodInvokerFilter;
import org.exoplatform.services.rest.resource.GenericMethodResource;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/ContextParametersInjectionTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/ContextParametersInjectionTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/ContextParametersInjectionTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,8 +18,8 @@
*/
package org.exoplatform.services.rest.impl.resource;
-import org.exoplatform.services.rest.AbstractResourceTest;
import org.exoplatform.services.rest.InitialProperties;
+import org.exoplatform.services.rest.impl.AbstractResourceTest;
import org.exoplatform.services.rest.impl.MultivaluedMapImpl;
import org.exoplatform.services.rest.impl.header.HeaderHelper;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/MatchedURIsAndResourcesTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/MatchedURIsAndResourcesTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/MatchedURIsAndResourcesTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.resource;
-import org.exoplatform.services.rest.AbstractResourceTest;
+import org.exoplatform.services.rest.impl.AbstractResourceTest;
import org.exoplatform.services.rest.impl.header.HeaderHelper;
import java.util.ArrayList;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/ResourceDescriptorTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/ResourceDescriptorTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/ResourceDescriptorTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,9 +18,9 @@
*/
package org.exoplatform.services.rest.impl.resource;
-import org.exoplatform.services.rest.BaseTest;
import org.exoplatform.services.rest.ConstructorDescriptor;
import org.exoplatform.services.rest.FieldInjector;
+import org.exoplatform.services.rest.impl.BaseTest;
import org.exoplatform.services.rest.impl.header.MediaTypeHelper;
import org.exoplatform.services.rest.method.MethodParameter;
import org.exoplatform.services.rest.resource.AbstractResourceDescriptor;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/ResourceDescriptorValidatorTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/ResourceDescriptorValidatorTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/resource/ResourceDescriptorValidatorTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.resource;
-import org.exoplatform.services.rest.BaseTest;
+import org.exoplatform.services.rest.impl.BaseTest;
import org.exoplatform.services.rest.resource.AbstractResourceDescriptor;
import org.exoplatform.services.rest.resource.ResourceMethodDescriptor;
import org.exoplatform.services.rest.resource.ResourceMethodMap;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/uri/UriBuilderTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/uri/UriBuilderTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/uri/UriBuilderTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.uri;
-import org.exoplatform.services.rest.BaseTest;
+import org.exoplatform.services.rest.impl.BaseTest;
import java.net.URI;
import java.util.HashMap;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/uri/UriComponentTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/uri/UriComponentTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/impl/uri/UriComponentTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.impl.uri;
-import org.exoplatform.services.rest.BaseTest;
+import org.exoplatform.services.rest.impl.BaseTest;
import java.util.List;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/util/MediaTypeMapTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/util/MediaTypeMapTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/util/MediaTypeMapTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.util;
-import org.exoplatform.services.rest.BaseTest;
+import org.exoplatform.services.rest.impl.BaseTest;
import java.util.Iterator;
Modified:
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/wadl/WadlProcessorTest.java
===================================================================
---
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/wadl/WadlProcessorTest.java 2009-10-13
13:50:24 UTC (rev 274)
+++
ws/branches/2.2.x/rest/core/src/test/java/org/exoplatform/services/rest/wadl/WadlProcessorTest.java 2009-10-13
16:17:02 UTC (rev 275)
@@ -18,7 +18,7 @@
*/
package org.exoplatform.services.rest.wadl;
-import org.exoplatform.services.rest.BaseTest;
+import org.exoplatform.services.rest.impl.BaseTest;
import org.exoplatform.services.rest.impl.resource.AbstractResourceDescriptorImpl;
import org.exoplatform.services.rest.resource.AbstractResourceDescriptor;
import org.exoplatform.services.rest.wadl.research.Application;