gatein SVN: r3218 - in components/wsrp/trunk: common/src/main/java/org/gatein/wsrp and 9 other directories.
by do-not-reply@jboss.org
Author: chris.laprun(a)jboss.com
Date: 2010-05-31 13:24:50 -0400 (Mon, 31 May 2010)
New Revision: 3218
Modified:
components/wsrp/trunk/common/pom.xml
components/wsrp/trunk/common/src/main/java/org/gatein/wsrp/WSRPExceptionFactory.java
components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/consumer/WSRPConsumerImpl.java
components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/SOAPServiceFactory.java
components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/ServiceFactory.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/ProducerInfoTestCase.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/BehaviorBackedServiceFactory.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/BehaviorBackedServiceFactory.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/PortletManagementBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/BasicPortletManagementBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/DestroyClonesPortletManagementBehavior.java
components/wsrp/trunk/producer/pom.xml
components/wsrp/trunk/producer/src/main/java/org/gatein/wsrp/producer/RequestProcessor.java
components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/MarkupEndpoint.java
components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/PortletManagementEndpoint.java
components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/RegistrationEndpoint.java
components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/ServiceDescriptionEndpoint.java
Log:
- Fixed improper namespace in JAX-WS annotations for version 2 of service.
- Fixed version 2 deployment of service so that it is working in limited testing.
- Removed now useless methods.
- Fixed improper order in initialization in RequestProcessor.prepareInvocation.
- Cleaned-up POM files a little.
Modified: components/wsrp/trunk/common/pom.xml
===================================================================
--- components/wsrp/trunk/common/pom.xml 2010-05-31 06:35:30 UTC (rev 3217)
+++ components/wsrp/trunk/common/pom.xml 2010-05-31 17:24:50 UTC (rev 3218)
@@ -68,7 +68,6 @@
<dependency>
<groupId>com.google.collections</groupId>
<artifactId>google-collections</artifactId>
- <version>1.0</version>
</dependency>
<!-- tests -->
Modified: components/wsrp/trunk/common/src/main/java/org/gatein/wsrp/WSRPExceptionFactory.java
===================================================================
--- components/wsrp/trunk/common/src/main/java/org/gatein/wsrp/WSRPExceptionFactory.java 2010-05-31 06:35:30 UTC (rev 3217)
+++ components/wsrp/trunk/common/src/main/java/org/gatein/wsrp/WSRPExceptionFactory.java 2010-05-31 17:24:50 UTC (rev 3218)
@@ -69,8 +69,6 @@
{
private static final Logger log = LoggerFactory.getLogger(WSRPExceptionFactory.class);
- private static final String NS = "urn:oasis:names:tc:wsrp:v1:types";
-
public static final String ACCESS_DENIED = "AccessDenied";
public static final String INCONSISTENT_PARAMETERS = "InconsistentParameters";
public static final String INVALID_REGISTRATION = "InvalidRegistration";
@@ -85,7 +83,6 @@
public static final String UNSUPPORTED_MIME_TYPE = "UnsupportedMimeType";
public static final String UNSUPPORTED_MODE = "UnsupportedMode";
public static final String UNSUPPORTED_WINDOW_STATE = "UnsupportedWindowState";
- private static final String NS_PREFIX = "wsrp";
private static final Map<String, ExceptionFactory<? extends Exception, ? extends Fault>> errorCodeToExceptions =
new HashMap<String, ExceptionFactory<? extends Exception, ? extends Fault>>(17);
Modified: components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/consumer/WSRPConsumerImpl.java
===================================================================
--- components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/consumer/WSRPConsumerImpl.java 2010-05-31 06:35:30 UTC (rev 3217)
+++ components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/consumer/WSRPConsumerImpl.java 2010-05-31 17:24:50 UTC (rev 3218)
@@ -578,7 +578,7 @@
return producerInfo.getEndpointConfigurationInfo();
}
- public WSRPV2ServiceDescriptionPortType getServiceDescriptionService() throws PortletInvokerException
+ private WSRPV2ServiceDescriptionPortType getServiceDescriptionService() throws PortletInvokerException
{
refreshProducerInfo(false);
return getEndpointConfigurationInfo().getServiceDescriptionService();
@@ -590,13 +590,13 @@
return getEndpointConfigurationInfo().getMarkupService();
}
- public WSRPV2PortletManagementPortType getPortletManagementService() throws PortletInvokerException
+ private WSRPV2PortletManagementPortType getPortletManagementService() throws PortletInvokerException
{
refreshProducerInfo(false);
return getEndpointConfigurationInfo().getPortletManagementService();
}
- public WSRPV2RegistrationPortType getRegistrationService() throws PortletInvokerException
+ private WSRPV2RegistrationPortType getRegistrationService() throws PortletInvokerException
{
refreshProducerInfo(false);
return getEndpointConfigurationInfo().getRegistrationService();
Modified: components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/SOAPServiceFactory.java
===================================================================
--- components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/SOAPServiceFactory.java 2010-05-31 06:35:30 UTC (rev 3217)
+++ components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/SOAPServiceFactory.java 2010-05-31 17:24:50 UTC (rev 3218)
@@ -49,7 +49,8 @@
private String wsdlDefinitionURL;
- private final static QName SERVICE = new QName("urn:oasis:names:tc:wsrp:v1:wsdl", "WSRPService");
+ private final static QName V1_SERVICE = new QName("urn:oasis:names:tc:wsrp:v1:wsdl", "WSRPService");
+ private final static QName V2_SERVICE = new QName("urn:oasis:names:tc:wsrp:v2:wsdl", "WSRPService");
private Map<Class, Object> services = new ConcurrentHashMap<Class, Object>();
private String markupURL;
@@ -146,53 +147,7 @@
return failed;
}
- public String getServiceDescriptionURL()
- {
- return serviceDescriptionURL;
- }
- public String getMarkupURL()
- {
- return markupURL;
- }
-
- public String getRegistrationURL()
- {
- return registrationURL;
- }
-
- public String getPortletManagementURL()
- {
- return portletManagementURL;
- }
-
- public void setServiceDescriptionURL(String serviceDescriptionURL)
- {
- ParameterValidation.throwIllegalArgExceptionIfNullOrEmpty(serviceDescriptionURL, "Mandatory Service Description interface", null);
- this.serviceDescriptionURL = serviceDescriptionURL;
- setFailed(false); // reset failed status to false since we can't assert it anymore
- }
-
- public void setMarkupURL(String markupURL)
- {
- ParameterValidation.throwIllegalArgExceptionIfNullOrEmpty(markupURL, "Mandatory Markup interface", null);
- this.markupURL = markupURL;
- setFailed(false); // reset failed status to false since we can't assert it anymore
- }
-
- public void setRegistrationURL(String registrationURL)
- {
- this.registrationURL = registrationURL;
- setFailed(false); // reset failed status to false since we can't assert it anymore
- }
-
- public void setPortletManagementURL(String portletManagementURL)
- {
- this.portletManagementURL = portletManagementURL;
- setFailed(false); // reset failed status to false since we can't assert it anymore
- }
-
-
public void stop()
{
// todo: implement as needed
@@ -244,7 +199,7 @@
ParameterValidation.throwIllegalArgExceptionIfNullOrEmpty(wsdlDefinitionURL, "WSDL URL", "SOAPServiceFactory");
URI wsdlURL = new URI(wsdlDefinitionURL);
- Service service = Service.create(wsdlURL.toURL(), SERVICE);
+ Service service = Service.create(wsdlURL.toURL(), V2_SERVICE);
WSRPV2MarkupPortType markupPortType = service.getPort(WSRPV2MarkupPortType.class);
services.put(WSRPV2MarkupPortType.class, markupPortType);
Modified: components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/ServiceFactory.java
===================================================================
--- components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/ServiceFactory.java 2010-05-31 06:35:30 UTC (rev 3217)
+++ components/wsrp/trunk/consumer/src/main/java/org/gatein/wsrp/services/ServiceFactory.java 2010-05-31 17:24:50 UTC (rev 3218)
@@ -52,22 +52,6 @@
*/
boolean isFailed();
- String getServiceDescriptionURL();
-
- String getMarkupURL();
-
- String getRegistrationURL();
-
- String getPortletManagementURL();
-
- void setServiceDescriptionURL(String serviceDescriptionURL);
-
- void setMarkupURL(String markupURL);
-
- void setRegistrationURL(String registrationURL);
-
- void setPortletManagementURL(String portletManagementURL);
-
void start() throws Exception;
void stop();
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/ProducerInfoTestCase.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/ProducerInfoTestCase.java 2010-05-31 06:35:30 UTC (rev 3217)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/ProducerInfoTestCase.java 2010-05-31 17:24:50 UTC (rev 3218)
@@ -41,6 +41,7 @@
import org.oasis.wsrp.v2.InvalidUserCategory;
import org.oasis.wsrp.v2.Lifetime;
import org.oasis.wsrp.v2.MissingParameters;
+import org.oasis.wsrp.v2.ModifyRegistrationRequired;
import org.oasis.wsrp.v2.OperationFailed;
import org.oasis.wsrp.v2.OperationFailedFault;
import org.oasis.wsrp.v2.OperationNotSupported;
@@ -359,7 +360,7 @@
{
@Override
- public void getPortletDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> desiredLocales, @WebParam(mode = WebParam.Mode.OUT, name = "portletDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<PortletDescription> portletDescription, @WebParam(mode = WebParam.Mode.OUT, name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<ResourceList> resourceList, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions) thr!
ows MissingParameters, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, AccessDenied, OperationFailed
+ public void getPortletDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> desiredLocales, @WebParam(name = "portletDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<PortletDescription> portletDescription, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) thr!
ows AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
{
super.getPortletDescription(registrationContext, portletContext, userContext, desiredLocales, portletDescription, resourceList, extensions);
portletDescription.value = createPortletDescription("test2", null);
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/BehaviorBackedServiceFactory.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/BehaviorBackedServiceFactory.java 2010-05-31 06:35:30 UTC (rev 3217)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/BehaviorBackedServiceFactory.java 2010-05-31 17:24:50 UTC (rev 3218)
@@ -137,46 +137,6 @@
return timeout;
}
- public String getServiceDescriptionURL()
- {
- return SD_URL;
- }
-
- public String getMarkupURL()
- {
- return M_URL;
- }
-
- public String getRegistrationURL()
- {
- return R_URL;
- }
-
- public String getPortletManagementURL()
- {
- return PM_URL;
- }
-
- public void setServiceDescriptionURL(String serviceDescriptionURL)
- {
- // do nothing
- }
-
- public void setMarkupURL(String markupURL)
- {
- // do nothing
- }
-
- public void setRegistrationURL(String registrationURL)
- {
- // do nothing
- }
-
- public void setPortletManagementURL(String portletManagementURL)
- {
- // do nothing
- }
-
public void create() throws Exception
{
throw new NotYetImplemented();
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/BehaviorBackedServiceFactory.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/BehaviorBackedServiceFactory.java 2010-05-31 06:35:30 UTC (rev 3217)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/BehaviorBackedServiceFactory.java 2010-05-31 17:24:50 UTC (rev 3218)
@@ -137,46 +137,6 @@
return timeout;
}
- public String getServiceDescriptionURL()
- {
- return SD_URL;
- }
-
- public String getMarkupURL()
- {
- return M_URL;
- }
-
- public String getRegistrationURL()
- {
- return R_URL;
- }
-
- public String getPortletManagementURL()
- {
- return PM_URL;
- }
-
- public void setServiceDescriptionURL(String serviceDescriptionURL)
- {
- // do nothing
- }
-
- public void setMarkupURL(String markupURL)
- {
- // do nothing
- }
-
- public void setRegistrationURL(String registrationURL)
- {
- // do nothing
- }
-
- public void setPortletManagementURL(String portletManagementURL)
- {
- // do nothing
- }
-
public void create() throws Exception
{
throw new NotYetImplemented();
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/PortletManagementBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/PortletManagementBehavior.java 2010-05-31 06:35:30 UTC (rev 3217)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/PortletManagementBehavior.java 2010-05-31 17:24:50 UTC (rev 3218)
@@ -69,12 +69,12 @@
*/
public class PortletManagementBehavior extends TestProducerBehavior implements WSRPV2PortletManagementPortType
{
- public void getPortletPropertyDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> desiredLocales, @WebParam(mode = WebParam.Mode.OUT, name = "modelDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<ModelDescription> modelDescription, @WebParam(mode = WebParam.Mode.OUT, name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<ResourceList> resourceList, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions) thro!
ws MissingParameters, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, AccessDenied, OperationFailed
+ public void getPortletPropertyDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> desiredLocales, @WebParam(name = "modelDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ModelDescription> modelDescription, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) thro!
ws AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
{
incrementCallCount();
}
- public void getPortletDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> desiredLocales, @WebParam(mode = WebParam.Mode.OUT, name = "portletDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<PortletDescription> portletDescription, @WebParam(mode = WebParam.Mode.OUT, name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<ResourceList> resourceList, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions) throws!
MissingParameters, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, AccessDenied, OperationFailed
+ public void getPortletDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> desiredLocales, @WebParam(name = "portletDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<PortletDescription> portletDescription, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws!
AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
{
incrementCallCount();
}
@@ -129,7 +129,7 @@
incrementCallCount();
}
- public void getPortletProperties(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") UserContext userContext, @WebParam(name = "names", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> names, @WebParam(mode = WebParam.Mode.OUT, name = "properties", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Property>> properties, @WebParam(mode = WebParam.Mode.OUT, name = "resetProperties", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<ResetProperty>> resetProperties, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions) throws MissingParameters, Incons!
istentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, AccessDenied, OperationFailed
+ public void getPortletProperties(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "names", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> names, @WebParam(name = "properties", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Property>> properties, @WebParam(name = "resetProperties", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<ResetProperty>> resetProperties, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, Inconsisten!
tParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
{
incrementCallCount();
}
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/BasicPortletManagementBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/BasicPortletManagementBehavior.java 2010-05-31 06:35:30 UTC (rev 3217)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/BasicPortletManagementBehavior.java 2010-05-31 17:24:50 UTC (rev 3218)
@@ -89,13 +89,13 @@
}
@Override
- public void getPortletPropertyDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> desiredLocales, @WebParam(mode = WebParam.Mode.OUT, name = "modelDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<ModelDescription> modelDescription, @WebParam(mode = WebParam.Mode.OUT, name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<ResourceList> resourceList, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions) thro!
ws MissingParameters, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, AccessDenied, OperationFailed
+ public void getPortletPropertyDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> desiredLocales, @WebParam(name = "modelDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ModelDescription> modelDescription, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) thro!
ws AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
{
throw new NotYetImplemented();
}
@Override
- public void getPortletDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> desiredLocales, @WebParam(mode = WebParam.Mode.OUT, name = "portletDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<PortletDescription> portletDescription, @WebParam(mode = WebParam.Mode.OUT, name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<ResourceList> resourceList, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions) throws!
MissingParameters, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, AccessDenied, OperationFailed
+ public void getPortletDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> desiredLocales, @WebParam(name = "portletDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<PortletDescription> portletDescription, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws!
AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
{
super.getPortletDescription(registrationContext, portletContext, userContext, desiredLocales, portletDescription, resourceList, extensions);
@@ -213,7 +213,7 @@
}
@Override
- public void getPortletProperties(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") UserContext userContext, @WebParam(name = "names", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> names, @WebParam(mode = WebParam.Mode.OUT, name = "properties", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Property>> properties, @WebParam(mode = WebParam.Mode.OUT, name = "resetProperties", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<ResetProperty>> resetProperties, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions) throws MissingParameters, Incons!
istentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, AccessDenied, OperationFailed
+ public void getPortletProperties(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "names", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> names, @WebParam(name = "properties", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Property>> properties, @WebParam(name = "resetProperties", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<ResetProperty>> resetProperties, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, Inconsisten!
tParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
{
String handle = getHandleFrom(portletContext, "portlet context");
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/DestroyClonesPortletManagementBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/DestroyClonesPortletManagementBehavior.java 2010-05-31 06:35:30 UTC (rev 3217)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/DestroyClonesPortletManagementBehavior.java 2010-05-31 17:24:50 UTC (rev 3218)
@@ -33,11 +33,14 @@
import org.oasis.wsrp.v2.InvalidRegistration;
import org.oasis.wsrp.v2.InvalidUserCategory;
import org.oasis.wsrp.v2.MissingParameters;
+import org.oasis.wsrp.v2.ModifyRegistrationRequired;
import org.oasis.wsrp.v2.OperationFailed;
+import org.oasis.wsrp.v2.OperationNotSupported;
import org.oasis.wsrp.v2.PortletContext;
import org.oasis.wsrp.v2.PortletDescription;
import org.oasis.wsrp.v2.RegistrationContext;
import org.oasis.wsrp.v2.ResourceList;
+import org.oasis.wsrp.v2.ResourceSuspended;
import org.oasis.wsrp.v2.UserContext;
import javax.jws.WebParam;
@@ -59,7 +62,7 @@
}
@Override
- public void getPortletDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> desiredLocales, @WebParam(mode = WebParam.Mode.OUT, name = "portletDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<PortletDescription> portletDescription, @WebParam(mode = WebParam.Mode.OUT, name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<ResourceList> resourceList, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions) throws!
MissingParameters, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, AccessDenied, OperationFailed
+ public void getPortletDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> desiredLocales, @WebParam(name = "portletDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<PortletDescription> portletDescription, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws!
AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
{
// only return the portlet description the first time the method is called since all other calls happen after
// the clone has been destroyed...
Modified: components/wsrp/trunk/producer/pom.xml
===================================================================
--- components/wsrp/trunk/producer/pom.xml 2010-05-31 06:35:30 UTC (rev 3217)
+++ components/wsrp/trunk/producer/pom.xml 2010-05-31 17:24:50 UTC (rev 3218)
@@ -87,12 +87,8 @@
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-jdk14</artifactId>
+ <scope>test</scope>
</dependency>
- <dependency>
- <groupId>com.google.collections</groupId>
- <artifactId>google-collections</artifactId>
- <version>1.0</version>
- </dependency>
</dependencies>
<!-- Disable some tests for now until we can find some time to work on migrating them -->
Modified: components/wsrp/trunk/producer/src/main/java/org/gatein/wsrp/producer/RequestProcessor.java
===================================================================
--- components/wsrp/trunk/producer/src/main/java/org/gatein/wsrp/producer/RequestProcessor.java 2010-05-31 06:35:30 UTC (rev 3217)
+++ components/wsrp/trunk/producer/src/main/java/org/gatein/wsrp/producer/RequestProcessor.java 2010-05-31 17:24:50 UTC (rev 3218)
@@ -23,11 +23,6 @@
package org.gatein.wsrp.producer;
-import com.google.common.collect.BiMap;
-import com.google.common.collect.HashBiMap;
-import com.google.common.collect.HashMultimap;
-import com.google.common.collect.Maps;
-import com.google.common.collect.Multimap;
import org.gatein.common.net.media.MediaType;
import org.gatein.common.util.MarkupInfo;
import org.gatein.common.util.ParameterValidation;
@@ -43,7 +38,6 @@
import org.gatein.pc.api.spi.UserContext;
import org.gatein.pc.api.spi.WindowContext;
import org.gatein.pc.api.state.AccessMode;
-import org.gatein.pc.api.state.PropertyMap;
import org.gatein.registration.Registration;
import org.gatein.wsrp.UserContextConverter;
import org.gatein.wsrp.WSRPConstants;
@@ -148,22 +142,40 @@
markupRequest = createMarkupRequestFrom(markupTypes, params, portlet);
// prepare information for invocation
+ final org.oasis.wsrp.v2.UserContext wsrpUserContext = getUserContext();
+ checkUserContext(wsrpUserContext);
+
+ SecurityContext securityContext = createSecurityContext(params, runtimeContext, wsrpUserContext);
+ MarkupInfo streamInfo = createStreamInfo(markupRequest);
+ PortalContext portalContext = createPortalContext(params, markupRequest);
+ UserContext userContext = createUserContext(wsrpUserContext, markupRequest.getLocale(), desiredLocales);
+ instanceContext = createInstanceContext(portletContext, getAccessMode(), runtimeContext.getPortletInstanceKey());
+ WindowContext windowContext = createWindowContext(portletContext.getId(), runtimeContext);
+
+ // prepare the invocation
+ WSRPPortletInvocationContext context = new WSRPPortletInvocationContext(streamInfo, securityContext, portalContext, userContext, instanceContext, windowContext);
+ PortletInvocation invocation = initInvocation(context);
+
+ invocation.setTarget(portlet.getContext());
+ invocation.setWindowState(WSRPUtils.getJSR168WindowStateFromWSRPName(markupRequest.getWindowState()));
+ invocation.setMode(WSRPUtils.getJSR168PortletModeFromWSRPName(markupRequest.getMode()));
+
NavigationalContext navigationalContext = params.getNavigationalContext();
- if(navigationalContext != null)
+ if (navigationalContext != null)
{
StateString navigationalState = createNavigationalState(navigationalContext.getOpaqueValue());
invocation.setNavigationalState(navigationalState);
// GTNWSRP-38: public NS
List<NamedString> publicParams = navigationalContext.getPublicValues();
- if(ParameterValidation.existsAndIsNotEmpty(publicParams))
+ if (ParameterValidation.existsAndIsNotEmpty(publicParams))
{
Map<String, String[]> publicNS = new HashMap<String, String[]>(publicParams.size());
for (NamedString publicParam : publicParams)
{
String paramName = publicParam.getName();
String[] values = publicNS.get(paramName);
- if(ParameterValidation.existsAndIsNotEmpty(values))
+ if (ParameterValidation.existsAndIsNotEmpty(values))
{
int valuesNb = values.length;
String[] newValues = new String[valuesNb + 1];
@@ -173,7 +185,7 @@
}
else
{
- values = new String[] {publicParam.getValue()};
+ values = new String[]{publicParam.getValue()};
publicNS.put(paramName, values);
}
}
@@ -181,25 +193,6 @@
}
}
-
- final org.oasis.wsrp.v2.UserContext wsrpUserContext = getUserContext();
- checkUserContext(wsrpUserContext);
-
- SecurityContext securityContext = createSecurityContext(params, runtimeContext, wsrpUserContext);
- MarkupInfo streamInfo = createStreamInfo(markupRequest);
- PortalContext portalContext = createPortalContext(params, markupRequest);
- UserContext userContext = createUserContext(wsrpUserContext, markupRequest.getLocale(), desiredLocales);
- instanceContext = createInstanceContext(portletContext, getAccessMode(), runtimeContext.getPortletInstanceKey());
- WindowContext windowContext = createWindowContext(portletContext.getId(), runtimeContext);
-
- // prepare the invocation
- WSRPPortletInvocationContext context = new WSRPPortletInvocationContext(streamInfo, securityContext, portalContext, userContext, instanceContext, windowContext);
- PortletInvocation invocation = initInvocation(context);
-
- invocation.setTarget(portlet.getContext());
- invocation.setWindowState(WSRPUtils.getJSR168WindowStateFromWSRPName(markupRequest.getWindowState()));
- invocation.setMode(WSRPUtils.getJSR168PortletModeFromWSRPName(markupRequest.getMode()));
-
context.contextualize(invocation);
setInvocation(invocation);
}
Modified: components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/MarkupEndpoint.java
===================================================================
--- components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/MarkupEndpoint.java 2010-05-31 06:35:30 UTC (rev 3217)
+++ components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/MarkupEndpoint.java 2010-05-31 17:24:50 UTC (rev 3218)
@@ -86,37 +86,6 @@
@HandlerChain(file = "wshandlers.xml")
public class MarkupEndpoint extends WSRPBaseEndpoint implements WSRPV2MarkupPortType
{
- public void performBlockingInteraction(
- @WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext,
- @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") PortletContext portletContext,
- @WebParam(name = "runtimeContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RuntimeContext runtimeContext,
- @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") UserContext userContext,
- @WebParam(name = "markupParams", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") MarkupParams markupParams,
- @WebParam(name = "interactionParams", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") InteractionParams interactionParams,
- @WebParam(mode = WebParam.Mode.OUT, name = "updateResponse", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<UpdateResponse> updateResponse,
- @WebParam(mode = WebParam.Mode.OUT, name = "redirectURL", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<String> redirectURL,
- @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions
- ) throws UnsupportedMimeType, UnsupportedMode, UnsupportedWindowState, InvalidCookie, InvalidSession, MissingParameters,
- UnsupportedLocale, InconsistentParameters, PortletStateChangeRequired, InvalidHandle, InvalidRegistration,
- InvalidUserCategory, AccessDenied, OperationFailed
- {
- forceSessionAccess();
-
- PerformBlockingInteraction performBlockingInteraction = new PerformBlockingInteraction();
- performBlockingInteraction.setPortletContext(portletContext);
- performBlockingInteraction.setRuntimeContext(runtimeContext);
- performBlockingInteraction.setMarkupParams(markupParams);
- performBlockingInteraction.setInteractionParams(interactionParams);
- performBlockingInteraction.setRegistrationContext(registrationContext);
- performBlockingInteraction.setUserContext(userContext);
-
- BlockingInteractionResponse interactionResponse = producer.performBlockingInteraction(performBlockingInteraction);
-
- updateResponse.value = interactionResponse.getUpdateResponse();
- redirectURL.value = interactionResponse.getRedirectURL();
- extensions.value = interactionResponse.getExtensions();
- }
-
public void handleEvents(
@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext,
@WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext,
@@ -142,7 +111,15 @@
) throws AccessDenied, InvalidRegistration, MissingParameters, ModifyRegistrationRequired, OperationFailed,
OperationNotSupported, ResourceSuspended
{
- return null; //To change body of implemented methods use File | Settings | File Templates.
+ forceSessionAccess();
+
+ ReleaseSessions releaseSessions = new ReleaseSessions();
+ releaseSessions.setRegistrationContext(registrationContext);
+ releaseSessions.getSessionIDs().addAll(sessionIDs);
+
+ ReturnAny returnAny = producer.releaseSessions(releaseSessions);
+
+ return returnAny.getExtensions();
}
public List<Extension> initCookie(
@@ -150,37 +127,17 @@
@WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext
) throws AccessDenied, InvalidRegistration, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
{
- return null; //To change body of implemented methods use File | Settings | File Templates.
- }
-
- public List<Extension> releaseSessions(
- @WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext,
- @WebParam(name = "sessionIDs", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> sessionIDs
- ) throws MissingParameters, InvalidRegistration, AccessDenied, OperationFailed
- {
forceSessionAccess();
- ReleaseSessions releaseSessions = new ReleaseSessions();
- releaseSessions.setRegistrationContext(registrationContext);
- releaseSessions.getSessionIDs().addAll(sessionIDs);
+ InitCookie initCookie = new InitCookie();
+ initCookie.setRegistrationContext(registrationContext);
- ReturnAny returnAny = producer.releaseSessions(releaseSessions);
+ ReturnAny returnAny = producer.initCookie(initCookie);
return returnAny.getExtensions();
}
- public void getMarkup(
- @WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext,
- @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") PortletContext portletContext,
- @WebParam(name = "runtimeContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RuntimeContext runtimeContext,
- @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") UserContext userContext,
- @WebParam(name = "markupParams", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") MarkupParams markupParams,
- @WebParam(mode = WebParam.Mode.OUT, name = "markupContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<MarkupContext> markupContext,
- @WebParam(mode = WebParam.Mode.OUT, name = "sessionContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<SessionContext> sessionContext,
- @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions
- ) throws UnsupportedMimeType, UnsupportedMode, UnsupportedWindowState, InvalidCookie, InvalidSession, MissingParameters,
- UnsupportedLocale, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, AccessDenied,
- OperationFailed
+ public void getMarkup(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "runtimeContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RuntimeContext runtimeContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "markupParams", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") MarkupParams markupParams, @WebParam(name = "markupContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<MarkupContext> markupContext, @WebParam(name = "sessionContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<SessionContext> sessionContext, @WebParam(name = "extensions", targetNamespace = "urn:oasi!
s:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidCookie, InvalidHandle, InvalidRegistration, InvalidSession, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, ResourceSuspended, UnsupportedLocale, UnsupportedMimeType, UnsupportedMode, UnsupportedWindowState
{
forceSessionAccess();
@@ -214,17 +171,22 @@
//To change body of implemented methods use File | Settings | File Templates.
}
- public List<Extension> initCookie(
- @WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext
- ) throws InvalidRegistration, AccessDenied, OperationFailed
+ public void performBlockingInteraction(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "runtimeContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RuntimeContext runtimeContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "markupParams", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") MarkupParams markupParams, @WebParam(name = "interactionParams", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") InteractionParams interactionParams, @WebParam(name = "updateResponse", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<UpdateResponse> updateResponse, @WebParam(name = "redirectURL", targetNamespace = "urn:oasis:na!
mes:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<String> redirectURL, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidCookie, InvalidHandle, InvalidRegistration, InvalidSession, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, PortletStateChangeRequired, ResourceSuspended, UnsupportedLocale, UnsupportedMimeType, UnsupportedMode, UnsupportedWindowState
{
forceSessionAccess();
- InitCookie initCookie = new InitCookie();
- initCookie.setRegistrationContext(registrationContext);
+ PerformBlockingInteraction performBlockingInteraction = new PerformBlockingInteraction();
+ performBlockingInteraction.setPortletContext(portletContext);
+ performBlockingInteraction.setRuntimeContext(runtimeContext);
+ performBlockingInteraction.setMarkupParams(markupParams);
+ performBlockingInteraction.setInteractionParams(interactionParams);
+ performBlockingInteraction.setRegistrationContext(registrationContext);
+ performBlockingInteraction.setUserContext(userContext);
- ReturnAny returnAny = producer.initCookie(initCookie);
+ BlockingInteractionResponse interactionResponse = producer.performBlockingInteraction(performBlockingInteraction);
- return returnAny.getExtensions();
+ updateResponse.value = interactionResponse.getUpdateResponse();
+ redirectURL.value = interactionResponse.getRedirectURL();
+ extensions.value = interactionResponse.getExtensions();
}
}
Modified: components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/PortletManagementEndpoint.java
===================================================================
--- components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/PortletManagementEndpoint.java 2010-05-31 06:35:30 UTC (rev 3217)
+++ components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/PortletManagementEndpoint.java 2010-05-31 17:24:50 UTC (rev 3218)
@@ -88,14 +88,15 @@
public class PortletManagementEndpoint extends WSRPBaseEndpoint implements WSRPV2PortletManagementPortType
{
public void getPortletPropertyDescription(
- @WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext,
- @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") PortletContext portletContext,
- @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") UserContext userContext,
- @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> desiredLocales,
- @WebParam(mode = WebParam.Mode.OUT, name = "modelDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<ModelDescription> modelDescription,
- @WebParam(mode = WebParam.Mode.OUT, name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<ResourceList> resourceList,
- @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions
- ) throws MissingParameters, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, AccessDenied, OperationFailed
+ @WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext,
+ @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext,
+ @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext,
+ @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> desiredLocales,
+ @WebParam(name = "modelDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ModelDescription> modelDescription,
+ @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList,
+ @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions)
+ throws AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory,
+ MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
{
GetPortletPropertyDescription getPortletPropertyDescription = new GetPortletPropertyDescription();
getPortletPropertyDescription.setRegistrationContext(registrationContext);
@@ -110,59 +111,16 @@
extensions.value = descriptionResponse.getExtensions();
}
- public void setPortletProperties(
- @WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext,
- @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") PortletContext portletContext,
- @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") UserContext userContext,
- @WebParam(name = "propertyList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") PropertyList propertyList,
- @WebParam(mode = WebParam.Mode.OUT, name = "portletHandle", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<String> portletHandle,
- @WebParam(mode = WebParam.Mode.OUT, name = "portletState", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<byte[]> portletState,
- @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions
- ) throws MissingParameters, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, AccessDenied, OperationFailed
- {
- SetPortletProperties setPortletProperties = new SetPortletProperties();
- setPortletProperties.setRegistrationContext(registrationContext);
- setPortletProperties.setPortletContext(portletContext);
- setPortletProperties.setUserContext(userContext);
- setPortletProperties.setPropertyList(propertyList);
-
- PortletContext response = producer.setPortletProperties(setPortletProperties);
-
- portletHandle.value = response.getPortletHandle();
- portletState.value = response.getPortletState();
- extensions.value = response.getExtensions();
- }
-
- public void clonePortlet(
- @WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext,
- @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") PortletContext portletContext,
- @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") UserContext userContext,
- @WebParam(mode = WebParam.Mode.OUT, name = "portletHandle", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<String> portletHandle,
- @WebParam(mode = WebParam.Mode.OUT, name = "portletState", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<byte[]> portletState,
- @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions
- ) throws MissingParameters, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, AccessDenied, OperationFailed
- {
- ClonePortlet clonePortlet = new ClonePortlet();
- clonePortlet.setRegistrationContext(registrationContext);
- clonePortlet.setPortletContext(portletContext);
- clonePortlet.setUserContext(userContext);
-
- PortletContext response = producer.clonePortlet(clonePortlet);
-
- portletHandle.value = response.getPortletHandle();
- portletState.value = response.getPortletState();
- extensions.value = response.getExtensions();
- }
-
public void getPortletDescription(
- @WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext,
- @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") PortletContext portletContext,
- @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") UserContext userContext,
- @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> desiredLocales,
- @WebParam(mode = WebParam.Mode.OUT, name = "portletDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<PortletDescription> portletDescription,
- @WebParam(mode = WebParam.Mode.OUT, name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<ResourceList> resourceList,
- @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions
- ) throws MissingParameters, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, AccessDenied, OperationFailed
+ @WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext,
+ @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext,
+ @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext,
+ @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> desiredLocales,
+ @WebParam(name = "portletDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<PortletDescription> portletDescription,
+ @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList,
+ @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions)
+ throws AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory,
+ MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
{
GetPortletDescription getPortletDescription = new GetPortletDescription();
getPortletDescription.setRegistrationContext(registrationContext);
@@ -189,7 +147,16 @@
throws AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory,
MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
{
- //To change body of implemented methods use File | Settings | File Templates.
+ ClonePortlet clonePortlet = new ClonePortlet();
+ clonePortlet.setRegistrationContext(registrationContext);
+ clonePortlet.setPortletContext(portletContext);
+ clonePortlet.setUserContext(userContext);
+
+ PortletContext response = producer.clonePortlet(clonePortlet);
+
+ portletHandle.value = response.getPortletHandle();
+ portletState.value = response.getPortletState();
+ extensions.value = response.getExtensions();
}
public void destroyPortlets(
@@ -200,7 +167,14 @@
@WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions)
throws InconsistentParameters, InvalidRegistration, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
{
- //To change body of implemented methods use File | Settings | File Templates.
+ DestroyPortlets destroyPortlets = new DestroyPortlets();
+ destroyPortlets.setRegistrationContext(registrationContext);
+ destroyPortlets.getPortletHandles().addAll(portletHandles);
+
+ DestroyPortletsResponse destroyPortletsResponse = producer.destroyPortlets(destroyPortlets);
+
+ failedPortlets.value = destroyPortletsResponse.getFailedPortlets();
+ extensions.value = destroyPortletsResponse.getExtensions();
}
public void getPortletsLifetime(
@@ -303,18 +277,20 @@
@WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions)
throws AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
{
- //To change body of implemented methods use File | Settings | File Templates.
+ SetPortletProperties setPortletProperties = new SetPortletProperties();
+ setPortletProperties.setRegistrationContext(registrationContext);
+ setPortletProperties.setPortletContext(portletContext);
+ setPortletProperties.setUserContext(userContext);
+ setPortletProperties.setPropertyList(propertyList);
+
+ PortletContext response = producer.setPortletProperties(setPortletProperties);
+
+ portletHandle.value = response.getPortletHandle();
+ portletState.value = response.getPortletState();
+ extensions.value = response.getExtensions();
}
- public void getPortletProperties(
- @WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext,
- @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") PortletContext portletContext,
- @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") UserContext userContext,
- @WebParam(name = "names", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> names,
- @WebParam(mode = WebParam.Mode.OUT, name = "properties", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Property>> properties,
- @WebParam(mode = WebParam.Mode.OUT, name = "resetProperties", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<ResetProperty>> resetProperties,
- @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions
- ) throws MissingParameters, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, AccessDenied, OperationFailed
+ public void getPortletProperties(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "names", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> names, @WebParam(name = "properties", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Property>> properties, @WebParam(name = "resetProperties", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<ResetProperty>> resetProperties, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, Inconsisten!
tParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
{
GetPortletProperties getPortletProperties = new GetPortletProperties();
getPortletProperties.setRegistrationContext(registrationContext);
@@ -328,21 +304,4 @@
resetProperties.value = result.getResetProperties();
extensions.value = result.getExtensions();
}
-
- /*public void destroyPortlets(
- @WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext,
- @WebParam(name = "portletHandles", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> portletHandles,
- @WebParam(mode = WebParam.Mode.OUT, name = "destroyFailed", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<DestroyFailed>> destroyFailed,
- @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions
- ) throws MissingParameters, InconsistentParameters, InvalidRegistration, OperationFailed
- {
- DestroyPortlets destroyPortlets = new DestroyPortlets();
- destroyPortlets.setRegistrationContext(registrationContext);
- destroyPortlets.getPortletHandles().addAll(portletHandles);
-
- DestroyPortletsResponse destroyPortletsResponse = producer.destroyPortlets(destroyPortlets);
-
- destroyFailed.value = destroyPortletsResponse.getDestroyFailed();
- extensions.value = destroyPortletsResponse.getExtensions();
- }*/
}
Modified: components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/RegistrationEndpoint.java
===================================================================
--- components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/RegistrationEndpoint.java 2010-05-31 06:35:30 UTC (rev 3217)
+++ components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/RegistrationEndpoint.java 2010-05-31 17:24:50 UTC (rev 3218)
@@ -35,7 +35,6 @@
import org.oasis.wsrp.v2.ModifyRegistrationRequired;
import org.oasis.wsrp.v2.OperationFailed;
import org.oasis.wsrp.v2.OperationNotSupported;
-import org.oasis.wsrp.v2.Property;
import org.oasis.wsrp.v2.RegistrationContext;
import org.oasis.wsrp.v2.RegistrationData;
import org.oasis.wsrp.v2.RegistrationState;
@@ -65,74 +64,7 @@
@HandlerChain(file = "wshandlers.xml")
public class RegistrationEndpoint extends WSRPBaseEndpoint implements WSRPV2RegistrationPortType
{
-
public void register(
- @WebParam(name = "consumerName", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") String consumerName,
- @WebParam(name = "consumerAgent", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") String consumerAgent,
- @WebParam(name = "methodGetSupported", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") boolean methodGetSupported,
- @WebParam(name = "consumerModes", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> consumerModes,
- @WebParam(name = "consumerWindowStates", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> consumerWindowStates,
- @WebParam(name = "consumerUserScopes", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> consumerUserScopes,
- @WebParam(name = "customUserProfileData", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> customUserProfileData,
- @WebParam(name = "registrationProperties", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<Property> registrationProperties,
- @WebParam(mode = WebParam.Mode.INOUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions,
- @WebParam(mode = WebParam.Mode.OUT, name = "registrationHandle", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<String> registrationHandle,
- @WebParam(mode = WebParam.Mode.OUT, name = "registrationState", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<byte[]> registrationState)
- throws MissingParameters, OperationFailed
- {
- RegistrationData registrationData = new RegistrationData();
- registrationData.setConsumerName(consumerName);
- registrationData.setConsumerAgent(consumerAgent);
- registrationData.getConsumerModes().addAll(consumerModes);
- registrationData.getConsumerWindowStates().addAll(consumerWindowStates);
- registrationData.getConsumerUserScopes().addAll(consumerUserScopes);
-// registrationData.getCustomUserProfileData().addAll(customUserProfileData);
- registrationData.getRegistrationProperties().addAll(registrationProperties);
- registrationData.getExtensions().addAll(extensions.value);
-
- RegistrationContext registrationContext = producer.register(registrationData);
-
- registrationHandle.value = registrationContext.getRegistrationHandle();
- registrationState.value = registrationContext.getRegistrationState();
- extensions.value = registrationContext.getExtensions();
- }
-
- public void modifyRegistration(
- @WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext,
- @WebParam(name = "registrationData", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationData registrationData,
- @WebParam(mode = WebParam.Mode.OUT, name = "registrationState", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<byte[]> registrationState,
- @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions)
- throws MissingParameters, InvalidRegistration, OperationFailed
- {
- ModifyRegistration modifyRegistration = new ModifyRegistration();
- modifyRegistration.setRegistrationContext(registrationContext);
- modifyRegistration.setRegistrationData(registrationData);
-
- RegistrationState result = producer.modifyRegistration(modifyRegistration);
-
- // it is possible (if not likely) that result of modifyRegistration be null
- if (result != null)
- {
- registrationState.value = result.getRegistrationState();
- extensions.value = result.getExtensions();
- }
- }
-
- public List<Extension> deregister(
- @WebParam(name = "registrationHandle", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") String registrationHandle,
- @WebParam(name = "registrationState", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") byte[] registrationState,
- @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<Extension> extensions)
- throws InvalidRegistration, OperationFailed
- {
- RegistrationContext rc = new RegistrationContext();
- rc.setRegistrationHandle(registrationHandle);
- rc.setRegistrationState(registrationState);
-
- producer.deregister(rc);
- return null;
- }
-
- public void register(
@WebParam(name = "registrationData", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationData registrationData,
@WebParam(name = "lifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") Lifetime lifetime,
@WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext,
@@ -142,7 +74,11 @@
@WebParam(name = "registrationHandle", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<String> registrationHandle)
throws MissingParameters, OperationFailed, OperationNotSupported
{
- //To change body of implemented methods use File | Settings | File Templates.
+ RegistrationContext registrationContext = producer.register(registrationData);
+
+ registrationHandle.value = registrationContext.getRegistrationHandle();
+ registrationState.value = registrationContext.getRegistrationState();
+ extensions.value = registrationContext.getExtensions();
}
public List<Extension> deregister(
@@ -150,7 +86,8 @@
@WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext)
throws InvalidRegistration, OperationFailed, OperationNotSupported, ResourceSuspended
{
- return null; //To change body of implemented methods use File | Settings | File Templates.
+ producer.deregister(registrationContext);
+ return null;
}
public void modifyRegistration(
@@ -162,7 +99,18 @@
@WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions)
throws InvalidRegistration, MissingParameters, OperationFailed, OperationNotSupported, ResourceSuspended
{
- //To change body of implemented methods use File | Settings | File Templates.
+ ModifyRegistration modifyRegistration = new ModifyRegistration();
+ modifyRegistration.setRegistrationContext(registrationContext);
+ modifyRegistration.setRegistrationData(registrationData);
+
+ RegistrationState result = producer.modifyRegistration(modifyRegistration);
+
+ // it is possible (if not likely) that result of modifyRegistration be null
+ if (result != null)
+ {
+ registrationState.value = result.getRegistrationState();
+ extensions.value = result.getExtensions();
+ }
}
public Lifetime getRegistrationLifetime(
Modified: components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/ServiceDescriptionEndpoint.java
===================================================================
--- components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/ServiceDescriptionEndpoint.java 2010-05-31 06:35:30 UTC (rev 3217)
+++ components/wsrp/trunk/wsrp-producer-war/src/main/java/org/gatein/wsrp/endpoints/v2/ServiceDescriptionEndpoint.java 2010-05-31 17:24:50 UTC (rev 3218)
@@ -65,41 +65,6 @@
public class ServiceDescriptionEndpoint extends WSRPBaseEndpoint implements WSRPV2ServiceDescriptionPortType
{
public void getServiceDescription(
- @WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext,
- @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> desiredLocales,
- @WebParam(mode = WebParam.Mode.OUT, name = "requiresRegistration", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<Boolean> requiresRegistration,
- @WebParam(mode = WebParam.Mode.OUT, name = "offeredPortlets", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<PortletDescription>> offeredPortlets,
- @WebParam(mode = WebParam.Mode.OUT, name = "userCategoryDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<ItemDescription>> userCategoryDescriptions,
- @WebParam(mode = WebParam.Mode.OUT, name = "customUserProfileItemDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<ItemDescription>> customUserProfileItemDescriptions,
- @WebParam(mode = WebParam.Mode.OUT, name = "customWindowStateDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<ItemDescription>> customWindowStateDescriptions,
- @WebParam(mode = WebParam.Mode.OUT, name = "customModeDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<ItemDescription>> customModeDescriptions,
- @WebParam(mode = WebParam.Mode.OUT, name = "requiresInitCookie", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<CookieProtocol> requiresInitCookie,
- @WebParam(mode = WebParam.Mode.OUT, name = "registrationPropertyDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<ModelDescription> registrationPropertyDescription,
- @WebParam(mode = WebParam.Mode.OUT, name = "locales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<String>> locales,
- @WebParam(mode = WebParam.Mode.OUT, name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<ResourceList> resourceList,
- @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions
- ) throws InvalidRegistration, OperationFailed
- {
- GetServiceDescription getServiceDescription = new GetServiceDescription();
- getServiceDescription.setRegistrationContext(registrationContext);
- getServiceDescription.getDesiredLocales().addAll(desiredLocales);
-
- ServiceDescription description = producer.getServiceDescription(getServiceDescription);
-
- requiresRegistration.value = description.isRequiresRegistration();
- offeredPortlets.value = description.getOfferedPortlets();
- userCategoryDescriptions.value = description.getUserCategoryDescriptions();
-// customUserProfileItemDescriptions.value = description.getCustomUserProfileItemDescriptions();
- customWindowStateDescriptions.value = description.getCustomWindowStateDescriptions();
- customModeDescriptions.value = description.getCustomModeDescriptions();
- requiresInitCookie.value = description.getRequiresInitCookie();
- registrationPropertyDescription.value = description.getRegistrationPropertyDescription();
- locales.value = description.getLocales();
- resourceList.value = description.getResourceList();
- extensions.value = description.getExtensions();
- }
-
- public void getServiceDescription(
@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext,
@WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> desiredLocales,
@WebParam(name = "portletHandles", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> portletHandles,
@@ -122,6 +87,22 @@
@WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions)
throws InvalidRegistration, ModifyRegistrationRequired, OperationFailed, ResourceSuspended
{
- //To change body of implemented methods use File | Settings | File Templates.
+ GetServiceDescription getServiceDescription = new GetServiceDescription();
+ getServiceDescription.setRegistrationContext(registrationContext);
+ getServiceDescription.getDesiredLocales().addAll(desiredLocales);
+
+ ServiceDescription description = producer.getServiceDescription(getServiceDescription);
+
+ requiresRegistration.value = description.isRequiresRegistration();
+ offeredPortlets.value = description.getOfferedPortlets();
+ userCategoryDescriptions.value = description.getUserCategoryDescriptions();
+// customUserProfileItemDescriptions.value = description.getCustomUserProfileItemDescriptions();
+ customWindowStateDescriptions.value = description.getCustomWindowStateDescriptions();
+ customModeDescriptions.value = description.getCustomModeDescriptions();
+ requiresInitCookie.value = description.getRequiresInitCookie();
+ registrationPropertyDescription.value = description.getRegistrationPropertyDescription();
+ locales.value = description.getLocales();
+ resourceList.value = description.getResourceList();
+ extensions.value = description.getExtensions();
}
}
14 years, 7 months
gatein SVN: r3217 - epp/docs/tags.
by do-not-reply@jboss.org
Author: thomas.heute(a)jboss.com
Date: 2010-05-31 02:35:30 -0400 (Mon, 31 May 2010)
New Revision: 3217
Added:
epp/docs/tags/EPP_5_0_0_GA/
Log:
Tagging docs of 5.0.0
Copied: epp/docs/tags/EPP_5_0_0_GA (from rev 3216, epp/docs/branches/EPP_5_0_Branch)
14 years, 7 months
gatein SVN: r3216 - portal/branches and 1 other directory.
by do-not-reply@jboss.org
Author: thomas.heute(a)jboss.com
Date: 2010-05-31 02:33:50 -0400 (Mon, 31 May 2010)
New Revision: 3216
Added:
epp/docs/branches/EPP_5_0_Branch/
Removed:
portal/branches/EPP_5_0_0_Branch_Docs/
Log:
Moving docs where it should always have been
Copied: epp/docs/branches/EPP_5_0_Branch (from rev 3215, portal/branches/EPP_5_0_0_Branch_Docs)
14 years, 7 months
gatein SVN: r3215 - in portal/branches/wsrp2-integration: component/wsrp/src/main/java/org/gatein/portal/wsrp/state/consumer/mapping and 1 other directories.
by do-not-reply@jboss.org
Author: chris.laprun(a)jboss.com
Date: 2010-05-29 05:08:48 -0400 (Sat, 29 May 2010)
New Revision: 3215
Modified:
portal/branches/wsrp2-integration/component/wsrp/src/main/java/org/gatein/portal/wsrp/state/consumer/mapping/RegistrationInfoMapping.java
portal/branches/wsrp2-integration/component/wsrp/src/main/java/org/gatein/portal/wsrp/state/consumer/mapping/RegistrationPropertyMapping.java
portal/branches/wsrp2-integration/packaging/module/src/main/javascript/portal.packaging.module.js
portal/branches/wsrp2-integration/pom.xml
Log:
- Modifications to run with WSRP 2 snapshot.
Modified: portal/branches/wsrp2-integration/component/wsrp/src/main/java/org/gatein/portal/wsrp/state/consumer/mapping/RegistrationInfoMapping.java
===================================================================
--- portal/branches/wsrp2-integration/component/wsrp/src/main/java/org/gatein/portal/wsrp/state/consumer/mapping/RegistrationInfoMapping.java 2010-05-28 09:32:17 UTC (rev 3214)
+++ portal/branches/wsrp2-integration/component/wsrp/src/main/java/org/gatein/portal/wsrp/state/consumer/mapping/RegistrationInfoMapping.java 2010-05-29 09:08:48 UTC (rev 3215)
@@ -87,7 +87,7 @@
for (RegistrationProperty property : regInfo.getRegistrationProperties().values())
{
// create new RegistrationPropertyMapping for this RegistrationInfoMapping
- RegistrationPropertyMapping rpm = createRegistrationProperty(property.getName());
+ RegistrationPropertyMapping rpm = createRegistrationProperty(property.getName().toString());
// add newly created RegistrationPropertyMapping to parent then initialize for JCR
rpms.add(rpm);
Modified: portal/branches/wsrp2-integration/component/wsrp/src/main/java/org/gatein/portal/wsrp/state/consumer/mapping/RegistrationPropertyMapping.java
===================================================================
--- portal/branches/wsrp2-integration/component/wsrp/src/main/java/org/gatein/portal/wsrp/state/consumer/mapping/RegistrationPropertyMapping.java 2010-05-28 09:32:17 UTC (rev 3214)
+++ portal/branches/wsrp2-integration/component/wsrp/src/main/java/org/gatein/portal/wsrp/state/consumer/mapping/RegistrationPropertyMapping.java 2010-05-29 09:08:48 UTC (rev 3215)
@@ -65,7 +65,7 @@
public void initFrom(RegistrationProperty property)
{
// set properties
- setName(property.getName());
+ setName(property.getName().toString());
setStatus(property.getStatus());
setValue(property.getValue());
Modified: portal/branches/wsrp2-integration/packaging/module/src/main/javascript/portal.packaging.module.js
===================================================================
--- portal/branches/wsrp2-integration/packaging/module/src/main/javascript/portal.packaging.module.js 2010-05-28 09:32:17 UTC (rev 3214)
+++ portal/branches/wsrp2-integration/packaging/module/src/main/javascript/portal.packaging.module.js 2010-05-29 09:08:48 UTC (rev 3215)
@@ -86,6 +86,7 @@
.addDependency(new Project("org.gatein.wsrp", "wsrp-producer-lib", "jar",wsrpVersion))
.addDependency(new Project("org.gatein.wsrp", "wsrp-common", "jar", wsrpVersion))
.addDependency(new Project("org.gatein.wsrp", "wsrp-wsrp1-ws", "jar", wsrpVersion))
+ .addDependency(new Project("org.gatein.wsrp", "wsrp-wsrp2-ws", "jar", wsrpVersion))
.addDependency(new Project("org.gatein.wsrp", "wsrp-consumer", "jar", wsrpVersion))
.addDependency(new Project("org.gatein.wsrp", "wsrp-integration-api", "jar", wsrpVersion));
Modified: portal/branches/wsrp2-integration/pom.xml
===================================================================
--- portal/branches/wsrp2-integration/pom.xml 2010-05-28 09:32:17 UTC (rev 3214)
+++ portal/branches/wsrp2-integration/pom.xml 2010-05-29 09:08:48 UTC (rev 3215)
@@ -44,11 +44,11 @@
<org.jibx.version>1.2.1</org.jibx.version>
<org.shindig.version>1.0-r790473-Patch02</org.shindig.version>
<nl.captcha.simplecaptcha.version>1.1.1-GA-Patch01</nl.captcha.simplecaptcha.version>
- <org.gatein.common.version>2.0.2-GA</org.gatein.common.version>
+ <org.gatein.common.version>2.0.3-GA-SNAPSHOT</org.gatein.common.version>
<org.gatein.wci.version>2.0.1-GA</org.gatein.wci.version>
<org.gatein.pc.version>2.1.1-GA</org.gatein.pc.version>
<org.picketlink.idm>1.1.5.CR01</org.picketlink.idm>
- <org.gatein.wsrp.version>1.1.1-GA</org.gatein.wsrp.version>
+ <org.gatein.wsrp.version>2.0.0-Alpha-01-SNAPSHOT</org.gatein.wsrp.version>
<org.gatein.mop.version>1.0.3-CR01</org.gatein.mop.version>
<org.slf4j.version>1.5.6</org.slf4j.version>
<rhino.version>1.6R5</rhino.version>
14 years, 7 months
gatein SVN: r3214 - in components/wsrp/trunk: wsrp2-ws/src/main/resources/wsdl and 1 other directory.
by do-not-reply@jboss.org
Author: chris.laprun(a)jboss.com
Date: 2010-05-28 05:32:17 -0400 (Fri, 28 May 2010)
New Revision: 3214
Modified:
components/wsrp/trunk/wsrp1-ws/src/main/resources/wsdl/wsrp-1.0-services.wsdl
components/wsrp/trunk/wsrp2-ws/src/main/resources/wsdl/wsrp-2.0-services.wsdl
Log:
- Changed name of port for Markup to WSRPMarkupService to be consistent with what's declared in the producer war.
Modified: components/wsrp/trunk/wsrp1-ws/src/main/resources/wsdl/wsrp-1.0-services.wsdl
===================================================================
--- components/wsrp/trunk/wsrp1-ws/src/main/resources/wsdl/wsrp-1.0-services.wsdl 2010-05-28 09:29:22 UTC (rev 3213)
+++ components/wsrp/trunk/wsrp1-ws/src/main/resources/wsdl/wsrp-1.0-services.wsdl 2010-05-28 09:32:17 UTC (rev 3214)
@@ -30,21 +30,21 @@
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
- <import namespace="urn:oasis:names:tc:wsrp:v1:bind"
- location="wsrp_v1_bindings.wsdl"/>
+ <import namespace="urn:oasis:names:tc:wsrp:v1:bind"
+ location="wsrp_v1_bindings.wsdl"/>
- <wsdl:service name="WSRPService">
- <wsdl:port binding="bind:WSRP_v1_Markup_Binding_SOAP" name="WSRPBaseService">
- <soap:address location="http://my.service:8080/WSRPService"/>
- </wsdl:port>
- <wsdl:port binding="bind:WSRP_v1_ServiceDescription_Binding_SOAP" name="WSRPServiceDescriptionService">
- <soap:address location="http://my.service:8080/WSRPService"/>
- </wsdl:port>
- <wsdl:port binding="bind:WSRP_v1_Registration_Binding_SOAP" name="WSRPRegistrationService">
- <soap:address location="http://my.service:8080/WSRPService"/>
- </wsdl:port>
- <wsdl:port binding="bind:WSRP_v1_PortletManagement_Binding_SOAP" name="WSRPPortletManagementService">
- <soap:address location="http://my.service:8080/WSRPService"/>
- </wsdl:port>
- </wsdl:service>
+ <wsdl:service name="WSRPService">
+ <wsdl:port binding="bind:WSRP_v1_Markup_Binding_SOAP" name="WSRPMarkupService">
+ <soap:address location="REPLACE_WITH_ACTUAL_URL"/>
+ </wsdl:port>
+ <wsdl:port binding="bind:WSRP_v1_ServiceDescription_Binding_SOAP" name="WSRPServiceDescriptionService">
+ <soap:address location="REPLACE_WITH_ACTUAL_URL"/>
+ </wsdl:port>
+ <wsdl:port binding="bind:WSRP_v1_Registration_Binding_SOAP" name="WSRPRegistrationService">
+ <soap:address location="REPLACE_WITH_ACTUAL_URL"/>
+ </wsdl:port>
+ <wsdl:port binding="bind:WSRP_v1_PortletManagement_Binding_SOAP" name="WSRPPortletManagementService">
+ <soap:address location="REPLACE_WITH_ACTUAL_URL"/>
+ </wsdl:port>
+ </wsdl:service>
</wsdl:definitions>
Modified: components/wsrp/trunk/wsrp2-ws/src/main/resources/wsdl/wsrp-2.0-services.wsdl
===================================================================
--- components/wsrp/trunk/wsrp2-ws/src/main/resources/wsdl/wsrp-2.0-services.wsdl 2010-05-28 09:29:22 UTC (rev 3213)
+++ components/wsrp/trunk/wsrp2-ws/src/main/resources/wsdl/wsrp-2.0-services.wsdl 2010-05-28 09:32:17 UTC (rev 3214)
@@ -33,7 +33,7 @@
<import namespace="urn:oasis:names:tc:wsrp:v2:bind" location="wsrp-2.0-bindings.wsdl"/>
<wsdl:service name="WSRPService">
- <wsdl:port binding="bind:WSRP_v2_Markup_Binding_SOAP" name="WSRPBaseService">
+ <wsdl:port binding="bind:WSRP_v2_Markup_Binding_SOAP" name="WSRPMarkupService">
<soap:address location="REPLACE_WITH_ACTUAL_URL"/>
</wsdl:port>
<wsdl:port binding="bind:WSRP_v2_ServiceDescription_Binding_SOAP" name="WSRPServiceDescriptionService">
14 years, 7 months
gatein SVN: r3213 - in components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF: wsdl and 1 other directory.
by do-not-reply@jboss.org
Author: chris.laprun(a)jboss.com
Date: 2010-05-28 05:29:22 -0400 (Fri, 28 May 2010)
New Revision: 3213
Added:
components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/wsdl/wsrp-2.0-bindings.wsdl
components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/wsdl/wsrp-2.0-extra.xsd
components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/wsdl/wsrp-2.0-interfaces.wsdl
components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/wsdl/wsrp-2.0-services.wsdl
components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/wsdl/wsrp-2.0-types.xsd
Modified:
components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/web.xml
Log:
- Producer should now properly deploy (which is different from properly working! ^_^)
Modified: components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/web.xml
===================================================================
--- components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/web.xml 2010-05-28 07:31:38 UTC (rev 3212)
+++ components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/web.xml 2010-05-28 09:29:22 UTC (rev 3213)
@@ -55,58 +55,110 @@
</servlet>-->
- <!-- WSRP Endpoints -->
+ <!-- WSRP 2 Endpoints -->
<servlet>
- <servlet-name>ServiceDescriptionService</servlet-name>
+ <servlet-name>V2ServiceDescriptionService</servlet-name>
<servlet-class>org.gatein.wsrp.endpoints.v2.ServiceDescriptionEndpoint</servlet-class>
<init-param>
<param-name>wsrp-interface</param-name>
- <param-value>org.oasis.wsrp.v2.WSRPV1ServiceDescriptionPortType</param-value>
+ <param-value>org.oasis.wsrp.v2.WSRPV2ServiceDescriptionPortType</param-value>
</init-param>
</servlet>
<servlet>
- <servlet-name>MarkupService</servlet-name>
+ <servlet-name>V2MarkupService</servlet-name>
<servlet-class>org.gatein.wsrp.endpoints.v2.MarkupEndpoint</servlet-class>
<init-param>
<param-name>wsrp-interface</param-name>
- <param-value>org.oasis.wsrp.v2.WSRPV1MarkupPortType</param-value>
+ <param-value>org.oasis.wsrp.v2.WSRPV2MarkupPortType</param-value>
</init-param>
</servlet>
<servlet>
- <servlet-name>RegistrationService</servlet-name>
+ <servlet-name>V2RegistrationService</servlet-name>
<servlet-class>org.gatein.wsrp.endpoints.v2.RegistrationEndpoint</servlet-class>
<init-param>
<param-name>wsrp-interface</param-name>
- <param-value>org.oasis.wsrp.v2.WSRPV1RegistrationPortType</param-value>
+ <param-value>org.oasis.wsrp.v2.WSRPV2RegistrationPortType</param-value>
</init-param>
</servlet>
<servlet>
- <servlet-name>PortletManagementService</servlet-name>
+ <servlet-name>V2PortletManagementService</servlet-name>
<servlet-class>org.gatein.wsrp.endpoints.v2.PortletManagementEndpoint</servlet-class>
<init-param>
<param-name>wsrp-interface</param-name>
- <param-value>org.oasis.wsrp.v2.WSRPV1PortletManagementPortType</param-value>
+ <param-value>org.oasis.wsrp.v2.WSRPV2PortletManagementPortType</param-value>
</init-param>
</servlet>
- <!-- WSRP endpoint mappings -->
+ <!-- WSRP 2 endpoint mappings -->
<servlet-mapping>
- <servlet-name>ServiceDescriptionService</servlet-name>
- <url-pattern>/ServiceDescriptionService</url-pattern>
+ <servlet-name>V2ServiceDescriptionService</servlet-name>
+ <url-pattern>/v2/ServiceDescriptionService</url-pattern>
</servlet-mapping>
<servlet-mapping>
- <servlet-name>MarkupService</servlet-name>
- <url-pattern>/MarkupService</url-pattern>
+ <servlet-name>V2MarkupService</servlet-name>
+ <url-pattern>/v2/MarkupService</url-pattern>
</servlet-mapping>
<servlet-mapping>
- <servlet-name>RegistrationService</servlet-name>
- <url-pattern>/RegistrationService</url-pattern>
+ <servlet-name>V2RegistrationService</servlet-name>
+ <url-pattern>/v2/RegistrationService</url-pattern>
</servlet-mapping>
<servlet-mapping>
- <servlet-name>PortletManagementService</servlet-name>
- <url-pattern>/PortletManagementService</url-pattern>
+ <servlet-name>V2PortletManagementService</servlet-name>
+ <url-pattern>/v2/PortletManagementService</url-pattern>
</servlet-mapping>
+ <!-- WSRP 1 Endpoints -->
+ <servlet>
+ <servlet-name>V1ServiceDescriptionService</servlet-name>
+ <servlet-class>org.gatein.wsrp.endpoints.v1.ServiceDescriptionEndpoint</servlet-class>
+ <init-param>
+ <param-name>wsrp-interface</param-name>
+ <param-value>org.oasis.wsrp.v1.WSRPV1ServiceDescriptionPortType</param-value>
+ </init-param>
+ </servlet>
+ <servlet>
+ <servlet-name>V1MarkupService</servlet-name>
+ <servlet-class>org.gatein.wsrp.endpoints.v1.MarkupEndpoint</servlet-class>
+ <init-param>
+ <param-name>wsrp-interface</param-name>
+ <param-value>org.oasis.wsrp.v1.WSRPV1MarkupPortType</param-value>
+ </init-param>
+ </servlet>
+ <servlet>
+ <servlet-name>V1RegistrationService</servlet-name>
+ <servlet-class>org.gatein.wsrp.endpoints.v1.RegistrationEndpoint</servlet-class>
+ <init-param>
+ <param-name>wsrp-interface</param-name>
+ <param-value>org.oasis.wsrp.v1.WSRPV1RegistrationPortType</param-value>
+ </init-param>
+ </servlet>
+ <servlet>
+ <servlet-name>V1PortletManagementService</servlet-name>
+ <servlet-class>org.gatein.wsrp.endpoints.v1.PortletManagementEndpoint</servlet-class>
+ <init-param>
+ <param-name>wsrp-interface</param-name>
+ <param-value>org.oasis.wsrp.v1.WSRPV1PortletManagementPortType</param-value>
+ </init-param>
+ </servlet>
+
+ <!-- WSRP 1 endpoint mappings -->
+ <servlet-mapping>
+ <servlet-name>V1ServiceDescriptionService</servlet-name>
+ <url-pattern>/v1/ServiceDescriptionService</url-pattern>
+ </servlet-mapping>
+ <servlet-mapping>
+ <servlet-name>V1MarkupService</servlet-name>
+ <url-pattern>/v1/MarkupService</url-pattern>
+ </servlet-mapping>
+ <servlet-mapping>
+ <servlet-name>V1RegistrationService</servlet-name>
+ <url-pattern>/v1/RegistrationService</url-pattern>
+ </servlet-mapping>
+ <servlet-mapping>
+ <servlet-name>V1PortletManagementService</servlet-name>
+ <url-pattern>/v1/PortletManagementService</url-pattern>
+ </servlet-mapping>
+
</web-app>
Added: components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/wsdl/wsrp-2.0-bindings.wsdl
===================================================================
--- components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/wsdl/wsrp-2.0-bindings.wsdl (rev 0)
+++ components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/wsdl/wsrp-2.0-bindings.wsdl 2010-05-28 09:29:22 UTC (rev 3213)
@@ -0,0 +1,959 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ JBoss, a division of Red Hat
+ ~ Copyright 2010, Red Hat Middleware, LLC, and individual
+ ~ contributors as indicated by the @authors tag. See the
+ ~ copyright.txt in the distribution for a full listing of
+ ~ individual contributors.
+ ~
+ ~ 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.
+ -->
+
+<wsdl:definitions targetNamespace="urn:oasis:names:tc:wsrp:v2:bind"
+ xmlns:bind="urn:oasis:names:tc:wsrp:v2:bind"
+ xmlns:intf="urn:oasis:names:tc:wsrp:v2:intf"
+
+ xmlns="http://schemas.xmlsoap.org/wsdl/"
+
+ xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
+ xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
+
+ <!-- This file reflects v2.0 of the specification -->
+
+ <import namespace="urn:oasis:names:tc:wsrp:v2:intf" location="wsrp-2.0-interfaces.wsdl"/>
+
+ <wsdl:binding name="WSRP_v2_Markup_Binding_SOAP" type="intf:WSRP_v2_Markup_PortType">
+ <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
+
+ <wsdl:operation name="getMarkup">
+ <soap:operation soapAction="urn:oasis:names:tc:wsrp:v2:getMarkup"/>
+ <wsdl:input name="getMarkup">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="getMarkupResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="AccessDenied">
+ <soap:fault name="AccessDenied" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InconsistentParameters">
+ <soap:fault name="InconsistentParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidCookie">
+ <soap:fault name="InvalidCookie" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidHandle">
+ <soap:fault name="InvalidHandle" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidRegistration">
+ <soap:fault name="InvalidRegistration" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidSession">
+ <soap:fault name="InvalidSession" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidUserCategory">
+ <soap:fault name="InvalidUserCategory" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="MissingParameters">
+ <soap:fault name="MissingParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ModifyRegistrationRequired">
+ <soap:fault name="ModifyRegistrationRequired" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationFailed">
+ <soap:fault name="OperationFailed" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ResourceSuspended">
+ <soap:fault name="ResourceSuspended" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="UnsupportedLocale">
+ <soap:fault name="UnsupportedLocale" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="UnsupportedMimeType">
+ <soap:fault name="UnsupportedMimeType" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="UnsupportedMode">
+ <soap:fault name="UnsupportedMode" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="UnsupportedWindowState">
+ <soap:fault name="UnsupportedWindowState" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+
+ <wsdl:operation name="getResource">
+ <soap:operation soapAction="urn:oasis:names:tc:wsrp:v2:getResource"/>
+ <wsdl:input name="getResource">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="getResourceResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="AccessDenied">
+ <soap:fault name="AccessDenied" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InconsistentParameters">
+ <soap:fault name="InconsistentParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidCookie">
+ <soap:fault name="InvalidCookie" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidHandle">
+ <soap:fault name="InvalidHandle" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidRegistration">
+ <soap:fault name="InvalidRegistration" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidSession">
+ <soap:fault name="InvalidSession" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidUserCategory">
+ <soap:fault name="InvalidUserCategory" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="MissingParameters">
+ <soap:fault name="MissingParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ModifyRegistrationRequired">
+ <soap:fault name="ModifyRegistrationRequired" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationFailed">
+ <soap:fault name="OperationFailed" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationNotSupported">
+ <soap:fault name="OperationNotSupported" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ResourceSuspended">
+ <soap:fault name="ResourceSuspended" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="UnsupportedLocale">
+ <soap:fault name="UnsupportedLocale" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="UnsupportedMimeType">
+ <soap:fault name="UnsupportedMimeType" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="UnsupportedMode">
+ <soap:fault name="UnsupportedMode" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="UnsupportedWindowState">
+ <soap:fault name="UnsupportedWindowState" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+
+ <wsdl:operation name="performBlockingInteraction">
+ <soap:operation soapAction="urn:oasis:names:tc:wsrp:v2:performBlockingInteraction"/>
+ <wsdl:input name="performBlockingInteraction">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="performBlockingInteractionResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="AccessDenied">
+ <soap:fault name="AccessDenied" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InconsistentParameters">
+ <soap:fault name="InconsistentParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidCookie">
+ <soap:fault name="InvalidCookie" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidHandle">
+ <soap:fault name="InvalidHandle" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidRegistration">
+ <soap:fault name="InvalidRegistration" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidSession">
+ <soap:fault name="InvalidSession" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidUserCategory">
+ <soap:fault name="InvalidUserCategory" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="MissingParameters">
+ <soap:fault name="MissingParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ModifyRegistrationRequired">
+ <soap:fault name="ModifyRegistrationRequired" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationFailed">
+ <soap:fault name="OperationFailed" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="PortletStateChangeRequired">
+ <soap:fault name="PortletStateChangeRequired" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ResourceSuspended">
+ <soap:fault name="ResourceSuspended" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="UnsupportedLocale">
+ <soap:fault name="UnsupportedLocale" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="UnsupportedMimeType">
+ <soap:fault name="UnsupportedMimeType" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="UnsupportedMode">
+ <soap:fault name="UnsupportedMode" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="UnsupportedWindowState">
+ <soap:fault name="UnsupportedWindowState" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+
+ <wsdl:operation name="handleEvents">
+ <soap:operation soapAction="urn:oasis:names:tc:wsrp:v2:handleEvents"/>
+ <wsdl:input name="handleEvents">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="handleEventsResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="AccessDenied">
+ <soap:fault name="AccessDenied" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InconsistentParameters">
+ <soap:fault name="InconsistentParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidCookie">
+ <soap:fault name="InvalidCookie" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidHandle">
+ <soap:fault name="InvalidHandle" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidRegistration">
+ <soap:fault name="InvalidRegistration" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidSession">
+ <soap:fault name="InvalidSession" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidUserCategory">
+ <soap:fault name="InvalidUserCategory" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="MissingParameters">
+ <soap:fault name="MissingParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ModifyRegistrationRequired">
+ <soap:fault name="ModifyRegistrationRequired" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationFailed">
+ <soap:fault name="OperationFailed" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationNotSupported">
+ <soap:fault name="OperationNotSupported" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="PortletStateChangeRequired">
+ <soap:fault name="PortletStateChangeRequired" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ResourceSuspended">
+ <soap:fault name="ResourceSuspended" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="UnsupportedLocale">
+ <soap:fault name="UnsupportedLocale" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="UnsupportedMimeType">
+ <soap:fault name="UnsupportedMimeType" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="UnsupportedMode">
+ <soap:fault name="UnsupportedMode" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="UnsupportedWindowState">
+ <soap:fault name="UnsupportedWindowState" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+
+ <wsdl:operation name="releaseSessions">
+ <soap:operation soapAction="urn:oasis:names:tc:wsrp:v2:releaseSessions"/>
+ <wsdl:input name="releaseSessions">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="releaseSessionsResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="AccessDenied">
+ <soap:fault name="AccessDenied" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidRegistration">
+ <soap:fault name="InvalidRegistration" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="MissingParameters">
+ <soap:fault name="MissingParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ModifyRegistrationRequired">
+ <soap:fault name="ModifyRegistrationRequired" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationFailed">
+ <soap:fault name="OperationFailed" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationNotSupported">
+ <soap:fault name="OperationNotSupported" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ResourceSuspended">
+ <soap:fault name="ResourceSuspended" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+
+ <wsdl:operation name="initCookie">
+ <soap:operation soapAction="urn:oasis:names:tc:wsrp:v2:initCookie"/>
+ <wsdl:input name="initCookie">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="initCookieResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="AccessDenied">
+ <soap:fault name="AccessDenied" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidRegistration">
+ <soap:fault name="InvalidRegistration" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ModifyRegistrationRequired">
+ <soap:fault name="ModifyRegistrationRequired" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationFailed">
+ <soap:fault name="OperationFailed" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationNotSupported">
+ <soap:fault name="OperationNotSupported" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ResourceSuspended">
+ <soap:fault name="ResourceSuspended" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+ </wsdl:binding>
+
+
+ <wsdl:binding name="WSRP_v2_ServiceDescription_Binding_SOAP" type="intf:WSRP_v2_ServiceDescription_PortType">
+ <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
+
+ <wsdl:operation name="getServiceDescription">
+ <soap:operation soapAction="urn:oasis:names:tc:wsrp:v2:getServiceDescription"/>
+ <wsdl:input name="getServiceDescription">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="getServiceDescriptionResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="InvalidRegistration">
+ <soap:fault name="InvalidRegistration" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ModifyRegistrationRequired">
+ <soap:fault name="ModifyRegistrationRequired" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationFailed">
+ <soap:fault name="OperationFailed" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ResourceSuspended">
+ <soap:fault name="ResourceSuspended" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+ </wsdl:binding>
+
+ <wsdl:binding name="WSRP_v2_PortletManagement_Binding_SOAP" type="intf:WSRP_v2_PortletManagement_PortType">
+ <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
+
+ <wsdl:operation name="getPortletDescription">
+ <soap:operation soapAction="urn:oasis:names:tc:wsrp:v2:getPortletDescription"/>
+ <wsdl:input name="getPortletDescription">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="getPortletDescriptionResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="AccessDenied">
+ <soap:fault name="AccessDenied" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InconsistentParameters">
+ <soap:fault name="InconsistentParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidHandle">
+ <soap:fault name="InvalidHandle" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidRegistration">
+ <soap:fault name="InvalidRegistration" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidUserCategory">
+ <soap:fault name="InvalidUserCategory" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="MissingParameters">
+ <soap:fault name="MissingParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ModifyRegistrationRequired">
+ <soap:fault name="ModifyRegistrationRequired" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationFailed">
+ <soap:fault name="OperationFailed" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationNotSupported">
+ <soap:fault name="OperationNotSupported" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ResourceSuspended">
+ <soap:fault name="ResourceSuspended" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+
+ <wsdl:operation name="clonePortlet">
+ <soap:operation soapAction="urn:oasis:names:tc:wsrp:v2:clonePortlet"/>
+ <wsdl:input name="clonePortlet">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="clonePortletResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="AccessDenied">
+ <soap:fault name="AccessDenied" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InconsistentParameters">
+ <soap:fault name="InconsistentParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidHandle">
+ <soap:fault name="InvalidHandle" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidRegistration">
+ <soap:fault name="InvalidRegistration" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidUserCategory">
+ <soap:fault name="InvalidUserCategory" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="MissingParameters">
+ <soap:fault name="MissingParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ModifyRegistrationRequired">
+ <soap:fault name="ModifyRegistrationRequired" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationFailed">
+ <soap:fault name="OperationFailed" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationNotSupported">
+ <soap:fault name="OperationNotSupported" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ResourceSuspended">
+ <soap:fault name="ResourceSuspended" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+
+ <wsdl:operation name="destroyPortlets">
+ <soap:operation soapAction="urn:oasis:names:tc:wsrp:v2:destroyPortlets"/>
+ <wsdl:input name="destroyPortlets">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="destroyPortletsResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="InconsistentParameters">
+ <soap:fault name="InconsistentParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidRegistration">
+ <soap:fault name="InvalidRegistration" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="MissingParameters">
+ <soap:fault name="MissingParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ModifyRegistrationRequired">
+ <soap:fault name="ModifyRegistrationRequired" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationFailed">
+ <soap:fault name="OperationFailed" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationNotSupported">
+ <soap:fault name="OperationNotSupported" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ResourceSuspended">
+ <soap:fault name="ResourceSuspended" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+
+ <wsdl:operation name="getPortletsLifetime">
+ <soap:operation soapAction="urn:oasis:names:tc:wsrp:v2:getPortletsLifetime"/>
+ <wsdl:input name="getPortletsLifetime">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="getPortletsLifetimeResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="AccessDenied">
+ <soap:fault name="AccessDenied" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InconsistentParameters">
+ <soap:fault name="InconsistentParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidHandle">
+ <soap:fault name="InvalidHandle" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidRegistration">
+ <soap:fault name="InvalidRegistration" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ModifyRegistrationRequired">
+ <soap:fault name="ModifyRegistrationRequired" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationFailed">
+ <soap:fault name="OperationFailed" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationNotSupported">
+ <soap:fault name="OperationNotSupported" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ResourceSuspended">
+ <soap:fault name="ResourceSuspended" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+
+ <wsdl:operation name="setPortletsLifetime">
+ <soap:operation soapAction="urn:oasis:names:tc:wsrp:v2:setPortletsLifetime"/>
+ <wsdl:input name="setPortletsLifetime">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="setPortletsLifetimeResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="AccessDenied">
+ <soap:fault name="AccessDenied" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InconsistentParameters">
+ <soap:fault name="InconsistentParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidHandle">
+ <soap:fault name="InvalidHandle" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidRegistration">
+ <soap:fault name="InvalidRegistration" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ModifyRegistrationRequired">
+ <soap:fault name="ModifyRegistrationRequired" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationFailed">
+ <soap:fault name="OperationFailed" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationNotSupported">
+ <soap:fault name="OperationNotSupported" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ResourceSuspended">
+ <soap:fault name="ResourceSuspended" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+
+ <wsdl:operation name="copyPortlets">
+ <soap:operation soapAction="urn:oasis:names:tc:wsrp:v2:copyPortlets"/>
+ <wsdl:input name="copyPortlets">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="copyPortletsResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="AccessDenied">
+ <soap:fault name="AccessDenied" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InconsistentParameters">
+ <soap:fault name="InconsistentParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidHandle">
+ <soap:fault name="InvalidHandle" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidRegistration">
+ <soap:fault name="InvalidRegistration" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidUserCategory">
+ <soap:fault name="InvalidUserCategory" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="MissingParameters">
+ <soap:fault name="MissingParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ModifyRegistrationRequired">
+ <soap:fault name="ModifyRegistrationRequired" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationFailed">
+ <soap:fault name="OperationFailed" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationNotSupported">
+ <soap:fault name="OperationNotSupported" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ResourceSuspended">
+ <soap:fault name="ResourceSuspended" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+
+ <wsdl:operation name="exportPortlets">
+ <soap:operation soapAction="urn:oasis:names:tc:wsrp:v2:exportPortlet"/>
+ <wsdl:input name="exportPortlets">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="exportPortletsResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="AccessDenied">
+ <soap:fault name="AccessDenied" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InconsistentParameters">
+ <soap:fault name="InconsistentParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidHandle">
+ <soap:fault name="InvalidHandle" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidRegistration">
+ <soap:fault name="InvalidRegistration" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidUserCategory">
+ <soap:fault name="InvalidUserCategory" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="MissingParameters">
+ <soap:fault name="MissingParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ModifyRegistrationRequired">
+ <soap:fault name="ModifyRegistrationRequired" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationFailed">
+ <soap:fault name="OperationFailed" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationNotSupported">
+ <soap:fault name="OperationNotSupported" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ResourceSuspended">
+ <soap:fault name="ResourceSuspended" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ExportByValueNotSupported">
+ <soap:fault name="ExportByValueNotSupported" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+
+ <wsdl:operation name="importPortlets">
+ <soap:operation soapAction="urn:oasis:names:tc:wsrp:v2:importPortlet"/>
+ <wsdl:input name="importPortlets">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="importPortletsResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="AccessDenied">
+ <soap:fault name="AccessDenied" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InconsistentParameters">
+ <soap:fault name="InconsistentParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidRegistration">
+ <soap:fault name="InvalidRegistration" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidUserCategory">
+ <soap:fault name="InvalidUserCategory" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="MissingParameters">
+ <soap:fault name="MissingParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ModifyRegistrationRequired">
+ <soap:fault name="ModifyRegistrationRequired" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationFailed">
+ <soap:fault name="OperationFailed" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationNotSupported">
+ <soap:fault name="OperationNotSupported" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ResourceSuspended">
+ <soap:fault name="ResourceSuspended" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ExportNoLongerValid">
+ <soap:fault name="ExportNoLongerValid" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+
+ <wsdl:operation name="releaseExport">
+ <soap:operation soapAction="urn:oasis:names:tc:wsrp:v2:importPortlet"/>
+ <wsdl:input name="releaseExport">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="releaseExportResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ </wsdl:operation>
+
+ <wsdl:operation name="setExportLifetime">
+ <soap:operation soapAction="urn:oasis:names:tc:wsrp:v2:setExportLifetime"/>
+ <wsdl:input name="setExportLifetime">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="setExportLifetimeResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="AccessDenied">
+ <soap:fault name="AccessDenied" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidHandle">
+ <soap:fault name="InvalidHandle" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidRegistration">
+ <soap:fault name="InvalidRegistration" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ModifyRegistrationRequired">
+ <soap:fault name="ModifyRegistrationRequired" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationFailed">
+ <soap:fault name="OperationFailed" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationNotSupported">
+ <soap:fault name="OperationNotSupported" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ResourceSuspended">
+ <soap:fault name="ResourceSuspended" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+
+ <wsdl:operation name="setPortletProperties">
+ <soap:operation soapAction="urn:oasis:names:tc:wsrp:v2:setPortletProperties"/>
+ <wsdl:input name="setPortletProperties">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="setPortletPropertiesResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="AccessDenied">
+ <soap:fault name="AccessDenied" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InconsistentParameters">
+ <soap:fault name="InconsistentParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidHandle">
+ <soap:fault name="InvalidHandle" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidRegistration">
+ <soap:fault name="InvalidRegistration" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidUserCategory">
+ <soap:fault name="InvalidUserCategory" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="MissingParameters">
+ <soap:fault name="MissingParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ModifyRegistrationRequired">
+ <soap:fault name="ModifyRegistrationRequired" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationFailed">
+ <soap:fault name="OperationFailed" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationNotSupported">
+ <soap:fault name="OperationNotSupported" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ResourceSuspended">
+ <soap:fault name="ResourceSuspended" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+
+ <wsdl:operation name="getPortletProperties">
+ <soap:operation soapAction="urn:oasis:names:tc:wsrp:v2:getPortletProperties"/>
+ <wsdl:input name="getPortletProperties">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="getPortletPropertiesResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="AccessDenied">
+ <soap:fault name="AccessDenied" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InconsistentParameters">
+ <soap:fault name="InconsistentParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidHandle">
+ <soap:fault name="InvalidHandle" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidRegistration">
+ <soap:fault name="InvalidRegistration" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidUserCategory">
+ <soap:fault name="InvalidUserCategory" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="MissingParameters">
+ <soap:fault name="MissingParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ModifyRegistrationRequired">
+ <soap:fault name="ModifyRegistrationRequired" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationFailed">
+ <soap:fault name="OperationFailed" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationNotSupported">
+ <soap:fault name="OperationNotSupported" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ResourceSuspended">
+ <soap:fault name="ResourceSuspended" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+
+ <wsdl:operation name="getPortletPropertyDescription">
+ <soap:operation soapAction="urn:oasis:names:tc:wsrp:v2:getPortletPropertyDescription"/>
+ <wsdl:input name="getPortletPropertyDescription">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="getPortletPropertyDescriptionResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="AccessDenied">
+ <soap:fault name="AccessDenied" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InconsistentParameters">
+ <soap:fault name="InconsistentParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidHandle">
+ <soap:fault name="InvalidHandle" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidRegistration">
+ <soap:fault name="InvalidRegistration" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidUserCategory">
+ <soap:fault name="InvalidUserCategory" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="MissingParameters">
+ <soap:fault name="MissingParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ModifyRegistrationRequired">
+ <soap:fault name="ModifyRegistrationRequired" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationFailed">
+ <soap:fault name="OperationFailed" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationNotSupported">
+ <soap:fault name="OperationNotSupported" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ResourceSuspended">
+ <soap:fault name="ResourceSuspended" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+ </wsdl:binding>
+
+ <wsdl:binding name="WSRP_v2_Registration_Binding_SOAP" type="intf:WSRP_v2_Registration_PortType">
+ <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
+
+ <wsdl:operation name="register">
+ <soap:operation soapAction="urn:oasis:names:tc:wsrp:v2:register"/>
+ <wsdl:input name="register">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="registerResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="MissingParameters">
+ <soap:fault name="MissingParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationFailed">
+ <soap:fault name="OperationFailed" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationNotSupported">
+ <soap:fault name="OperationNotSupported" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+
+ <wsdl:operation name="deregister">
+ <soap:operation soapAction="urn:oasis:names:tc:wsrp:v2:deregister"/>
+ <wsdl:input name="deregister">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="deregisterResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="InvalidRegistration">
+ <soap:fault name="InvalidRegistration" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationFailed">
+ <soap:fault name="OperationFailed" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationNotSupported">
+ <soap:fault name="OperationNotSupported" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ResourceSuspended">
+ <soap:fault name="ResourceSuspended" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+
+ <wsdl:operation name="modifyRegistration">
+ <soap:operation soapAction="urn:oasis:names:tc:wsrp:v2:modifyRegistration"/>
+ <wsdl:input name="modifyRegistration">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="modifyRegistrationResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="InvalidRegistration">
+ <soap:fault name="InvalidRegistration" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="MissingParameters">
+ <soap:fault name="MissingParameters" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationFailed">
+ <soap:fault name="OperationFailed" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationNotSupported">
+ <soap:fault name="OperationNotSupported" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ResourceSuspended">
+ <soap:fault name="ResourceSuspended" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+
+ <wsdl:operation name="getRegistrationLifetime">
+ <soap:operation soapAction="urn:oasis:names:tc:wsrp:v2:getRegistrationLifetime"/>
+ <wsdl:input name="getRegistrationLifetime">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="getRegistrationLifetimeResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="AccessDenied">
+ <soap:fault name="AccessDenied" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidHandle">
+ <soap:fault name="InvalidHandle" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidRegistration">
+ <soap:fault name="InvalidRegistration" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ModifyRegistrationRequired">
+ <soap:fault name="ModifyRegistrationRequired" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationFailed">
+ <soap:fault name="OperationFailed" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationNotSupported">
+ <soap:fault name="OperationNotSupported" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ResourceSuspended">
+ <soap:fault name="ResourceSuspended" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+
+ <wsdl:operation name="setRegistrationLifetime">
+ <soap:operation soapAction="urn:oasis:names:tc:wsrp:v2:setRegistrationLifetime"/>
+ <wsdl:input name="setRegistrationLifetime">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="setRegistrationLifetimeResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="AccessDenied">
+ <soap:fault name="AccessDenied" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidHandle">
+ <soap:fault name="InvalidHandle" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="InvalidRegistration">
+ <soap:fault name="InvalidRegistration" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ModifyRegistrationRequired">
+ <soap:fault name="ModifyRegistrationRequired" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationFailed">
+ <soap:fault name="OperationFailed" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="OperationNotSupported">
+ <soap:fault name="OperationNotSupported" use="literal"/>
+ </wsdl:fault>
+ <wsdl:fault name="ResourceSuspended">
+ <soap:fault name="ResourceSuspended" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+ </wsdl:binding>
+
+</wsdl:definitions>
Added: components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/wsdl/wsrp-2.0-extra.xsd
===================================================================
--- components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/wsdl/wsrp-2.0-extra.xsd (rev 0)
+++ components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/wsdl/wsrp-2.0-extra.xsd 2010-05-28 09:29:22 UTC (rev 3213)
@@ -0,0 +1,97 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ JBoss, a division of Red Hat
+ ~ Copyright 2010, Red Hat Middleware, LLC, and individual
+ ~ contributors as indicated by the @authors tag. See the
+ ~ copyright.txt in the distribution for a full listing of
+ ~ individual contributors.
+ ~
+ ~ 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.
+ -->
+
+<schema targetNamespace="urn:oasis:names:tc:wsrp:extra"
+ xmlns:wsrp-extra="urn:oasis:names:tc:wsrp:extra"
+ xmlns:wsrpv2="urn:oasis:names:tc:wsrp:v2:types"
+
+ xmlns="http://www.w3.org/2001/XMLSchema"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+
+ elementFormDefault="qualified">
+
+
+ <import namespace="urn:oasis:names:tc:wsrp:v2:types" schemaLocation="wsrp-2.0-types.xsd"/>
+
+ <!-- Type definitions in a non-WSRP types namespace for use as extension elements -->
+
+ <complexType name="QNamedString">
+ <attribute name="qname" type="xsd:QName" use="required"/>
+ <attribute name="value" type="xsd:string" use="optional"/>
+ <!-- Axis v1.1 ignores the following declaration! -->
+ <anyAttribute/>
+ </complexType>
+ <element name="QNamedString" type="wsrp-extra:QNamedString"/>
+
+ <complexType name="QNamedStringArray">
+ <sequence>
+ <element name="QNamedString" type="wsrp-extra:QNamedString" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <anyAttribute/>
+ </complexType>
+ <element name="QNamedStringArray" type="wsrp-extra:QNamedStringArray"/>
+
+ <complexType name="QNamedMultiValue">
+ <sequence>
+ <element name="value" type="xsd:string" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="qname" type="xsd:QName" use="required"/>
+ <!-- Axis v1.1 ignores the following declaration! -->
+ <anyAttribute/>
+ </complexType>
+ <element name="QNamedMultiValue" type="wsrp-extra:QNamedMultiValue"/>
+
+ <complexType name="QNamedMultiValueArray">
+ <sequence>
+ <element name="QNamedMultiValue" type="wsrp-extra:QNamedMultiValue" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <anyAttribute/>
+ </complexType>
+ <element name="QNamedMultiValueArray" type="wsrp-extra:QNamedMultiValueArray"/>
+
+ <complexType name="NamedMultiValue">
+ <sequence>
+ <element name="value" type="xsd:string" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="name" type="xsd:string" use="required"/>
+ </complexType>
+ <element name="NamedMultiValue" type="wsrp-extra:NamedMultiValue"/>
+
+ <complexType name="NamedMultiValueArray">
+ <sequence>
+ <element name="NamedMultiValue" type="wsrp-extra:NamedMultiValue" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <anyAttribute/>
+ </complexType>
+ <element name="NamedMultiValueArray" type="wsrp-extra:NamedMultiValueArray"/>
+
+ <!-- Well known extensions -->
+ <element name="doctype" type="wsrp-extra:QNamedString"/>
+
+ <element name="extendedURLParameters" type="wsrpv2:NamedStringArray"/>
+
+ <element name="sharedResource" type="xsd:string"/>
+ <!-- preferrably QName -->
+
+</schema>
Added: components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/wsdl/wsrp-2.0-interfaces.wsdl
===================================================================
--- components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/wsdl/wsrp-2.0-interfaces.wsdl (rev 0)
+++ components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/wsdl/wsrp-2.0-interfaces.wsdl 2010-05-28 09:29:22 UTC (rev 3213)
@@ -0,0 +1,662 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ JBoss, a division of Red Hat
+ ~ Copyright 2010, Red Hat Middleware, LLC, and individual
+ ~ contributors as indicated by the @authors tag. See the
+ ~ copyright.txt in the distribution for a full listing of
+ ~ individual contributors.
+ ~
+ ~ 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.
+ -->
+
+<wsdl:definitions targetNamespace="urn:oasis:names:tc:wsrp:v2:intf"
+ xmlns:types="urn:oasis:names:tc:wsrp:v2:types"
+ xmlns:intf="urn:oasis:names:tc:wsrp:v2:intf"
+
+ xmlns="http://schemas.xmlsoap.org/wsdl/"
+
+ xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ >
+
+ <!-- This file reflects v2.0 of the specification -->
+
+ <wsdl:types>
+ <schema targetNamespace="urn:oasis:names:tc:wsrp:v2:intf"
+ xmlns="http://www.w3.org/2001/XMLSchema"
+ elementFormDefault="qualified">
+
+ <import namespace="urn:oasis:names:tc:wsrp:v2:types" schemaLocation="wsrp-2.0-types.xsd"/>
+
+ </schema>
+ </wsdl:types>
+
+
+ <!-- - - - - - - - - -->
+ <!-- fault messages -->
+ <!-- - - - - - - - - -->
+
+ <wsdl:message name="AccessDenied">
+ <wsdl:part name="fault" element="types:AccessDenied"/>
+ </wsdl:message>
+
+ <wsdl:message name="InconsistentParameters">
+ <wsdl:part name="fault" element="types:InconsistentParameters"/>
+ </wsdl:message>
+
+ <wsdl:message name="InvalidCookie">
+ <wsdl:part name="fault" element="types:InvalidCookie"/>
+ </wsdl:message>
+
+ <wsdl:message name="InvalidHandle">
+ <wsdl:part name="fault" element="types:InvalidHandle"/>
+ </wsdl:message>
+
+ <wsdl:message name="InvalidRegistration">
+ <wsdl:part name="fault" element="types:InvalidRegistration"/>
+ </wsdl:message>
+
+ <wsdl:message name="InvalidSession">
+ <wsdl:part name="fault" element="types:InvalidSession"/>
+ </wsdl:message>
+
+ <wsdl:message name="InvalidUserCategory">
+ <wsdl:part name="fault" element="types:InvalidUserCategory"/>
+ </wsdl:message>
+
+ <wsdl:message name="ModifyRegistrationRequired">
+ <wsdl:part name="fault" element="types:ModifyRegistrationRequired"/>
+ </wsdl:message>
+
+ <wsdl:message name="MissingParameters">
+ <wsdl:part name="fault" element="types:MissingParameters"/>
+ </wsdl:message>
+
+ <wsdl:message name="OperationFailed">
+ <wsdl:part name="fault" element="types:OperationFailed"/>
+ </wsdl:message>
+
+ <wsdl:message name="OperationNotSupported">
+ <wsdl:part name="fault" element="types:OperationNotSupported"/>
+ </wsdl:message>
+
+ <wsdl:message name="PortletStateChangeRequired">
+ <wsdl:part name="fault" element="types:PortletStateChangeRequired"/>
+ </wsdl:message>
+
+ <wsdl:message name="ResourceSuspended">
+ <wsdl:part name="fault" element="types:ResourceSuspended"/>
+ </wsdl:message>
+
+ <wsdl:message name="UnsupportedMode">
+ <wsdl:part name="fault" element="types:UnsupportedMode"/>
+ </wsdl:message>
+
+ <wsdl:message name="UnsupportedLocale">
+ <wsdl:part name="fault" element="types:UnsupportedLocale"/>
+ </wsdl:message>
+
+ <wsdl:message name="UnsupportedMimeType">
+ <wsdl:part name="fault" element="types:UnsupportedMimeType"/>
+ </wsdl:message>
+
+ <wsdl:message name="UnsupportedWindowState">
+ <wsdl:part name="fault" element="types:UnsupportedWindowState"/>
+ </wsdl:message>
+
+ <wsdl:message name="ExportByValueNotSupported">
+ <wsdl:part name="fault" element="types:ExportByValueNotSupported"/>
+ </wsdl:message>
+
+ <wsdl:message name="ExportNoLongerValid">
+ <wsdl:part name="fault" element="types:ExportNoLongerValid"/>
+ </wsdl:message>
+
+
+ <!-- - - - - - - - - - - -->
+ <!-- Operations messages -->
+ <!-- - - - - - - - - - - -->
+
+ <wsdl:message name="getMarkup">
+ <wsdl:part name="getMarkup" element="types:getMarkup"/>
+ </wsdl:message>
+ <wsdl:message name="getMarkupResponse">
+ <wsdl:part name="getMarkupResponse" element="types:getMarkupResponse"/>
+ </wsdl:message>
+
+ <wsdl:message name="getResource">
+ <wsdl:part name="getResource" element="types:getResource"/>
+ </wsdl:message>
+ <wsdl:message name="getResourceResponse">
+ <wsdl:part name="getResourceResponse" element="types:getResourceResponse"/>
+ </wsdl:message>
+
+ <wsdl:message name="performBlockingInteraction">
+ <wsdl:part name="performBlockingInteraction" element="types:performBlockingInteraction"/>
+ </wsdl:message>
+ <wsdl:message name="performBlockingInteractionResponse">
+ <wsdl:part name="performBlockingInteractionResponse" element="types:performBlockingInteractionResponse"/>
+ </wsdl:message>
+
+ <wsdl:message name="handleEvents">
+ <wsdl:part name="handleEvents" element="types:handleEvents"/>
+ </wsdl:message>
+ <wsdl:message name="handleEventsResponse">
+ <wsdl:part name="handleEventsResponse" element="types:handleEventsResponse"/>
+ </wsdl:message>
+
+ <wsdl:message name="getServiceDescription">
+ <wsdl:part name="getServiceDescription" element="types:getServiceDescription"/>
+ </wsdl:message>
+ <wsdl:message name="getServiceDescriptionResponse">
+ <wsdl:part name="getServiceDescriptionResponse" element="types:getServiceDescriptionResponse"/>
+ </wsdl:message>
+
+ <wsdl:message name="register">
+ <wsdl:part name="register" element="types:register"/>
+ </wsdl:message>
+ <wsdl:message name="registerResponse">
+ <wsdl:part name="registerResponse" element="types:registerResponse"/>
+ </wsdl:message>
+
+ <wsdl:message name="deregister">
+ <wsdl:part name="deregister" element="types:deregister"/>
+ </wsdl:message>
+ <wsdl:message name="deregisterResponse">
+ <wsdl:part name="deregisterResponse" element="types:deregisterResponse"/>
+ </wsdl:message>
+
+ <wsdl:message name="modifyRegistration">
+ <wsdl:part name="modifyRegistration" element="types:modifyRegistration"/>
+ </wsdl:message>
+ <wsdl:message name="modifyRegistrationResponse">
+ <wsdl:part name="modifyRegistrationResponse" element="types:modifyRegistrationResponse"/>
+ </wsdl:message>
+
+ <wsdl:message name="getPortletDescription">
+ <wsdl:part name="getPortletDescription" element="types:getPortletDescription"/>
+ </wsdl:message>
+ <wsdl:message name="getPortletDescriptionResponse">
+ <wsdl:part name="getPortletDescriptionResponse" element="types:getPortletDescriptionResponse"/>
+ </wsdl:message>
+
+ <wsdl:message name="clonePortlet">
+ <wsdl:part name="clonePortlet" element="types:clonePortlet"/>
+ </wsdl:message>
+ <wsdl:message name="clonePortletResponse">
+ <wsdl:part name="clonePortletResponse" element="types:clonePortletResponse"/>
+ </wsdl:message>
+
+ <wsdl:message name="destroyPortlets">
+ <wsdl:part name="destroyPortlets" element="types:destroyPortlets"/>
+ </wsdl:message>
+ <wsdl:message name="destroyPortletsResponse">
+ <wsdl:part name="destroyPortletsResponse" element="types:destroyPortletsResponse"/>
+ </wsdl:message>
+
+ <wsdl:message name="setPortletProperties">
+ <wsdl:part name="setPortletProperties" element="types:setPortletProperties"/>
+ </wsdl:message>
+ <wsdl:message name="setPortletPropertiesResponse">
+ <wsdl:part name="setPortletPropertiesResponse" element="types:setPortletPropertiesResponse"/>
+ </wsdl:message>
+
+ <wsdl:message name="getPortletProperties">
+ <wsdl:part name="getPortletProperties" element="types:getPortletProperties"/>
+ </wsdl:message>
+ <wsdl:message name="getPortletPropertiesResponse">
+ <wsdl:part name="getPortletPropertiesResponse" element="types:getPortletPropertiesResponse"/>
+ </wsdl:message>
+
+ <wsdl:message name="getPortletPropertyDescription">
+ <wsdl:part name="getPortletPropertyDescription" element="types:getPortletPropertyDescription"/>
+ </wsdl:message>
+ <wsdl:message name="getPortletPropertyDescriptionResponse">
+ <wsdl:part name="getPortletPropertyDescriptionResponse" element="types:getPortletPropertyDescriptionResponse"/>
+ </wsdl:message>
+
+ <wsdl:message name="releaseSessions">
+ <wsdl:part name="releaseSessions" element="types:releaseSessions"/>
+ </wsdl:message>
+ <wsdl:message name="releaseSessionsResponse">
+ <wsdl:part name="releaseSessionsResponse" element="types:releaseSessionsResponse"/>
+ </wsdl:message>
+
+ <wsdl:message name="initCookie">
+ <wsdl:part name="initCookie" element="types:initCookie"/>
+ </wsdl:message>
+ <wsdl:message name="initCookieResponse">
+ <wsdl:part name="initCookieResponse" element="types:initCookieResponse"/>
+ </wsdl:message>
+
+ <wsdl:message name="copyPortlets">
+ <wsdl:part name="copyPortlets" element="types:copyPortlets"/>
+ </wsdl:message>
+ <wsdl:message name="copyPortletsResponse">
+ <wsdl:part name="copyPortletsResponse" element="types:copyPortletsResponse"/>
+ </wsdl:message>
+
+ <wsdl:message name="exportPortlets">
+ <wsdl:part name="exportPortlets" element="types:exportPortlets"/>
+ </wsdl:message>
+ <wsdl:message name="exportPortletsResponse">
+ <wsdl:part name="exportPortletsResponse" element="types:exportPortletsResponse"/>
+ </wsdl:message>
+
+ <wsdl:message name="importPortlets">
+ <wsdl:part name="importPortlets" element="types:importPortlets"/>
+ </wsdl:message>
+ <wsdl:message name="importPortletsResponse">
+ <wsdl:part name="importPortletsResponse" element="types:importPortletsResponse"/>
+ </wsdl:message>
+
+ <wsdl:message name="releaseExport">
+ <wsdl:part name="releaseExport" element="types:releaseExport"/>
+ </wsdl:message>
+ <wsdl:message name="releaseExportResponse">
+ <wsdl:part name="releaseExportResponse" element="types:releaseExportResponse"/>
+ </wsdl:message>
+
+ <wsdl:message name="setExportLifetime">
+ <wsdl:part name="setExportLifetime" element="types:setExportLifetime"/>
+ </wsdl:message>
+ <wsdl:message name="setExportLifetimeResponse">
+ <wsdl:part name="setExportLifetimeResponse" element="types:setExportLifetimeResponse"/>
+ </wsdl:message>
+
+ <wsdl:message name="getRegistrationLifetime">
+ <wsdl:part name="getRegistrationLifetime" element="types:getRegistrationLifetime"/>
+ </wsdl:message>
+ <wsdl:message name="getRegistrationLifetimeResponse">
+ <wsdl:part name="getRegistrationLifetimeResponse" element="types:getRegistrationLifetimeResponse"/>
+ </wsdl:message>
+
+ <wsdl:message name="setRegistrationLifetime">
+ <wsdl:part name="setRegistrationLifetime" element="types:setRegistrationLifetime"/>
+ </wsdl:message>
+ <wsdl:message name="setRegistrationLifetimeResponse">
+ <wsdl:part name="setRegistrationLifetimeResponse" element="types:setRegistrationLifetimeResponse"/>
+ </wsdl:message>
+
+ <wsdl:message name="getPortletsLifetime">
+ <wsdl:part name="getPortletsLifetime" element="types:getPortletsLifetime"/>
+ </wsdl:message>
+ <wsdl:message name="getPortletsLifetimeResponse">
+ <wsdl:part name="getPortletsLifetimeResponse" element="types:getPortletsLifetimeResponse"/>
+ </wsdl:message>
+
+ <wsdl:message name="setPortletsLifetime">
+ <wsdl:part name="setPortletsLifetime" element="types:setPortletsLifetime"/>
+ </wsdl:message>
+ <wsdl:message name="setPortletsLifetimeResponse">
+ <wsdl:part name="setPortletsLifetimeResponse" element="types:setPortletsLifetimeResponse"/>
+ </wsdl:message>
+
+ <wsdl:portType name="WSRP_v2_Markup_PortType">
+ <wsdl:operation name="getMarkup">
+ <wsdl:input message="intf:getMarkup" name="getMarkup"/>
+ <wsdl:output message="intf:getMarkupResponse" name="getMarkupResponse"/>
+ <wsdl:fault message="intf:AccessDenied" name="AccessDenied"/>
+ <wsdl:fault message="intf:InconsistentParameters" name="InconsistentParameters"/>
+ <wsdl:fault message="intf:InvalidCookie" name="InvalidCookie"/>
+ <wsdl:fault message="intf:InvalidHandle" name="InvalidHandle"/>
+ <wsdl:fault message="intf:InvalidRegistration" name="InvalidRegistration"/>
+ <wsdl:fault message="intf:InvalidSession" name="InvalidSession"/>
+ <wsdl:fault message="intf:InvalidUserCategory" name="InvalidUserCategory"/>
+ <wsdl:fault message="intf:MissingParameters" name="MissingParameters"/>
+ <wsdl:fault message="intf:ModifyRegistrationRequired" name="ModifyRegistrationRequired"/>
+ <wsdl:fault message="intf:OperationFailed" name="OperationFailed"/>
+ <wsdl:fault message="intf:ResourceSuspended" name="ResourceSuspended"/>
+ <wsdl:fault message="intf:UnsupportedLocale" name="UnsupportedLocale"/>
+ <wsdl:fault message="intf:UnsupportedMimeType" name="UnsupportedMimeType"/>
+ <wsdl:fault message="intf:UnsupportedMode" name="UnsupportedMode"/>
+ <wsdl:fault message="intf:UnsupportedWindowState" name="UnsupportedWindowState"/>
+ </wsdl:operation>
+
+ <wsdl:operation name="getResource">
+ <wsdl:input message="intf:getResource" name="getResource"/>
+ <wsdl:output message="intf:getResourceResponse" name="getResourceResponse"/>
+ <wsdl:fault message="intf:AccessDenied" name="AccessDenied"/>
+ <wsdl:fault message="intf:InconsistentParameters" name="InconsistentParameters"/>
+ <wsdl:fault message="intf:InvalidCookie" name="InvalidCookie"/>
+ <wsdl:fault message="intf:InvalidHandle" name="InvalidHandle"/>
+ <wsdl:fault message="intf:InvalidRegistration" name="InvalidRegistration"/>
+ <wsdl:fault message="intf:InvalidSession" name="InvalidSession"/>
+ <wsdl:fault message="intf:InvalidUserCategory" name="InvalidUserCategory"/>
+ <wsdl:fault message="intf:MissingParameters" name="MissingParameters"/>
+ <wsdl:fault message="intf:ModifyRegistrationRequired" name="ModifyRegistrationRequired"/>
+ <wsdl:fault message="intf:OperationFailed" name="OperationFailed"/>
+ <wsdl:fault message="intf:OperationNotSupported" name="OperationNotSupported"/>
+ <wsdl:fault message="intf:ResourceSuspended" name="ResourceSuspended"/>
+ <wsdl:fault message="intf:UnsupportedLocale" name="UnsupportedLocale"/>
+ <wsdl:fault message="intf:UnsupportedMimeType" name="UnsupportedMimeType"/>
+ <wsdl:fault message="intf:UnsupportedMode" name="UnsupportedMode"/>
+ <wsdl:fault message="intf:UnsupportedWindowState" name="UnsupportedWindowState"/>
+ </wsdl:operation>
+
+ <wsdl:operation name="performBlockingInteraction">
+ <wsdl:input message="intf:performBlockingInteraction" name="performBlockingInteraction"/>
+ <wsdl:output message="intf:performBlockingInteractionResponse" name="performBlockingInteractionResponse"/>
+ <wsdl:fault message="intf:AccessDenied" name="AccessDenied"/>
+ <wsdl:fault message="intf:InconsistentParameters" name="InconsistentParameters"/>
+ <wsdl:fault message="intf:InvalidCookie" name="InvalidCookie"/>
+ <wsdl:fault message="intf:InvalidHandle" name="InvalidHandle"/>
+ <wsdl:fault message="intf:InvalidRegistration" name="InvalidRegistration"/>
+ <wsdl:fault message="intf:InvalidSession" name="InvalidSession"/>
+ <wsdl:fault message="intf:InvalidUserCategory" name="InvalidUserCategory"/>
+ <wsdl:fault message="intf:MissingParameters" name="MissingParameters"/>
+ <wsdl:fault message="intf:ModifyRegistrationRequired" name="ModifyRegistrationRequired"/>
+ <wsdl:fault message="intf:OperationFailed" name="OperationFailed"/>
+ <wsdl:fault message="intf:PortletStateChangeRequired" name="PortletStateChangeRequired"/>
+ <wsdl:fault message="intf:ResourceSuspended" name="ResourceSuspended"/>
+ <wsdl:fault message="intf:UnsupportedLocale" name="UnsupportedLocale"/>
+ <wsdl:fault message="intf:UnsupportedMimeType" name="UnsupportedMimeType"/>
+ <wsdl:fault message="intf:UnsupportedMode" name="UnsupportedMode"/>
+ <wsdl:fault message="intf:UnsupportedWindowState" name="UnsupportedWindowState"/>
+ </wsdl:operation>
+
+ <wsdl:operation name="handleEvents">
+ <wsdl:input message="intf:handleEvents" name="handleEvents"/>
+ <wsdl:output message="intf:handleEventsResponse" name="handleEventsResponse"/>
+ <wsdl:fault message="intf:AccessDenied" name="AccessDenied"/>
+ <wsdl:fault message="intf:InconsistentParameters" name="InconsistentParameters"/>
+ <wsdl:fault message="intf:InvalidCookie" name="InvalidCookie"/>
+ <wsdl:fault message="intf:InvalidHandle" name="InvalidHandle"/>
+ <wsdl:fault message="intf:InvalidRegistration" name="InvalidRegistration"/>
+ <wsdl:fault message="intf:InvalidSession" name="InvalidSession"/>
+ <wsdl:fault message="intf:InvalidUserCategory" name="InvalidUserCategory"/>
+ <wsdl:fault message="intf:MissingParameters" name="MissingParameters"/>
+ <wsdl:fault message="intf:ModifyRegistrationRequired" name="ModifyRegistrationRequired"/>
+ <wsdl:fault message="intf:OperationFailed" name="OperationFailed"/>
+ <wsdl:fault message="intf:OperationNotSupported" name="OperationNotSupported"/>
+ <wsdl:fault message="intf:PortletStateChangeRequired" name="PortletStateChangeRequired"/>
+ <wsdl:fault message="intf:ResourceSuspended" name="ResourceSuspended"/>
+ <wsdl:fault message="intf:UnsupportedLocale" name="UnsupportedLocale"/>
+ <wsdl:fault message="intf:UnsupportedMimeType" name="UnsupportedMimeType"/>
+ <wsdl:fault message="intf:UnsupportedMode" name="UnsupportedMode"/>
+ <wsdl:fault message="intf:UnsupportedWindowState" name="UnsupportedWindowState"/>
+ </wsdl:operation>
+
+ <wsdl:operation name="initCookie">
+ <wsdl:input message="intf:initCookie" name="initCookie"/>
+ <wsdl:output message="intf:initCookieResponse" name="initCookieResponse"/>
+ <wsdl:fault message="intf:AccessDenied" name="AccessDenied"/>
+ <wsdl:fault message="intf:InvalidRegistration" name="InvalidRegistration"/>
+ <wsdl:fault message="intf:ModifyRegistrationRequired" name="ModifyRegistrationRequired"/>
+ <wsdl:fault message="intf:OperationFailed" name="OperationFailed"/>
+ <wsdl:fault message="intf:OperationNotSupported" name="OperationNotSupported"/>
+ <wsdl:fault message="intf:ResourceSuspended" name="ResourceSuspended"/>
+ </wsdl:operation>
+
+ <wsdl:operation name="releaseSessions">
+ <wsdl:input message="intf:releaseSessions" name="releaseSessions"/>
+ <wsdl:output message="intf:releaseSessionsResponse" name="releaseSessionsResponse"/>
+ <wsdl:fault message="intf:AccessDenied" name="AccessDenied"/>
+ <wsdl:fault message="intf:InvalidRegistration" name="InvalidRegistration"/>
+ <wsdl:fault message="intf:MissingParameters" name="MissingParameters"/>
+ <wsdl:fault message="intf:ModifyRegistrationRequired" name="ModifyRegistrationRequired"/>
+ <wsdl:fault message="intf:OperationFailed" name="OperationFailed"/>
+ <wsdl:fault message="intf:OperationNotSupported" name="OperationNotSupported"/>
+ <wsdl:fault message="intf:ResourceSuspended" name="ResourceSuspended"/>
+ </wsdl:operation>
+
+ </wsdl:portType>
+
+ <wsdl:portType name="WSRP_v2_ServiceDescription_PortType">
+ <wsdl:operation name="getServiceDescription">
+ <wsdl:input message="intf:getServiceDescription" name="getServiceDescription"/>
+ <wsdl:output message="intf:getServiceDescriptionResponse" name="getServiceDescriptionResponse"/>
+ <wsdl:fault message="intf:InvalidRegistration" name="InvalidRegistration"/>
+ <wsdl:fault message="intf:ModifyRegistrationRequired" name="ModifyRegistrationRequired"/>
+ <wsdl:fault message="intf:OperationFailed" name="OperationFailed"/>
+ <wsdl:fault message="intf:ResourceSuspended" name="ResourceSuspended"/>
+ </wsdl:operation>
+ </wsdl:portType>
+
+ <wsdl:portType name="WSRP_v2_Registration_PortType">
+ <wsdl:operation name="register">
+ <wsdl:input message="intf:register" name="register"/>
+ <wsdl:output message="intf:registerResponse" name="registerResponse"/>
+ <wsdl:fault message="intf:MissingParameters" name="MissingParameters"/>
+ <wsdl:fault message="intf:OperationFailed" name="OperationFailed"/>
+ <wsdl:fault message="intf:OperationNotSupported" name="OperationNotSupported"/>
+ </wsdl:operation>
+
+ <wsdl:operation name="deregister">
+ <wsdl:input message="intf:deregister" name="deregister"/>
+ <wsdl:output message="intf:deregisterResponse" name="deregisterResponse"/>
+ <wsdl:fault message="intf:InvalidRegistration" name="InvalidRegistration"/>
+ <wsdl:fault message="intf:OperationFailed" name="OperationFailed"/>
+ <wsdl:fault message="intf:OperationNotSupported" name="OperationNotSupported"/>
+ <wsdl:fault message="intf:ResourceSuspended" name="ResourceSuspended"/>
+ </wsdl:operation>
+
+ <wsdl:operation name="modifyRegistration">
+ <wsdl:input message="intf:modifyRegistration" name="modifyRegistration"/>
+ <wsdl:output message="intf:modifyRegistrationResponse" name="modifyRegistrationResponse"/>
+ <wsdl:fault message="intf:InvalidRegistration" name="InvalidRegistration"/>
+ <wsdl:fault message="intf:MissingParameters" name="MissingParameters"/>
+ <wsdl:fault message="intf:OperationFailed" name="OperationFailed"/>
+ <wsdl:fault message="intf:OperationNotSupported" name="OperationNotSupported"/>
+ <wsdl:fault message="intf:ResourceSuspended" name="ResourceSuspended"/>
+ </wsdl:operation>
+
+ <wsdl:operation name="getRegistrationLifetime">
+ <wsdl:input message="intf:getRegistrationLifetime" name="getRegistrationLifetime"/>
+ <wsdl:output message="intf:getRegistrationLifetimeResponse" name="getRegistrationLifetimeResponse"/>
+ <wsdl:fault message="intf:AccessDenied" name="AccessDenied"/>
+ <wsdl:fault message="intf:InvalidHandle" name="InvalidHandle"/>
+ <wsdl:fault message="intf:InvalidRegistration" name="InvalidRegistration"/>
+ <wsdl:fault message="intf:ModifyRegistrationRequired" name="ModifyRegistrationRequired"/>
+ <wsdl:fault message="intf:OperationFailed" name="OperationFailed"/>
+ <wsdl:fault message="intf:OperationNotSupported" name="OperationNotSupported"/>
+ <wsdl:fault message="intf:ResourceSuspended" name="ResourceSuspended"/>
+ </wsdl:operation>
+
+ <wsdl:operation name="setRegistrationLifetime">
+ <wsdl:input message="intf:setRegistrationLifetime" name="setRegistrationLifetime"/>
+ <wsdl:output message="intf:setRegistrationLifetimeResponse" name="setRegistrationLifetimeResponse"/>
+ <wsdl:fault message="intf:AccessDenied" name="AccessDenied"/>
+ <wsdl:fault message="intf:InvalidHandle" name="InvalidHandle"/>
+ <wsdl:fault message="intf:InvalidRegistration" name="InvalidRegistration"/>
+ <wsdl:fault message="intf:ModifyRegistrationRequired" name="ModifyRegistrationRequired"/>
+ <wsdl:fault message="intf:OperationFailed" name="OperationFailed"/>
+ <wsdl:fault message="intf:OperationNotSupported" name="OperationNotSupported"/>
+ <wsdl:fault message="intf:ResourceSuspended" name="ResourceSuspended"/>
+ </wsdl:operation>
+
+ </wsdl:portType>
+
+ <wsdl:portType name="WSRP_v2_PortletManagement_PortType">
+ <wsdl:operation name="getPortletDescription">
+ <wsdl:input message="intf:getPortletDescription" name="getPortletDescription"/>
+ <wsdl:output message="intf:getPortletDescriptionResponse" name="getPortletDescriptionResponse"/>
+ <wsdl:fault message="intf:AccessDenied" name="AccessDenied"/>
+ <wsdl:fault message="intf:InconsistentParameters" name="InconsistentParameters"/>
+ <wsdl:fault message="intf:InvalidHandle" name="InvalidHandle"/>
+ <wsdl:fault message="intf:InvalidRegistration" name="InvalidRegistration"/>
+ <wsdl:fault message="intf:InvalidUserCategory" name="InvalidUserCategory"/>
+ <wsdl:fault message="intf:MissingParameters" name="MissingParameters"/>
+ <wsdl:fault message="intf:ModifyRegistrationRequired" name="ModifyRegistrationRequired"/>
+ <wsdl:fault message="intf:OperationFailed" name="OperationFailed"/>
+ <wsdl:fault message="intf:OperationNotSupported" name="OperationNotSupported"/>
+ <wsdl:fault message="intf:ResourceSuspended" name="ResourceSuspended"/>
+ </wsdl:operation>
+
+ <wsdl:operation name="clonePortlet">
+ <wsdl:input message="intf:clonePortlet" name="clonePortlet"/>
+ <wsdl:output message="intf:clonePortletResponse" name="clonePortletResponse"/>
+ <wsdl:fault message="intf:AccessDenied" name="AccessDenied"/>
+ <wsdl:fault message="intf:InconsistentParameters" name="InconsistentParameters"/>
+ <wsdl:fault message="intf:InvalidHandle" name="InvalidHandle"/>
+ <wsdl:fault message="intf:InvalidRegistration" name="InvalidRegistration"/>
+ <wsdl:fault message="intf:InvalidUserCategory" name="InvalidUserCategory"/>
+ <wsdl:fault message="intf:MissingParameters" name="MissingParameters"/>
+ <wsdl:fault message="intf:ModifyRegistrationRequired" name="ModifyRegistrationRequired"/>
+ <wsdl:fault message="intf:OperationFailed" name="OperationFailed"/>
+ <wsdl:fault message="intf:OperationNotSupported" name="OperationNotSupported"/>
+ <wsdl:fault message="intf:ResourceSuspended" name="ResourceSuspended"/>
+ </wsdl:operation>
+
+ <wsdl:operation name="destroyPortlets">
+ <wsdl:input message="intf:destroyPortlets" name="destroyPortlets"/>
+ <wsdl:output message="intf:destroyPortletsResponse" name="destroyPortletsResponse"/>
+ <wsdl:fault message="intf:InconsistentParameters" name="InconsistentParameters"/>
+ <wsdl:fault message="intf:InvalidRegistration" name="InvalidRegistration"/>
+ <wsdl:fault message="intf:MissingParameters" name="MissingParameters"/>
+ <wsdl:fault message="intf:ModifyRegistrationRequired" name="ModifyRegistrationRequired"/>
+ <wsdl:fault message="intf:OperationFailed" name="OperationFailed"/>
+ <wsdl:fault message="intf:OperationNotSupported" name="OperationNotSupported"/>
+ <wsdl:fault message="intf:ResourceSuspended" name="ResourceSuspended"/>
+ </wsdl:operation>
+
+ <wsdl:operation name="setPortletProperties">
+ <wsdl:input message="intf:setPortletProperties" name="setPortletProperties"/>
+ <wsdl:output message="intf:setPortletPropertiesResponse" name="setPortletPropertiesResponse"/>
+ <wsdl:fault message="intf:AccessDenied" name="AccessDenied"/>
+ <wsdl:fault message="intf:InconsistentParameters" name="InconsistentParameters"/>
+ <wsdl:fault message="intf:InvalidHandle" name="InvalidHandle"/>
+ <wsdl:fault message="intf:InvalidRegistration" name="InvalidRegistration"/>
+ <wsdl:fault message="intf:InvalidUserCategory" name="InvalidUserCategory"/>
+ <wsdl:fault message="intf:MissingParameters" name="MissingParameters"/>
+ <wsdl:fault message="intf:ModifyRegistrationRequired" name="ModifyRegistrationRequired"/>
+ <wsdl:fault message="intf:OperationFailed" name="OperationFailed"/>
+ <wsdl:fault message="intf:OperationNotSupported" name="OperationNotSupported"/>
+ <wsdl:fault message="intf:ResourceSuspended" name="ResourceSuspended"/>
+ </wsdl:operation>
+
+ <wsdl:operation name="getPortletProperties">
+ <wsdl:input message="intf:getPortletProperties" name="getPortletProperties"/>
+ <wsdl:output message="intf:getPortletPropertiesResponse" name="getPortletPropertiesResponse"/>
+ <wsdl:fault message="intf:AccessDenied" name="AccessDenied"/>
+ <wsdl:fault message="intf:InconsistentParameters" name="InconsistentParameters"/>
+ <wsdl:fault message="intf:InvalidHandle" name="InvalidHandle"/>
+ <wsdl:fault message="intf:InvalidRegistration" name="InvalidRegistration"/>
+ <wsdl:fault message="intf:InvalidUserCategory" name="InvalidUserCategory"/>
+ <wsdl:fault message="intf:MissingParameters" name="MissingParameters"/>
+ <wsdl:fault message="intf:ModifyRegistrationRequired" name="ModifyRegistrationRequired"/>
+ <wsdl:fault message="intf:OperationFailed" name="OperationFailed"/>
+ <wsdl:fault message="intf:OperationNotSupported" name="OperationNotSupported"/>
+ <wsdl:fault message="intf:ResourceSuspended" name="ResourceSuspended"/>
+ </wsdl:operation>
+
+ <wsdl:operation name="getPortletPropertyDescription">
+ <wsdl:input message="intf:getPortletPropertyDescription" name="getPortletPropertyDescription"/>
+ <wsdl:output message="intf:getPortletPropertyDescriptionResponse"
+ name="getPortletPropertyDescriptionResponse"/>
+ <wsdl:fault message="intf:AccessDenied" name="AccessDenied"/>
+ <wsdl:fault message="intf:InconsistentParameters" name="InconsistentParameters"/>
+ <wsdl:fault message="intf:InvalidHandle" name="InvalidHandle"/>
+ <wsdl:fault message="intf:InvalidRegistration" name="InvalidRegistration"/>
+ <wsdl:fault message="intf:InvalidUserCategory" name="InvalidUserCategory"/>
+ <wsdl:fault message="intf:MissingParameters" name="MissingParameters"/>
+ <wsdl:fault message="intf:ModifyRegistrationRequired" name="ModifyRegistrationRequired"/>
+ <wsdl:fault message="intf:OperationFailed" name="OperationFailed"/>
+ <wsdl:fault message="intf:OperationNotSupported" name="OperationNotSupported"/>
+ <wsdl:fault message="intf:ResourceSuspended" name="ResourceSuspended"/>
+ </wsdl:operation>
+
+ <wsdl:operation name="copyPortlets">
+ <wsdl:input message="intf:copyPortlets" name="copyPortlets"/>
+ <wsdl:output message="intf:copyPortletsResponse" name="copyPortletsResponse"/>
+ <wsdl:fault message="intf:AccessDenied" name="AccessDenied"/>
+ <wsdl:fault message="intf:InconsistentParameters" name="InconsistentParameters"/>
+ <wsdl:fault message="intf:InvalidHandle" name="InvalidHandle"/>
+ <wsdl:fault message="intf:InvalidRegistration" name="InvalidRegistration"/>
+ <wsdl:fault message="intf:InvalidUserCategory" name="InvalidUserCategory"/>
+ <wsdl:fault message="intf:MissingParameters" name="MissingParameters"/>
+ <wsdl:fault message="intf:ModifyRegistrationRequired" name="ModifyRegistrationRequired"/>
+ <wsdl:fault message="intf:OperationFailed" name="OperationFailed"/>
+ <wsdl:fault message="intf:OperationNotSupported" name="OperationNotSupported"/>
+ <wsdl:fault message="intf:ResourceSuspended" name="ResourceSuspended"/>
+ </wsdl:operation>
+
+ <wsdl:operation name="exportPortlets">
+ <wsdl:input message="intf:exportPortlets" name="exportPortlets"/>
+ <wsdl:output message="intf:exportPortletsResponse" name="exportPortletsResponse"/>
+ <wsdl:fault message="intf:AccessDenied" name="AccessDenied"/>
+ <wsdl:fault message="intf:InconsistentParameters" name="InconsistentParameters"/>
+ <wsdl:fault message="intf:InvalidHandle" name="InvalidHandle"/>
+ <wsdl:fault message="intf:InvalidRegistration" name="InvalidRegistration"/>
+ <wsdl:fault message="intf:InvalidUserCategory" name="InvalidUserCategory"/>
+ <wsdl:fault message="intf:MissingParameters" name="MissingParameters"/>
+ <wsdl:fault message="intf:ModifyRegistrationRequired" name="ModifyRegistrationRequired"/>
+ <wsdl:fault message="intf:OperationFailed" name="OperationFailed"/>
+ <wsdl:fault message="intf:OperationNotSupported" name="OperationNotSupported"/>
+ <wsdl:fault message="intf:ResourceSuspended" name="ResourceSuspended"/>
+ <wsdl:fault message="intf:ExportByValueNotSupported" name="ExportByValueNotSupported"/>
+ </wsdl:operation>
+
+ <wsdl:operation name="importPortlets">
+ <wsdl:input message="intf:importPortlets" name="importPortlets"/>
+ <wsdl:output message="intf:importPortletsResponse" name="importPortletsResponse"/>
+ <wsdl:fault message="intf:AccessDenied" name="AccessDenied"/>
+ <wsdl:fault message="intf:InconsistentParameters" name="InconsistentParameters"/>
+ <wsdl:fault message="intf:InvalidRegistration" name="InvalidRegistration"/>
+ <wsdl:fault message="intf:InvalidUserCategory" name="InvalidUserCategory"/>
+ <wsdl:fault message="intf:MissingParameters" name="MissingParameters"/>
+ <wsdl:fault message="intf:ModifyRegistrationRequired" name="ModifyRegistrationRequired"/>
+ <wsdl:fault message="intf:OperationFailed" name="OperationFailed"/>
+ <wsdl:fault message="intf:OperationNotSupported" name="OperationNotSupported"/>
+ <wsdl:fault message="intf:ResourceSuspended" name="ResourceSuspended"/>
+ <wsdl:fault message="intf:ExportNoLongerValid" name="ExportNoLongerValid"/>
+ </wsdl:operation>
+
+ <wsdl:operation name="releaseExport">
+ <wsdl:input message="intf:releaseExport" name="releaseExport"/>
+ <wsdl:output message="intf:releaseExportResponse" name="releaseExportResponse"/>
+ </wsdl:operation>
+
+ <wsdl:operation name="setExportLifetime">
+ <wsdl:input message="intf:setExportLifetime" name="setExportLifetime"/>
+ <wsdl:output message="intf:setExportLifetimeResponse" name="setExportLifetimeResponse"/>
+ <wsdl:fault message="intf:AccessDenied" name="AccessDenied"/>
+ <wsdl:fault message="intf:InvalidHandle" name="InvalidHandle"/>
+ <wsdl:fault message="intf:InvalidRegistration" name="InvalidRegistration"/>
+ <wsdl:fault message="intf:ModifyRegistrationRequired" name="ModifyRegistrationRequired"/>
+ <wsdl:fault message="intf:OperationFailed" name="OperationFailed"/>
+ <wsdl:fault message="intf:OperationNotSupported" name="OperationNotSupported"/>
+ <wsdl:fault message="intf:ResourceSuspended" name="ResourceSuspended"/>
+ </wsdl:operation>
+
+ <wsdl:operation name="getPortletsLifetime">
+ <wsdl:input message="intf:getPortletsLifetime" name="getPortletsLifetime"/>
+ <wsdl:output message="intf:getPortletsLifetimeResponse" name="getPortletsLifetimeResponse"/>
+ <wsdl:fault message="intf:AccessDenied" name="AccessDenied"/>
+ <wsdl:fault message="intf:InconsistentParameters" name="InconsistentParameters"/>
+ <wsdl:fault message="intf:InvalidHandle" name="InvalidHandle"/>
+ <wsdl:fault message="intf:InvalidRegistration" name="InvalidRegistration"/>
+ <wsdl:fault message="intf:ModifyRegistrationRequired" name="ModifyRegistrationRequired"/>
+ <wsdl:fault message="intf:OperationFailed" name="OperationFailed"/>
+ <wsdl:fault message="intf:OperationNotSupported" name="OperationNotSupported"/>
+ <wsdl:fault message="intf:ResourceSuspended" name="ResourceSuspended"/>
+ </wsdl:operation>
+
+ <wsdl:operation name="setPortletsLifetime">
+ <wsdl:input message="intf:setPortletsLifetime" name="setPortletsLifetime"/>
+ <wsdl:output message="intf:setPortletsLifetimeResponse" name="setPortletsLifetimeResponse"/>
+ <wsdl:fault message="intf:AccessDenied" name="AccessDenied"/>
+ <wsdl:fault message="intf:InconsistentParameters" name="InconsistentParameters"/>
+ <wsdl:fault message="intf:InvalidHandle" name="InvalidHandle"/>
+ <wsdl:fault message="intf:InvalidRegistration" name="InvalidRegistration"/>
+ <wsdl:fault message="intf:ModifyRegistrationRequired" name="ModifyRegistrationRequired"/>
+ <wsdl:fault message="intf:OperationFailed" name="OperationFailed"/>
+ <wsdl:fault message="intf:OperationNotSupported" name="OperationNotSupported"/>
+ <wsdl:fault message="intf:ResourceSuspended" name="ResourceSuspended"/>
+ </wsdl:operation>
+ </wsdl:portType>
+</wsdl:definitions>
Added: components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/wsdl/wsrp-2.0-services.wsdl
===================================================================
--- components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/wsdl/wsrp-2.0-services.wsdl (rev 0)
+++ components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/wsdl/wsrp-2.0-services.wsdl 2010-05-28 09:29:22 UTC (rev 3213)
@@ -0,0 +1,49 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ JBoss, a division of Red Hat
+ ~ Copyright 2010, Red Hat Middleware, LLC, and individual
+ ~ contributors as indicated by the @authors tag. See the
+ ~ copyright.txt in the distribution for a full listing of
+ ~ individual contributors.
+ ~
+ ~ 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.
+ -->
+
+<wsdl:definitions targetNamespace="urn:oasis:names:tc:wsrp:v2:wsdl"
+ xmlns:bind="urn:oasis:names:tc:wsrp:v2:bind"
+
+ xmlns="http://schemas.xmlsoap.org/wsdl/"
+
+ xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
+ xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
+
+ <import namespace="urn:oasis:names:tc:wsrp:v2:bind" location="wsrp-2.0-bindings.wsdl"/>
+
+ <wsdl:service name="WSRPService">
+ <wsdl:port binding="bind:WSRP_v2_Markup_Binding_SOAP" name="WSRPMarkupService">
+ <soap:address location="REPLACE_WITH_ACTUAL_URL"/>
+ </wsdl:port>
+ <wsdl:port binding="bind:WSRP_v2_ServiceDescription_Binding_SOAP" name="WSRPServiceDescriptionService">
+ <soap:address location="REPLACE_WITH_ACTUAL_URL"/>
+ </wsdl:port>
+ <wsdl:port binding="bind:WSRP_v2_Registration_Binding_SOAP" name="WSRPRegistrationService">
+ <soap:address location="REPLACE_WITH_ACTUAL_URL"/>
+ </wsdl:port>
+ <wsdl:port binding="bind:WSRP_v2_PortletManagement_Binding_SOAP" name="WSRPPortletManagementService">
+ <soap:address location="REPLACE_WITH_ACTUAL_URL"/>
+ </wsdl:port>
+ </wsdl:service>
+</wsdl:definitions>
Added: components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/wsdl/wsrp-2.0-types.xsd
===================================================================
--- components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/wsdl/wsrp-2.0-types.xsd (rev 0)
+++ components/wsrp/trunk/wsrp-producer-war/src/main/webapp/WEB-INF/wsdl/wsrp-2.0-types.xsd 2010-05-28 09:29:22 UTC (rev 3213)
@@ -0,0 +1,1470 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ JBoss, a division of Red Hat
+ ~ Copyright 2010, Red Hat Middleware, LLC, and individual
+ ~ contributors as indicated by the @authors tag. See the
+ ~ copyright.txt in the distribution for a full listing of
+ ~ individual contributors.
+ ~
+ ~ 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.
+ -->
+
+<schema targetNamespace="urn:oasis:names:tc:wsrp:v2:types"
+ xmlns:types="urn:oasis:names:tc:wsrp:v2:types"
+
+ xmlns="http://www.w3.org/2001/XMLSchema"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+
+ elementFormDefault="qualified">
+
+ <!-- This file reflects v2.0 of the specification -->
+
+ <import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="http://www.w3.org/2001/xml.xsd"/>
+
+ <!-- - - - - - - - - - - - - - - - - -->
+ <!-- General types used throughout -->
+ <!-- - - - - - - - - - - - - - - - - -->
+ <!-- This definition matches the WSRP v2 specification, but is not used throughout the
+ rest of these definitions as not all stacks are able to handle restrictions on strings
+ -->
+ <simpleType name="Handle">
+ <restriction base="xsd:string">
+ <xsd:minLength value="1"/>
+ <xsd:maxLength value="255"/>
+ </restriction>
+ </simpleType>
+ <element name="Handle" type="types:Handle"/>
+
+ <!-- This definition matches the WSRP v2 specification, but is not used throughout the
+ rest of these definitions as not all stacks are able to handle restrictions on strings
+ -->
+ <simpleType name="ID">
+ <restriction base="xsd:string">
+ <xsd:minLength value="1"/>
+ <xsd:maxLength value="4096"/>
+ </restriction>
+ </simpleType>
+ <element name="ID" type="types:ID"/>
+
+ <!-- This definition matches the WSRP v2 specification, but is not used throughout the
+ rest of these definitions as not all stacks are able to handle restrictions on strings
+ -->
+ <simpleType name="Key">
+ <restriction base="xsd:string">
+ <xsd:minLength value="1"/>
+ <xsd:maxLength value="255"/>
+ </restriction>
+ </simpleType>
+ <element name="Key" type="types:Key"/>
+
+ <complexType name="Extension">
+ <sequence>
+ <any namespace="##other" processContents="lax"/>
+ </sequence>
+ </complexType>
+
+ <complexType name="ExtensionPart">
+ <sequence>
+ <element name="extendedTypes" type="xsd:string" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="schemaType" type="types:ModelTypes" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="name" type="xsd:QName" use="required"/>
+ <attribute name="type" type="xsd:QName" use="required"/>
+ <attribute name="schemaLocation" type="xsd:anyURI" use="optional"/>
+ </complexType>
+ <element name="ExtensionPart" type="types:ExtensionPart"/>
+
+ <complexType name="ExtensionDescription">
+ <sequence>
+ <element name="parts" type="types:ExtensionPart" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="aliases" type="xsd:QName" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="description" type="types:LocalizedString" minOccurs="0"/>
+ <element name="label" type="types:LocalizedString" minOccurs="0"/>
+ <element name="hint" type="types:LocalizedString" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="name" type="xsd:QName" use="required"/>
+ </complexType>
+ <element name="ExtensionDescription" type="types:ExtensionDescription"/>
+
+ <complexType name="LocalizedString">
+ <sequence>
+ <element name="value" type="xsd:string"/>
+ </sequence>
+ <attribute ref="xml:lang" use="required"/>
+ <attribute name="resourceName" type="xsd:string" use="optional"/>
+ </complexType>
+
+ <complexType name="ResourceList">
+ <sequence>
+ <element name="resources" type="types:Resource" maxOccurs="unbounded"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+
+ <complexType name="Resource">
+ <sequence>
+ <element name="values" type="types:ResourceValue" maxOccurs="unbounded"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="resourceName" type="xsd:string" use="required"/>
+ </complexType>
+
+ <complexType name="ResourceValue">
+ <sequence>
+ <element name="value" type="xsd:string"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute ref="xml:lang" use="required"/>
+ </complexType>
+
+ <complexType name="NamedString">
+ <sequence>
+ <element name="value" type="xsd:string" minOccurs="0"/>
+ </sequence>
+ <attribute name="name" type="xsd:string" use="required"/>
+ </complexType>
+
+ <complexType name="NamedStringArray">
+ <sequence>
+ <element name="NamedString" type="types:NamedString" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="NamedStringArray" type="types:NamedStringArray"/>
+
+ <!-- - - - - - - - - -->
+ <!-- Producer types -->
+ <!-- - - - - - - - - -->
+
+ <complexType name="RegistrationData">
+ <sequence>
+ <element name="consumerName" type="xsd:string"/>
+ <element name="consumerAgent" type="xsd:string"/>
+ <element name="methodGetSupported" type="xsd:boolean"/>
+ <element name="consumerModes" type="xsd:string" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="consumerWindowStates" type="xsd:string" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="consumerUserScopes" type="xsd:string" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="extensionDescriptions" type="types:ExtensionDescription" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="registrationProperties" type="types:Property" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="resourceList" type="types:ResourceList" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="RegistrationData" type="types:RegistrationData"/>
+
+
+ <complexType name="RegistrationState">
+ <sequence>
+ <element name="registrationState" type="xsd:base64Binary" minOccurs="0"/>
+ <element name="scheduledDestruction" type="types:Lifetime" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="RegistrationState" type="types:RegistrationState"/>
+
+ <complexType name="RegistrationContext">
+ <complexContent>
+ <extension base="types:RegistrationState">
+ <sequence>
+ <element name="registrationHandle" type="xsd:string"/>
+ </sequence>
+ </extension>
+ </complexContent>
+ </complexType>
+ <element name="RegistrationContext" type="types:RegistrationContext"/>
+
+ <complexType name="SessionContext">
+ <sequence>
+ <element name="sessionID" type="xsd:string" minOccurs="0"/>
+ <element name="expires" type="xsd:int" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="SessionContext" type="types:SessionContext"/>
+
+ <complexType name="SessionParams">
+ <sequence>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="sessionID" type="xsd:string" use="optional"/>
+ </complexType>
+ <element name="SessionParams" type="types:SessionParams"/>
+
+ <complexType name="RuntimeContext">
+ <sequence>
+ <element name="userAuthentication" type="xsd:string"/>
+ <element name="portletInstanceKey" type="xsd:string"/>
+ <element name="namespacePrefix" type="xsd:string"/>
+ <element name="templates" type="types:Templates" minOccurs="0"/>
+ <element name="sessionParams" type="types:SessionParams" minOccurs="0"/>
+ <element name="pageState" type="xsd:string" minOccurs="0"/>
+ <element name="portletStates" type="xsd:string" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="RuntimeContext" type="types:RuntimeContext"/>
+
+ <complexType name="ItemDescription">
+ <sequence>
+ <element name="description" type="types:LocalizedString" nillable="true"/>
+ <element name="displayName" type="types:LocalizedString" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="itemName" type="xsd:string" use="required"/>
+ </complexType>
+
+ <simpleType name="CookieProtocol">
+ <restriction base="xsd:string">
+ <enumeration value="none"/>
+ <enumeration value="perUser"/>
+ <enumeration value="perGroup"/>
+ </restriction>
+ </simpleType>
+
+ <complexType name="ExportDescription">
+ <sequence>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="recommendedExportSize" type="xsd:integer" use="optional"/>
+ </complexType>
+ <element name="ExportDescription" type="types:ExportDescription"/>
+
+ <complexType name="ServiceDescription">
+ <sequence>
+ <element name="requiresRegistration" type="xsd:boolean"/>
+ <element name="offeredPortlets" type="types:PortletDescription" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="userCategoryDescriptions" type="types:ItemDescription" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="extensionDescriptions" type="types:ExtensionDescription" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="customWindowStateDescriptions" type="types:ItemDescription" minOccurs="0"
+ maxOccurs="unbounded"/>
+ <element name="customModeDescriptions" type="types:ItemDescription" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="requiresInitCookie" type="types:CookieProtocol" default="none" minOccurs="0"/>
+ <element name="registrationPropertyDescription" type="types:ModelDescription" minOccurs="0"/>
+ <element name="locales" type="xsd:string" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="resourceList" type="types:ResourceList" minOccurs="0"/>
+ <element name="eventDescriptions" type="types:EventDescription" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="schemaType" type="types:ModelTypes" minOccurs="0"/>
+ <element name="supportedOptions" type="xsd:string" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="exportDescription" type="types:ExportDescription" minOccurs="0"/>
+ <element name="mayReturnRegistrationState" type="xsd:boolean" minOccurs="0" default="false"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="ServiceDescription" type="types:ServiceDescription"/>
+
+ <complexType name="Lifetime">
+ <sequence>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <!--
+ The following two attributes are marked as optional despite the spec
+ requiring values so that some validating parsers do not require
+ values even when the element is supplied with nillable="true"
+ -->
+ <attribute name="currentTime" type="xsd:dateTime" use="optional"/>
+ <attribute name="terminationTime" type="xsd:dateTime" use="optional"/>
+ <attribute name="refreshDuration" type="xsd:duration" use="optional"/>
+ </complexType>
+ <element name="Lifetime" type="types:Lifetime"/>
+
+ <!-- - - - - - - - - - - - - - - - - - - -->
+ <!-- Portlet types (metadata and runtime) -->
+ <!-- - - - - - - - - - - - - - - - - - - -->
+
+ <complexType name="MarkupType">
+ <sequence>
+ <element name="mimeType" type="xsd:string"/>
+ <element name="modes" type="xsd:string" maxOccurs="unbounded"/>
+ <element name="windowStates" type="xsd:string" maxOccurs="unbounded"/>
+ <element name="locales" type="xsd:string" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+
+ <complexType name="PortletDescription">
+ <sequence>
+ <element name="portletHandle" type="xsd:string"/>
+ <element name="markupTypes" type="types:MarkupType" maxOccurs="unbounded"/>
+ <element name="groupID" type="xsd:string" minOccurs="0"/>
+ <element name="description" type="types:LocalizedString" minOccurs="0"/>
+ <element name="shortTitle" type="types:LocalizedString" minOccurs="0"/>
+ <element name="title" type="types:LocalizedString" minOccurs="0"/>
+ <element name="displayName" type="types:LocalizedString" minOccurs="0"/>
+ <element name="keywords" type="types:LocalizedString" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="publishedEvents" type="xsd:QName" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="handledEvents" type="xsd:QName" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="navigationalPublicValueDescriptions" type="types:ParameterDescription" minOccurs="0"
+ maxOccurs="unbounded"/>
+ <element name="userCategories" type="xsd:string" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="userProfileItems" type="xsd:string" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="portletManagedModes" type="xsd:string" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="usesMethodGet" type="xsd:boolean" default="false" minOccurs="0"/>
+ <element name="defaultMarkupSecure" type="xsd:boolean" default="false" minOccurs="0"/>
+ <element name="onlySecure" type="xsd:boolean" default="false" minOccurs="0"/>
+ <element name="userContextStoredInSession" type="xsd:boolean" default="false" minOccurs="0"/>
+ <element name="templatesStoredInSession" type="xsd:boolean" default="false" minOccurs="0"/>
+ <element name="hasUserSpecificState" type="xsd:boolean" default="false" minOccurs="0"/>
+ <element name="doesUrlTemplateProcessing" type="xsd:boolean" default="false" minOccurs="0"/>
+ <element name="mayReturnPortletState" type="xsd:boolean" default="false" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="portletID" type="xsd:string" use="optional"/>
+ </complexType>
+
+ <complexType name="PortletDescriptionResponse">
+ <sequence>
+ <element name="portletDescription" type="types:PortletDescription"/>
+ <element name="resourceList" type="types:ResourceList" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+
+ <complexType name="PortletContext">
+ <sequence>
+ <element name="portletHandle" type="xsd:string"/>
+ <element name="portletState" type="xsd:base64Binary" minOccurs="0"/>
+ <element name="scheduledDestruction" type="types:Lifetime" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="PortletContext" type="types:PortletContext"/>
+
+ <simpleType name="ErrorCodes">
+ <restriction base="xsd:QName">
+ <enumeration value="types:AccessDenied"/>
+ <enumeration value="types:ExportNoLongerValid"/>
+ <enumeration value="types:InconsistentParameters"/>
+ <enumeration value="types:InvalidRegistration"/>
+ <enumeration value="types:InvalidCookie"/>
+ <enumeration value="types:InvalidHandle"/>
+ <enumeration value="types:InvalidSession"/>
+ <enumeration value="types:InvalidUserCategory"/>
+ <enumeration value="types:ModifyRegistrationRequired"/>
+ <enumeration value="types:MissingParameters"/>
+ <enumeration value="types:OperationFailed"/>
+ <enumeration value="types:OperationNotSupported"/>
+ <enumeration value="types:ResourceSuspended"/>
+ <enumeration value="types:TooBusy"/>
+ <enumeration value="types:TooManyRequests"/>
+ </restriction>
+ </simpleType>
+
+ <complexType name="BaseFailed">
+ <sequence>
+ <element name="reason" type="types:LocalizedString" minOccurs="0"/>
+ <element name="resourceList" type="types:ResourceList" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="errorCode" type="types:ErrorCodes" use="required"/>
+ </complexType>
+ <element name="BaseFailed" type="types:BaseFailed"/>
+
+ <complexType name="FailedPortlets">
+ <complexContent>
+ <extension base="types:BaseFailed">
+ <sequence>
+ <element name="portletHandles" type="xsd:string" maxOccurs="unbounded"/>
+ </sequence>
+ </extension>
+ </complexContent>
+ </complexType>
+ <element name="FailedPortlets" type="types:FailedPortlets"/>
+
+ <complexType name="SetPortletLifetime">
+ <sequence>
+ <element name="portletContext" type="types:PortletContext" maxOccurs="unbounded"/>
+ <element name="scheduledDestruction" type="types:Lifetime" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="setPortletLifetime" type="types:SetPortletLifetime"/>
+
+ <complexType name="PortletLifetime">
+ <sequence>
+ <element name="portletContext" type="types:PortletContext"/>
+ <element name="scheduledDestruction" type="types:Lifetime"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="PortletLifetime" type="types:PortletLifetime"/>
+
+ <!-- - - - - - - - - - - - -->
+ <!-- Event oriented types -->
+ <!-- - - - - - - - - - - - -->
+
+ <complexType name="EventDescription">
+ <sequence>
+ <element name="aliases" type="xsd:QName" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="description" type="types:LocalizedString" minOccurs="0"/>
+ <element name="label" type="types:LocalizedString" minOccurs="0"/>
+ <element name="hint" type="types:LocalizedString" minOccurs="0"/>
+ <element name="schemaType" type="types:ModelTypes" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="name" type="xsd:QName" use="required"/>
+ <attribute name="type" type="xsd:QName" use="optional"/>
+ <attribute name="schemaLocation" type="xsd:anyURI" use="optional"/>
+ </complexType>
+ <element name="EventDescription" type="types:EventDescription"/>
+
+ <complexType name="EventPayload">
+ <sequence>
+ <element name="namedStringArray" type="types:NamedStringArray" minOccurs="0"/>
+ <any namespace="##other" minOccurs="0" processContents="lax"/>
+ </sequence>
+ </complexType>
+ <element name="EventPayload" type="types:EventPayload"/>
+
+ <complexType name="Event">
+ <sequence>
+ <element name="payload" type="types:EventPayload" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="name" type="xsd:QName" use="required"/>
+ <attribute name="type" type="xsd:QName" use="optional"/>
+ </complexType>
+ <element name="Event" type="types:Event"/>
+
+ <complexType name="EventParams">
+ <sequence>
+ <element name="events" type="types:Event" minOccurs="1" maxOccurs="unbounded"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="portletStateChange" type="types:StateChange" use="required"/>
+ </complexType>
+ <element name="EventParams" type="types:EventParams"/>
+
+ <complexType name="HandleEventsFailed">
+ <complexContent>
+ <extension base="types:BaseFailed">
+ <sequence>
+ <element name="index" type="xsd:integer" maxOccurs="unbounded"/>
+ </sequence>
+ </extension>
+ </complexContent>
+ </complexType>
+ <element name="HandleEventsFailed" type="types:HandleEventsFailed"/>
+
+ <!-- - - - - - - - - - - - -->
+ <!-- Markup oriented types -->
+ <!-- - - - - - - - - - - - -->
+
+ <complexType name="NavigationalContext">
+ <sequence>
+ <element name="publicValues" type="types:NamedString" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="opaqueValue" type="xsd:string" use="optional"/>
+ </complexType>
+ <element name="NavigationalContext" type="types:NavigationalContext"/>
+
+ <complexType name="MimeRequest">
+ <sequence>
+ <element name="secureClientCommunication" type="xsd:boolean"/>
+ <element name="locales" type="xsd:string" maxOccurs="unbounded"/>
+ <element name="mimeTypes" type="xsd:string" maxOccurs="unbounded"/>
+ <element name="mode" type="xsd:string"/>
+ <element name="windowState" type="xsd:string"/>
+ <element name="clientData" type="types:ClientData" minOccurs="0"/>
+ <element name="navigationalContext" type="types:NavigationalContext" minOccurs="0"/>
+ <element name="markupCharacterSets" type="xsd:string" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="validateTag" type="xsd:string" minOccurs="0"/>
+ <element name="validNewModes" type="xsd:string" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="validNewWindowStates" type="xsd:string" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="MimeRequest" type="types:MimeRequest"/>
+
+ <complexType name="MarkupParams">
+ <complexContent>
+ <extension base="types:MimeRequest">
+ <sequence/>
+ </extension>
+ </complexContent>
+ </complexType>
+ <element name="MarkupParams" type="types:MarkupParams"/>
+
+ <complexType name="ResourceParams">
+ <complexContent>
+ <extension base="types:MimeRequest">
+ <sequence>
+ <element name="formParameters" type="types:NamedString" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="uploadContexts" type="types:UploadContext" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="resourceID" type="xsd:string" use="required"/>
+ <attribute name="portletStateChange" type="types:StateChange" use="required"/>
+ <attribute name="resourceState" type="xsd:string" use="optional"/>
+ <attribute name="resourceCacheability" type="xsd:string" use="optional"/>
+ </extension>
+ </complexContent>
+ </complexType>
+ <element name="ResourceParams" type="types:ResourceParams"/>
+
+ <complexType name="MimeResponse">
+ <sequence>
+ <element name="useCachedItem" type="xsd:boolean" default="false" minOccurs="0"/>
+ <element name="mimeType" type="xsd:string" minOccurs="0"/>
+ <element name="itemString" type="xsd:string" minOccurs="0"/>
+ <element name="itemBinary" type="xsd:base64Binary" minOccurs="0"/>
+ <element name="locale" type="xsd:string" minOccurs="0"/>
+ <element name="requiresRewriting" type="xsd:boolean" default="false" minOccurs="0"/>
+ <element name="cacheControl" type="types:CacheControl" minOccurs="0"/>
+ <element name="clientAttributes" type="types:NamedString" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="ccppProfileWarning" type="xsd:string" use="optional"/>
+ </complexType>
+ <element name="MimeResponse" type="types:MimeResponse"/>
+
+ <complexType name="MarkupContext">
+ <complexContent>
+ <extension base="types:MimeResponse">
+ <sequence>
+ <element name="preferredTitle" type="xsd:string" minOccurs="0"/>
+ <element name="validNewModes" type="xsd:string" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </extension>
+ </complexContent>
+ </complexType>
+ <element name="MarkupContext" type="types:MarkupContext"/>
+
+ <complexType name="MarkupResponse">
+ <sequence>
+ <element name="markupContext" type="types:MarkupContext"/>
+ <element name="sessionContext" type="types:SessionContext" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+
+ <complexType name="ResourceContext">
+ <complexContent>
+ <extension base="types:MimeResponse">
+ <sequence/>
+ </extension>
+ </complexContent>
+ </complexType>
+ <element name="ResourceContext" type="types:ResourceContext"/>
+
+ <complexType name="ResourceResponse">
+ <sequence>
+ <element name="resourceContext" type="types:ResourceContext"/>
+ <element name="sessionContext" type="types:SessionContext" minOccurs="0"/>
+ <element name="portletContext" type="types:PortletContext" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+
+ <complexType name="CCPPProfileDiff">
+ <sequence>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="diffName" type="xsd:string" use="required"/>
+ <attribute name="description" type="xsd:string" use="required"/>
+ </complexType>
+ <element name="CCPPProfileDiff" type="types:CCPPProfileDiff"/>
+
+ <complexType name="CCPPHeaders">
+ <sequence>
+ <element name="profileDiffs" type="types:CCPPProfileDiff" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="profile" type="xsd:string" use="required"/>
+ </complexType>
+ <element name="CCPPHeaders" type="types:CCPPHeaders"/>
+
+ <complexType name="ClientData">
+ <sequence>
+ <element name="userAgent" type="xsd:string" minOccurs="0"/>
+ <element name="ccppHeaders" type="types:CCPPHeaders" minOccurs="0"/>
+ <element name="clientAttributes" type="types:NamedString" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="requestVerb" type="xsd:string" use="optional"/>
+ </complexType>
+ <element name="ClientData" type="types:ClientData"/>
+
+ <complexType name="CacheControl">
+ <sequence>
+ <element name="expires" type="xsd:int"/>
+ <element name="userScope" type="xsd:string"/>
+ <element name="validateTag" type="xsd:string" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+
+ <complexType name="Templates">
+ <sequence>
+ <element name="defaultTemplate" type="xsd:string" nillable="true"/>
+ <element name="blockingActionTemplate" type="xsd:string" minOccurs="0"/>
+ <element name="renderTemplate" type="xsd:string" minOccurs="0"/>
+ <element name="resourceTemplate" type="xsd:string" minOccurs="0"/>
+ <element name="secureDefaultTemplate" type="xsd:string" nillable="true"/>
+ <element name="secureBlockingActionTemplate" type="xsd:string" minOccurs="0"/>
+ <element name="secureRenderTemplate" type="xsd:string" minOccurs="0"/>
+ <element name="secureResourceTemplate" type="xsd:string" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="Templates" type="types:Templates"/>
+
+ <!-- - - - - - - - - - - - - - - -->
+ <!-- Interaction oriented types -->
+ <!-- - - - - - - - - - - - - - - -->
+
+ <simpleType name="StateChange">
+ <restriction base="xsd:string">
+ <enumeration value="readWrite"/>
+ <enumeration value="cloneBeforeWrite"/>
+ <enumeration value="readOnly"/>
+ </restriction>
+ </simpleType>
+
+ <complexType name="UploadContext">
+ <sequence>
+ <element name="mimeType" type="xsd:string"/>
+ <element name="uploadData" type="xsd:base64Binary"/>
+ <element name="mimeAttributes" type="types:NamedString" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+
+ <complexType name="InteractionParams">
+ <sequence>
+ <element name="portletStateChange" type="types:StateChange"/>
+ <element name="interactionState" type="xsd:string" minOccurs="0"/>
+ <element name="formParameters" type="types:NamedString" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="uploadContexts" type="types:UploadContext" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="InteractionParams" type="types:InteractionParams"/>
+
+ <complexType name="UpdateResponse">
+ <sequence>
+ <element name="sessionContext" type="types:SessionContext" minOccurs="0"/>
+ <element name="portletContext" type="types:PortletContext" minOccurs="0"/>
+ <element name="markupContext" type="types:MarkupContext" minOccurs="0"/>
+ <element name="events" type="types:Event" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="navigationalContext" type="types:NavigationalContext" minOccurs="0"/>
+ <element name="newWindowState" type="xsd:string" minOccurs="0"/>
+ <element name="newMode" type="xsd:string" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="UpdateResponse" type="types:UpdateResponse"/>
+
+ <complexType name="BlockingInteractionResponse">
+ <sequence>
+ <element name="updateResponse" type="types:UpdateResponse" minOccurs="0"/>
+ <element name="redirectURL" type="xsd:string" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="BlockingInteractionResponse" type="types:BlockingInteractionResponse"/>
+
+ <!-- - - - - - - - -->
+ <!-- Factory types -->
+ <!-- - - - - - - - -->
+
+ <complexType name="CopiedPortlet">
+ <sequence>
+ <element name="newPortletContext" type="types:PortletContext"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="fromPortletHandle" type="xsd:string" use="required"/>
+ </complexType>
+ <element name="CopiedPortlet" type="types:CopiedPortlet"/>
+
+ <complexType name="ExportedPortlet">
+ <sequence>
+ <element name="exportData" type="xsd:base64Binary"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="portletHandle" type="xsd:string" use="required"/>
+ </complexType>
+ <element name="ExportedPortlet" type="types:ExportedPortlet"/>
+
+ <complexType name="ImportPortlet">
+ <sequence>
+ <element name="exportData" type="xsd:base64Binary"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="importID" type="xsd:string" use="required"/>
+ </complexType>
+ <element name="ImportPortlet" type="types:ImportPortlet"/>
+
+ <complexType name="ImportedPortlet">
+ <sequence>
+ <element name="importID" type="xsd:string"/>
+ <element name="newPortletContext" type="types:PortletContext"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="ImportedPortlet" type="types:ImportedPortlet"/>
+
+ <complexType name="ImportPortletsFailed">
+ <complexContent>
+ <extension base="types:BaseFailed">
+ <sequence>
+ <element name="importID" type="xsd:string" maxOccurs="unbounded"/>
+ </sequence>
+ </extension>
+ </complexContent>
+ </complexType>
+ <element name="ImportPortletsFailed" type="types:ImportPortletsFailed"/>
+
+ <!-- - - - - - - - - - - -->
+ <!-- User Profile types -->
+ <!-- - - - - - - - - - - -->
+
+ <complexType name="Postal">
+ <sequence>
+ <element name="name" type="xsd:string" minOccurs="0"/>
+ <element name="street" type="xsd:string" minOccurs="0"/>
+ <element name="city" type="xsd:string" minOccurs="0"/>
+ <element name="stateprov" type="xsd:string" minOccurs="0"/>
+ <element name="postalcode" type="xsd:string" minOccurs="0"/>
+ <element name="country" type="xsd:string" minOccurs="0"/>
+ <element name="organization" type="xsd:string" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+
+ <complexType name="TelephoneNum">
+ <sequence>
+ <element name="intcode" type="xsd:string" minOccurs="0"/>
+ <element name="loccode" type="xsd:string" minOccurs="0"/>
+ <element name="number" type="xsd:string" minOccurs="0"/>
+ <element name="ext" type="xsd:string" minOccurs="0"/>
+ <element name="comment" type="xsd:string" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+
+ <complexType name="Telecom">
+ <sequence>
+ <element name="telephone" type="types:TelephoneNum" minOccurs="0"/>
+ <element name="fax" type="types:TelephoneNum" minOccurs="0"/>
+ <element name="mobile" type="types:TelephoneNum" minOccurs="0"/>
+ <element name="pager" type="types:TelephoneNum" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+
+ <complexType name="Online">
+ <sequence>
+ <element name="email" type="xsd:string" minOccurs="0"/>
+ <element name="uri" type="xsd:string" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+
+ <complexType name="Contact">
+ <sequence>
+ <element name="postal" type="types:Postal" minOccurs="0"/>
+ <element name="telecom" type="types:Telecom" minOccurs="0"/>
+ <element name="online" type="types:Online" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="Contact" type="types:Contact"/>
+
+ <complexType name="EmployerInfo">
+ <sequence>
+ <element name="employer" type="xsd:string" minOccurs="0"/>
+ <element name="department" type="xsd:string" minOccurs="0"/>
+ <element name="jobtitle" type="xsd:string" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+
+ <complexType name="PersonName">
+ <sequence>
+ <element name="prefix" type="xsd:string" minOccurs="0"/>
+ <element name="given" type="xsd:string" minOccurs="0"/>
+ <element name="family" type="xsd:string" minOccurs="0"/>
+ <element name="middle" type="xsd:string" minOccurs="0"/>
+ <element name="suffix" type="xsd:string" minOccurs="0"/>
+ <element name="nickname" type="xsd:string" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+
+ <complexType name="UserProfile">
+ <sequence>
+ <element name="name" type="types:PersonName" minOccurs="0"/>
+ <element name="bdate" type="xsd:dateTime" minOccurs="0"/>
+ <element name="gender" type="xsd:string" minOccurs="0"/>
+ <element name="employerInfo" type="types:EmployerInfo" minOccurs="0"/>
+ <element name="homeInfo" type="types:Contact" minOccurs="0"/>
+ <element name="businessInfo" type="types:Contact" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+
+ <complexType name="UserContext">
+ <sequence>
+ <element name="userContextKey" type="xsd:string"/>
+ <element name="userCategories" type="xsd:string" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="profile" type="types:UserProfile" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="UserContext" type="types:UserContext"/>
+
+ <!-- - - - - - - - - -->
+ <!-- Property types -->
+ <!-- - - - - - - - - -->
+
+ <complexType name="Property">
+ <sequence>
+ <element name="stringValue" type="xsd:string" minOccurs="0"/>
+ <any namespace="##other" minOccurs="0" maxOccurs="unbounded" processContents="lax"/>
+ </sequence>
+ <attribute name="name" type="xsd:QName" use="required"/>
+ <attribute name="type" type="xsd:QName" use="optional"/>
+ <!--<attribute ref="xsi:type" use="optional"/>-->
+ <attribute ref="xml:lang" use="optional"/>
+ </complexType>
+
+ <complexType name="ResetProperty">
+ <sequence/>
+ <attribute name="name" type="xsd:QName" use="required"/>
+ </complexType>
+
+ <complexType name="PropertyList">
+ <sequence>
+ <element name="properties" type="types:Property" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="resetProperties" type="types:ResetProperty" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="PropertyList" type="types:PropertyList"/>
+
+ <complexType name="PropertyDescription">
+ <sequence>
+ <element name="description" type="types:LocalizedString" minOccurs="0"/>
+ <element name="label" type="types:LocalizedString" minOccurs="0"/>
+ <element name="hint" type="types:LocalizedString" minOccurs="0"/>
+ <element name="usage" type="xsd:string" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="aliases" type="xsd:QName" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="name" type="xsd:QName" use="required"/>
+ <attribute name="type" type="xsd:QName" use="required"/>
+ <attribute name="schemaLocation" type="xsd:anyURI" use="optional"/>
+ </complexType>
+ <element name="PropertyDescription" type="types:PropertyDescription"/>
+
+ <complexType name="ParameterDescription">
+ <sequence>
+ <element name="names" type="xsd:QName" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="description" type="types:LocalizedString" minOccurs="0"/>
+ <element name="label" type="types:LocalizedString" minOccurs="0"/>
+ <element name="hint" type="types:LocalizedString" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="identifier" type="xsd:string" use="required"/>
+ </complexType>
+ <element name="ParameterDescription" type="types:ParameterDescription"/>
+
+ <complexType name="ModelTypes">
+ <sequence>
+ <any namespace="##other" processContents="lax"/>
+ </sequence>
+ </complexType>
+
+ <complexType name="ModelDescription">
+ <sequence>
+ <element name="propertyDescriptions" type="types:PropertyDescription" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="modelTypes" type="types:ModelTypes" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="ModelDescription" type="types:ModelDescription"/>
+
+ <!-- - - - - - - - - - - - - -->
+ <!-- operation message types -->
+ <!-- - - - - - - - - - - - - -->
+
+ <complexType name="ReturnAny">
+ <sequence>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+
+ <complexType name="getMarkup">
+ <sequence>
+ <element name="registrationContext" type="types:RegistrationContext" nillable="true"/>
+ <element name="portletContext" type="types:PortletContext"/>
+ <element name="runtimeContext" type="types:RuntimeContext"/>
+ <element name="userContext" type="types:UserContext" nillable="true"/>
+ <element name="markupParams" type="types:MarkupParams"/>
+ </sequence>
+ </complexType>
+ <element name="getMarkup" type="types:getMarkup"/>
+ <element name="getMarkupResponse" type="types:MarkupResponse"/>
+
+ <complexType name="getResource">
+ <sequence>
+ <element name="registrationContext" type="types:RegistrationContext" nillable="true"/>
+ <element name="portletContext" type="types:PortletContext"/>
+ <element name="runtimeContext" type="types:RuntimeContext"/>
+ <element name="userContext" type="types:UserContext" nillable="true"/>
+ <element name="resourceParams" type="types:ResourceParams"/>
+ </sequence>
+ </complexType>
+ <element name="getResource" type="types:getResource"/>
+ <element name="getResourceResponse" type="types:ResourceResponse"/>
+
+ <complexType name="performBlockingInteraction">
+ <sequence>
+ <element name="registrationContext" type="types:RegistrationContext" nillable="true"/>
+ <element name="portletContext" type="types:PortletContext"/>
+ <element name="runtimeContext" type="types:RuntimeContext"/>
+ <element name="userContext" type="types:UserContext" nillable="true"/>
+ <element name="markupParams" type="types:MarkupParams"/>
+ <element name="interactionParams" type="types:InteractionParams"/>
+ </sequence>
+ </complexType>
+ <element name="performBlockingInteraction" type="types:performBlockingInteraction"/>
+ <element name="performBlockingInteractionResponse" type="types:BlockingInteractionResponse"/>
+
+ <complexType name="handleEvents">
+ <sequence>
+ <element name="registrationContext" type="types:RegistrationContext" nillable="true"/>
+ <element name="portletContext" type="types:PortletContext"/>
+ <element name="runtimeContext" type="types:RuntimeContext"/>
+ <element name="userContext" type="types:UserContext" nillable="true"/>
+ <element name="markupParams" type="types:MarkupParams"/>
+ <element name="eventParams" type="types:EventParams"/>
+ </sequence>
+ </complexType>
+ <element name="handleEvents" type="types:handleEvents"/>
+ <complexType name="HandleEventsResponse">
+ <sequence>
+ <element name="updateResponse" type="types:UpdateResponse" minOccurs="0"/>
+ <element name="failedEvents" type="types:HandleEventsFailed" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="handleEventsResponse" type="types:HandleEventsResponse"/>
+
+ <complexType name="getServiceDescription">
+ <sequence>
+ <element name="registrationContext" type="types:RegistrationContext" nillable="true"/>
+ <element name="desiredLocales" type="xsd:string" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="portletHandles" type="xsd:string" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="userContext" type="types:UserContext" nillable="true"/>
+ </sequence>
+ </complexType>
+ <element name="getServiceDescription" type="types:getServiceDescription"/>
+ <element name="getServiceDescriptionResponse" type="types:ServiceDescription"/>
+
+ <complexType name="register">
+ <sequence>
+ <element name="registrationData" type="types:RegistrationData"/>
+ <element name="lifetime" type="types:Lifetime" nillable="true"/>
+ <element name="userContext" type="types:UserContext" nillable="true"/>
+ </sequence>
+ </complexType>
+ <element name="register" type="types:register"/>
+ <element name="registerResponse" type="types:RegistrationContext"/>
+
+ <complexType name="deregister">
+ <sequence>
+ <element name="registrationContext" type="types:RegistrationContext"/>
+ <element name="userContext" type="types:UserContext" nillable="true"/>
+ </sequence>
+ </complexType>
+ <element name="deregister" type="types:deregister"/>
+ <element name="deregisterResponse" type="types:ReturnAny"/>
+
+ <complexType name="modifyRegistration">
+ <sequence>
+ <element name="registrationContext" type="types:RegistrationContext" nillable="true"/>
+ <element name="registrationData" type="types:RegistrationData"/>
+ <element name="userContext" type="types:UserContext" nillable="true"/>
+ </sequence>
+ </complexType>
+ <element name="modifyRegistration" type="types:modifyRegistration"/>
+ <element name="modifyRegistrationResponse" type="types:RegistrationState"/>
+
+ <complexType name="getPortletDescription">
+ <sequence>
+ <element name="registrationContext" type="types:RegistrationContext" nillable="true"/>
+ <element name="portletContext" type="types:PortletContext"/>
+ <element name="userContext" type="types:UserContext" nillable="true"/>
+ <element name="desiredLocales" type="xsd:string" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="getPortletDescription" type="types:getPortletDescription"/>
+ <element name="getPortletDescriptionResponse" type="types:PortletDescriptionResponse"/>
+
+ <complexType name="clonePortlet">
+ <sequence>
+ <element name="registrationContext" type="types:RegistrationContext" nillable="true"/>
+ <element name="portletContext" type="types:PortletContext"/>
+ <element name="userContext" type="types:UserContext" nillable="true"/>
+ <element name="lifetime" type="types:Lifetime" nillable="true"/>
+ </sequence>
+ </complexType>
+ <element name="clonePortlet" type="types:clonePortlet"/>
+ <element name="clonePortletResponse" type="types:PortletContext"/>
+
+ <complexType name="copyPortlets">
+ <sequence>
+ <element name="toRegistrationContext" type="types:RegistrationContext" nillable="true"/>
+ <element name="toUserContext" type="types:UserContext" nillable="true"/>
+ <element name="fromRegistrationContext" type="types:RegistrationContext" nillable="true"/>
+ <element name="fromUserContext" type="types:UserContext" nillable="true"/>
+ <element name="fromPortletContexts" type="types:PortletContext" maxOccurs="unbounded"/>
+ <element name="lifetime" type="types:Lifetime" nillable="true"/>
+ </sequence>
+ </complexType>
+ <element name="copyPortlets" type="types:copyPortlets"/>
+
+ <complexType name="copyPortletsResponse">
+ <sequence>
+ <element name="copiedPortlets" type="types:CopiedPortlet" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="failedPortlets" type="types:FailedPortlets" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="resourceList" type="types:ResourceList" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="copyPortletsResponse" type="types:copyPortletsResponse"/>
+
+ <complexType name="exportPortlets">
+ <sequence>
+ <element name="registrationContext" type="types:RegistrationContext" nillable="true"/>
+ <element name="portletContext" type="types:PortletContext" maxOccurs="unbounded"/>
+ <element name="userContext" type="types:UserContext" nillable="true"/>
+ <element name="lifetime" type="types:Lifetime" nillable="true"/>
+ <element name="exportByValueRequired" type="xsd:boolean" minOccurs="0" default="false"/>
+ </sequence>
+ </complexType>
+ <element name="exportPortlets" type="types:exportPortlets"/>
+
+ <complexType name="exportPortletsResponse">
+ <sequence>
+ <element name="exportContext" type="xsd:base64Binary" nillable="true"/>
+ <element name="exportedPortlet" type="types:ExportedPortlet" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="failedPortlets" type="types:FailedPortlets" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="lifetime" type="types:Lifetime" minOccurs="0"/>
+ <element name="resourceList" type="types:ResourceList" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="exportPortletsResponse" type="types:exportPortletsResponse"/>
+
+ <complexType name="importPortlets">
+ <sequence>
+ <element name="registrationContext" type="types:RegistrationContext" nillable="true"/>
+ <element name="importContext" type="xsd:base64Binary" nillable="true"/>
+ <element name="importPortlet" type="types:ImportPortlet" maxOccurs="unbounded"/>
+ <element name="userContext" type="types:UserContext" nillable="true"/>
+ <element name="lifetime" type="types:Lifetime" nillable="true"/>
+ </sequence>
+ </complexType>
+ <element name="importPortlets" type="types:importPortlets"/>
+
+ <complexType name="importPortletsResponse">
+ <sequence>
+ <element name="importedPortlets" type="types:ImportedPortlet" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="importFailed" type="types:ImportPortletsFailed" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="resourceList" type="types:ResourceList" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="importPortletsResponse" type="types:importPortletsResponse"/>
+
+ <complexType name="releaseExport">
+ <sequence>
+ <element name="registrationContext" type="types:RegistrationContext" nillable="true"/>
+ <element name="exportContext" type="xsd:base64Binary"/>
+ <element name="userContext" type="types:UserContext" nillable="true"/>
+ </sequence>
+ </complexType>
+ <element name="releaseExport" type="types:releaseExport"/>
+ <element name="releaseExportResponse" type="types:ReturnAny" nillable="true"/>
+
+ <complexType name="setExportLifetime">
+ <sequence>
+ <element name="registrationContext" type="types:RegistrationContext" nillable="true"/>
+ <element name="exportContext" type="xsd:base64Binary"/>
+ <element name="userContext" type="types:UserContext" nillable="true"/>
+ <element name="lifetime" type="types:Lifetime" nillable="true"/>
+ </sequence>
+ </complexType>
+ <element name="setExportLifetime" type="types:setExportLifetime"/>
+ <element name="setExportLifetimeResponse" type="types:Lifetime" nillable="true"/>
+
+ <complexType name="destroyPortlets">
+ <sequence>
+ <element name="registrationContext" type="types:RegistrationContext" nillable="true"/>
+ <element name="portletHandles" type="xsd:string" maxOccurs="unbounded"/>
+ <element name="userContext" type="types:UserContext" nillable="true"/>
+ </sequence>
+ </complexType>
+ <element name="destroyPortlets" type="types:destroyPortlets"/>
+
+ <complexType name="DestroyPortletsResponse">
+ <sequence>
+ <element name="failedPortlets" type="types:FailedPortlets" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="destroyPortletsResponse" type="types:DestroyPortletsResponse"/>
+
+ <complexType name="setPortletProperties">
+ <sequence>
+ <element name="registrationContext" type="types:RegistrationContext" nillable="true"/>
+ <element name="portletContext" type="types:PortletContext"/>
+ <element name="userContext" type="types:UserContext" nillable="true"/>
+ <element name="propertyList" type="types:PropertyList"/>
+ </sequence>
+ </complexType>
+ <element name="setPortletProperties" type="types:setPortletProperties"/>
+ <element name="setPortletPropertiesResponse" type="types:PortletContext"/>
+
+ <complexType name="getPortletProperties">
+ <sequence>
+ <element name="registrationContext" type="types:RegistrationContext" nillable="true"/>
+ <element name="portletContext" type="types:PortletContext"/>
+ <element name="userContext" type="types:UserContext" nillable="true"/>
+ <element name="names" type="xsd:string" nillable="true" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="getPortletProperties" type="types:getPortletProperties"/>
+ <element name="getPortletPropertiesResponse" type="types:PropertyList"/>
+
+ <complexType name="getPortletPropertyDescription">
+ <sequence>
+ <element name="registrationContext" type="types:RegistrationContext" nillable="true"/>
+ <element name="portletContext" type="types:PortletContext"/>
+ <element name="userContext" type="types:UserContext" nillable="true"/>
+ <element name="desiredLocales" type="xsd:string" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="getPortletPropertyDescription" type="types:getPortletPropertyDescription"/>
+
+ <complexType name="PortletPropertyDescriptionResponse">
+ <sequence>
+ <element name="modelDescription" type="types:ModelDescription" minOccurs="0"/>
+ <element name="resourceList" type="types:ResourceList" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="getPortletPropertyDescriptionResponse" type="types:PortletPropertyDescriptionResponse"/>
+
+ <complexType name="releaseSessions">
+ <sequence>
+ <element name="registrationContext" type="types:RegistrationContext" nillable="true"/>
+ <element name="sessionIDs" type="xsd:string" maxOccurs="unbounded"/>
+ <element name="userContext" type="types:UserContext" nillable="true"/>
+ </sequence>
+ </complexType>
+ <element name="releaseSessions" type="types:releaseSessions"/>
+ <element name="releaseSessionsResponse" type="types:ReturnAny"/>
+
+ <complexType name="initCookie">
+ <sequence>
+ <element name="registrationContext" type="types:RegistrationContext" nillable="true"/>
+ <element name="userContext" type="types:UserContext" nillable="true"/>
+ </sequence>
+ </complexType>
+ <element name="initCookie" type="types:initCookie"/>
+ <element name="initCookieResponse" type="types:ReturnAny"/>
+
+ <complexType name="getRegistrationLifetime">
+ <sequence>
+ <element name="registrationContext" type="types:RegistrationContext" nillable="true"/>
+ <element name="userContext" type="types:UserContext" nillable="true"/>
+ </sequence>
+ </complexType>
+ <element name="getRegistrationLifetime" type="types:getRegistrationLifetime"/>
+ <element name="getRegistrationLifetimeResponse" type="types:Lifetime" nillable="true"/>
+
+ <complexType name="setRegistrationLifetime">
+ <sequence>
+ <element name="registrationContext" type="types:RegistrationContext" nillable="true"/>
+ <element name="userContext" type="types:UserContext" nillable="true"/>
+ <element name="lifetime" type="types:Lifetime" nillable="true"/>
+ </sequence>
+ </complexType>
+ <element name="setRegistrationLifetime" type="types:setRegistrationLifetime"/>
+ <element name="setRegistrationLifetimeResponse" type="types:Lifetime" nillable="true"/>
+
+ <complexType name="getPortletsLifetime">
+ <sequence>
+ <element name="registrationContext" type="types:RegistrationContext" nillable="true"/>
+ <element name="portletContext" type="types:PortletContext" maxOccurs="unbounded"/>
+ <element name="userContext" type="types:UserContext" nillable="true"/>
+ </sequence>
+ </complexType>
+ <element name="getPortletsLifetime" type="types:getPortletsLifetime"/>
+
+ <complexType name="getPortletsLifetimeResponse">
+ <sequence>
+ <element name="portletLifetime" type="types:PortletLifetime" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="failedPortlets" type="types:FailedPortlets" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="resourceList" type="types:ResourceList" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="getPortletsLifetimeResponse" type="types:getPortletsLifetimeResponse" nillable="true"/>
+
+ <complexType name="setPortletsLifetime">
+ <sequence>
+ <element name="registrationContext" type="types:RegistrationContext" nillable="true"/>
+ <element name="portletContext" type="types:PortletContext" maxOccurs="unbounded"/>
+ <element name="userContext" type="types:UserContext" nillable="true"/>
+ <element name="lifetime" type="types:Lifetime" nillable="true"/>
+ </sequence>
+ </complexType>
+ <element name="setPortletsLifetime" type="types:setPortletsLifetime"/>
+
+ <complexType name="setPortletsLifetimeResponse">
+ <sequence>
+ <element name="updatedPortlet" type="types:PortletLifetime" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="failedPortlets" type="types:FailedPortlets" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="resourceList" type="types:ResourceList" minOccurs="0"/>
+ <element name="extensions" type="types:Extension" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <element name="setPortletsLifetimeResponse" type="types:setPortletsLifetimeResponse"/>
+
+ <!-- - - - - - - -->
+ <!-- fault types -->
+ <!-- - - - - - - -->
+
+ <complexType name="Fault">
+ <sequence/>
+ </complexType>
+
+ <complexType name="AccessDeniedFault">
+ <complexContent>
+ <extension base="types:Fault">
+ <sequence/>
+ </extension>
+ </complexContent>
+ </complexType>
+ <element name="AccessDenied" type="types:AccessDeniedFault"/>
+
+ <complexType name="InconsistentParametersFault">
+ <complexContent>
+ <extension base="types:Fault">
+ <sequence/>
+ </extension>
+ </complexContent>
+ </complexType>
+ <element name="InconsistentParameters" type="types:InconsistentParametersFault"/>
+
+ <complexType name="InvalidRegistrationFault">
+ <complexContent>
+ <extension base="types:Fault">
+ <sequence/>
+ </extension>
+ </complexContent>
+ </complexType>
+ <element name="InvalidRegistration" type="types:InvalidRegistrationFault"/>
+
+ <complexType name="MissingParametersFault">
+ <complexContent>
+ <extension base="types:Fault">
+ <sequence/>
+ </extension>
+ </complexContent>
+ </complexType>
+ <element name="MissingParameters" type="types:MissingParametersFault"/>
+
+ <complexType name="OperationFailedFault">
+ <complexContent>
+ <extension base="types:Fault">
+ <sequence/>
+ </extension>
+ </complexContent>
+ </complexType>
+ <element name="OperationFailed" type="types:OperationFailedFault"/>
+
+ <complexType name="InvalidHandleFault">
+ <complexContent>
+ <extension base="types:Fault">
+ <sequence/>
+ </extension>
+ </complexContent>
+ </complexType>
+ <element name="InvalidHandle" type="types:InvalidHandleFault"/>
+
+ <complexType name="InvalidUserCategoryFault">
+ <complexContent>
+ <extension base="types:Fault">
+ <sequence/>
+ </extension>
+ </complexContent>
+ </complexType>
+ <element name="InvalidUserCategory" type="types:InvalidUserCategoryFault"/>
+
+ <complexType name="PortletStateChangeRequiredFault">
+ <complexContent>
+ <extension base="types:Fault">
+ <sequence/>
+ </extension>
+ </complexContent>
+ </complexType>
+
+ <element name="PortletStateChangeRequired" type="types:PortletStateChangeRequiredFault"/>
+
+ <complexType name="InvalidCookieFault">
+ <complexContent>
+ <extension base="types:Fault">
+ <sequence/>
+ </extension>
+ </complexContent>
+ </complexType>
+
+ <element name="InvalidCookie" type="types:InvalidCookieFault"/>
+
+ <complexType name="InvalidSessionFault">
+ <complexContent>
+ <extension base="types:Fault">
+ <sequence/>
+ </extension>
+ </complexContent>
+ </complexType>
+
+ <element name="InvalidSession" type="types:InvalidSessionFault"/>
+
+ <complexType name="UnsupportedModeFault">
+ <complexContent>
+ <extension base="types:Fault">
+ <sequence/>
+ </extension>
+ </complexContent>
+ </complexType>
+ <element name="UnsupportedMode" type="types:UnsupportedModeFault"/>
+
+ <complexType name="UnsupportedWindowStateFault">
+ <complexContent>
+ <extension base="types:Fault">
+ <sequence/>
+ </extension>
+ </complexContent>
+ </complexType>
+ <element name="UnsupportedWindowState" type="types:UnsupportedWindowStateFault"/>
+
+ <complexType name="UnsupportedLocaleFault">
+ <complexContent>
+ <extension base="types:Fault">
+ <sequence/>
+ </extension>
+ </complexContent>
+ </complexType>
+ <element name="UnsupportedLocale" type="types:UnsupportedLocaleFault"/>
+
+ <complexType name="UnsupportedMimeTypeFault">
+ <complexContent>
+ <extension base="types:Fault">
+ <sequence/>
+ </extension>
+ </complexContent>
+ </complexType>
+ <element name="UnsupportedMimeType" type="types:UnsupportedMimeTypeFault"/>
+
+ <complexType name="ModifyRegistrationRequiredFault">
+ <complexContent>
+ <extension base="types:Fault">
+ <sequence/>
+ </extension>
+ </complexContent>
+ </complexType>
+ <element name="ModifyRegistrationRequired" type="types:ModifyRegistrationRequiredFault"/>
+
+ <complexType name="ResourceSuspendedFault">
+ <complexContent>
+ <extension base="types:Fault">
+ <sequence/>
+ </extension>
+ </complexContent>
+ </complexType>
+ <element name="ResourceSuspended" type="types:ResourceSuspendedFault"/>
+
+ <complexType name="OperationNotSupportedFault">
+ <complexContent>
+ <extension base="types:Fault">
+ <sequence/>
+ </extension>
+ </complexContent>
+ </complexType>
+ <element name="OperationNotSupported" type="types:OperationNotSupportedFault"/>
+
+ <complexType name="ExportByValueNotSupportedFault">
+ <complexContent>
+ <extension base="types:Fault">
+ <sequence/>
+ </extension>
+ </complexContent>
+ </complexType>
+ <element name="ExportByValueNotSupported" type="types:ExportByValueNotSupportedFault"/>
+
+ <complexType name="ExportNoLongerValidFault">
+ <complexContent>
+ <extension base="types:Fault">
+ <sequence/>
+ </extension>
+ </complexContent>
+ </complexType>
+ <element name="ExportNoLongerValid" type="types:ExportNoLongerValidFault"/>
+
+ <!-- - - - - - - - - - - - -->
+ <!-- WSRP defined events -->
+ <!-- - - - - - - - - - - - -->
+ <element name="eventHandlingFailed">
+ <complexType>
+ <sequence>
+ <any minOccurs="0" processContents="lax"/>
+ </sequence>
+ </complexType>
+ </element>
+
+ <element name="newNavigationalContextScope">
+ <complexType>
+ <sequence>
+ <any minOccurs="0" processContents="lax"/>
+ </sequence>
+ </complexType>
+ </element>
+
+ <element name="newMode">
+ <complexType>
+ <sequence>
+ <any minOccurs="0" processContents="lax"/>
+ </sequence>
+ </complexType>
+ </element>
+
+ <element name="newWindowState">
+ <complexType>
+ <sequence>
+ <any minOccurs="0" processContents="lax"/>
+ </sequence>
+ </complexType>
+ </element>
+
+</schema>
14 years, 7 months
gatein SVN: r3212 - portal/trunk/portlet/exoadmin/src/main/webapp/WEB-INF/classes/locale/portlet/exoadmin.
by do-not-reply@jboss.org
Author: kien_nguyen
Date: 2010-05-28 03:31:38 -0400 (Fri, 28 May 2010)
New Revision: 3212
Modified:
portal/trunk/portlet/exoadmin/src/main/webapp/WEB-INF/classes/locale/portlet/exoadmin/RegisterPortlet_fr.properties
Log:
GTNPORTAL-964 Translation problem in register portlet
Modified: portal/trunk/portlet/exoadmin/src/main/webapp/WEB-INF/classes/locale/portlet/exoadmin/RegisterPortlet_fr.properties
===================================================================
--- portal/trunk/portlet/exoadmin/src/main/webapp/WEB-INF/classes/locale/portlet/exoadmin/RegisterPortlet_fr.properties 2010-05-27 19:22:20 UTC (rev 3211)
+++ portal/trunk/portlet/exoadmin/src/main/webapp/WEB-INF/classes/locale/portlet/exoadmin/RegisterPortlet_fr.properties 2010-05-28 07:31:38 UTC (rev 3212)
@@ -28,6 +28,8 @@
UIRegisterForm.label.lastName=Nom:
UIRegisterForm.label.emailAddress=Addresse EMail:
UIRegisterForm.label.captcha=Texte de vérification:
+UIRegisterForm.action.Subscribe=S'abonner
+UIRegisterForm.action.Reset=R\u00e9initialiser
UIRegisterEditMode.title=Préférences de la portlet d'enregistrement
UIRegisterEditMode.label.useCaptcha=Utiliser captcha:
14 years, 7 months
gatein SVN: r3211 - portal/branches.
by do-not-reply@jboss.org
Author: chris.laprun(a)jboss.com
Date: 2010-05-27 15:22:20 -0400 (Thu, 27 May 2010)
New Revision: 3211
Removed:
portal/branches/wsrp-integration/
Log:
Removing obsolete branch
14 years, 7 months
gatein SVN: r3210 - portal/branches.
by do-not-reply@jboss.org
Author: chris.laprun(a)jboss.com
Date: 2010-05-27 15:12:49 -0400 (Thu, 27 May 2010)
New Revision: 3210
Added:
portal/branches/wsrp2-integration/
Log:
Creating branch to work on WSRP 2 integration.
Copied: portal/branches/wsrp2-integration (from rev 3209, portal/trunk)
14 years, 7 months
gatein SVN: r3209 - in components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp: protocol/v1 and 7 other directories.
by do-not-reply@jboss.org
Author: chris.laprun(a)jboss.com
Date: 2010-05-27 12:51:39 -0400 (Thu, 27 May 2010)
New Revision: 3209
Added:
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/BehaviorBackedServiceFactory.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/BehaviorRegistry.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/TestWSRPProducer.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/TestWSRPProducerImpl.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/BehaviorBackedServiceFactory.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/BehaviorRegistry.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/MarkupBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/PortletManagementBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/RegistrationBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/ServiceDescriptionBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/TestProducerBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/TestWSRPProducer.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/TestWSRPProducerImpl.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/BasicMarkupBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/BasicPortletManagementBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/BasicServiceDescriptionBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/DestroyClonesPortletManagementBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/EmptyMarkupBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/GroupedPortletsServiceDescriptionBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/InitCookieMarkupBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/InitCookieNotRequiredMarkupBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/NullMarkupBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/PerGroupInitCookieMarkupBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/PerUserInitCookieMarkupBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/ResourceMarkupBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/SessionMarkupBehavior.java
Removed:
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/BehaviorRegistry.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/TestWSRPProducer.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/TestWSRPProducerImpl.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/support/BehaviorBackedServiceFactory.java
Modified:
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/EndpointConfigurationInfoTestCase.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/ProducerInfoTestCase.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/RegistrationInfoTestCase.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/RegistrationPropertyTestCase.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/WSRPConsumerBaseTest.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/protocol/v1/InteropServiceDescriptionTestCase.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/protocol/v1/MarkupTestCase.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/protocol/v1/PortletManagementTestCase.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/MarkupBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/BasicMarkupBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/BasicPortletManagementBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/DestroyClonesPortletManagementBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/EmptyMarkupBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/InitCookieMarkupBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/InitCookieNotRequiredMarkupBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/NullMarkupBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/PerGroupInitCookieMarkupBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/PerUserInitCookieMarkupBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/ResourceMarkupBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/SessionMarkupBehavior.java
components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/support/MockEndpointConfigurationInfo.java
Log:
- Duplicated TestWSRPProducer and behavior structure for WSRP 2 so that both versions of the protocol can be tested.
- Moved classes so that we can isolate classes that can only work with one version of the protocol in a specific package (not completely done).
- Activated tests should now all pass.
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/EndpointConfigurationInfoTestCase.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/EndpointConfigurationInfoTestCase.java 2010-05-27 07:15:18 UTC (rev 3208)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/EndpointConfigurationInfoTestCase.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -26,7 +26,7 @@
import junit.framework.TestCase;
import org.gatein.pc.api.InvokerUnavailableException;
import org.gatein.wsrp.services.ServiceFactory;
-import org.gatein.wsrp.test.support.BehaviorBackedServiceFactory;
+import org.gatein.wsrp.test.protocol.v2.BehaviorBackedServiceFactory;
/**
* @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/ProducerInfoTestCase.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/ProducerInfoTestCase.java 2010-05-27 07:15:18 UTC (rev 3208)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/ProducerInfoTestCase.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -25,34 +25,36 @@
import junit.framework.TestCase;
import org.gatein.pc.api.Portlet;
-import org.gatein.pc.api.PortletContext;
import org.gatein.pc.api.PortletInvokerException;
-import org.gatein.wsrp.spec.v1.WSRP1ExceptionFactory;
-import org.gatein.wsrp.test.protocol.v1.PortletManagementBehavior;
-import org.gatein.wsrp.test.protocol.v1.RegistrationBehavior;
-import org.gatein.wsrp.test.protocol.v1.ServiceDescriptionBehavior;
-import org.gatein.wsrp.test.support.BehaviorBackedServiceFactory;
+import org.gatein.wsrp.WSRPExceptionFactory;
+import org.gatein.wsrp.test.protocol.v2.BehaviorBackedServiceFactory;
+import org.gatein.wsrp.test.protocol.v2.PortletManagementBehavior;
+import org.gatein.wsrp.test.protocol.v2.RegistrationBehavior;
+import org.gatein.wsrp.test.protocol.v2.ServiceDescriptionBehavior;
import org.gatein.wsrp.test.support.MockConsumerRegistry;
-import org.oasis.wsrp.v1.V1AccessDenied;
-import org.oasis.wsrp.v1.V1Extension;
-import org.oasis.wsrp.v1.V1InconsistentParameters;
-import org.oasis.wsrp.v1.V1InvalidHandle;
-import org.oasis.wsrp.v1.V1InvalidRegistration;
-import org.oasis.wsrp.v1.V1InvalidRegistrationFault;
-import org.oasis.wsrp.v1.V1InvalidUserCategory;
-import org.oasis.wsrp.v1.V1MissingParameters;
-import org.oasis.wsrp.v1.V1OperationFailed;
-import org.oasis.wsrp.v1.V1OperationFailedFault;
-import org.oasis.wsrp.v1.V1PortletContext;
-import org.oasis.wsrp.v1.V1PortletDescription;
-import org.oasis.wsrp.v1.V1Property;
-import org.oasis.wsrp.v1.V1RegistrationContext;
-import org.oasis.wsrp.v1.V1RegistrationData;
-import org.oasis.wsrp.v1.V1ResourceList;
-import org.oasis.wsrp.v1.V1UserContext;
+import org.oasis.wsrp.v2.AccessDenied;
+import org.oasis.wsrp.v2.Extension;
+import org.oasis.wsrp.v2.InconsistentParameters;
+import org.oasis.wsrp.v2.InvalidHandle;
+import org.oasis.wsrp.v2.InvalidRegistration;
+import org.oasis.wsrp.v2.InvalidRegistrationFault;
+import org.oasis.wsrp.v2.InvalidUserCategory;
+import org.oasis.wsrp.v2.Lifetime;
+import org.oasis.wsrp.v2.MissingParameters;
+import org.oasis.wsrp.v2.OperationFailed;
+import org.oasis.wsrp.v2.OperationFailedFault;
+import org.oasis.wsrp.v2.OperationNotSupported;
+import org.oasis.wsrp.v2.PortletContext;
+import org.oasis.wsrp.v2.PortletDescription;
+import org.oasis.wsrp.v2.Property;
import org.oasis.wsrp.v2.RegistrationContext;
+import org.oasis.wsrp.v2.RegistrationData;
+import org.oasis.wsrp.v2.ResourceList;
+import org.oasis.wsrp.v2.ResourceSuspended;
+import org.oasis.wsrp.v2.UserContext;
import javax.jws.WebParam;
+import javax.xml.namespace.QName;
import javax.xml.ws.Holder;
import java.util.List;
@@ -173,14 +175,14 @@
// activate caching for this test so that we can simulate portlet deployment on the producer with a cached SD
info.setExpirationCacheSeconds(1000);
- PortletContext portletContext = PortletContext.createPortletContext("test");
+ org.gatein.pc.api.PortletContext portletContext = org.gatein.pc.api.PortletContext.createPortletContext("test");
Portlet portlet = info.getPortlet(portletContext);
assertNotNull(portlet);
assertEquals(portletContext, portlet.getContext());
assertEquals(1, behavior.getCallCount());
// test2 is not in the service description, so it should be looked up via Portlet Management...
- portletContext = PortletContext.createPortletContext("test2");
+ portletContext = org.gatein.pc.api.PortletContext.createPortletContext("test2");
// add portlet management behavior
TestPortletManagementBehavior pmBehavior = new TestPortletManagementBehavior();
serviceFactory.getRegistry().setPortletManagementBehavior(pmBehavior);
@@ -193,7 +195,7 @@
serviceFactory.getRegistry().setPortletManagementBehavior(null);
// simulate a new portlet deployment since last time the SD was refreshed
behavior.addPortletDescription(behavior.createPortletDescription("test3", null));
- portletContext = PortletContext.createPortletContext("test3");
+ portletContext = org.gatein.pc.api.PortletContext.createPortletContext("test3");
portlet = info.getPortlet(portletContext);
assertEquals(2, behavior.getCallCount());
assertNotNull(portlet);
@@ -355,8 +357,9 @@
private static class TestPortletManagementBehavior extends PortletManagementBehavior
{
+
@Override
- public void getPortletDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> desiredLocales, @WebParam(name = "portletDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types", mode = WebParam.Mode.OUT) Holder<V1PortletDescription> portletDescription, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types", mode = WebParam.Mode.OUT) Holder<V1ResourceList> resourceList, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types", mode = WebParam.Mode.OUT) Holder<List<V1Extension>> ext!
ensions) throws V1AccessDenied, V1InconsistentParameters, V1InvalidHandle, V1InvalidRegistration, V1InvalidUserCategory, V1MissingParameters, V1OperationFailed
+ public void getPortletDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> desiredLocales, @WebParam(mode = WebParam.Mode.OUT, name = "portletDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<PortletDescription> portletDescription, @WebParam(mode = WebParam.Mode.OUT, name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<ResourceList> resourceList, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions) thr!
ows MissingParameters, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, AccessDenied, OperationFailed
{
super.getPortletDescription(registrationContext, portletContext, userContext, desiredLocales, portletDescription, resourceList, extensions);
portletDescription.value = createPortletDescription("test2", null);
@@ -365,41 +368,41 @@
private static class TestRegistrationBehavior extends RegistrationBehavior
{
- private static final String PROP_NAME = "prop0";
+ private static final QName PROP_NAME = QName.valueOf("prop0");
private static final String MODIFIED_VALUE = "value2";
private static final String ORIGINAL_VALUE = "value";
@Override
- public void register(@WebParam(name = "consumerName", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") String consumerName, @WebParam(name = "consumerAgent", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") String consumerAgent, @WebParam(name = "methodGetSupported", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") boolean methodGetSupported, @WebParam(name = "consumerModes", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> consumerModes, @WebParam(name = "consumerWindowStates", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> consumerWindowStates, @WebParam(name = "consumerUserScopes", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> consumerUserScopes, @WebParam(name = "customUserProfileData", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> customUserProfileData, @WebParam(name = "registrationProperties", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<V1Property> regi!
strationProperties, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types", mode = WebParam.Mode.INOUT) Holder<List<V1Extension>> extensions, @WebParam(name = "registrationHandle", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types", mode = WebParam.Mode.OUT) Holder<String> registrationHandle, @WebParam(name = "registrationState", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types", mode = WebParam.Mode.OUT) Holder<byte[]> registrationState) throws V1MissingParameters, V1OperationFailed
+ public void register(@WebParam(name = "registrationData", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationData registrationData, @WebParam(name = "lifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") Lifetime lifetime, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "registrationState", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<byte[]> registrationState, @WebParam(name = "scheduledDestruction", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<Lifetime> scheduledDestruction, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions, @WebParam(name = "registrationHandle", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<String> registrationHandle) throws Mi!
ssingParameters, OperationFailed, OperationNotSupported
{
- V1Property prop = checkRegistrationData(registrationProperties);
+ Property prop = checkRegistrationData(registrationData.getRegistrationProperties());
String value = prop.getStringValue();
if (ORIGINAL_VALUE.equals(value) && PROP_NAME.equals(prop.getName()))
{
- super.register(consumerName, consumerAgent, methodGetSupported, consumerModes, consumerWindowStates, consumerUserScopes, customUserProfileData, registrationProperties, extensions, registrationHandle, registrationState);
+ super.register(registrationData, lifetime, userContext, registrationState, scheduledDestruction, extensions, registrationHandle);
return;
}
- throw WSRP1ExceptionFactory.<V1OperationFailed, V1OperationFailedFault>throwWSException(WSRP1ExceptionFactory.OPERATION_FAILED,
+ throw WSRPExceptionFactory.<OperationFailed, OperationFailedFault>throwWSException(WSRPExceptionFactory.OPERATION_FAILED,
value + " is not a valid value for " + PROP_NAME, null);
}
@Override
- public void modifyRegistration(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext, @WebParam(name = "registrationData", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationData registrationData, @WebParam(name = "registrationState", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types", mode = WebParam.Mode.OUT) Holder<byte[]> registrationState, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types", mode = WebParam.Mode.OUT) Holder<List<V1Extension>> extensions) throws V1InvalidRegistration, V1MissingParameters, V1OperationFailed
+ public void modifyRegistration(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "registrationData", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationData registrationData, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "registrationState", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<byte[]> registrationState, @WebParam(name = "scheduledDestruction", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<Lifetime> scheduledDestruction, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws InvalidRegistration, MissingParameters, OperationFailed, OperationNotSupported, ResourceSuspended
{
incrementCallCount();
- WSRP1ExceptionFactory.throwMissingParametersIfValueIsMissing(registrationContext, "RegistrationContext", null);
+ WSRPExceptionFactory.throwMissingParametersIfValueIsMissing(registrationContext, "RegistrationContext", null);
if (!RegistrationBehavior.REGISTRATION_HANDLE.equals(registrationContext.getRegistrationHandle()))
{
- WSRP1ExceptionFactory.<V1InvalidRegistration, V1InvalidRegistrationFault>throwWSException(WSRP1ExceptionFactory.INVALID_REGISTRATION, "Invalid registration", null);
+ WSRPExceptionFactory.<InvalidRegistration, InvalidRegistrationFault>throwWSException(WSRPExceptionFactory.INVALID_REGISTRATION, "Invalid registration", null);
}
- WSRP1ExceptionFactory.throwMissingParametersIfValueIsMissing(registrationData, "RegistrationData", null);
+ WSRPExceptionFactory.throwMissingParametersIfValueIsMissing(registrationData, "RegistrationData", null);
- V1Property prop = checkRegistrationData(registrationData.getRegistrationProperties());
+ Property prop = checkRegistrationData(registrationData.getRegistrationProperties());
String value = prop.getStringValue();
if (MODIFIED_VALUE.equals(value) && PROP_NAME.equals(prop.getName()))
@@ -407,16 +410,17 @@
return;
}
- throw WSRP1ExceptionFactory.<V1OperationFailed, V1OperationFailedFault>throwWSException(WSRP1ExceptionFactory.OPERATION_FAILED, value
+ throw WSRPExceptionFactory.<OperationFailed, OperationFailedFault>throwWSException(WSRPExceptionFactory.OPERATION_FAILED, value
+ " is not a valid value for " + PROP_NAME, null);
+
}
- private V1Property checkRegistrationData(List<V1Property> registrationProperties) throws V1OperationFailed
+ private Property checkRegistrationData(List<Property> registrationProperties) throws OperationFailed
{
- WSRP1ExceptionFactory.throwOperationFailedIfValueIsMissing(registrationProperties, "RegistrationData");
+ WSRPExceptionFactory.throwOperationFailedIfValueIsMissing(registrationProperties, "RegistrationData");
- V1Property prop = registrationProperties.get(0);
- WSRP1ExceptionFactory.throwOperationFailedIfValueIsMissing(prop, "Registration property");
+ Property prop = registrationProperties.get(0);
+ WSRPExceptionFactory.throwOperationFailedIfValueIsMissing(prop, "Registration property");
return prop;
}
}
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/RegistrationInfoTestCase.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/RegistrationInfoTestCase.java 2010-05-27 07:15:18 UTC (rev 3208)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/RegistrationInfoTestCase.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -26,8 +26,7 @@
import junit.framework.TestCase;
import org.gatein.wsrp.WSRPConstants;
import org.gatein.wsrp.WSRPTypeFactory;
-import org.gatein.wsrp.spec.v1.V2V1Converter;
-import org.gatein.wsrp.test.protocol.v1.ServiceDescriptionBehavior;
+import org.gatein.wsrp.test.protocol.v2.ServiceDescriptionBehavior;
import org.oasis.wsrp.v2.Property;
import org.oasis.wsrp.v2.RegistrationContext;
import org.oasis.wsrp.v2.RegistrationData;
@@ -249,10 +248,15 @@
assertEquals(1, result.getRegistrationProperties().size());
assertFalse(info.isModifyRegistrationNeeded());
- Map regProps = result.getRegistrationProperties();
+ checkProperties(result);
+ }
+
+ private void checkProperties(RegistrationInfo.RegistrationRefreshResult result)
+ {
+ Map<QName, RegistrationProperty> regProps = result.getRegistrationProperties();
assertNotNull(regProps);
- RegistrationProperty prop = (RegistrationProperty)regProps.get("foo");
+ RegistrationProperty prop = regProps.get(QName.valueOf("foo"));
assertNotNull(prop);
assertEquals("bar", prop.getValue());
assertTrue(prop.isInvalid());
@@ -276,14 +280,7 @@
assertEquals(1, result.getRegistrationProperties().size());
assertTrue(info.isModifyRegistrationNeeded());
- Map regProps = result.getRegistrationProperties();
- assertNotNull(regProps);
-
- RegistrationProperty prop = (RegistrationProperty)regProps.get("foo");
- assertNotNull(prop);
- assertEquals("bar", prop.getValue());
- assertTrue(prop.isInvalid());
- assertEquals(RegistrationProperty.Status.INEXISTENT, prop.getStatus());
+ checkProperties(result);
}
public void testRefreshRegistrationRegistrationNoLocalInfo()
@@ -299,14 +296,14 @@
assertEquals(2, result.getRegistrationProperties().size());
assertFalse(info.isModifyRegistrationNeeded()); // we weren't registered
- Map regProps = result.getRegistrationProperties();
+ Map<QName, RegistrationProperty> regProps = result.getRegistrationProperties();
assertNotNull(regProps);
- RegistrationProperty prop = (RegistrationProperty)regProps.get("prop0");
+ RegistrationProperty prop = regProps.get(QName.valueOf("prop0"));
assertNotNull(prop);
assertTrue(prop.isInvalid());
assertEquals(RegistrationProperty.Status.MISSING, prop.getStatus());
- prop = (RegistrationProperty)regProps.get("prop1");
+ prop = regProps.get(QName.valueOf("prop1"));
assertNotNull(prop);
assertTrue(prop.isInvalid());
assertEquals(RegistrationProperty.Status.MISSING, prop.getStatus());
@@ -327,14 +324,14 @@
assertEquals(2, result.getRegistrationProperties().size());
assertTrue(info.isModifyRegistrationNeeded());
- Map regProps = result.getRegistrationProperties();
+ Map<QName, RegistrationProperty> regProps = result.getRegistrationProperties();
assertNotNull(regProps);
- RegistrationProperty prop = (RegistrationProperty)regProps.get("prop0");
+ RegistrationProperty prop = regProps.get(QName.valueOf("prop0"));
assertNotNull(prop);
assertTrue(prop.isInvalid());
assertEquals(RegistrationProperty.Status.MISSING, prop.getStatus());
- prop = (RegistrationProperty)regProps.get("prop1");
+ prop = regProps.get(QName.valueOf("prop1"));
assertNotNull(prop);
assertTrue(prop.isInvalid());
assertEquals(RegistrationProperty.Status.MISSING, prop.getStatus());
@@ -501,12 +498,12 @@
assertNotNull(properties);
assertEquals(1, properties.size());
Property property = properties.get(0);
- assertEquals("prop0", property.getName());
+ assertEquals("prop0", property.getName().toString());
assertEquals(prop0Value, property.getStringValue());
}
private ServiceDescription createServiceDescription(boolean requiresRegistration, int numberOfProperties)
{
- return V2V1Converter.toV2ServiceDescription(ServiceDescriptionBehavior.createServiceDescription(requiresRegistration, numberOfProperties));
+ return ServiceDescriptionBehavior.createServiceDescription(requiresRegistration, numberOfProperties);
}
}
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/RegistrationPropertyTestCase.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/RegistrationPropertyTestCase.java 2010-05-27 07:15:18 UTC (rev 3208)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/RegistrationPropertyTestCase.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -25,6 +25,8 @@
import junit.framework.TestCase;
+import javax.xml.namespace.QName;
+
/**
* @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
* @version $Revision: 11941 $
@@ -106,7 +108,7 @@
public void testGetters()
{
- assertEquals("name", prop.getName());
+ assertEquals(QName.valueOf("name"), prop.getName());
assertEquals("value", prop.getValue());
assertEquals("en", prop.getLang());
assertNull(prop.isInvalid());
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/WSRPConsumerBaseTest.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/WSRPConsumerBaseTest.java 2010-05-27 07:15:18 UTC (rev 3208)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/consumer/WSRPConsumerBaseTest.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -1,39 +1,39 @@
-/******************************************************************************
- * JBoss, a division of Red Hat *
- * Copyright 2006, Red Hat Middleware, LLC, and individual *
- * contributors as indicated by the @authors tag. See the *
- * copyright.txt in the distribution for a full listing of *
- * individual contributors. *
- * *
- * 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. *
- ******************************************************************************/
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.consumer;
import junit.framework.TestCase;
import org.gatein.wsrp.WSRPConsumer;
-import org.gatein.wsrp.test.BehaviorRegistry;
import org.gatein.wsrp.test.ExtendedAssert;
-import org.gatein.wsrp.test.TestWSRPProducer;
-import org.gatein.wsrp.test.TestWSRPProducerImpl;
+import org.gatein.wsrp.test.protocol.v1.BehaviorRegistry;
import org.gatein.wsrp.test.protocol.v1.MarkupBehavior;
import org.gatein.wsrp.test.protocol.v1.PortletManagementBehavior;
import org.gatein.wsrp.test.protocol.v1.RegistrationBehavior;
import org.gatein.wsrp.test.protocol.v1.ServiceDescriptionBehavior;
import org.gatein.wsrp.test.protocol.v1.TestProducerBehavior;
+import org.gatein.wsrp.test.protocol.v1.TestWSRPProducer;
+import org.gatein.wsrp.test.protocol.v1.TestWSRPProducerImpl;
import org.gatein.wsrp.test.protocol.v1.behaviors.BasicMarkupBehavior;
import org.gatein.wsrp.test.protocol.v1.behaviors.BasicPortletManagementBehavior;
import org.gatein.wsrp.test.protocol.v1.behaviors.BasicServiceDescriptionBehavior;
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/protocol/v1/InteropServiceDescriptionTestCase.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/protocol/v1/InteropServiceDescriptionTestCase.java 2010-05-27 07:15:18 UTC (rev 3208)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/protocol/v1/InteropServiceDescriptionTestCase.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -1,31 +1,32 @@
/*
-* JBoss, a division of Red Hat
-* Copyright 2008, Red Hat Middleware, LLC, and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* 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.
-*/
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.protocol.v1;
import org.gatein.pc.api.Portlet;
import org.gatein.pc.api.PortletInvokerException;
-import org.gatein.wsrp.test.BehaviorRegistry;
import org.gatein.wsrp.test.ExtendedAssert;
+import org.gatein.wsrp.test.protocol.v1.BehaviorRegistry;
import java.util.HashSet;
import java.util.Set;
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/protocol/v1/MarkupTestCase.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/protocol/v1/MarkupTestCase.java 2010-05-27 07:15:18 UTC (rev 3208)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/protocol/v1/MarkupTestCase.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -40,8 +40,8 @@
import org.gatein.pc.portlet.impl.spi.AbstractUserContext;
import org.gatein.pc.portlet.impl.spi.AbstractWindowContext;
import org.gatein.wsrp.consumer.ProducerSessionInformation;
-import org.gatein.wsrp.test.BehaviorRegistry;
import org.gatein.wsrp.test.ExtendedAssert;
+import org.gatein.wsrp.test.protocol.v1.BehaviorRegistry;
import org.gatein.wsrp.test.protocol.v1.behaviors.BasicMarkupBehavior;
import org.gatein.wsrp.test.protocol.v1.behaviors.EmptyMarkupBehavior;
import org.gatein.wsrp.test.protocol.v1.behaviors.GroupedPortletsServiceDescriptionBehavior;
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/protocol/v1/PortletManagementTestCase.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/protocol/v1/PortletManagementTestCase.java 2010-05-27 07:15:18 UTC (rev 3208)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/protocol/v1/PortletManagementTestCase.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -1,25 +1,25 @@
-/******************************************************************************
- * JBoss, a division of Red Hat *
- * Copyright 2006, Red Hat Middleware, LLC, and individual *
- * contributors as indicated by the @authors tag. See the *
- * copyright.txt in the distribution for a full listing of *
- * individual contributors. *
- * *
- * 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. *
- ******************************************************************************/
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.protocol.v1;
@@ -28,8 +28,8 @@
import org.gatein.pc.api.PortletInvokerException;
import org.gatein.pc.api.PortletStateType;
import org.gatein.pc.api.state.DestroyCloneFailure;
-import org.gatein.wsrp.test.BehaviorRegistry;
import org.gatein.wsrp.test.ExtendedAssert;
+import org.gatein.wsrp.test.protocol.v1.BehaviorRegistry;
import org.gatein.wsrp.test.protocol.v1.behaviors.BasicMarkupBehavior;
import org.gatein.wsrp.test.protocol.v1.behaviors.BasicPortletManagementBehavior;
import org.gatein.wsrp.test.protocol.v1.behaviors.DestroyClonesPortletManagementBehavior;
Deleted: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/BehaviorRegistry.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/BehaviorRegistry.java 2010-05-27 07:15:18 UTC (rev 3208)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/BehaviorRegistry.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -1,115 +0,0 @@
-/*
- * JBoss, a division of Red Hat
- * Copyright 2010, Red Hat Middleware, LLC, and individual
- * contributors as indicated by the @authors tag. See the
- * copyright.txt in the distribution for a full listing of
- * individual contributors.
- *
- * 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.gatein.wsrp.test;
-
-import org.gatein.wsrp.WSRPExceptionFactory;
-import org.gatein.wsrp.test.protocol.v1.MarkupBehavior;
-import org.gatein.wsrp.test.protocol.v1.PortletManagementBehavior;
-import org.gatein.wsrp.test.protocol.v1.RegistrationBehavior;
-import org.gatein.wsrp.test.protocol.v1.ServiceDescriptionBehavior;
-import org.oasis.wsrp.v2.InvalidHandle;
-import org.oasis.wsrp.v2.InvalidHandleFault;
-
-import java.util.HashMap;
-import java.util.Map;
-
-/**
- * @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
- * @version $Revision: 9360 $
- * @since 2.6
- */
-public class BehaviorRegistry
-{
- private final Map<String, MarkupBehavior> behaviors = new HashMap<String, MarkupBehavior>();
- private PortletManagementBehavior portletManagementBehavior;
- private ServiceDescriptionBehavior serviceDescriptionBehavior;
- private RegistrationBehavior registrationBehavior;
-
- public ServiceDescriptionBehavior getServiceDescriptionBehavior()
- {
- // this is required since the consumer will try to access the producer as soon as it's started and the test
- // producer will not be properly setup at that time since it's set up in the test's setUp method...
- if (serviceDescriptionBehavior == null)
- {
- return ServiceDescriptionBehavior.DEFAULT;
- }
-
- return serviceDescriptionBehavior;
- }
-
- public void clear()
- {
- behaviors.clear();
- }
-
- public MarkupBehavior getMarkupBehaviorFor(String handle) throws InvalidHandle
- {
- if (behaviors.containsKey(handle))
- {
- return behaviors.get(handle);
- }
- throw WSRPExceptionFactory.<InvalidHandle, InvalidHandleFault>throwWSException(WSRPExceptionFactory.INVALID_HANDLE,
- "There is no registered MarkupBehavior for handle '" + handle + "'", null);
- }
-
- public void registerMarkupBehavior(MarkupBehavior behavior)
- {
- for (String handle : behavior.getSupportedHandles())
- {
- MarkupBehavior existing = behaviors.get(handle);
- if (existing != null)
- {
- throw new IllegalArgumentException("Cannot register behavior " + behavior.getClass().getName()
- + " because it uses a handle '" + handle + "' that's already associated with behavior "
- + existing.getClass().getName());
- }
- behaviors.put(handle, behavior);
- }
- }
-
- public PortletManagementBehavior getPortletManagementBehavior()
- {
- return portletManagementBehavior;
- }
-
- public void setPortletManagementBehavior(PortletManagementBehavior portletManagementBehavior)
- {
- this.portletManagementBehavior = portletManagementBehavior;
- }
-
- public void setServiceDescriptionBehavior(ServiceDescriptionBehavior serviceDescriptionBehavior)
- {
- this.serviceDescriptionBehavior = serviceDescriptionBehavior;
- }
-
- public RegistrationBehavior getRegistrationBehavior()
- {
- return registrationBehavior;
- }
-
- public void setRegistrationBehavior(RegistrationBehavior registrationBehavior)
- {
- this.registrationBehavior = registrationBehavior;
- }
-}
Deleted: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/TestWSRPProducer.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/TestWSRPProducer.java 2010-05-27 07:15:18 UTC (rev 3208)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/TestWSRPProducer.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -1,50 +0,0 @@
-/*
- * JBoss, a division of Red Hat
- * Copyright 2010, Red Hat Middleware, LLC, and individual
- * contributors as indicated by the @authors tag. See the
- * copyright.txt in the distribution for a full listing of
- * individual contributors.
- *
- * 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.gatein.wsrp.test;
-
-/**
- * Exposes WSPRProducer test implementation methods - we inject what it returns
- *
- * @author <a href="mailto:boleslaw.dawidowicz@jboss.org">Boleslaw Dawidowicz</a>
- * @version $Revision: 10610 $
- */
-public interface TestWSRPProducer
-{
- /** Resets any currently held state. */
- void reset();
-
- BehaviorRegistry getBehaviorRegistry();
-
- /**
- * Sets the currently used portlet handle identifying the MarkupBehavior we're using. This is needed to be able to
- * dispatch calls to initCookie to the proper behavior.
- *
- * @param handle
- */
- void setCurrentMarkupBehaviorHandle(String handle);
-
- void setRequiresInitCookie(String cookieProtocolAsString);
-
- void usingStrictModeChangedTo(boolean strictMode);
-}
Deleted: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/TestWSRPProducerImpl.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/TestWSRPProducerImpl.java 2010-05-27 07:15:18 UTC (rev 3208)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/TestWSRPProducerImpl.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -1,268 +0,0 @@
-/*
- * JBoss, a division of Red Hat
- * Copyright 2010, Red Hat Middleware, LLC, and individual
- * contributors as indicated by the @authors tag. See the
- * copyright.txt in the distribution for a full listing of
- * individual contributors.
- *
- * 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.gatein.wsrp.test;
-
-import org.gatein.wsrp.spec.v1.WSRP1ExceptionFactory;
-import org.gatein.wsrp.test.protocol.v1.MarkupBehavior;
-import org.gatein.wsrp.test.protocol.v1.PortletManagementBehavior;
-import org.gatein.wsrp.test.protocol.v1.ServiceDescriptionBehavior;
-import org.oasis.wsrp.v1.V1AccessDenied;
-import org.oasis.wsrp.v1.V1CookieProtocol;
-import org.oasis.wsrp.v1.V1DestroyFailed;
-import org.oasis.wsrp.v1.V1Extension;
-import org.oasis.wsrp.v1.V1InconsistentParameters;
-import org.oasis.wsrp.v1.V1InteractionParams;
-import org.oasis.wsrp.v1.V1InvalidCookie;
-import org.oasis.wsrp.v1.V1InvalidHandle;
-import org.oasis.wsrp.v1.V1InvalidHandleFault;
-import org.oasis.wsrp.v1.V1InvalidRegistration;
-import org.oasis.wsrp.v1.V1InvalidSession;
-import org.oasis.wsrp.v1.V1InvalidUserCategory;
-import org.oasis.wsrp.v1.V1ItemDescription;
-import org.oasis.wsrp.v1.V1MarkupContext;
-import org.oasis.wsrp.v1.V1MarkupParams;
-import org.oasis.wsrp.v1.V1MissingParameters;
-import org.oasis.wsrp.v1.V1ModelDescription;
-import org.oasis.wsrp.v1.V1OperationFailed;
-import org.oasis.wsrp.v1.V1OperationFailedFault;
-import org.oasis.wsrp.v1.V1PortletContext;
-import org.oasis.wsrp.v1.V1PortletDescription;
-import org.oasis.wsrp.v1.V1PortletStateChangeRequired;
-import org.oasis.wsrp.v1.V1Property;
-import org.oasis.wsrp.v1.V1PropertyList;
-import org.oasis.wsrp.v1.V1RegistrationContext;
-import org.oasis.wsrp.v1.V1RegistrationData;
-import org.oasis.wsrp.v1.V1ResetProperty;
-import org.oasis.wsrp.v1.V1ResourceList;
-import org.oasis.wsrp.v1.V1RuntimeContext;
-import org.oasis.wsrp.v1.V1SessionContext;
-import org.oasis.wsrp.v1.V1UnsupportedLocale;
-import org.oasis.wsrp.v1.V1UnsupportedMimeType;
-import org.oasis.wsrp.v1.V1UnsupportedMode;
-import org.oasis.wsrp.v1.V1UnsupportedWindowState;
-import org.oasis.wsrp.v1.V1UpdateResponse;
-import org.oasis.wsrp.v1.V1UserContext;
-import org.oasis.wsrp.v1.WSRPV1MarkupPortType;
-import org.oasis.wsrp.v1.WSRPV1PortletManagementPortType;
-import org.oasis.wsrp.v1.WSRPV1RegistrationPortType;
-import org.oasis.wsrp.v1.WSRPV1ServiceDescriptionPortType;
-import org.oasis.wsrp.v2.InvalidHandle;
-
-import javax.jws.WebParam;
-import javax.xml.ws.Holder;
-import java.util.List;
-
-/**
- * This is dummy clone of org.jboss.portal.wsrp.producer.WSRPProducerImpl customizable from client side. Just for
- * consumer implementation testing purposes.
- *
- * @author <a href="mailto:Boleslaw.Dawidowicz@jboss.com">Boleslaw Dawidowicz</a>
- * @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
- * @version $Revision: 12020 $
- * @since 2.4
- */
-public class TestWSRPProducerImpl implements TestWSRPProducer, WSRPV1MarkupPortType, WSRPV1PortletManagementPortType, WSRPV1RegistrationPortType, WSRPV1ServiceDescriptionPortType
-{
- private int sessionExpirationTime = 600;
-
- private V1CookieProtocol requiresInitCookie = V1CookieProtocol.NONE;
-
- private BehaviorRegistry behaviorRegistry = new BehaviorRegistry();
-
- public static final String USER_COOKIE = "cookie";
-
- private String currentMarkupBehaviorHandle;
-
- private boolean strict = true;
-
- public TestWSRPProducerImpl()
- {
- reset();
- }
-
- public BehaviorRegistry getBehaviorRegistry()
- {
- return behaviorRegistry;
- }
-
- public void setCurrentMarkupBehaviorHandle(String handle)
- {
- currentMarkupBehaviorHandle = handle;
- }
-
- public void reset()
- {
- requiresInitCookie = null;
- currentMarkupBehaviorHandle = null;
- behaviorRegistry.clear();
- }
-
- private MarkupBehavior getMarkupBehaviorFor(String portletHandle) throws V1InvalidHandle
- {
- try
- {
- return behaviorRegistry.getMarkupBehaviorFor(portletHandle);
- }
- catch (InvalidHandle invalidHandle)
- {
- throw WSRP1ExceptionFactory.<V1InvalidHandle, V1InvalidHandleFault>throwWSException(WSRP1ExceptionFactory.INVALID_HANDLE, "Invalid handle", null);
- }
- }
-
- private ServiceDescriptionBehavior getServiceDescriptionBehavior()
- {
- return behaviorRegistry.getServiceDescriptionBehavior();
- }
-
- public PortletManagementBehavior getPortletManagementBehavior()
- {
- return behaviorRegistry.getPortletManagementBehavior();
- }
-
- // ServiceDescription implementation ********************************************************************************
-
-
- public void getServiceDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> desiredLocales, @WebParam(mode = WebParam.Mode.OUT, name = "requiresRegistration", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<Boolean> requiresRegistration, @WebParam(mode = WebParam.Mode.OUT, name = "offeredPortlets", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1PortletDescription>> offeredPortlets, @WebParam(mode = WebParam.Mode.OUT, name = "userCategoryDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1ItemDescription>> userCategoryDescriptions, @WebParam(mode = WebParam.Mode.OUT, name = "customUserProfileItemDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1ItemDescription>> customUserProfileIte!
mDescriptions, @WebParam(mode = WebParam.Mode.OUT, name = "customWindowStateDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1ItemDescription>> customWindowStateDescriptions, @WebParam(mode = WebParam.Mode.OUT, name = "customModeDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1ItemDescription>> customModeDescriptions, @WebParam(mode = WebParam.Mode.OUT, name = "requiresInitCookie", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<V1CookieProtocol> requiresInitCookie, @WebParam(mode = WebParam.Mode.OUT, name = "registrationPropertyDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<V1ModelDescription> registrationPropertyDescription, @WebParam(mode = WebParam.Mode.OUT, name = "locales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<String>> locales, @WebParam(mode = WebParam.Mode.OUT, name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:ty!
pes") Holder<V1ResourceList> resourceList, @WebParam(mode = We!
bParam.M
ode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1Extension>> extensions) throws V1InvalidRegistration, V1OperationFailed
- {
- getServiceDescriptionBehavior().getServiceDescription(registrationContext, desiredLocales, requiresRegistration,
- offeredPortlets, userCategoryDescriptions, customUserProfileItemDescriptions, customWindowStateDescriptions,
- customModeDescriptions, requiresInitCookie, registrationPropertyDescription, locales, resourceList, extensions);
- }
-
- // MarkupService implementation *************************************************************************************
-
-
- public void performBlockingInteraction(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1PortletContext portletContext, @WebParam(name = "runtimeContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RuntimeContext runtimeContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1UserContext userContext, @WebParam(name = "markupParams", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1MarkupParams markupParams, @WebParam(name = "interactionParams", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1InteractionParams interactionParams, @WebParam(mode = WebParam.Mode.OUT, name = "updateResponse", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<V1UpdateResponse> updateResponse, @WebParam(mode = WebParam.Mode.OUT, name = "redir!
ectURL", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<String> redirectURL, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1Extension>> extensions) throws V1UnsupportedMimeType, V1UnsupportedMode, V1UnsupportedWindowState, V1InvalidCookie, V1InvalidSession, V1MissingParameters, V1UnsupportedLocale, V1InconsistentParameters, V1PortletStateChangeRequired, V1InvalidHandle, V1InvalidRegistration, V1InvalidUserCategory, V1AccessDenied, V1OperationFailed
- {
- getMarkupBehaviorFor(portletContext.getPortletHandle()).performBlockingInteraction(registrationContext, portletContext, runtimeContext, userContext, markupParams, interactionParams, updateResponse, redirectURL, extensions);
- }
-
- public List<V1Extension> releaseSessions(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext, @WebParam(name = "sessionIDs", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> sessionIDs) throws V1MissingParameters, V1InvalidRegistration, V1AccessDenied, V1OperationFailed
- {
- return null;
- }
-
- public void getMarkup(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1PortletContext portletContext, @WebParam(name = "runtimeContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RuntimeContext runtimeContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1UserContext userContext, @WebParam(name = "markupParams", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1MarkupParams markupParams, @WebParam(mode = WebParam.Mode.OUT, name = "markupContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<V1MarkupContext> markupContext, @WebParam(mode = WebParam.Mode.OUT, name = "sessionContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<V1SessionContext> sessionContext, @WebParam(mode = WebParam.Mode.OUT, name = "!
extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1Extension>> extensions) throws V1UnsupportedMimeType, V1UnsupportedMode, V1UnsupportedWindowState, V1InvalidCookie, V1InvalidSession, V1MissingParameters, V1UnsupportedLocale, V1InconsistentParameters, V1InvalidHandle, V1InvalidRegistration, V1InvalidUserCategory, V1AccessDenied, V1OperationFailed
- {
- getMarkupBehaviorFor(portletContext.getPortletHandle()).getMarkup(registrationContext, portletContext, runtimeContext, userContext, markupParams, markupContext, sessionContext, extensions);
- }
-
- public List<V1Extension> initCookie(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext) throws V1InvalidRegistration, V1AccessDenied, V1OperationFailed
- {
- // should only be called if we required cookies to be initialized
- if (requiresInitCookie == null || V1CookieProtocol.NONE.equals(requiresInitCookie))
- {
- throw WSRP1ExceptionFactory.<V1OperationFailed, V1OperationFailedFault>throwWSException(WSRP1ExceptionFactory.OPERATION_FAILED, "Shouldn't have called initCookie", null);
- }
-
- try
- {
- return getMarkupBehaviorFor(currentMarkupBehaviorHandle).initCookie(registrationContext);
- }
- catch (V1InvalidHandle invalidHandle)
- {
- throw WSRP1ExceptionFactory.<V1OperationFailed, V1OperationFailedFault>throwWSException(WSRP1ExceptionFactory.OPERATION_FAILED, "Invalid handle", invalidHandle);
- }
- }
-
- // Registration implementation **************************************************************************************
-
-
- public void register(@WebParam(name = "consumerName", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") String consumerName, @WebParam(name = "consumerAgent", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") String consumerAgent, @WebParam(name = "methodGetSupported", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") boolean methodGetSupported, @WebParam(name = "consumerModes", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> consumerModes, @WebParam(name = "consumerWindowStates", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> consumerWindowStates, @WebParam(name = "consumerUserScopes", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> consumerUserScopes, @WebParam(name = "customUserProfileData", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> customUserProfileData, @WebParam(name = "registrationProperties", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<V1Property> registr!
ationProperties, @WebParam(mode = WebParam.Mode.INOUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1Extension>> extensions, @WebParam(mode = WebParam.Mode.OUT, name = "registrationHandle", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<String> registrationHandle, @WebParam(mode = WebParam.Mode.OUT, name = "registrationState", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<byte[]> registrationState) throws V1MissingParameters, V1OperationFailed
- {
- registrationHandle.value = "registration";
- }
-
- public void modifyRegistration(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext, @WebParam(name = "registrationData", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationData registrationData, @WebParam(mode = WebParam.Mode.OUT, name = "registrationState", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<byte[]> registrationState, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1Extension>> extensions) throws V1MissingParameters, V1InvalidRegistration, V1OperationFailed
- {
- // do nothing
- }
-
- public void deregister(@WebParam(name = "registrationHandle", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") String registrationHandle, @WebParam(name = "registrationState", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") byte[] registrationState, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types", mode = WebParam.Mode.INOUT) Holder<List<V1Extension>> extensions) throws V1InvalidRegistration, V1OperationFailed
- {
- // do nothing
- }
-
- // PortletManagement implementation *********************************************************************************
-
- public void getPortletPropertyDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> desiredLocales, @WebParam(mode = WebParam.Mode.OUT, name = "modelDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<V1ModelDescription> modelDescription, @WebParam(mode = WebParam.Mode.OUT, name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<V1ResourceList> resourceList, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1Extension>> exte!
nsions) throws V1MissingParameters, V1InconsistentParameters, V1InvalidHandle, V1InvalidRegistration, V1InvalidUserCategory, V1AccessDenied, V1OperationFailed
- {
- getPortletManagementBehavior().getPortletPropertyDescription(registrationContext, portletContext, userContext, desiredLocales, modelDescription, resourceList, extensions);
- }
-
- public void setPortletProperties(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1UserContext userContext, @WebParam(name = "propertyList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1PropertyList propertyList, @WebParam(mode = WebParam.Mode.OUT, name = "portletHandle", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<String> portletHandle, @WebParam(mode = WebParam.Mode.OUT, name = "portletState", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<byte[]> portletState, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1Extension>> extensions) throws V1MissingParameters, V!
1InconsistentParameters, V1InvalidHandle, V1InvalidRegistration, V1InvalidUserCategory, V1AccessDenied, V1OperationFailed
- {
- getPortletManagementBehavior().setPortletProperties(registrationContext, portletContext, userContext, propertyList, portletHandle, portletState, extensions);
- }
-
- public void clonePortlet(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1UserContext userContext, @WebParam(mode = WebParam.Mode.OUT, name = "portletHandle", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<String> portletHandle, @WebParam(mode = WebParam.Mode.OUT, name = "portletState", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<byte[]> portletState, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1Extension>> extensions) throws V1MissingParameters, V1InconsistentParameters, V1InvalidHandle, V1InvalidRegistration, V1InvalidUserCategory, V1AccessDenied, V1OperationFailed
- {
- getPortletManagementBehavior().clonePortlet(registrationContext, portletContext, userContext, portletHandle, portletState, extensions);
- }
-
- public void getPortletDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> desiredLocales, @WebParam(mode = WebParam.Mode.OUT, name = "portletDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<V1PortletDescription> portletDescription, @WebParam(mode = WebParam.Mode.OUT, name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<V1ResourceList> resourceList, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1Extension>> extens!
ions) throws V1MissingParameters, V1InconsistentParameters, V1InvalidHandle, V1InvalidRegistration, V1InvalidUserCategory, V1AccessDenied, V1OperationFailed
- {
- getPortletManagementBehavior().getPortletDescription(registrationContext, portletContext, userContext, desiredLocales, portletDescription, resourceList, extensions);
- }
-
- public void getPortletProperties(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1UserContext userContext, @WebParam(name = "names", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> names, @WebParam(mode = WebParam.Mode.OUT, name = "properties", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1Property>> properties, @WebParam(mode = WebParam.Mode.OUT, name = "resetProperties", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1ResetProperty>> resetProperties, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1Extension>> extensions) throws V1MissingPara!
meters, V1InconsistentParameters, V1InvalidHandle, V1InvalidRegistration, V1InvalidUserCategory, V1AccessDenied, V1OperationFailed
- {
- getPortletManagementBehavior().getPortletProperties(registrationContext, portletContext, userContext, names, properties, resetProperties, extensions);
- }
-
- public void destroyPortlets(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext, @WebParam(name = "portletHandles", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> portletHandles, @WebParam(mode = WebParam.Mode.OUT, name = "destroyFailed", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1DestroyFailed>> destroyFailed, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1Extension>> extensions) throws V1MissingParameters, V1InconsistentParameters, V1InvalidRegistration, V1OperationFailed
- {
- getPortletManagementBehavior().destroyPortlets(registrationContext, portletHandles, destroyFailed, extensions);
- }
-
- // Producer implementation ******************************************************************************************
-
- public V1CookieProtocol getRequiresInitCookie()
- {
- return requiresInitCookie;
- }
-
- public void setRequiresInitCookie(String cookieProtocolAsString)
- {
- V1CookieProtocol protocol = V1CookieProtocol.fromValue(cookieProtocolAsString);
- this.requiresInitCookie = protocol;
- getServiceDescriptionBehavior().setRequiresInitCookie(requiresInitCookie);
- }
-
- public int getSessionExpirationTime()
- {
- return sessionExpirationTime;
- }
-
- public void setSessionExpirationTime(int sessionExpirationTime)
- {
- this.sessionExpirationTime = sessionExpirationTime;
- }
-
- public void usingStrictModeChangedTo(boolean strictMode)
- {
-// WSRPValidator.setStrict(strictMode);
- strict = strictMode;
- }
-}
Copied: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/BehaviorBackedServiceFactory.java (from rev 3203, components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/support/BehaviorBackedServiceFactory.java)
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/BehaviorBackedServiceFactory.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/BehaviorBackedServiceFactory.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,227 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v1;
+
+import org.gatein.common.NotYetImplemented;
+import org.gatein.pc.api.Mode;
+import org.gatein.pc.api.WindowState;
+import org.gatein.wsrp.services.ServiceFactory;
+import org.oasis.wsrp.v1.V1AccessDenied;
+import org.oasis.wsrp.v1.V1GetMarkup;
+import org.oasis.wsrp.v1.V1InconsistentParameters;
+import org.oasis.wsrp.v1.V1InvalidCookie;
+import org.oasis.wsrp.v1.V1InvalidHandle;
+import org.oasis.wsrp.v1.V1InvalidRegistration;
+import org.oasis.wsrp.v1.V1InvalidSession;
+import org.oasis.wsrp.v1.V1InvalidUserCategory;
+import org.oasis.wsrp.v1.V1MissingParameters;
+import org.oasis.wsrp.v1.V1OperationFailed;
+import org.oasis.wsrp.v1.V1UnsupportedLocale;
+import org.oasis.wsrp.v1.V1UnsupportedMimeType;
+import org.oasis.wsrp.v1.V1UnsupportedMode;
+import org.oasis.wsrp.v1.V1UnsupportedWindowState;
+import org.oasis.wsrp.v1.WSRPV1MarkupPortType;
+import org.oasis.wsrp.v1.WSRPV1PortletManagementPortType;
+import org.oasis.wsrp.v1.WSRPV1RegistrationPortType;
+import org.oasis.wsrp.v1.WSRPV1ServiceDescriptionPortType;
+
+/**
+ * @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
+ * @version $Revision: 11461 $
+ * @since 2.6
+ */
+public class BehaviorBackedServiceFactory implements ServiceFactory
+{
+ private BehaviorRegistry registry;
+ private final static String MARKUP = "markup";
+ private final static String SD_URL = "sd";
+ private final static String M_URL = "m";
+ private final static String PM_URL = "pm";
+ private final static String R_URL = "r";
+ private boolean initialized = false;
+ private String wsdl = DEFAULT_WSDL_URL;
+ public static final String DEFAULT_WSDL_URL = "http://example.com/producer?wsdl";
+ private int timeout;
+
+
+ public BehaviorBackedServiceFactory()
+ {
+ registry = new BehaviorRegistry();
+ registry.registerMarkupBehavior(new SimpleMarkupBehavior());
+ }
+
+ public <T> T getService(Class<T> serviceClass) throws Exception
+ {
+ if (!isAvailable() && !isFailed())
+ {
+ start();
+ }
+
+ if (WSRPV1ServiceDescriptionPortType.class.isAssignableFrom(serviceClass))
+ {
+ return (T)registry.getServiceDescriptionBehavior();
+ }
+ if (WSRPV1MarkupPortType.class.isAssignableFrom(serviceClass))
+ {
+ return (T)registry.getMarkupBehaviorFor(MARKUP);
+ }
+ if (WSRPV1PortletManagementPortType.class.isAssignableFrom(serviceClass))
+ {
+ return (T)registry.getPortletManagementBehavior();
+ }
+ if (WSRPV1RegistrationPortType.class.isAssignableFrom(serviceClass))
+ {
+ return (T)registry.getRegistrationBehavior();
+ }
+ return null;
+ }
+
+ public BehaviorRegistry getRegistry()
+ {
+ return registry;
+ }
+
+ public void setRegistry(BehaviorRegistry registry)
+ {
+ this.registry = registry;
+ }
+
+ public boolean isAvailable()
+ {
+ return initialized;
+ }
+
+ public boolean isFailed()
+ {
+ return false;
+ }
+
+ public void setFailed(boolean failed)
+ {
+ // do nothing
+ }
+
+ public void setWSOperationTimeOut(int msBeforeTimeOut)
+ {
+ if (msBeforeTimeOut < 0)
+ {
+ msBeforeTimeOut = DEFAULT_TIMEOUT_MS;
+ }
+
+ timeout = msBeforeTimeOut;
+ }
+
+ public int getWSOperationTimeOut()
+ {
+ return timeout;
+ }
+
+ public String getServiceDescriptionURL()
+ {
+ return SD_URL;
+ }
+
+ public String getMarkupURL()
+ {
+ return M_URL;
+ }
+
+ public String getRegistrationURL()
+ {
+ return R_URL;
+ }
+
+ public String getPortletManagementURL()
+ {
+ return PM_URL;
+ }
+
+ public void setServiceDescriptionURL(String serviceDescriptionURL)
+ {
+ // do nothing
+ }
+
+ public void setMarkupURL(String markupURL)
+ {
+ // do nothing
+ }
+
+ public void setRegistrationURL(String registrationURL)
+ {
+ // do nothing
+ }
+
+ public void setPortletManagementURL(String portletManagementURL)
+ {
+ // do nothing
+ }
+
+ public void create() throws Exception
+ {
+ throw new NotYetImplemented();
+ }
+
+ public void start() throws Exception
+ {
+ initialized = true;
+ }
+
+ public void stop()
+ {
+ throw new NotYetImplemented();
+ }
+
+ public void setWsdlDefinitionURL(String wsdlDefinitionURL)
+ {
+ wsdl = wsdlDefinitionURL;
+ }
+
+ public String getWsdlDefinitionURL()
+ {
+ return wsdl;
+ }
+
+ public void destroy()
+ {
+ throw new NotYetImplemented();
+ }
+
+ private class SimpleMarkupBehavior extends MarkupBehavior
+ {
+ public SimpleMarkupBehavior()
+ {
+ super(BehaviorBackedServiceFactory.this.registry);
+ registerHandle(MARKUP);
+ }
+
+ @Override
+ protected String getMarkupString(Mode mode, WindowState windowState, String navigationalState, V1GetMarkup getMarkup)
+ throws V1UnsupportedWindowState, V1InvalidCookie, V1InvalidSession, V1AccessDenied, V1InconsistentParameters,
+ V1InvalidHandle, V1UnsupportedLocale, V1UnsupportedMode, V1OperationFailed, V1MissingParameters, V1InvalidUserCategory,
+ V1InvalidRegistration, V1UnsupportedMimeType
+ {
+ return MARKUP;
+ }
+ }
+}
Property changes on: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/BehaviorBackedServiceFactory.java
___________________________________________________________________
Name: svn:executable
+ *
Copied: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/BehaviorRegistry.java (from rev 3203, components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/BehaviorRegistry.java)
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/BehaviorRegistry.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/BehaviorRegistry.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,111 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v1;
+
+import org.gatein.wsrp.WSRPExceptionFactory;
+import org.oasis.wsrp.v2.InvalidHandle;
+import org.oasis.wsrp.v2.InvalidHandleFault;
+
+import java.util.HashMap;
+import java.util.Map;
+
+/**
+ * @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
+ * @version $Revision: 9360 $
+ * @since 2.6
+ */
+public class BehaviorRegistry
+{
+ private final Map<String, MarkupBehavior> behaviors = new HashMap<String, MarkupBehavior>();
+ private PortletManagementBehavior portletManagementBehavior;
+ private ServiceDescriptionBehavior serviceDescriptionBehavior;
+ private RegistrationBehavior registrationBehavior;
+
+ public ServiceDescriptionBehavior getServiceDescriptionBehavior()
+ {
+ // this is required since the consumer will try to access the producer as soon as it's started and the test
+ // producer will not be properly setup at that time since it's set up in the test's setUp method...
+ if (serviceDescriptionBehavior == null)
+ {
+ return ServiceDescriptionBehavior.DEFAULT;
+ }
+
+ return serviceDescriptionBehavior;
+ }
+
+ public void clear()
+ {
+ behaviors.clear();
+ }
+
+ public MarkupBehavior getMarkupBehaviorFor(String handle) throws InvalidHandle
+ {
+ if (behaviors.containsKey(handle))
+ {
+ return behaviors.get(handle);
+ }
+ throw WSRPExceptionFactory.<InvalidHandle, InvalidHandleFault>throwWSException(WSRPExceptionFactory.INVALID_HANDLE,
+ "There is no registered MarkupBehavior for handle '" + handle + "'", null);
+ }
+
+ public void registerMarkupBehavior(MarkupBehavior behavior)
+ {
+ for (String handle : behavior.getSupportedHandles())
+ {
+ MarkupBehavior existing = behaviors.get(handle);
+ if (existing != null)
+ {
+ throw new IllegalArgumentException("Cannot register behavior " + behavior.getClass().getName()
+ + " because it uses a handle '" + handle + "' that's already associated with behavior "
+ + existing.getClass().getName());
+ }
+ behaviors.put(handle, behavior);
+ }
+ }
+
+ public PortletManagementBehavior getPortletManagementBehavior()
+ {
+ return portletManagementBehavior;
+ }
+
+ public void setPortletManagementBehavior(PortletManagementBehavior portletManagementBehavior)
+ {
+ this.portletManagementBehavior = portletManagementBehavior;
+ }
+
+ public void setServiceDescriptionBehavior(ServiceDescriptionBehavior serviceDescriptionBehavior)
+ {
+ this.serviceDescriptionBehavior = serviceDescriptionBehavior;
+ }
+
+ public RegistrationBehavior getRegistrationBehavior()
+ {
+ return registrationBehavior;
+ }
+
+ public void setRegistrationBehavior(RegistrationBehavior registrationBehavior)
+ {
+ this.registrationBehavior = registrationBehavior;
+ }
+}
Property changes on: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/BehaviorRegistry.java
___________________________________________________________________
Name: svn:executable
+ *
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/MarkupBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/MarkupBehavior.java 2010-05-27 07:15:18 UTC (rev 3208)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/MarkupBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -28,7 +28,6 @@
import org.gatein.pc.api.WindowState;
import org.gatein.wsrp.WSRPUtils;
import org.gatein.wsrp.spec.v1.WSRP1TypeFactory;
-import org.gatein.wsrp.test.BehaviorRegistry;
import org.oasis.wsrp.v1.V1AccessDenied;
import org.oasis.wsrp.v1.V1Extension;
import org.oasis.wsrp.v1.V1GetMarkup;
@@ -166,11 +165,10 @@
String markupString = getMarkupString(WSRPUtils.getJSR168PortletModeFromWSRPName(markupParams.getMode()),
WSRPUtils.getJSR168WindowStateFromWSRPName(markupParams.getWindowState()), markupParams.getNavigationalState(), gm);
- V1MarkupContext v2MarkupContext = WSRP1TypeFactory.createMarkupContext(MediaType.TEXT_HTML.getValue(), markupString);
- markupContext.value = v2MarkupContext;
+ markupContext.value = WSRP1TypeFactory.createMarkupContext(MediaType.TEXT_HTML.getValue(), markupString);
markupContext.value.setRequiresUrlRewriting(Boolean.TRUE);
- V1MarkupResponse markupResponse = WSRP1TypeFactory.createMarkupResponse(v2MarkupContext);
+ V1MarkupResponse markupResponse = WSRP1TypeFactory.createMarkupResponse(markupContext.value);
modifyResponseIfNeeded(markupResponse);
}
Copied: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/TestWSRPProducer.java (from rev 3203, components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/TestWSRPProducer.java)
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/TestWSRPProducer.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/TestWSRPProducer.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,50 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v1;
+
+/**
+ * Exposes WSPRProducer test implementation methods - we inject what it returns
+ *
+ * @author <a href="mailto:boleslaw.dawidowicz@jboss.org">Boleslaw Dawidowicz</a>
+ * @version $Revision: 10610 $
+ */
+public interface TestWSRPProducer
+{
+ /** Resets any currently held state. */
+ void reset();
+
+ BehaviorRegistry getBehaviorRegistry();
+
+ /**
+ * Sets the currently used portlet handle identifying the MarkupBehavior we're using. This is needed to be able to
+ * dispatch calls to initCookie to the proper behavior.
+ *
+ * @param handle
+ */
+ void setCurrentMarkupBehaviorHandle(String handle);
+
+ void setRequiresInitCookie(String cookieProtocolAsString);
+
+ void usingStrictModeChangedTo(boolean strictMode);
+}
Property changes on: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/TestWSRPProducer.java
___________________________________________________________________
Name: svn:executable
+ *
Copied: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/TestWSRPProducerImpl.java (from rev 3203, components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/TestWSRPProducerImpl.java)
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/TestWSRPProducerImpl.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/TestWSRPProducerImpl.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,265 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v1;
+
+import org.gatein.wsrp.spec.v1.WSRP1ExceptionFactory;
+import org.oasis.wsrp.v1.V1AccessDenied;
+import org.oasis.wsrp.v1.V1CookieProtocol;
+import org.oasis.wsrp.v1.V1DestroyFailed;
+import org.oasis.wsrp.v1.V1Extension;
+import org.oasis.wsrp.v1.V1InconsistentParameters;
+import org.oasis.wsrp.v1.V1InteractionParams;
+import org.oasis.wsrp.v1.V1InvalidCookie;
+import org.oasis.wsrp.v1.V1InvalidHandle;
+import org.oasis.wsrp.v1.V1InvalidHandleFault;
+import org.oasis.wsrp.v1.V1InvalidRegistration;
+import org.oasis.wsrp.v1.V1InvalidSession;
+import org.oasis.wsrp.v1.V1InvalidUserCategory;
+import org.oasis.wsrp.v1.V1ItemDescription;
+import org.oasis.wsrp.v1.V1MarkupContext;
+import org.oasis.wsrp.v1.V1MarkupParams;
+import org.oasis.wsrp.v1.V1MissingParameters;
+import org.oasis.wsrp.v1.V1ModelDescription;
+import org.oasis.wsrp.v1.V1OperationFailed;
+import org.oasis.wsrp.v1.V1OperationFailedFault;
+import org.oasis.wsrp.v1.V1PortletContext;
+import org.oasis.wsrp.v1.V1PortletDescription;
+import org.oasis.wsrp.v1.V1PortletStateChangeRequired;
+import org.oasis.wsrp.v1.V1Property;
+import org.oasis.wsrp.v1.V1PropertyList;
+import org.oasis.wsrp.v1.V1RegistrationContext;
+import org.oasis.wsrp.v1.V1RegistrationData;
+import org.oasis.wsrp.v1.V1ResetProperty;
+import org.oasis.wsrp.v1.V1ResourceList;
+import org.oasis.wsrp.v1.V1RuntimeContext;
+import org.oasis.wsrp.v1.V1SessionContext;
+import org.oasis.wsrp.v1.V1UnsupportedLocale;
+import org.oasis.wsrp.v1.V1UnsupportedMimeType;
+import org.oasis.wsrp.v1.V1UnsupportedMode;
+import org.oasis.wsrp.v1.V1UnsupportedWindowState;
+import org.oasis.wsrp.v1.V1UpdateResponse;
+import org.oasis.wsrp.v1.V1UserContext;
+import org.oasis.wsrp.v1.WSRPV1MarkupPortType;
+import org.oasis.wsrp.v1.WSRPV1PortletManagementPortType;
+import org.oasis.wsrp.v1.WSRPV1RegistrationPortType;
+import org.oasis.wsrp.v1.WSRPV1ServiceDescriptionPortType;
+import org.oasis.wsrp.v2.InvalidHandle;
+
+import javax.jws.WebParam;
+import javax.xml.ws.Holder;
+import java.util.List;
+
+/**
+ * This is dummy clone of org.jboss.portal.wsrp.producer.WSRPProducerImpl customizable from client side. Just for
+ * consumer implementation testing purposes.
+ *
+ * @author <a href="mailto:Boleslaw.Dawidowicz@jboss.com">Boleslaw Dawidowicz</a>
+ * @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
+ * @version $Revision: 12020 $
+ * @since 2.4
+ */
+public class TestWSRPProducerImpl implements TestWSRPProducer, WSRPV1MarkupPortType, WSRPV1PortletManagementPortType, WSRPV1RegistrationPortType, WSRPV1ServiceDescriptionPortType
+{
+ private int sessionExpirationTime = 600;
+
+ private V1CookieProtocol requiresInitCookie = V1CookieProtocol.NONE;
+
+ private BehaviorRegistry behaviorRegistry = new BehaviorRegistry();
+
+ public static final String USER_COOKIE = "cookie";
+
+ private String currentMarkupBehaviorHandle;
+
+ private boolean strict = true;
+
+ public TestWSRPProducerImpl()
+ {
+ reset();
+ }
+
+ public BehaviorRegistry getBehaviorRegistry()
+ {
+ return behaviorRegistry;
+ }
+
+ public void setCurrentMarkupBehaviorHandle(String handle)
+ {
+ currentMarkupBehaviorHandle = handle;
+ }
+
+ public void reset()
+ {
+ requiresInitCookie = null;
+ currentMarkupBehaviorHandle = null;
+ behaviorRegistry.clear();
+ }
+
+ private MarkupBehavior getMarkupBehaviorFor(String portletHandle) throws V1InvalidHandle
+ {
+ try
+ {
+ return behaviorRegistry.getMarkupBehaviorFor(portletHandle);
+ }
+ catch (InvalidHandle invalidHandle)
+ {
+ throw WSRP1ExceptionFactory.<V1InvalidHandle, V1InvalidHandleFault>throwWSException(WSRP1ExceptionFactory.INVALID_HANDLE, "Invalid handle", null);
+ }
+ }
+
+ private ServiceDescriptionBehavior getServiceDescriptionBehavior()
+ {
+ return behaviorRegistry.getServiceDescriptionBehavior();
+ }
+
+ public PortletManagementBehavior getPortletManagementBehavior()
+ {
+ return behaviorRegistry.getPortletManagementBehavior();
+ }
+
+ // ServiceDescription implementation ********************************************************************************
+
+
+ public void getServiceDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> desiredLocales, @WebParam(mode = WebParam.Mode.OUT, name = "requiresRegistration", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<Boolean> requiresRegistration, @WebParam(mode = WebParam.Mode.OUT, name = "offeredPortlets", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1PortletDescription>> offeredPortlets, @WebParam(mode = WebParam.Mode.OUT, name = "userCategoryDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1ItemDescription>> userCategoryDescriptions, @WebParam(mode = WebParam.Mode.OUT, name = "customUserProfileItemDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1ItemDescription>> customUserProfileIte!
mDescriptions, @WebParam(mode = WebParam.Mode.OUT, name = "customWindowStateDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1ItemDescription>> customWindowStateDescriptions, @WebParam(mode = WebParam.Mode.OUT, name = "customModeDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1ItemDescription>> customModeDescriptions, @WebParam(mode = WebParam.Mode.OUT, name = "requiresInitCookie", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<V1CookieProtocol> requiresInitCookie, @WebParam(mode = WebParam.Mode.OUT, name = "registrationPropertyDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<V1ModelDescription> registrationPropertyDescription, @WebParam(mode = WebParam.Mode.OUT, name = "locales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<String>> locales, @WebParam(mode = WebParam.Mode.OUT, name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:ty!
pes") Holder<V1ResourceList> resourceList, @WebParam(mode = We!
bParam.M
ode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1Extension>> extensions) throws V1InvalidRegistration, V1OperationFailed
+ {
+ getServiceDescriptionBehavior().getServiceDescription(registrationContext, desiredLocales, requiresRegistration,
+ offeredPortlets, userCategoryDescriptions, customUserProfileItemDescriptions, customWindowStateDescriptions,
+ customModeDescriptions, requiresInitCookie, registrationPropertyDescription, locales, resourceList, extensions);
+ }
+
+ // MarkupService implementation *************************************************************************************
+
+
+ public void performBlockingInteraction(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1PortletContext portletContext, @WebParam(name = "runtimeContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RuntimeContext runtimeContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1UserContext userContext, @WebParam(name = "markupParams", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1MarkupParams markupParams, @WebParam(name = "interactionParams", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1InteractionParams interactionParams, @WebParam(mode = WebParam.Mode.OUT, name = "updateResponse", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<V1UpdateResponse> updateResponse, @WebParam(mode = WebParam.Mode.OUT, name = "redir!
ectURL", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<String> redirectURL, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1Extension>> extensions) throws V1UnsupportedMimeType, V1UnsupportedMode, V1UnsupportedWindowState, V1InvalidCookie, V1InvalidSession, V1MissingParameters, V1UnsupportedLocale, V1InconsistentParameters, V1PortletStateChangeRequired, V1InvalidHandle, V1InvalidRegistration, V1InvalidUserCategory, V1AccessDenied, V1OperationFailed
+ {
+ getMarkupBehaviorFor(portletContext.getPortletHandle()).performBlockingInteraction(registrationContext, portletContext, runtimeContext, userContext, markupParams, interactionParams, updateResponse, redirectURL, extensions);
+ }
+
+ public List<V1Extension> releaseSessions(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext, @WebParam(name = "sessionIDs", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> sessionIDs) throws V1MissingParameters, V1InvalidRegistration, V1AccessDenied, V1OperationFailed
+ {
+ return null;
+ }
+
+ public void getMarkup(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1PortletContext portletContext, @WebParam(name = "runtimeContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RuntimeContext runtimeContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1UserContext userContext, @WebParam(name = "markupParams", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1MarkupParams markupParams, @WebParam(mode = WebParam.Mode.OUT, name = "markupContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<V1MarkupContext> markupContext, @WebParam(mode = WebParam.Mode.OUT, name = "sessionContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<V1SessionContext> sessionContext, @WebParam(mode = WebParam.Mode.OUT, name = "!
extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1Extension>> extensions) throws V1UnsupportedMimeType, V1UnsupportedMode, V1UnsupportedWindowState, V1InvalidCookie, V1InvalidSession, V1MissingParameters, V1UnsupportedLocale, V1InconsistentParameters, V1InvalidHandle, V1InvalidRegistration, V1InvalidUserCategory, V1AccessDenied, V1OperationFailed
+ {
+ getMarkupBehaviorFor(portletContext.getPortletHandle()).getMarkup(registrationContext, portletContext, runtimeContext, userContext, markupParams, markupContext, sessionContext, extensions);
+ }
+
+ public List<V1Extension> initCookie(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext) throws V1InvalidRegistration, V1AccessDenied, V1OperationFailed
+ {
+ // should only be called if we required cookies to be initialized
+ if (requiresInitCookie == null || V1CookieProtocol.NONE.equals(requiresInitCookie))
+ {
+ throw WSRP1ExceptionFactory.<V1OperationFailed, V1OperationFailedFault>throwWSException(WSRP1ExceptionFactory.OPERATION_FAILED, "Shouldn't have called initCookie", null);
+ }
+
+ try
+ {
+ return getMarkupBehaviorFor(currentMarkupBehaviorHandle).initCookie(registrationContext);
+ }
+ catch (V1InvalidHandle invalidHandle)
+ {
+ throw WSRP1ExceptionFactory.<V1OperationFailed, V1OperationFailedFault>throwWSException(WSRP1ExceptionFactory.OPERATION_FAILED, "Invalid handle", invalidHandle);
+ }
+ }
+
+ // Registration implementation **************************************************************************************
+
+
+ public void register(@WebParam(name = "consumerName", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") String consumerName, @WebParam(name = "consumerAgent", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") String consumerAgent, @WebParam(name = "methodGetSupported", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") boolean methodGetSupported, @WebParam(name = "consumerModes", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> consumerModes, @WebParam(name = "consumerWindowStates", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> consumerWindowStates, @WebParam(name = "consumerUserScopes", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> consumerUserScopes, @WebParam(name = "customUserProfileData", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> customUserProfileData, @WebParam(name = "registrationProperties", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<V1Property> registr!
ationProperties, @WebParam(mode = WebParam.Mode.INOUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1Extension>> extensions, @WebParam(mode = WebParam.Mode.OUT, name = "registrationHandle", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<String> registrationHandle, @WebParam(mode = WebParam.Mode.OUT, name = "registrationState", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<byte[]> registrationState) throws V1MissingParameters, V1OperationFailed
+ {
+ registrationHandle.value = "registration";
+ }
+
+ public void modifyRegistration(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext, @WebParam(name = "registrationData", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationData registrationData, @WebParam(mode = WebParam.Mode.OUT, name = "registrationState", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<byte[]> registrationState, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1Extension>> extensions) throws V1MissingParameters, V1InvalidRegistration, V1OperationFailed
+ {
+ // do nothing
+ }
+
+ public void deregister(@WebParam(name = "registrationHandle", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") String registrationHandle, @WebParam(name = "registrationState", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") byte[] registrationState, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types", mode = WebParam.Mode.INOUT) Holder<List<V1Extension>> extensions) throws V1InvalidRegistration, V1OperationFailed
+ {
+ // do nothing
+ }
+
+ // PortletManagement implementation *********************************************************************************
+
+ public void getPortletPropertyDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> desiredLocales, @WebParam(mode = WebParam.Mode.OUT, name = "modelDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<V1ModelDescription> modelDescription, @WebParam(mode = WebParam.Mode.OUT, name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<V1ResourceList> resourceList, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1Extension>> exte!
nsions) throws V1MissingParameters, V1InconsistentParameters, V1InvalidHandle, V1InvalidRegistration, V1InvalidUserCategory, V1AccessDenied, V1OperationFailed
+ {
+ getPortletManagementBehavior().getPortletPropertyDescription(registrationContext, portletContext, userContext, desiredLocales, modelDescription, resourceList, extensions);
+ }
+
+ public void setPortletProperties(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1UserContext userContext, @WebParam(name = "propertyList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1PropertyList propertyList, @WebParam(mode = WebParam.Mode.OUT, name = "portletHandle", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<String> portletHandle, @WebParam(mode = WebParam.Mode.OUT, name = "portletState", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<byte[]> portletState, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1Extension>> extensions) throws V1MissingParameters, V!
1InconsistentParameters, V1InvalidHandle, V1InvalidRegistration, V1InvalidUserCategory, V1AccessDenied, V1OperationFailed
+ {
+ getPortletManagementBehavior().setPortletProperties(registrationContext, portletContext, userContext, propertyList, portletHandle, portletState, extensions);
+ }
+
+ public void clonePortlet(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1UserContext userContext, @WebParam(mode = WebParam.Mode.OUT, name = "portletHandle", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<String> portletHandle, @WebParam(mode = WebParam.Mode.OUT, name = "portletState", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<byte[]> portletState, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1Extension>> extensions) throws V1MissingParameters, V1InconsistentParameters, V1InvalidHandle, V1InvalidRegistration, V1InvalidUserCategory, V1AccessDenied, V1OperationFailed
+ {
+ getPortletManagementBehavior().clonePortlet(registrationContext, portletContext, userContext, portletHandle, portletState, extensions);
+ }
+
+ public void getPortletDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> desiredLocales, @WebParam(mode = WebParam.Mode.OUT, name = "portletDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<V1PortletDescription> portletDescription, @WebParam(mode = WebParam.Mode.OUT, name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<V1ResourceList> resourceList, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1Extension>> extens!
ions) throws V1MissingParameters, V1InconsistentParameters, V1InvalidHandle, V1InvalidRegistration, V1InvalidUserCategory, V1AccessDenied, V1OperationFailed
+ {
+ getPortletManagementBehavior().getPortletDescription(registrationContext, portletContext, userContext, desiredLocales, portletDescription, resourceList, extensions);
+ }
+
+ public void getPortletProperties(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1UserContext userContext, @WebParam(name = "names", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> names, @WebParam(mode = WebParam.Mode.OUT, name = "properties", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1Property>> properties, @WebParam(mode = WebParam.Mode.OUT, name = "resetProperties", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1ResetProperty>> resetProperties, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1Extension>> extensions) throws V1MissingPara!
meters, V1InconsistentParameters, V1InvalidHandle, V1InvalidRegistration, V1InvalidUserCategory, V1AccessDenied, V1OperationFailed
+ {
+ getPortletManagementBehavior().getPortletProperties(registrationContext, portletContext, userContext, names, properties, resetProperties, extensions);
+ }
+
+ public void destroyPortlets(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") V1RegistrationContext registrationContext, @WebParam(name = "portletHandles", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> portletHandles, @WebParam(mode = WebParam.Mode.OUT, name = "destroyFailed", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1DestroyFailed>> destroyFailed, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<V1Extension>> extensions) throws V1MissingParameters, V1InconsistentParameters, V1InvalidRegistration, V1OperationFailed
+ {
+ getPortletManagementBehavior().destroyPortlets(registrationContext, portletHandles, destroyFailed, extensions);
+ }
+
+ // Producer implementation ******************************************************************************************
+
+ public V1CookieProtocol getRequiresInitCookie()
+ {
+ return requiresInitCookie;
+ }
+
+ public void setRequiresInitCookie(String cookieProtocolAsString)
+ {
+ V1CookieProtocol protocol = V1CookieProtocol.fromValue(cookieProtocolAsString);
+ this.requiresInitCookie = protocol;
+ getServiceDescriptionBehavior().setRequiresInitCookie(requiresInitCookie);
+ }
+
+ public int getSessionExpirationTime()
+ {
+ return sessionExpirationTime;
+ }
+
+ public void setSessionExpirationTime(int sessionExpirationTime)
+ {
+ this.sessionExpirationTime = sessionExpirationTime;
+ }
+
+ public void usingStrictModeChangedTo(boolean strictMode)
+ {
+// WSRPValidator.setStrict(strictMode);
+ strict = strictMode;
+ }
+}
Property changes on: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/TestWSRPProducerImpl.java
___________________________________________________________________
Name: svn:executable
+ *
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/BasicMarkupBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/BasicMarkupBehavior.java 2010-05-27 07:15:18 UTC (rev 3208)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/BasicMarkupBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -28,7 +28,7 @@
import org.gatein.wsrp.WSRPConstants;
import org.gatein.wsrp.WSRPTypeFactory;
import org.gatein.wsrp.spec.v1.WSRP1TypeFactory;
-import org.gatein.wsrp.test.BehaviorRegistry;
+import org.gatein.wsrp.test.protocol.v1.BehaviorRegistry;
import org.gatein.wsrp.test.protocol.v1.MarkupBehavior;
import org.oasis.wsrp.v1.V1AccessDenied;
import org.oasis.wsrp.v1.V1Extension;
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/BasicPortletManagementBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/BasicPortletManagementBehavior.java 2010-05-27 07:15:18 UTC (rev 3208)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/BasicPortletManagementBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -25,7 +25,7 @@
import org.gatein.wsrp.spec.v1.WSRP1ExceptionFactory;
import org.gatein.wsrp.spec.v1.WSRP1TypeFactory;
-import org.gatein.wsrp.test.BehaviorRegistry;
+import org.gatein.wsrp.test.protocol.v1.BehaviorRegistry;
import org.gatein.wsrp.test.protocol.v1.MarkupBehavior;
import org.gatein.wsrp.test.protocol.v1.PortletManagementBehavior;
import org.oasis.wsrp.v1.V1AccessDenied;
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/DestroyClonesPortletManagementBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/DestroyClonesPortletManagementBehavior.java 2010-05-27 07:15:18 UTC (rev 3208)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/DestroyClonesPortletManagementBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -24,7 +24,7 @@
package org.gatein.wsrp.test.protocol.v1.behaviors;
import org.gatein.wsrp.spec.v1.WSRP1ExceptionFactory;
-import org.gatein.wsrp.test.BehaviorRegistry;
+import org.gatein.wsrp.test.protocol.v1.BehaviorRegistry;
import org.oasis.wsrp.v1.V1AccessDenied;
import org.oasis.wsrp.v1.V1Extension;
import org.oasis.wsrp.v1.V1InconsistentParameters;
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/EmptyMarkupBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/EmptyMarkupBehavior.java 2010-05-27 07:15:18 UTC (rev 3208)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/EmptyMarkupBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -25,7 +25,7 @@
import org.gatein.pc.api.Mode;
import org.gatein.pc.api.WindowState;
-import org.gatein.wsrp.test.BehaviorRegistry;
+import org.gatein.wsrp.test.protocol.v1.BehaviorRegistry;
import org.gatein.wsrp.test.protocol.v1.MarkupBehavior;
import org.oasis.wsrp.v1.V1AccessDenied;
import org.oasis.wsrp.v1.V1GetMarkup;
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/InitCookieMarkupBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/InitCookieMarkupBehavior.java 2010-05-27 07:15:18 UTC (rev 3208)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/InitCookieMarkupBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -26,7 +26,7 @@
import org.gatein.pc.api.Mode;
import org.gatein.pc.api.WindowState;
import org.gatein.wsrp.spec.v1.WSRP1ExceptionFactory;
-import org.gatein.wsrp.test.BehaviorRegistry;
+import org.gatein.wsrp.test.protocol.v1.BehaviorRegistry;
import org.gatein.wsrp.test.protocol.v1.MarkupBehavior;
import org.oasis.wsrp.v1.V1AccessDenied;
import org.oasis.wsrp.v1.V1Extension;
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/InitCookieNotRequiredMarkupBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/InitCookieNotRequiredMarkupBehavior.java 2010-05-27 07:15:18 UTC (rev 3208)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/InitCookieNotRequiredMarkupBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -24,7 +24,7 @@
package org.gatein.wsrp.test.protocol.v1.behaviors;
import org.gatein.wsrp.spec.v1.WSRP1ExceptionFactory;
-import org.gatein.wsrp.test.BehaviorRegistry;
+import org.gatein.wsrp.test.protocol.v1.BehaviorRegistry;
import org.oasis.wsrp.v1.V1AccessDenied;
import org.oasis.wsrp.v1.V1Extension;
import org.oasis.wsrp.v1.V1InvalidRegistration;
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/NullMarkupBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/NullMarkupBehavior.java 2010-05-27 07:15:18 UTC (rev 3208)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/NullMarkupBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -25,7 +25,7 @@
import org.gatein.pc.api.Mode;
import org.gatein.pc.api.WindowState;
-import org.gatein.wsrp.test.BehaviorRegistry;
+import org.gatein.wsrp.test.protocol.v1.BehaviorRegistry;
import org.gatein.wsrp.test.protocol.v1.MarkupBehavior;
import org.oasis.wsrp.v1.V1AccessDenied;
import org.oasis.wsrp.v1.V1GetMarkup;
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/PerGroupInitCookieMarkupBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/PerGroupInitCookieMarkupBehavior.java 2010-05-27 07:15:18 UTC (rev 3208)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/PerGroupInitCookieMarkupBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -24,7 +24,7 @@
package org.gatein.wsrp.test.protocol.v1.behaviors;
import org.gatein.wsrp.spec.v1.WSRP1ExceptionFactory;
-import org.gatein.wsrp.test.BehaviorRegistry;
+import org.gatein.wsrp.test.protocol.v1.BehaviorRegistry;
import org.oasis.wsrp.v1.V1AccessDenied;
import org.oasis.wsrp.v1.V1Extension;
import org.oasis.wsrp.v1.V1InvalidRegistration;
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/PerUserInitCookieMarkupBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/PerUserInitCookieMarkupBehavior.java 2010-05-27 07:15:18 UTC (rev 3208)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/PerUserInitCookieMarkupBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -1,28 +1,29 @@
/*
-* JBoss, a division of Red Hat
-* Copyright 2008, Red Hat Middleware, LLC, and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* 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.
-*/
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v1.behaviors;
-import org.gatein.wsrp.test.BehaviorRegistry;
+import org.gatein.wsrp.test.protocol.v1.BehaviorRegistry;
/**
* @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/ResourceMarkupBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/ResourceMarkupBehavior.java 2010-05-27 07:15:18 UTC (rev 3208)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/ResourceMarkupBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -25,7 +25,7 @@
import org.gatein.pc.api.Mode;
import org.gatein.pc.api.WindowState;
-import org.gatein.wsrp.test.BehaviorRegistry;
+import org.gatein.wsrp.test.protocol.v1.BehaviorRegistry;
import org.gatein.wsrp.test.protocol.v1.MarkupBehavior;
import org.oasis.wsrp.v1.V1AccessDenied;
import org.oasis.wsrp.v1.V1GetMarkup;
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/SessionMarkupBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/SessionMarkupBehavior.java 2010-05-27 07:15:18 UTC (rev 3208)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v1/behaviors/SessionMarkupBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -26,7 +26,7 @@
import org.gatein.pc.api.Mode;
import org.gatein.pc.api.WindowState;
import org.gatein.wsrp.spec.v1.WSRP1TypeFactory;
-import org.gatein.wsrp.test.BehaviorRegistry;
+import org.gatein.wsrp.test.protocol.v1.BehaviorRegistry;
import org.gatein.wsrp.test.protocol.v1.MarkupBehavior;
import org.oasis.wsrp.v1.V1AccessDenied;
import org.oasis.wsrp.v1.V1Extension;
Added: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/BehaviorBackedServiceFactory.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/BehaviorBackedServiceFactory.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/BehaviorBackedServiceFactory.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,224 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v2;
+
+import org.gatein.common.NotYetImplemented;
+import org.gatein.pc.api.Mode;
+import org.gatein.pc.api.WindowState;
+import org.gatein.wsrp.services.ServiceFactory;
+import org.oasis.wsrp.v2.AccessDenied;
+import org.oasis.wsrp.v2.GetMarkup;
+import org.oasis.wsrp.v2.InconsistentParameters;
+import org.oasis.wsrp.v2.InvalidCookie;
+import org.oasis.wsrp.v2.InvalidHandle;
+import org.oasis.wsrp.v2.InvalidRegistration;
+import org.oasis.wsrp.v2.InvalidSession;
+import org.oasis.wsrp.v2.InvalidUserCategory;
+import org.oasis.wsrp.v2.MissingParameters;
+import org.oasis.wsrp.v2.OperationFailed;
+import org.oasis.wsrp.v2.UnsupportedLocale;
+import org.oasis.wsrp.v2.UnsupportedMimeType;
+import org.oasis.wsrp.v2.UnsupportedMode;
+import org.oasis.wsrp.v2.UnsupportedWindowState;
+import org.oasis.wsrp.v2.WSRPV2MarkupPortType;
+import org.oasis.wsrp.v2.WSRPV2PortletManagementPortType;
+import org.oasis.wsrp.v2.WSRPV2RegistrationPortType;
+import org.oasis.wsrp.v2.WSRPV2ServiceDescriptionPortType;
+
+/**
+ * @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
+ * @version $Revision: 11461 $
+ * @since 2.6
+ */
+public class BehaviorBackedServiceFactory implements ServiceFactory
+{
+ private BehaviorRegistry registry;
+ private final static String MARKUP = "markup";
+ private final static String SD_URL = "sd";
+ private final static String M_URL = "m";
+ private final static String PM_URL = "pm";
+ private final static String R_URL = "r";
+ private boolean initialized = false;
+ private String wsdl = DEFAULT_WSDL_URL;
+ public static final String DEFAULT_WSDL_URL = "http://example.com/producer?wsdl";
+ private int timeout;
+
+
+ public BehaviorBackedServiceFactory()
+ {
+ registry = new BehaviorRegistry();
+ registry.registerMarkupBehavior(new SimpleMarkupBehavior());
+ }
+
+ public <T> T getService(Class<T> serviceClass) throws Exception
+ {
+ if (!isAvailable() && !isFailed())
+ {
+ start();
+ }
+
+ if (WSRPV2ServiceDescriptionPortType.class.isAssignableFrom(serviceClass))
+ {
+ return (T)registry.getServiceDescriptionBehavior();
+ }
+ if (WSRPV2MarkupPortType.class.isAssignableFrom(serviceClass))
+ {
+ return (T)registry.getMarkupBehaviorFor(MARKUP);
+ }
+ if (WSRPV2PortletManagementPortType.class.isAssignableFrom(serviceClass))
+ {
+ return (T)registry.getPortletManagementBehavior();
+ }
+ if (WSRPV2RegistrationPortType.class.isAssignableFrom(serviceClass))
+ {
+ return (T)registry.getRegistrationBehavior();
+ }
+ return null;
+ }
+
+ public BehaviorRegistry getRegistry()
+ {
+ return registry;
+ }
+
+ public void setRegistry(BehaviorRegistry registry)
+ {
+ this.registry = registry;
+ }
+
+ public boolean isAvailable()
+ {
+ return initialized;
+ }
+
+ public boolean isFailed()
+ {
+ return false;
+ }
+
+ public void setFailed(boolean failed)
+ {
+ // do nothing
+ }
+
+ public void setWSOperationTimeOut(int msBeforeTimeOut)
+ {
+ if (msBeforeTimeOut < 0)
+ {
+ msBeforeTimeOut = DEFAULT_TIMEOUT_MS;
+ }
+
+ timeout = msBeforeTimeOut;
+ }
+
+ public int getWSOperationTimeOut()
+ {
+ return timeout;
+ }
+
+ public String getServiceDescriptionURL()
+ {
+ return SD_URL;
+ }
+
+ public String getMarkupURL()
+ {
+ return M_URL;
+ }
+
+ public String getRegistrationURL()
+ {
+ return R_URL;
+ }
+
+ public String getPortletManagementURL()
+ {
+ return PM_URL;
+ }
+
+ public void setServiceDescriptionURL(String serviceDescriptionURL)
+ {
+ // do nothing
+ }
+
+ public void setMarkupURL(String markupURL)
+ {
+ // do nothing
+ }
+
+ public void setRegistrationURL(String registrationURL)
+ {
+ // do nothing
+ }
+
+ public void setPortletManagementURL(String portletManagementURL)
+ {
+ // do nothing
+ }
+
+ public void create() throws Exception
+ {
+ throw new NotYetImplemented();
+ }
+
+ public void start() throws Exception
+ {
+ initialized = true;
+ }
+
+ public void stop()
+ {
+ throw new NotYetImplemented();
+ }
+
+ public void setWsdlDefinitionURL(String wsdlDefinitionURL)
+ {
+ wsdl = wsdlDefinitionURL;
+ }
+
+ public String getWsdlDefinitionURL()
+ {
+ return wsdl;
+ }
+
+ public void destroy()
+ {
+ throw new NotYetImplemented();
+ }
+
+ private class SimpleMarkupBehavior extends MarkupBehavior
+ {
+ public SimpleMarkupBehavior()
+ {
+ super(BehaviorBackedServiceFactory.this.registry);
+ registerHandle(MARKUP);
+ }
+
+ @Override
+ protected String getMarkupString(Mode mode, WindowState windowState, String navigationalState, GetMarkup getMarkup) throws UnsupportedWindowState, InvalidCookie, InvalidSession, AccessDenied, InconsistentParameters, InvalidHandle, UnsupportedLocale, UnsupportedMode, OperationFailed, MissingParameters, InvalidUserCategory, InvalidRegistration, UnsupportedMimeType
+ {
+ return MARKUP;
+ }
+ }
+}
\ No newline at end of file
Added: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/BehaviorRegistry.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/BehaviorRegistry.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/BehaviorRegistry.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,111 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v2;
+
+import org.gatein.wsrp.WSRPExceptionFactory;
+import org.oasis.wsrp.v2.InvalidHandle;
+import org.oasis.wsrp.v2.InvalidHandleFault;
+
+import java.util.HashMap;
+import java.util.Map;
+
+/**
+ * @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
+ * @version $Revision: 9360 $
+ * @since 2.6
+ */
+public class BehaviorRegistry
+{
+ private final Map<String, MarkupBehavior> behaviors = new HashMap<String, MarkupBehavior>();
+ private PortletManagementBehavior portletManagementBehavior;
+ private ServiceDescriptionBehavior serviceDescriptionBehavior;
+ private RegistrationBehavior registrationBehavior;
+
+ public ServiceDescriptionBehavior getServiceDescriptionBehavior()
+ {
+ // this is required since the consumer will try to access the producer as soon as it's started and the test
+ // producer will not be properly setup at that time since it's set up in the test's setUp method...
+ if (serviceDescriptionBehavior == null)
+ {
+ return ServiceDescriptionBehavior.DEFAULT;
+ }
+
+ return serviceDescriptionBehavior;
+ }
+
+ public void clear()
+ {
+ behaviors.clear();
+ }
+
+ public MarkupBehavior getMarkupBehaviorFor(String handle) throws InvalidHandle
+ {
+ if (behaviors.containsKey(handle))
+ {
+ return behaviors.get(handle);
+ }
+ throw WSRPExceptionFactory.<InvalidHandle, InvalidHandleFault>throwWSException(WSRPExceptionFactory.INVALID_HANDLE,
+ "There is no registered MarkupBehavior for handle '" + handle + "'", null);
+ }
+
+ public void registerMarkupBehavior(MarkupBehavior behavior)
+ {
+ for (String handle : behavior.getSupportedHandles())
+ {
+ MarkupBehavior existing = behaviors.get(handle);
+ if (existing != null)
+ {
+ throw new IllegalArgumentException("Cannot register behavior " + behavior.getClass().getName()
+ + " because it uses a handle '" + handle + "' that's already associated with behavior "
+ + existing.getClass().getName());
+ }
+ behaviors.put(handle, behavior);
+ }
+ }
+
+ public PortletManagementBehavior getPortletManagementBehavior()
+ {
+ return portletManagementBehavior;
+ }
+
+ public void setPortletManagementBehavior(PortletManagementBehavior portletManagementBehavior)
+ {
+ this.portletManagementBehavior = portletManagementBehavior;
+ }
+
+ public void setServiceDescriptionBehavior(ServiceDescriptionBehavior serviceDescriptionBehavior)
+ {
+ this.serviceDescriptionBehavior = serviceDescriptionBehavior;
+ }
+
+ public RegistrationBehavior getRegistrationBehavior()
+ {
+ return registrationBehavior;
+ }
+
+ public void setRegistrationBehavior(RegistrationBehavior registrationBehavior)
+ {
+ this.registrationBehavior = registrationBehavior;
+ }
+}
Property changes on: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/BehaviorRegistry.java
___________________________________________________________________
Name: svn:executable
+ *
Added: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/MarkupBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/MarkupBehavior.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/MarkupBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,187 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v2;
+
+import org.gatein.common.NotYetImplemented;
+import org.gatein.common.net.media.MediaType;
+import org.gatein.pc.api.Mode;
+import org.gatein.pc.api.WindowState;
+import org.gatein.wsrp.WSRPTypeFactory;
+import org.gatein.wsrp.WSRPUtils;
+import org.oasis.wsrp.v2.AccessDenied;
+import org.oasis.wsrp.v2.EventParams;
+import org.oasis.wsrp.v2.Extension;
+import org.oasis.wsrp.v2.GetMarkup;
+import org.oasis.wsrp.v2.HandleEventsFailed;
+import org.oasis.wsrp.v2.InconsistentParameters;
+import org.oasis.wsrp.v2.InteractionParams;
+import org.oasis.wsrp.v2.InvalidCookie;
+import org.oasis.wsrp.v2.InvalidHandle;
+import org.oasis.wsrp.v2.InvalidRegistration;
+import org.oasis.wsrp.v2.InvalidSession;
+import org.oasis.wsrp.v2.InvalidUserCategory;
+import org.oasis.wsrp.v2.MarkupContext;
+import org.oasis.wsrp.v2.MarkupParams;
+import org.oasis.wsrp.v2.MarkupResponse;
+import org.oasis.wsrp.v2.MissingParameters;
+import org.oasis.wsrp.v2.ModifyRegistrationRequired;
+import org.oasis.wsrp.v2.OperationFailed;
+import org.oasis.wsrp.v2.OperationNotSupported;
+import org.oasis.wsrp.v2.PortletContext;
+import org.oasis.wsrp.v2.PortletDescription;
+import org.oasis.wsrp.v2.PortletStateChangeRequired;
+import org.oasis.wsrp.v2.RegistrationContext;
+import org.oasis.wsrp.v2.ResourceContext;
+import org.oasis.wsrp.v2.ResourceParams;
+import org.oasis.wsrp.v2.ResourceSuspended;
+import org.oasis.wsrp.v2.RuntimeContext;
+import org.oasis.wsrp.v2.SessionContext;
+import org.oasis.wsrp.v2.UnsupportedLocale;
+import org.oasis.wsrp.v2.UnsupportedMimeType;
+import org.oasis.wsrp.v2.UnsupportedMode;
+import org.oasis.wsrp.v2.UnsupportedWindowState;
+import org.oasis.wsrp.v2.UpdateResponse;
+import org.oasis.wsrp.v2.UserContext;
+import org.oasis.wsrp.v2.WSRPV2MarkupPortType;
+
+import javax.jws.WebParam;
+import javax.xml.ws.Holder;
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * Behavior delivering Markup services.
+ *
+ * @author <a href="mailto:chris.laprun@jboss.com?subject=org.gatein.wsrp.test.AbstractMarkupBehavior">Chris Laprun</a>
+ * @version $Revision: 10337 $
+ * @since 2.6
+ */
+public abstract class MarkupBehavior extends TestProducerBehavior implements WSRPV2MarkupPortType
+{
+ private List<String> handles = new ArrayList<String>(3);
+ private BehaviorRegistry registry;
+
+
+ protected MarkupBehavior(BehaviorRegistry registry)
+ {
+ this.registry = registry;
+ }
+
+ /**
+ * Returns a markup String based on the passed information.
+ *
+ * @param mode the requested mode
+ * @param windowState the requested window state
+ * @param navigationalState the current navigational state
+ * @param getMarkup the original GetMarkup request (in case more information is required by this behavior)
+ * @return a possibly <code>null</code> markup String
+ */
+ protected abstract String getMarkupString(Mode mode, WindowState windowState, String navigationalState, GetMarkup getMarkup)
+ throws UnsupportedWindowState, InvalidCookie, InvalidSession, AccessDenied, InconsistentParameters, InvalidHandle,
+ UnsupportedLocale, UnsupportedMode, OperationFailed, MissingParameters, InvalidUserCategory, InvalidRegistration,
+ UnsupportedMimeType;
+
+ /**
+ * Allows this behavior to modify the response after the markup has been generated. The default implementation does
+ * nothing.
+ *
+ * @param markupResponse the response that will be passed on to the consumer
+ */
+ public void modifyResponseIfNeeded(MarkupResponse markupResponse)
+ {
+ // default implementation does not nothing
+ }
+
+ public List<String> getSupportedHandles()
+ {
+ return handles;
+ }
+
+ public PortletDescription getPortletDescriptionFor(String handle)
+ {
+ if (handles.contains(handle))
+ {
+ return createPortletDescription(handle, getSuffixFor(handle));
+ }
+ throw new IllegalArgumentException("MarkupBehavior " + getClass().getName() + " is not associated with handle '"
+ + handle + "'");
+ }
+
+ protected String getSuffixFor(String handle)
+ {
+ return "";
+ }
+
+ protected void registerHandle(String handle)
+ {
+ handles.add(handle);
+ registry.getServiceDescriptionBehavior().addPortletDescription(createPortletDescription(handle, getSuffixFor(handle)));
+ }
+
+ public void getResource(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.INOUT) Holder<PortletContext> portletContext, @WebParam(name = "runtimeContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RuntimeContext runtimeContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "resourceParams", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") ResourceParams resourceParams, @WebParam(name = "resourceContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceContext> resourceContext, @WebParam(name = "sessionContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<SessionContext> sessionContext, @WebPara!
m(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidCookie, InvalidHandle, InvalidRegistration, InvalidSession, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended, UnsupportedLocale, UnsupportedMimeType, UnsupportedMode, UnsupportedWindowState
+ {
+ throw new NotYetImplemented();
+ }
+
+ public void performBlockingInteraction(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "runtimeContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RuntimeContext runtimeContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "markupParams", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") MarkupParams markupParams, @WebParam(name = "interactionParams", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") InteractionParams interactionParams, @WebParam(name = "updateResponse", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<UpdateResponse> updateResponse, @WebParam(name = "redirectURL", targetNamespace = "urn:oasis:na!
mes:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<String> redirectURL, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidCookie, InvalidHandle, InvalidRegistration, InvalidSession, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, PortletStateChangeRequired, ResourceSuspended, UnsupportedLocale, UnsupportedMimeType, UnsupportedMode, UnsupportedWindowState
+ {
+ // do nothing
+ }
+
+ public void handleEvents(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "runtimeContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RuntimeContext runtimeContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "markupParams", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") MarkupParams markupParams, @WebParam(name = "eventParams", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") EventParams eventParams, @WebParam(name = "updateResponse", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<UpdateResponse> updateResponse, @WebParam(name = "failedEvents", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = W!
ebParam.Mode.OUT) Holder<List<HandleEventsFailed>> failedEvents, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidCookie, InvalidHandle, InvalidRegistration, InvalidSession, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, PortletStateChangeRequired, ResourceSuspended, UnsupportedLocale, UnsupportedMimeType, UnsupportedMode, UnsupportedWindowState
+ {
+ throw new NotYetImplemented();
+ }
+
+ public List<Extension> releaseSessions(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "sessionIDs", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> sessionIDs, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext) throws AccessDenied, InvalidRegistration, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ throw new NotYetImplemented();
+ }
+
+ public void getMarkup(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "runtimeContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RuntimeContext runtimeContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "markupParams", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") MarkupParams markupParams, @WebParam(name = "markupContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<MarkupContext> markupContext, @WebParam(name = "sessionContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<SessionContext> sessionContext, @WebParam(name = "extensions", targetNamespace = "urn:oasi!
s:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidCookie, InvalidHandle, InvalidRegistration, InvalidSession, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, ResourceSuspended, UnsupportedLocale, UnsupportedMimeType, UnsupportedMode, UnsupportedWindowState
+ {
+ GetMarkup gm = new GetMarkup();
+ gm.setMarkupParams(markupParams);
+ gm.setPortletContext(portletContext);
+ gm.setRegistrationContext(registrationContext);
+ gm.setRuntimeContext(runtimeContext);
+ gm.setUserContext(userContext);
+
+ String markupString = getMarkupString(WSRPUtils.getJSR168PortletModeFromWSRPName(markupParams.getMode()),
+ WSRPUtils.getJSR168WindowStateFromWSRPName(markupParams.getWindowState()),
+ markupParams.getNavigationalContext().getOpaqueValue(), gm);
+
+ markupContext.value = WSRPTypeFactory.createMarkupContext(MediaType.TEXT_HTML.getValue(), markupString);
+ markupContext.value.setRequiresRewriting(Boolean.TRUE);
+
+ MarkupResponse markupResponse = WSRPTypeFactory.createMarkupResponse(markupContext.value);
+
+ modifyResponseIfNeeded(markupResponse);
+ }
+
+ public List<Extension> initCookie(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext) throws AccessDenied, InvalidRegistration, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ return null;
+ }
+}
Property changes on: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/MarkupBehavior.java
___________________________________________________________________
Name: svn:executable
+ *
Added: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/PortletManagementBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/PortletManagementBehavior.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/PortletManagementBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,136 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v2;
+
+import org.gatein.common.NotYetImplemented;
+import org.oasis.wsrp.v2.AccessDenied;
+import org.oasis.wsrp.v2.CopiedPortlet;
+import org.oasis.wsrp.v2.ExportByValueNotSupported;
+import org.oasis.wsrp.v2.ExportNoLongerValid;
+import org.oasis.wsrp.v2.ExportedPortlet;
+import org.oasis.wsrp.v2.Extension;
+import org.oasis.wsrp.v2.FailedPortlets;
+import org.oasis.wsrp.v2.ImportPortlet;
+import org.oasis.wsrp.v2.ImportPortletsFailed;
+import org.oasis.wsrp.v2.ImportedPortlet;
+import org.oasis.wsrp.v2.InconsistentParameters;
+import org.oasis.wsrp.v2.InvalidHandle;
+import org.oasis.wsrp.v2.InvalidRegistration;
+import org.oasis.wsrp.v2.InvalidUserCategory;
+import org.oasis.wsrp.v2.Lifetime;
+import org.oasis.wsrp.v2.MissingParameters;
+import org.oasis.wsrp.v2.ModelDescription;
+import org.oasis.wsrp.v2.ModifyRegistrationRequired;
+import org.oasis.wsrp.v2.OperationFailed;
+import org.oasis.wsrp.v2.OperationNotSupported;
+import org.oasis.wsrp.v2.PortletContext;
+import org.oasis.wsrp.v2.PortletDescription;
+import org.oasis.wsrp.v2.PortletLifetime;
+import org.oasis.wsrp.v2.Property;
+import org.oasis.wsrp.v2.PropertyList;
+import org.oasis.wsrp.v2.RegistrationContext;
+import org.oasis.wsrp.v2.ResetProperty;
+import org.oasis.wsrp.v2.ResourceList;
+import org.oasis.wsrp.v2.ResourceSuspended;
+import org.oasis.wsrp.v2.SetExportLifetime;
+import org.oasis.wsrp.v2.UserContext;
+import org.oasis.wsrp.v2.WSRPV2PortletManagementPortType;
+
+import javax.jws.WebParam;
+import javax.xml.ws.Holder;
+import java.util.List;
+
+/**
+ * @author <a href="mailto:chris.laprun@jboss.com?subject=org.gatein.wsrp.test.PortletManagementBehavior">Chris
+ * Laprun</a>
+ * @version $Revision: 8784 $
+ * @since 2.6
+ */
+public class PortletManagementBehavior extends TestProducerBehavior implements WSRPV2PortletManagementPortType
+{
+ public void getPortletPropertyDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> desiredLocales, @WebParam(mode = WebParam.Mode.OUT, name = "modelDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<ModelDescription> modelDescription, @WebParam(mode = WebParam.Mode.OUT, name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<ResourceList> resourceList, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions) thro!
ws MissingParameters, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, AccessDenied, OperationFailed
+ {
+ incrementCallCount();
+ }
+
+ public void getPortletDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> desiredLocales, @WebParam(mode = WebParam.Mode.OUT, name = "portletDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<PortletDescription> portletDescription, @WebParam(mode = WebParam.Mode.OUT, name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<ResourceList> resourceList, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions) throws!
MissingParameters, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, AccessDenied, OperationFailed
+ {
+ incrementCallCount();
+ }
+
+ public void clonePortlet(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "lifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") Lifetime lifetime, @WebParam(name = "portletHandle", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<String> portletHandle, @WebParam(name = "portletState", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<byte[]> portletState, @WebParam(name = "scheduledDestruction", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<Lifetime> scheduledDestruction, @WebParam(name = "extensions", targetNamespace!
= "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ incrementCallCount();
+ }
+
+ public void destroyPortlets(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletHandles", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> portletHandles, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "failedPortlets", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<FailedPortlets>> failedPortlets, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws InconsistentParameters, InvalidRegistration, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ incrementCallCount();
+ }
+
+ public void getPortletsLifetime(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<PortletContext> portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "portletLifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<PortletLifetime>> portletLifetime, @WebParam(name = "failedPortlets", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<FailedPortlets>> failedPortlets, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT)!
Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ throw new NotYetImplemented();
+ }
+
+ public void setPortletsLifetime(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<PortletContext> portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "lifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") Lifetime lifetime, @WebParam(name = "updatedPortlet", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<PortletLifetime>> updatedPortlet, @WebParam(name = "failedPortlets", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<FailedPortlets>> failedPortlets, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(!
name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ throw new NotYetImplemented();
+ }
+
+ public void copyPortlets(@WebParam(name = "toRegistrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext toRegistrationContext, @WebParam(name = "toUserContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext toUserContext, @WebParam(name = "fromRegistrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext fromRegistrationContext, @WebParam(name = "fromUserContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext fromUserContext, @WebParam(name = "fromPortletContexts", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<PortletContext> fromPortletContexts, @WebParam(name = "lifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") Lifetime lifetime, @WebParam(name = "copiedPortlets", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<CopiedPortlet>> copiedPortlets, @WebParam(name = "failedPortlets", targetNamesp!
ace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<FailedPortlets>> failedPortlets, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ throw new NotYetImplemented();
+ }
+
+ public void exportPortlets(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<PortletContext> portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "lifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.INOUT) Holder<Lifetime> lifetime, @WebParam(name = "exportByValueRequired", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") Boolean exportByValueRequired, @WebParam(name = "exportContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<byte[]> exportContext, @WebParam(name = "exportedPortlet", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<ExportedPortlet>> exportedPortlet, @WebParam(name!
= "failedPortlets", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<FailedPortlets>> failedPortlets, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, ExportByValueNotSupported, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ throw new NotYetImplemented();
+ }
+
+ public void importPortlets(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "importContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") byte[] importContext, @WebParam(name = "importPortlet", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<ImportPortlet> importPortlet, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "lifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") Lifetime lifetime, @WebParam(name = "importedPortlets", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<ImportedPortlet>> importedPortlets, @WebParam(name = "importFailed", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<ImportPortletsFailed>> importFailed, @WebParam(name = "resourceList", targetNamespace =!
"urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, ExportNoLongerValid, InconsistentParameters, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ throw new NotYetImplemented();
+ }
+
+ public List<Extension> releaseExport(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "exportContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") byte[] exportContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext)
+ {
+ throw new NotYetImplemented();
+ }
+
+ public Lifetime setExportLifetime(@WebParam(name = "setExportLifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", partName = "setExportLifetime") SetExportLifetime setExportLifetime) throws AccessDenied, InvalidHandle, InvalidRegistration, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ throw new NotYetImplemented();
+ }
+
+ public void setPortletProperties(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "propertyList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PropertyList propertyList, @WebParam(name = "portletHandle", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<String> portletHandle, @WebParam(name = "portletState", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<byte[]> portletState, @WebParam(name = "scheduledDestruction", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<Lifetime> scheduledDestruction, @WebParam(name = "extensio!
ns", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ incrementCallCount();
+ }
+
+ public void getPortletProperties(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") UserContext userContext, @WebParam(name = "names", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> names, @WebParam(mode = WebParam.Mode.OUT, name = "properties", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Property>> properties, @WebParam(mode = WebParam.Mode.OUT, name = "resetProperties", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<ResetProperty>> resetProperties, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions) throws MissingParameters, Incons!
istentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, AccessDenied, OperationFailed
+ {
+ incrementCallCount();
+ }
+}
Property changes on: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/PortletManagementBehavior.java
___________________________________________________________________
Name: svn:executable
+ *
Added: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/RegistrationBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/RegistrationBehavior.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/RegistrationBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,83 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v2;
+
+import org.gatein.common.NotYetImplemented;
+import org.oasis.wsrp.v2.AccessDenied;
+import org.oasis.wsrp.v2.Extension;
+import org.oasis.wsrp.v2.GetRegistrationLifetime;
+import org.oasis.wsrp.v2.InvalidHandle;
+import org.oasis.wsrp.v2.InvalidRegistration;
+import org.oasis.wsrp.v2.Lifetime;
+import org.oasis.wsrp.v2.MissingParameters;
+import org.oasis.wsrp.v2.ModifyRegistrationRequired;
+import org.oasis.wsrp.v2.OperationFailed;
+import org.oasis.wsrp.v2.OperationNotSupported;
+import org.oasis.wsrp.v2.RegistrationContext;
+import org.oasis.wsrp.v2.RegistrationData;
+import org.oasis.wsrp.v2.ResourceSuspended;
+import org.oasis.wsrp.v2.SetRegistrationLifetime;
+import org.oasis.wsrp.v2.UserContext;
+import org.oasis.wsrp.v2.WSRPV2RegistrationPortType;
+
+import javax.jws.WebParam;
+import javax.xml.ws.Holder;
+import java.util.List;
+
+/**
+ * @author <a href="mailto:chris.laprun@jboss.com?subject=org.gatein.wsrp.test.RegistrationBehavior">Chris Laprun</a>
+ * @version $Revision: 8784 $
+ * @since 2.6
+ */
+public class RegistrationBehavior extends TestProducerBehavior implements WSRPV2RegistrationPortType
+{
+ public static final String REGISTRATION_HANDLE = "registration";
+
+ public void register(@WebParam(name = "registrationData", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationData registrationData, @WebParam(name = "lifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") Lifetime lifetime, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "registrationState", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<byte[]> registrationState, @WebParam(name = "scheduledDestruction", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<Lifetime> scheduledDestruction, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions, @WebParam(name = "registrationHandle", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<String> registrationHandle) throws Missi!
ngParameters, OperationFailed, OperationNotSupported
+ {
+ incrementCallCount();
+ registrationHandle.value = REGISTRATION_HANDLE;
+ }
+
+ public List<Extension> deregister(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext) throws InvalidRegistration, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ incrementCallCount();
+ return null;
+ }
+
+ public void modifyRegistration(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "registrationData", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationData registrationData, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "registrationState", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<byte[]> registrationState, @WebParam(name = "scheduledDestruction", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<Lifetime> scheduledDestruction, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws InvalidRegistration, MissingParameters, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ incrementCallCount();
+ }
+
+ public Lifetime getRegistrationLifetime(@WebParam(name = "getRegistrationLifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", partName = "getRegistrationLifetime") GetRegistrationLifetime getRegistrationLifetime) throws AccessDenied, InvalidHandle, InvalidRegistration, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ throw new NotYetImplemented();
+ }
+
+ public Lifetime setRegistrationLifetime(@WebParam(name = "setRegistrationLifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", partName = "setRegistrationLifetime") SetRegistrationLifetime setRegistrationLifetime) throws AccessDenied, InvalidHandle, InvalidRegistration, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ throw new NotYetImplemented();
+ }
+}
Property changes on: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/RegistrationBehavior.java
___________________________________________________________________
Name: svn:executable
+ *
Added: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/ServiceDescriptionBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/ServiceDescriptionBehavior.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/ServiceDescriptionBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,148 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v2;
+
+import org.gatein.wsrp.WSRPConstants;
+import org.gatein.wsrp.WSRPTypeFactory;
+import org.oasis.wsrp.v2.CookieProtocol;
+import org.oasis.wsrp.v2.EventDescription;
+import org.oasis.wsrp.v2.ExportDescription;
+import org.oasis.wsrp.v2.Extension;
+import org.oasis.wsrp.v2.ExtensionDescription;
+import org.oasis.wsrp.v2.InvalidRegistration;
+import org.oasis.wsrp.v2.ItemDescription;
+import org.oasis.wsrp.v2.ModelDescription;
+import org.oasis.wsrp.v2.ModelTypes;
+import org.oasis.wsrp.v2.ModifyRegistrationRequired;
+import org.oasis.wsrp.v2.OperationFailed;
+import org.oasis.wsrp.v2.PortletDescription;
+import org.oasis.wsrp.v2.PropertyDescription;
+import org.oasis.wsrp.v2.RegistrationContext;
+import org.oasis.wsrp.v2.ResourceList;
+import org.oasis.wsrp.v2.ResourceSuspended;
+import org.oasis.wsrp.v2.ServiceDescription;
+import org.oasis.wsrp.v2.UserContext;
+import org.oasis.wsrp.v2.WSRPV2ServiceDescriptionPortType;
+
+import javax.jws.WebParam;
+import javax.xml.ws.Holder;
+import java.util.ArrayList;
+import java.util.HashSet;
+import java.util.LinkedList;
+import java.util.List;
+import java.util.Set;
+
+/**
+ * @author <a href="mailto:chris.laprun@jboss.com?subject=org.gatein.wsrp.test.ServiceDescriptionBehavior">Chris
+ * Laprun</a>
+ * @version $Revision: 11320 $
+ * @since 2.6
+ */
+public class ServiceDescriptionBehavior extends TestProducerBehavior implements WSRPV2ServiceDescriptionPortType
+{
+ protected ServiceDescription serviceDescription;
+ private static final ServiceDescription DEFAULT_SERVICE_DESCRIPTION = WSRPTypeFactory.createServiceDescription(false);
+ public static final ServiceDescriptionBehavior DEFAULT = new ServiceDescriptionBehavior();
+
+ protected List<PortletDescription> offeredPortlets;
+ private boolean requiresRegistration;
+ private CookieProtocol cookieProtocol;
+ private ModelDescription registrationProperties;
+
+ public ServiceDescriptionBehavior()
+ {
+ offeredPortlets = new LinkedList<PortletDescription>();
+ }
+
+ public void setRequiresRegistration(boolean requiresRegistration)
+ {
+ this.requiresRegistration = requiresRegistration;
+ }
+
+ public void setRequiresInitCookie(CookieProtocol requiresInitCookie)
+ {
+ this.cookieProtocol = requiresInitCookie;
+ }
+
+ public void setServiceDescription(boolean requiresRegistration, int numberOfProps)
+ {
+ ServiceDescription sd = createServiceDescription(requiresRegistration, numberOfProps);
+ offeredPortlets = sd.getOfferedPortlets();
+ this.requiresRegistration = sd.isRequiresRegistration();
+ registrationProperties = sd.getRegistrationPropertyDescription();
+ }
+
+ public static ServiceDescription getDefaultServiceDescription()
+ {
+ return DEFAULT_SERVICE_DESCRIPTION;
+ }
+
+ public void addPortletDescription(PortletDescription portletDescription)
+ {
+ offeredPortlets.add(portletDescription);
+ }
+
+ public Set<String> getPortletHandles()
+ {
+ Set<String> handles = new HashSet<String>(offeredPortlets.size());
+
+ for (PortletDescription description : offeredPortlets)
+ {
+ handles.add(description.getPortletHandle());
+ }
+
+ return handles;
+ }
+
+ public int getPortletNumber()
+ {
+ return offeredPortlets.size();
+ }
+
+ public static ServiceDescription createServiceDescription(boolean requiresRegistration, int numberOfProperties)
+ {
+ ServiceDescription sd = WSRPTypeFactory.createServiceDescription(requiresRegistration);
+
+ if (requiresRegistration)
+ {
+ List<PropertyDescription> descriptions = new ArrayList<PropertyDescription>(numberOfProperties);
+ for (int i = 0; i < numberOfProperties; i++)
+ {
+ descriptions.add(WSRPTypeFactory.createPropertyDescription("prop" + i, WSRPConstants.XSD_STRING));
+ }
+ sd.setRegistrationPropertyDescription(WSRPTypeFactory.createModelDescription(descriptions));
+ }
+
+ return sd;
+ }
+
+ public void getServiceDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> desiredLocales, @WebParam(name = "portletHandles", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> portletHandles, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "requiresRegistration", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<Boolean> requiresRegistration, @WebParam(name = "offeredPortlets", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<PortletDescription>> offeredPortlets, @WebParam(name = "userCategoryDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<ItemDes!
cription>> userCategoryDescriptions, @WebParam(name = "extensionDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<ExtensionDescription>> extensionDescriptions, @WebParam(name = "customWindowStateDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<ItemDescription>> customWindowStateDescriptions, @WebParam(name = "customModeDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<ItemDescription>> customModeDescriptions, @WebParam(name = "requiresInitCookie", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<CookieProtocol> requiresInitCookie, @WebParam(name = "registrationPropertyDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ModelDescription> registrationPropertyDescription, @WebParam(name = "locales", targetNamespace = "urn:!
oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holde!
r<List<S
tring>> locales, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(name = "eventDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<EventDescription>> eventDescriptions, @WebParam(name = "schemaType", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ModelTypes> schemaType, @WebParam(name = "supportedOptions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<String>> supportedOptions, @WebParam(name = "exportDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ExportDescription> exportDescription, @WebParam(name = "mayReturnRegistrationState", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<Boolean> mayReturnRegistrationState, @WebParam(name = "extens!
ions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws InvalidRegistration, ModifyRegistrationRequired, OperationFailed, ResourceSuspended
+ {
+ incrementCallCount();
+ offeredPortlets.value = this.offeredPortlets;
+ requiresRegistration.value = this.requiresRegistration;
+ requiresInitCookie.value = this.cookieProtocol;
+ registrationPropertyDescription.value = registrationProperties;
+ }
+}
Property changes on: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/ServiceDescriptionBehavior.java
___________________________________________________________________
Name: svn:executable
+ *
Added: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/TestProducerBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/TestProducerBehavior.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/TestProducerBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,99 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v2;
+
+import org.gatein.common.net.media.MediaType;
+import org.gatein.wsrp.WSRPConstants;
+import org.gatein.wsrp.WSRPTypeFactory;
+import org.oasis.wsrp.v2.LocalizedString;
+import org.oasis.wsrp.v2.MarkupType;
+import org.oasis.wsrp.v2.PortletDescription;
+
+/**
+ * Provides a base class for Producer behavior used in Consumer testing.
+ *
+ * @author <a href="mailto:chris.laprun@jboss.com?subject=org.gatein.wsrp.test.TestProducerBehavior">Chris Laprun</a>
+ * @version $Revision: 11317 $
+ * @since 2.6
+ */
+public abstract class TestProducerBehavior
+{
+ protected int callCount;
+ public static final String SAMPLE_DESCRIPTION = "SampleDescription";
+ public static final String SAMPLE_SHORTTITLE = "SampleShortTitle";
+ public static final String SAMPLE_TITLE = "SampleTitle";
+ public static final String SAMPLE_DISPLAYNAME = "SampleDisplayName";
+ public static final String SAMPLE_KEYWORD = "keyword";
+
+ /**
+ * Increment the number of times methods of this behavior have been called. Used when the behavior changes depending
+ * on how many times methods have been called.
+ */
+ public void incrementCallCount()
+ {
+ callCount++;
+ }
+
+ public int getCallCount()
+ {
+ return callCount;
+ }
+
+ public PortletDescription createPortletDescription(String portletHandle, String suffix)
+ {
+ PortletDescription portletDesc = new PortletDescription();
+ portletDesc.setPortletHandle(portletHandle);
+ MarkupType markupType = new MarkupType();
+ markupType.setMimeType(MediaType.TEXT_HTML.getValue());
+ markupType.getModes().add(WSRPConstants.VIEW_MODE);
+ markupType.getWindowStates().add(WSRPConstants.NORMAL_WINDOW_STATE);
+ markupType.getLocales().addAll(WSRPConstants.getDefaultLocales());
+ portletDesc.getMarkupTypes().add(markupType);
+
+ String suffixString = suffix == null ? "" : suffix;
+ portletDesc.setDescription(createLocalizedString(SAMPLE_DESCRIPTION + suffixString));
+ portletDesc.setTitle(createLocalizedString(SAMPLE_TITLE + suffixString));
+ portletDesc.setShortTitle(createLocalizedString(SAMPLE_SHORTTITLE + suffixString));
+ portletDesc.setDisplayName(createLocalizedString(SAMPLE_DISPLAYNAME + suffixString));
+ portletDesc.getKeywords().add(createLocalizedString(SAMPLE_KEYWORD + suffixString));
+ return portletDesc;
+ }
+
+ /**
+ * Create the dummiest form of LocalizedString
+ *
+ * @param value
+ * @return
+ */
+ public static LocalizedString createLocalizedString(String value)
+ {
+ return WSRPTypeFactory.createLocalizedString(value);
+ }
+
+ /** Produces String from LocalizedString */
+ public static String extractString(org.gatein.common.i18n.LocalizedString ls)
+ {
+ return ls.getPreferredOrBestLocalizedMappingFor(new String[]{"en"}).getString();
+ }
+}
Property changes on: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/TestProducerBehavior.java
___________________________________________________________________
Name: svn:executable
+ *
Added: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/TestWSRPProducer.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/TestWSRPProducer.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/TestWSRPProducer.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,52 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v2;
+
+import org.oasis.wsrp.v2.CookieProtocol;
+
+/**
+ * Exposes WSPRProducer test implementation methods - we inject what it returns
+ *
+ * @author <a href="mailto:boleslaw.dawidowicz@jboss.org">Boleslaw Dawidowicz</a>
+ * @version $Revision: 10610 $
+ */
+public interface TestWSRPProducer
+{
+ /** Resets any currently held state. */
+ void reset();
+
+ BehaviorRegistry getBehaviorRegistry();
+
+ /**
+ * Sets the currently used portlet handle identifying the MarkupBehavior we're using. This is needed to be able to
+ * dispatch calls to initCookie to the proper behavior.
+ *
+ * @param handle
+ */
+ void setCurrentMarkupBehaviorHandle(String handle);
+
+ void setRequiresInitCookie(CookieProtocol requiresInitCookie);
+
+ void usingStrictModeChangedTo(boolean strictMode);
+}
Property changes on: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/TestWSRPProducer.java
___________________________________________________________________
Name: svn:executable
+ *
Added: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/TestWSRPProducerImpl.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/TestWSRPProducerImpl.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/TestWSRPProducerImpl.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,330 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v2;
+
+import org.gatein.common.NotYetImplemented;
+import org.gatein.wsrp.WSRPExceptionFactory;
+import org.oasis.wsrp.v2.AccessDenied;
+import org.oasis.wsrp.v2.CookieProtocol;
+import org.oasis.wsrp.v2.CopiedPortlet;
+import org.oasis.wsrp.v2.EventDescription;
+import org.oasis.wsrp.v2.EventParams;
+import org.oasis.wsrp.v2.ExportByValueNotSupported;
+import org.oasis.wsrp.v2.ExportDescription;
+import org.oasis.wsrp.v2.ExportNoLongerValid;
+import org.oasis.wsrp.v2.ExportedPortlet;
+import org.oasis.wsrp.v2.Extension;
+import org.oasis.wsrp.v2.ExtensionDescription;
+import org.oasis.wsrp.v2.FailedPortlets;
+import org.oasis.wsrp.v2.GetRegistrationLifetime;
+import org.oasis.wsrp.v2.HandleEventsFailed;
+import org.oasis.wsrp.v2.ImportPortlet;
+import org.oasis.wsrp.v2.ImportPortletsFailed;
+import org.oasis.wsrp.v2.ImportedPortlet;
+import org.oasis.wsrp.v2.InconsistentParameters;
+import org.oasis.wsrp.v2.InteractionParams;
+import org.oasis.wsrp.v2.InvalidCookie;
+import org.oasis.wsrp.v2.InvalidHandle;
+import org.oasis.wsrp.v2.InvalidRegistration;
+import org.oasis.wsrp.v2.InvalidSession;
+import org.oasis.wsrp.v2.InvalidUserCategory;
+import org.oasis.wsrp.v2.ItemDescription;
+import org.oasis.wsrp.v2.Lifetime;
+import org.oasis.wsrp.v2.MarkupContext;
+import org.oasis.wsrp.v2.MarkupParams;
+import org.oasis.wsrp.v2.MissingParameters;
+import org.oasis.wsrp.v2.ModelDescription;
+import org.oasis.wsrp.v2.ModelTypes;
+import org.oasis.wsrp.v2.ModifyRegistrationRequired;
+import org.oasis.wsrp.v2.OperationFailed;
+import org.oasis.wsrp.v2.OperationFailedFault;
+import org.oasis.wsrp.v2.OperationNotSupported;
+import org.oasis.wsrp.v2.PortletContext;
+import org.oasis.wsrp.v2.PortletDescription;
+import org.oasis.wsrp.v2.PortletLifetime;
+import org.oasis.wsrp.v2.PortletStateChangeRequired;
+import org.oasis.wsrp.v2.Property;
+import org.oasis.wsrp.v2.PropertyList;
+import org.oasis.wsrp.v2.RegistrationContext;
+import org.oasis.wsrp.v2.RegistrationData;
+import org.oasis.wsrp.v2.ResetProperty;
+import org.oasis.wsrp.v2.ResourceContext;
+import org.oasis.wsrp.v2.ResourceList;
+import org.oasis.wsrp.v2.ResourceParams;
+import org.oasis.wsrp.v2.ResourceSuspended;
+import org.oasis.wsrp.v2.RuntimeContext;
+import org.oasis.wsrp.v2.SessionContext;
+import org.oasis.wsrp.v2.SetExportLifetime;
+import org.oasis.wsrp.v2.SetRegistrationLifetime;
+import org.oasis.wsrp.v2.UnsupportedLocale;
+import org.oasis.wsrp.v2.UnsupportedMimeType;
+import org.oasis.wsrp.v2.UnsupportedMode;
+import org.oasis.wsrp.v2.UnsupportedWindowState;
+import org.oasis.wsrp.v2.UpdateResponse;
+import org.oasis.wsrp.v2.UserContext;
+import org.oasis.wsrp.v2.WSRPV2MarkupPortType;
+import org.oasis.wsrp.v2.WSRPV2PortletManagementPortType;
+import org.oasis.wsrp.v2.WSRPV2RegistrationPortType;
+import org.oasis.wsrp.v2.WSRPV2ServiceDescriptionPortType;
+
+import javax.jws.WebParam;
+import javax.xml.ws.Holder;
+import java.util.List;
+
+/**
+ * This is dummy clone of org.jboss.portal.wsrp.producer.WSRPProducerImpl customizable from client side. Just for
+ * consumer implementation testing purposes.
+ *
+ * @author <a href="mailto:Boleslaw.Dawidowicz@jboss.com">Boleslaw Dawidowicz</a>
+ * @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
+ * @version $Revision: 12020 $
+ * @since 2.4
+ */
+public class TestWSRPProducerImpl implements TestWSRPProducer, WSRPV2MarkupPortType, WSRPV2PortletManagementPortType, WSRPV2RegistrationPortType, WSRPV2ServiceDescriptionPortType
+{
+ private int sessionExpirationTime = 600;
+
+ private CookieProtocol requiresInitCookie = CookieProtocol.NONE;
+
+ private BehaviorRegistry behaviorRegistry = new BehaviorRegistry();
+
+ public static final String USER_COOKIE = "cookie";
+
+ private String currentMarkupBehaviorHandle;
+
+ private boolean strict = true;
+
+ public TestWSRPProducerImpl()
+ {
+ reset();
+ }
+
+ public BehaviorRegistry getBehaviorRegistry()
+ {
+ return behaviorRegistry;
+ }
+
+ public void setCurrentMarkupBehaviorHandle(String handle)
+ {
+ currentMarkupBehaviorHandle = handle;
+ }
+
+ public void reset()
+ {
+ requiresInitCookie = null;
+ currentMarkupBehaviorHandle = null;
+ behaviorRegistry.clear();
+ }
+
+ private MarkupBehavior getMarkupBehaviorFor(String portletHandle) throws InvalidHandle
+ {
+ return behaviorRegistry.getMarkupBehaviorFor(portletHandle);
+ }
+
+ private ServiceDescriptionBehavior getServiceDescriptionBehavior()
+ {
+ return behaviorRegistry.getServiceDescriptionBehavior();
+ }
+
+ public PortletManagementBehavior getPortletManagementBehavior()
+ {
+ return behaviorRegistry.getPortletManagementBehavior();
+ }
+
+ // ServiceDescription implementation ********************************************************************************
+
+
+ public void getServiceDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> desiredLocales, @WebParam(name = "portletHandles", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> portletHandles, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "requiresRegistration", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<Boolean> requiresRegistration, @WebParam(name = "offeredPortlets", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<PortletDescription>> offeredPortlets, @WebParam(name = "userCategoryDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<ItemDes!
cription>> userCategoryDescriptions, @WebParam(name = "extensionDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<ExtensionDescription>> extensionDescriptions, @WebParam(name = "customWindowStateDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<ItemDescription>> customWindowStateDescriptions, @WebParam(name = "customModeDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<ItemDescription>> customModeDescriptions, @WebParam(name = "requiresInitCookie", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<CookieProtocol> requiresInitCookie, @WebParam(name = "registrationPropertyDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ModelDescription> registrationPropertyDescription, @WebParam(name = "locales", targetNamespace = "urn:!
oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holde!
r<List<S
tring>> locales, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(name = "eventDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<EventDescription>> eventDescriptions, @WebParam(name = "schemaType", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ModelTypes> schemaType, @WebParam(name = "supportedOptions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<String>> supportedOptions, @WebParam(name = "exportDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ExportDescription> exportDescription, @WebParam(name = "mayReturnRegistrationState", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<Boolean> mayReturnRegistrationState, @WebParam(name = "extens!
ions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws InvalidRegistration, ModifyRegistrationRequired, OperationFailed, ResourceSuspended
+ {
+ getServiceDescriptionBehavior().getServiceDescription(registrationContext, desiredLocales, portletHandles, userContext, requiresRegistration, offeredPortlets, userCategoryDescriptions, extensionDescriptions, customWindowStateDescriptions, customModeDescriptions, requiresInitCookie, registrationPropertyDescription, locales, resourceList, eventDescriptions, schemaType, supportedOptions, exportDescription, mayReturnRegistrationState, extensions);
+ }
+
+ // MarkupService implementation *************************************************************************************
+
+ public void getMarkup(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "runtimeContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RuntimeContext runtimeContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "markupParams", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") MarkupParams markupParams, @WebParam(name = "markupContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<MarkupContext> markupContext, @WebParam(name = "sessionContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<SessionContext> sessionContext, @WebParam(name = "extensions", targetNamespace = "urn:oasi!
s:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidCookie, InvalidHandle, InvalidRegistration, InvalidSession, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, ResourceSuspended, UnsupportedLocale, UnsupportedMimeType, UnsupportedMode, UnsupportedWindowState
+ {
+ getMarkupBehaviorFor(portletContext.getPortletHandle()).getMarkup(registrationContext, portletContext, runtimeContext, userContext, markupParams, markupContext, sessionContext, extensions);
+ }
+
+ public void getResource(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.INOUT) Holder<PortletContext> portletContext, @WebParam(name = "runtimeContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RuntimeContext runtimeContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "resourceParams", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") ResourceParams resourceParams, @WebParam(name = "resourceContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceContext> resourceContext, @WebParam(name = "sessionContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<SessionContext> sessionContext, @WebPara!
m(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidCookie, InvalidHandle, InvalidRegistration, InvalidSession, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended, UnsupportedLocale, UnsupportedMimeType, UnsupportedMode, UnsupportedWindowState
+ {
+ getMarkupBehaviorFor(portletContext.value.getPortletHandle()).getResource(registrationContext, portletContext, runtimeContext, userContext, resourceParams, resourceContext, sessionContext, extensions);
+ }
+
+ public void performBlockingInteraction(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "runtimeContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RuntimeContext runtimeContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "markupParams", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") MarkupParams markupParams, @WebParam(name = "interactionParams", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") InteractionParams interactionParams, @WebParam(name = "updateResponse", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<UpdateResponse> updateResponse, @WebParam(name = "redirectURL", targetNamespace = "urn:oasis:na!
mes:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<String> redirectURL, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidCookie, InvalidHandle, InvalidRegistration, InvalidSession, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, PortletStateChangeRequired, ResourceSuspended, UnsupportedLocale, UnsupportedMimeType, UnsupportedMode, UnsupportedWindowState
+ {
+ getMarkupBehaviorFor(portletContext.getPortletHandle()).performBlockingInteraction(registrationContext, portletContext, runtimeContext, userContext, markupParams, interactionParams, updateResponse, redirectURL, extensions);
+ }
+
+ public void handleEvents(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "runtimeContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RuntimeContext runtimeContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "markupParams", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") MarkupParams markupParams, @WebParam(name = "eventParams", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") EventParams eventParams, @WebParam(name = "updateResponse", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<UpdateResponse> updateResponse, @WebParam(name = "failedEvents", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = W!
ebParam.Mode.OUT) Holder<List<HandleEventsFailed>> failedEvents, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidCookie, InvalidHandle, InvalidRegistration, InvalidSession, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, PortletStateChangeRequired, ResourceSuspended, UnsupportedLocale, UnsupportedMimeType, UnsupportedMode, UnsupportedWindowState
+ {
+ getMarkupBehaviorFor(portletContext.getPortletHandle()).handleEvents(registrationContext, portletContext, runtimeContext, userContext, markupParams, eventParams, updateResponse, failedEvents, extensions);
+ }
+
+ public List<Extension> releaseSessions(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "sessionIDs", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> sessionIDs, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext) throws AccessDenied, InvalidRegistration, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ throw new NotYetImplemented();
+ }
+
+ public List<Extension> initCookie(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext) throws AccessDenied, InvalidRegistration, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ // should only be called if we required cookies to be initialized
+ if (requiresInitCookie == null || CookieProtocol.NONE.equals(requiresInitCookie))
+ {
+ throw WSRPExceptionFactory.<OperationFailed, OperationFailedFault>throwWSException(WSRPExceptionFactory.OPERATION_FAILED, "Shouldn't have called initCookie", null);
+ }
+
+ try
+ {
+ return getMarkupBehaviorFor(currentMarkupBehaviorHandle).initCookie(registrationContext, userContext);
+ }
+ catch (InvalidHandle invalidHandle)
+ {
+ throw WSRPExceptionFactory.<OperationFailed, OperationFailedFault>throwWSException(WSRPExceptionFactory.OPERATION_FAILED, "Invalid handle", invalidHandle);
+ }
+ }
+
+ // Registration implementation **************************************************************************************
+
+ public void register(@WebParam(name = "registrationData", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationData registrationData, @WebParam(name = "lifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") Lifetime lifetime, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "registrationState", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<byte[]> registrationState, @WebParam(name = "scheduledDestruction", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<Lifetime> scheduledDestruction, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions, @WebParam(name = "registrationHandle", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<String> registrationHandle) throws Missi!
ngParameters, OperationFailed, OperationNotSupported
+ {
+ registrationHandle.value = "registration";
+ }
+
+ public List<Extension> deregister(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext) throws InvalidRegistration, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ return null;
+ }
+
+ public void modifyRegistration(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "registrationData", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationData registrationData, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "registrationState", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<byte[]> registrationState, @WebParam(name = "scheduledDestruction", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<Lifetime> scheduledDestruction, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws InvalidRegistration, MissingParameters, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ // do nothing
+ }
+
+ public Lifetime getRegistrationLifetime(@WebParam(name = "getRegistrationLifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", partName = "getRegistrationLifetime") GetRegistrationLifetime getRegistrationLifetime) throws AccessDenied, InvalidHandle, InvalidRegistration, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ throw new NotYetImplemented();
+ }
+
+ public Lifetime setRegistrationLifetime(@WebParam(name = "setRegistrationLifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", partName = "setRegistrationLifetime") SetRegistrationLifetime setRegistrationLifetime) throws AccessDenied, InvalidHandle, InvalidRegistration, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ throw new NotYetImplemented();
+ }
+
+ // PortletManagement implementation *********************************************************************************
+
+ public void getPortletDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> desiredLocales, @WebParam(name = "portletDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<PortletDescription> portletDescription, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws!
AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ getPortletManagementBehavior().getPortletDescription(registrationContext, portletContext, userContext, desiredLocales, portletDescription, resourceList, extensions);
+ }
+
+ public void clonePortlet(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "lifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") Lifetime lifetime, @WebParam(name = "portletHandle", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<String> portletHandle, @WebParam(name = "portletState", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<byte[]> portletState, @WebParam(name = "scheduledDestruction", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<Lifetime> scheduledDestruction, @WebParam(name = "extensions", targetNamespace!
= "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ getPortletManagementBehavior().clonePortlet(registrationContext, portletContext, userContext, lifetime, portletHandle, portletState, scheduledDestruction, extensions);
+ }
+
+ public void destroyPortlets(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletHandles", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> portletHandles, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "failedPortlets", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<FailedPortlets>> failedPortlets, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws InconsistentParameters, InvalidRegistration, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ getPortletManagementBehavior().destroyPortlets(registrationContext, portletHandles, userContext, failedPortlets, extensions);
+ }
+
+ public void getPortletsLifetime(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<PortletContext> portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "portletLifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<PortletLifetime>> portletLifetime, @WebParam(name = "failedPortlets", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<FailedPortlets>> failedPortlets, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT)!
Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ getPortletManagementBehavior().getPortletsLifetime(registrationContext, portletContext, userContext, portletLifetime, failedPortlets, resourceList, extensions);
+ }
+
+ public void setPortletsLifetime(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<PortletContext> portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "lifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") Lifetime lifetime, @WebParam(name = "updatedPortlet", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<PortletLifetime>> updatedPortlet, @WebParam(name = "failedPortlets", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<FailedPortlets>> failedPortlets, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(!
name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ getPortletManagementBehavior().setPortletsLifetime(registrationContext, portletContext, userContext, lifetime, updatedPortlet, failedPortlets, resourceList, extensions);
+ }
+
+ public void copyPortlets(@WebParam(name = "toRegistrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext toRegistrationContext, @WebParam(name = "toUserContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext toUserContext, @WebParam(name = "fromRegistrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext fromRegistrationContext, @WebParam(name = "fromUserContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext fromUserContext, @WebParam(name = "fromPortletContexts", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<PortletContext> fromPortletContexts, @WebParam(name = "lifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") Lifetime lifetime, @WebParam(name = "copiedPortlets", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<CopiedPortlet>> copiedPortlets, @WebParam(name = "failedPortlets", targetNamesp!
ace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<FailedPortlets>> failedPortlets, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ getPortletManagementBehavior().copyPortlets(toRegistrationContext, toUserContext, fromRegistrationContext, fromUserContext, fromPortletContexts, lifetime, copiedPortlets, failedPortlets, resourceList, extensions);
+ }
+
+ public void exportPortlets(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<PortletContext> portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "lifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.INOUT) Holder<Lifetime> lifetime, @WebParam(name = "exportByValueRequired", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") Boolean exportByValueRequired, @WebParam(name = "exportContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<byte[]> exportContext, @WebParam(name = "exportedPortlet", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<ExportedPortlet>> exportedPortlet, @WebParam(name!
= "failedPortlets", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<FailedPortlets>> failedPortlets, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, ExportByValueNotSupported, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ getPortletManagementBehavior().exportPortlets(registrationContext, portletContext, userContext, lifetime, exportByValueRequired, exportContext, exportedPortlet, failedPortlets, resourceList, extensions);
+ }
+
+ public void importPortlets(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "importContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") byte[] importContext, @WebParam(name = "importPortlet", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<ImportPortlet> importPortlet, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "lifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") Lifetime lifetime, @WebParam(name = "importedPortlets", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<ImportedPortlet>> importedPortlets, @WebParam(name = "importFailed", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<ImportPortletsFailed>> importFailed, @WebParam(name = "resourceList", targetNamespace =!
"urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, ExportNoLongerValid, InconsistentParameters, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ getPortletManagementBehavior().importPortlets(registrationContext, importContext, importPortlet, userContext, lifetime, importedPortlets, importFailed, resourceList, extensions);
+ }
+
+ public List<Extension> releaseExport(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "exportContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") byte[] exportContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext)
+ {
+ return getPortletManagementBehavior().releaseExport(registrationContext, exportContext, userContext);
+ }
+
+ public Lifetime setExportLifetime(@WebParam(name = "setExportLifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", partName = "setExportLifetime") SetExportLifetime setExportLifetime) throws AccessDenied, InvalidHandle, InvalidRegistration, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ return getPortletManagementBehavior().setExportLifetime(setExportLifetime);
+ }
+
+ public void setPortletProperties(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "propertyList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PropertyList propertyList, @WebParam(name = "portletHandle", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<String> portletHandle, @WebParam(name = "portletState", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<byte[]> portletState, @WebParam(name = "scheduledDestruction", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<Lifetime> scheduledDestruction, @WebParam(name = "extensio!
ns", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ getPortletManagementBehavior().setPortletProperties(registrationContext, portletContext, userContext, propertyList, portletHandle, portletState, scheduledDestruction, extensions);
+ }
+
+ public void getPortletProperties(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "names", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> names, @WebParam(name = "properties", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Property>> properties, @WebParam(name = "resetProperties", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<ResetProperty>> resetProperties, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, Inconsisten!
tParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ getPortletManagementBehavior().getPortletProperties(registrationContext, portletContext, userContext, names, properties, resetProperties, extensions);
+ }
+
+ public void getPortletPropertyDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> desiredLocales, @WebParam(name = "modelDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ModelDescription> modelDescription, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) thro!
ws AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ getPortletManagementBehavior().getPortletPropertyDescription(registrationContext, portletContext, userContext, desiredLocales, modelDescription, resourceList, extensions);
+ }
+
+ // Producer implementation ******************************************************************************************
+
+ public CookieProtocol getRequiresInitCookie()
+ {
+ return requiresInitCookie;
+ }
+
+ public void setRequiresInitCookie(CookieProtocol requiresInitCookie)
+ {
+ this.requiresInitCookie = requiresInitCookie;
+ getServiceDescriptionBehavior().setRequiresInitCookie(requiresInitCookie);
+ }
+
+ public int getSessionExpirationTime()
+ {
+ return sessionExpirationTime;
+ }
+
+ public void setSessionExpirationTime(int sessionExpirationTime)
+ {
+ this.sessionExpirationTime = sessionExpirationTime;
+ }
+
+ public void usingStrictModeChangedTo(boolean strictMode)
+ {
+// WSRPValidator.setStrict(strictMode);
+ strict = strictMode;
+ }
+}
Property changes on: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/TestWSRPProducerImpl.java
___________________________________________________________________
Name: svn:executable
+ *
Added: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/BasicMarkupBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/BasicMarkupBehavior.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/BasicMarkupBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,108 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v2.behaviors;
+
+import org.gatein.pc.api.Mode;
+import org.gatein.pc.api.OpaqueStateString;
+import org.gatein.pc.api.WindowState;
+import org.gatein.wsrp.WSRPConstants;
+import org.gatein.wsrp.WSRPTypeFactory;
+import org.gatein.wsrp.test.protocol.v2.BehaviorRegistry;
+import org.gatein.wsrp.test.protocol.v2.MarkupBehavior;
+import org.oasis.wsrp.v2.AccessDenied;
+import org.oasis.wsrp.v2.Extension;
+import org.oasis.wsrp.v2.GetMarkup;
+import org.oasis.wsrp.v2.InconsistentParameters;
+import org.oasis.wsrp.v2.InteractionParams;
+import org.oasis.wsrp.v2.InvalidCookie;
+import org.oasis.wsrp.v2.InvalidHandle;
+import org.oasis.wsrp.v2.InvalidRegistration;
+import org.oasis.wsrp.v2.InvalidSession;
+import org.oasis.wsrp.v2.InvalidUserCategory;
+import org.oasis.wsrp.v2.MarkupParams;
+import org.oasis.wsrp.v2.MarkupResponse;
+import org.oasis.wsrp.v2.MissingParameters;
+import org.oasis.wsrp.v2.ModifyRegistrationRequired;
+import org.oasis.wsrp.v2.OperationFailed;
+import org.oasis.wsrp.v2.PortletContext;
+import org.oasis.wsrp.v2.PortletStateChangeRequired;
+import org.oasis.wsrp.v2.RegistrationContext;
+import org.oasis.wsrp.v2.ResourceSuspended;
+import org.oasis.wsrp.v2.RuntimeContext;
+import org.oasis.wsrp.v2.UnsupportedLocale;
+import org.oasis.wsrp.v2.UnsupportedMimeType;
+import org.oasis.wsrp.v2.UnsupportedMode;
+import org.oasis.wsrp.v2.UnsupportedWindowState;
+import org.oasis.wsrp.v2.UpdateResponse;
+import org.oasis.wsrp.v2.UserContext;
+
+import javax.jws.WebParam;
+import javax.xml.ws.Holder;
+import java.util.List;
+
+/**
+ * @author <a href="mailto:chris.laprun@jboss.com?subject=org.gatein.wsrp.v1.consumer.producer.BasicProducer">Chris
+ * Laprun</a>
+ * @version $Revision: 8784 $
+ * @since 2.6
+ */
+public class BasicMarkupBehavior extends MarkupBehavior
+{
+ public static final String PORTLET_HANDLE = "SamplePortletHandle";
+ public static final String NS = "ns1";
+
+
+ public BasicMarkupBehavior(BehaviorRegistry registry)
+ {
+ super(registry);
+ registerHandle(PORTLET_HANDLE);
+ }
+
+ public String getMarkupString(Mode mode, WindowState windowState, String navigationalState, GetMarkup getMarkup)
+ {
+ StringBuffer markupString = new StringBuffer("portlet1:");
+
+ markupString.append(mode).append(":").append(windowState);
+ if (navigationalState != null)
+ {
+ markupString.append(":").append(navigationalState);
+ }
+
+ return markupString.toString();
+ }
+
+ @Override
+ public void performBlockingInteraction(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "runtimeContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RuntimeContext runtimeContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "markupParams", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") MarkupParams markupParams, @WebParam(name = "interactionParams", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") InteractionParams interactionParams, @WebParam(name = "updateResponse", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<UpdateResponse> updateResponse, @WebParam(name = "redirectURL", targetNamespace = "urn:oasis:na!
mes:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<String> redirectURL, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidCookie, InvalidHandle, InvalidRegistration, InvalidSession, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, PortletStateChangeRequired, ResourceSuspended, UnsupportedLocale, UnsupportedMimeType, UnsupportedMode, UnsupportedWindowState
+ {
+ UpdateResponse ur = WSRPTypeFactory.createUpdateResponse();
+ ur.setNavigationalContext(WSRPTypeFactory.createNavigationalContextOrNull(new OpaqueStateString(NS), null));
+ updateResponse.value = ur;
+ }
+
+ public void modifyResponseIfNeeded(MarkupResponse markupResponse)
+ {
+ // fake markup caching
+ markupResponse.getMarkupContext().setCacheControl(WSRPTypeFactory.createCacheControl(15, WSRPConstants.CACHE_PER_USER));
+ }
+}
Property changes on: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/BasicMarkupBehavior.java
___________________________________________________________________
Name: svn:executable
+ *
Added: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/BasicPortletManagementBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/BasicPortletManagementBehavior.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/BasicPortletManagementBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,260 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v2.behaviors;
+
+import org.gatein.common.NotYetImplemented;
+import org.gatein.wsrp.WSRPExceptionFactory;
+import org.gatein.wsrp.WSRPTypeFactory;
+import org.gatein.wsrp.test.protocol.v2.BehaviorRegistry;
+import org.gatein.wsrp.test.protocol.v2.MarkupBehavior;
+import org.gatein.wsrp.test.protocol.v2.PortletManagementBehavior;
+import org.oasis.wsrp.v2.AccessDenied;
+import org.oasis.wsrp.v2.CopiedPortlet;
+import org.oasis.wsrp.v2.ExportByValueNotSupported;
+import org.oasis.wsrp.v2.ExportNoLongerValid;
+import org.oasis.wsrp.v2.ExportedPortlet;
+import org.oasis.wsrp.v2.Extension;
+import org.oasis.wsrp.v2.FailedPortlets;
+import org.oasis.wsrp.v2.ImportPortlet;
+import org.oasis.wsrp.v2.ImportPortletsFailed;
+import org.oasis.wsrp.v2.ImportedPortlet;
+import org.oasis.wsrp.v2.InconsistentParameters;
+import org.oasis.wsrp.v2.InvalidHandle;
+import org.oasis.wsrp.v2.InvalidHandleFault;
+import org.oasis.wsrp.v2.InvalidRegistration;
+import org.oasis.wsrp.v2.InvalidUserCategory;
+import org.oasis.wsrp.v2.Lifetime;
+import org.oasis.wsrp.v2.MissingParameters;
+import org.oasis.wsrp.v2.ModelDescription;
+import org.oasis.wsrp.v2.ModifyRegistrationRequired;
+import org.oasis.wsrp.v2.OperationFailed;
+import org.oasis.wsrp.v2.OperationFailedFault;
+import org.oasis.wsrp.v2.OperationNotSupported;
+import org.oasis.wsrp.v2.PortletContext;
+import org.oasis.wsrp.v2.PortletDescription;
+import org.oasis.wsrp.v2.PortletLifetime;
+import org.oasis.wsrp.v2.Property;
+import org.oasis.wsrp.v2.PropertyList;
+import org.oasis.wsrp.v2.RegistrationContext;
+import org.oasis.wsrp.v2.ResetProperty;
+import org.oasis.wsrp.v2.ResourceList;
+import org.oasis.wsrp.v2.ResourceSuspended;
+import org.oasis.wsrp.v2.SetExportLifetime;
+import org.oasis.wsrp.v2.UserContext;
+
+import javax.jws.WebParam;
+import javax.xml.ws.Holder;
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
+ * @version $Revision: 8784 $
+ * @since 2.6
+ */
+public class BasicPortletManagementBehavior extends PortletManagementBehavior
+{
+ private static final String CLONE_SUFFIX = "_clone";
+ public static final String PROPERTY_NAME = "prop1";
+ public static final String PROPERTY_VALUE = "value1";
+ public static final String PROPERTY_NEW_VALUE = "value2";
+ public static final String CLONED_HANDLE = BasicMarkupBehavior.PORTLET_HANDLE + CLONE_SUFFIX;
+ private BehaviorRegistry registry;
+
+ public BasicPortletManagementBehavior(BehaviorRegistry registry)
+ {
+ super();
+ this.registry = registry;
+ }
+
+ @Override
+ public void getPortletPropertyDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> desiredLocales, @WebParam(mode = WebParam.Mode.OUT, name = "modelDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<ModelDescription> modelDescription, @WebParam(mode = WebParam.Mode.OUT, name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<ResourceList> resourceList, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions) thro!
ws MissingParameters, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, AccessDenied, OperationFailed
+ {
+ throw new NotYetImplemented();
+ }
+
+ @Override
+ public void getPortletDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> desiredLocales, @WebParam(mode = WebParam.Mode.OUT, name = "portletDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<PortletDescription> portletDescription, @WebParam(mode = WebParam.Mode.OUT, name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<ResourceList> resourceList, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions) throws!
MissingParameters, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, AccessDenied, OperationFailed
+ {
+ super.getPortletDescription(registrationContext, portletContext, userContext, desiredLocales, portletDescription, resourceList, extensions);
+
+ String handle = getHandleFrom(portletContext, "portlet context");
+
+ // need to fake that the clone exists... so remove suffix to get the description of the POP
+ int index = handle.indexOf(CLONE_SUFFIX);
+ if (index != -1)
+ {
+ handle = handle.substring(0, index);
+ }
+
+ // get the POP description...
+ MarkupBehavior markupBehaviorFor = registry.getMarkupBehaviorFor(handle);
+ PortletDescription description = markupBehaviorFor.getPortletDescriptionFor(handle);
+
+ // if it was a clone, add the suffix back to the handle.
+ if (index != -1)
+ {
+ description.setPortletHandle(handle + CLONE_SUFFIX);
+ }
+
+ portletDescription.value = description;
+ }
+
+ @Override
+ public void clonePortlet(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "lifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") Lifetime lifetime, @WebParam(name = "portletHandle", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<String> portletHandle, @WebParam(name = "portletState", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<byte[]> portletState, @WebParam(name = "scheduledDestruction", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<Lifetime> scheduledDestruction, @WebParam(name = "extensions", targetNamespace!
= "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ String handle = getHandleFrom(portletContext, "portlet context");
+
+ if (!BasicMarkupBehavior.PORTLET_HANDLE.equals(handle))
+ {
+ throw WSRPExceptionFactory.<InvalidHandle, InvalidHandleFault>throwWSException(WSRPExceptionFactory.INVALID_HANDLE,
+ "Can only clone portlet with handle '" + BasicMarkupBehavior.PORTLET_HANDLE + "'", null);
+ }
+
+ portletHandle.value = CLONED_HANDLE;
+ }
+
+ @Override
+ public void destroyPortlets(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletHandles", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> portletHandles, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "failedPortlets", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<FailedPortlets>> failedPortlets, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws InconsistentParameters, InvalidRegistration, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ super.destroyPortlets(registrationContext, portletHandles, userContext, failedPortlets, extensions);
+ WSRPExceptionFactory.throwMissingParametersIfValueIsMissing(portletHandles, "portlet handles", "destroyPortlets");
+ if (portletHandles.isEmpty())
+ {
+ WSRPExceptionFactory.throwMissingParametersIfValueIsMissing(portletHandles, "portlet handles", "DestroyPortlets");
+ }
+
+ for (String handle : portletHandles)
+ {
+ if (!CLONED_HANDLE.equals(handle))
+ {
+ ArrayList<String> failed = new ArrayList<String>();
+ failed.add(handle);
+ failedPortlets.value.add(WSRPTypeFactory.createFailedPortlets(failed, "Handle '" + handle + "' doesn't exist"));
+ }
+ }
+ }
+
+ @Override
+ public void getPortletsLifetime(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<PortletContext> portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "portletLifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<PortletLifetime>> portletLifetime, @WebParam(name = "failedPortlets", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<FailedPortlets>> failedPortlets, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT)!
Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ throw new NotYetImplemented();
+ }
+
+ @Override
+ public void setPortletsLifetime(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<PortletContext> portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "lifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") Lifetime lifetime, @WebParam(name = "updatedPortlet", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<PortletLifetime>> updatedPortlet, @WebParam(name = "failedPortlets", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<FailedPortlets>> failedPortlets, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(!
name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ throw new NotYetImplemented();
+ }
+
+ @Override
+ public void copyPortlets(@WebParam(name = "toRegistrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext toRegistrationContext, @WebParam(name = "toUserContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext toUserContext, @WebParam(name = "fromRegistrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext fromRegistrationContext, @WebParam(name = "fromUserContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext fromUserContext, @WebParam(name = "fromPortletContexts", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<PortletContext> fromPortletContexts, @WebParam(name = "lifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") Lifetime lifetime, @WebParam(name = "copiedPortlets", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<CopiedPortlet>> copiedPortlets, @WebParam(name = "failedPortlets", targetNamesp!
ace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<FailedPortlets>> failedPortlets, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ throw new NotYetImplemented();
+ }
+
+ @Override
+ public void exportPortlets(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<PortletContext> portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "lifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.INOUT) Holder<Lifetime> lifetime, @WebParam(name = "exportByValueRequired", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") Boolean exportByValueRequired, @WebParam(name = "exportContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<byte[]> exportContext, @WebParam(name = "exportedPortlet", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<ExportedPortlet>> exportedPortlet, @WebParam(name!
= "failedPortlets", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<FailedPortlets>> failedPortlets, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, ExportByValueNotSupported, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ throw new NotYetImplemented();
+ }
+
+ @Override
+ public void importPortlets(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "importContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") byte[] importContext, @WebParam(name = "importPortlet", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<ImportPortlet> importPortlet, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "lifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") Lifetime lifetime, @WebParam(name = "importedPortlets", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<ImportedPortlet>> importedPortlets, @WebParam(name = "importFailed", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<ImportPortletsFailed>> importFailed, @WebParam(name = "resourceList", targetNamespace =!
"urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, ExportNoLongerValid, InconsistentParameters, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ throw new NotYetImplemented();
+ }
+
+ @Override
+ public List<Extension> releaseExport(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "exportContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") byte[] exportContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext)
+ {
+ throw new NotYetImplemented();
+ }
+
+ @Override
+ public Lifetime setExportLifetime(@WebParam(name = "setExportLifetime", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", partName = "setExportLifetime") SetExportLifetime setExportLifetime) throws AccessDenied, InvalidHandle, InvalidRegistration, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ throw new NotYetImplemented();
+ }
+
+ @Override
+ public void setPortletProperties(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "propertyList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PropertyList propertyList, @WebParam(name = "portletHandle", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<String> portletHandle, @WebParam(name = "portletState", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<byte[]> portletState, @WebParam(name = "scheduledDestruction", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<Lifetime> scheduledDestruction, @WebParam(name = "extensio!
ns", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ String handle = getHandleFrom(portletContext, "portlet context");
+
+ if (!(CLONED_HANDLE).equals(handle))
+ {
+ throw WSRPExceptionFactory.<OperationFailed, OperationFailedFault>throwWSException(WSRPExceptionFactory.OPERATION_FAILED,
+ "Cannot modify portlet '" + handle + "'", null);
+ }
+
+ portletHandle.value = handle;
+ }
+
+ @Override
+ public void getPortletProperties(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") UserContext userContext, @WebParam(name = "names", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> names, @WebParam(mode = WebParam.Mode.OUT, name = "properties", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Property>> properties, @WebParam(mode = WebParam.Mode.OUT, name = "resetProperties", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<ResetProperty>> resetProperties, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions) throws MissingParameters, Incons!
istentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, AccessDenied, OperationFailed
+ {
+ String handle = getHandleFrom(portletContext, "portlet context");
+
+ List<Property> propertyList = new ArrayList<Property>(1);
+
+ if (BasicMarkupBehavior.PORTLET_HANDLE.equals(handle))
+ {
+ propertyList.add(WSRPTypeFactory.createProperty(PROPERTY_NAME, "en", PROPERTY_VALUE));
+ }
+ else if (CLONED_HANDLE.equals(handle))
+ {
+ if (callCount != 2)
+ {
+ propertyList.add(WSRPTypeFactory.createProperty(PROPERTY_NAME, "en", PROPERTY_VALUE));
+ }
+ else
+ {
+ propertyList.add(WSRPTypeFactory.createProperty(PROPERTY_NAME, "en", PROPERTY_NEW_VALUE));
+ }
+ }
+ else
+ {
+ WSRPExceptionFactory.<InvalidHandle, InvalidHandleFault>throwWSException(WSRPExceptionFactory.INVALID_HANDLE,
+ "Unknown handle '" + handle + "'", null);
+ }
+
+ incrementCallCount();
+ properties.value = propertyList;
+ }
+
+ private String getHandleFrom(PortletContext portletContext, String context) throws MissingParameters, InvalidHandle
+ {
+ WSRPExceptionFactory.throwMissingParametersIfValueIsMissing(portletContext, "portlet context", context);
+ String handle = portletContext.getPortletHandle();
+ WSRPExceptionFactory.throwMissingParametersIfValueIsMissing(handle, "portlet handle", "PortletContext");
+ if (handle.length() == 0)
+ {
+ throw WSRPExceptionFactory.<InvalidHandle, InvalidHandleFault>throwWSException(WSRPExceptionFactory.INVALID_HANDLE,
+ "Portlet handle is empty", null);
+ }
+
+ return handle;
+ }
+}
Property changes on: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/BasicPortletManagementBehavior.java
___________________________________________________________________
Name: svn:executable
+ *
Added: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/BasicServiceDescriptionBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/BasicServiceDescriptionBehavior.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/BasicServiceDescriptionBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,46 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v2.behaviors;
+
+import org.gatein.wsrp.test.protocol.v2.ServiceDescriptionBehavior;
+import org.oasis.wsrp.v2.PortletDescription;
+
+/**
+ * @author <a href="mailto:chris.laprun@jboss.com?subject=org.gatein.wsrp.protocol.v1.behaviors.BasicServiceDescriptionBehavior">Chris
+ * Laprun</a>
+ * @version $Revision: 10610 $
+ * @since 2.6
+ */
+public class BasicServiceDescriptionBehavior extends ServiceDescriptionBehavior
+{
+
+ public BasicServiceDescriptionBehavior()
+ {
+ //Prepare description of two portlets
+ PortletDescription pd1 = createPortletDescription(BasicMarkupBehavior.PORTLET_HANDLE, "");
+ PortletDescription pd2 = createPortletDescription(SessionMarkupBehavior.PORTLET_HANDLE, "2");
+ offeredPortlets.add(pd1);
+ offeredPortlets.add(pd2);
+ }
+}
Property changes on: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/BasicServiceDescriptionBehavior.java
___________________________________________________________________
Name: svn:executable
+ *
Added: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/DestroyClonesPortletManagementBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/DestroyClonesPortletManagementBehavior.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/DestroyClonesPortletManagementBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,77 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v2.behaviors;
+
+import org.gatein.wsrp.WSRPExceptionFactory;
+import org.gatein.wsrp.test.protocol.v2.BehaviorRegistry;
+import org.oasis.wsrp.v2.AccessDenied;
+import org.oasis.wsrp.v2.Extension;
+import org.oasis.wsrp.v2.InconsistentParameters;
+import org.oasis.wsrp.v2.InvalidHandle;
+import org.oasis.wsrp.v2.InvalidHandleFault;
+import org.oasis.wsrp.v2.InvalidRegistration;
+import org.oasis.wsrp.v2.InvalidUserCategory;
+import org.oasis.wsrp.v2.MissingParameters;
+import org.oasis.wsrp.v2.OperationFailed;
+import org.oasis.wsrp.v2.PortletContext;
+import org.oasis.wsrp.v2.PortletDescription;
+import org.oasis.wsrp.v2.RegistrationContext;
+import org.oasis.wsrp.v2.ResourceList;
+import org.oasis.wsrp.v2.UserContext;
+
+import javax.jws.WebParam;
+import javax.xml.ws.Holder;
+import java.util.List;
+
+/**
+ * Specific behavior used in PortletManagementCase.testDestroyClones.
+ *
+ * @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
+ * @version $Revision: 8784 $
+ * @since 2.6
+ */
+public class DestroyClonesPortletManagementBehavior extends BasicPortletManagementBehavior
+{
+ public DestroyClonesPortletManagementBehavior(BehaviorRegistry registry)
+ {
+ super(registry);
+ }
+
+ @Override
+ public void getPortletDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") PortletContext portletContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") UserContext userContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") List<String> desiredLocales, @WebParam(mode = WebParam.Mode.OUT, name = "portletDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<PortletDescription> portletDescription, @WebParam(mode = WebParam.Mode.OUT, name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<ResourceList> resourceList, @WebParam(mode = WebParam.Mode.OUT, name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v1:types") Holder<List<Extension>> extensions) throws!
MissingParameters, InconsistentParameters, InvalidHandle, InvalidRegistration, InvalidUserCategory, AccessDenied, OperationFailed
+ {
+ // only return the portlet description the first time the method is called since all other calls happen after
+ // the clone has been destroyed...
+ if (getCallCount() == 0)
+ {
+ incrementCallCount();
+ super.getPortletDescription(registrationContext, portletContext, userContext, desiredLocales, portletDescription, resourceList, extensions);
+ }
+ else
+ {
+ throw WSRPExceptionFactory.<InvalidHandle, InvalidHandleFault>throwWSException(WSRPExceptionFactory.INVALID_HANDLE,
+ "Invalid portlet handle: " + portletContext.getPortletHandle(), null);
+ }
+ }
+}
Property changes on: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/DestroyClonesPortletManagementBehavior.java
___________________________________________________________________
Name: svn:executable
+ *
Added: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/EmptyMarkupBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/EmptyMarkupBehavior.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/EmptyMarkupBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,53 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v2.behaviors;
+
+import org.gatein.pc.api.Mode;
+import org.gatein.pc.api.WindowState;
+import org.gatein.wsrp.test.protocol.v2.BehaviorRegistry;
+import org.gatein.wsrp.test.protocol.v2.MarkupBehavior;
+import org.oasis.wsrp.v2.GetMarkup;
+
+/**
+ * @author <a href="mailto:chris.laprun@jboss.com?subject=org.gatein.wsrp.v1.consumer.producer.EmptyMarkupBehavior">Chris
+ * Laprun</a>
+ * @version $Revision: 8784 $
+ * @since 2.6
+ */
+public class EmptyMarkupBehavior extends MarkupBehavior
+{
+ public static final String PORTLET_HANDLE = "EmptyMarkup";
+
+
+ public EmptyMarkupBehavior(BehaviorRegistry registry)
+ {
+ super(registry);
+ registerHandle(PORTLET_HANDLE);
+ }
+
+ public String getMarkupString(Mode mode, WindowState windowState, String navigationalState, GetMarkup getMarkup)
+ {
+ return "";
+ }
+}
Property changes on: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/EmptyMarkupBehavior.java
___________________________________________________________________
Name: svn:executable
+ *
Added: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/GroupedPortletsServiceDescriptionBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/GroupedPortletsServiceDescriptionBehavior.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/GroupedPortletsServiceDescriptionBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,71 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v2.behaviors;
+
+import org.gatein.wsrp.test.protocol.v2.ServiceDescriptionBehavior;
+import org.oasis.wsrp.v2.CookieProtocol;
+import org.oasis.wsrp.v2.EventDescription;
+import org.oasis.wsrp.v2.ExportDescription;
+import org.oasis.wsrp.v2.Extension;
+import org.oasis.wsrp.v2.ExtensionDescription;
+import org.oasis.wsrp.v2.InvalidRegistration;
+import org.oasis.wsrp.v2.ItemDescription;
+import org.oasis.wsrp.v2.ModelDescription;
+import org.oasis.wsrp.v2.ModelTypes;
+import org.oasis.wsrp.v2.ModifyRegistrationRequired;
+import org.oasis.wsrp.v2.OperationFailed;
+import org.oasis.wsrp.v2.PortletDescription;
+import org.oasis.wsrp.v2.RegistrationContext;
+import org.oasis.wsrp.v2.ResourceList;
+import org.oasis.wsrp.v2.ResourceSuspended;
+import org.oasis.wsrp.v2.UserContext;
+
+import javax.jws.WebParam;
+import javax.xml.ws.Holder;
+import java.util.List;
+
+/**
+ * Wraps a service description to add group information on portlet descriptions...
+ *
+ * @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
+ * @version $Revision$
+ */
+public class GroupedPortletsServiceDescriptionBehavior extends ServiceDescriptionBehavior
+{
+ public GroupedPortletsServiceDescriptionBehavior(List<PortletDescription> offeredPortlets)
+ {
+ this.offeredPortlets = offeredPortlets;
+ }
+
+ @Override
+ public void getServiceDescription(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "desiredLocales", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> desiredLocales, @WebParam(name = "portletHandles", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") List<String> portletHandles, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "requiresRegistration", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<Boolean> requiresRegistration, @WebParam(name = "offeredPortlets", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<PortletDescription>> offeredPortlets, @WebParam(name = "userCategoryDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<ItemDes!
cription>> userCategoryDescriptions, @WebParam(name = "extensionDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<ExtensionDescription>> extensionDescriptions, @WebParam(name = "customWindowStateDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<ItemDescription>> customWindowStateDescriptions, @WebParam(name = "customModeDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<ItemDescription>> customModeDescriptions, @WebParam(name = "requiresInitCookie", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<CookieProtocol> requiresInitCookie, @WebParam(name = "registrationPropertyDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ModelDescription> registrationPropertyDescription, @WebParam(name = "locales", targetNamespace = "urn:!
oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holde!
r<List<S
tring>> locales, @WebParam(name = "resourceList", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ResourceList> resourceList, @WebParam(name = "eventDescriptions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<EventDescription>> eventDescriptions, @WebParam(name = "schemaType", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ModelTypes> schemaType, @WebParam(name = "supportedOptions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<String>> supportedOptions, @WebParam(name = "exportDescription", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<ExportDescription> exportDescription, @WebParam(name = "mayReturnRegistrationState", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<Boolean> mayReturnRegistrationState, @WebParam(name = "extens!
ions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws InvalidRegistration, ModifyRegistrationRequired, OperationFailed, ResourceSuspended
+ {
+ super.getServiceDescription(registrationContext, desiredLocales, portletHandles, userContext, requiresRegistration, offeredPortlets, userCategoryDescriptions, extensionDescriptions, customWindowStateDescriptions, customModeDescriptions, requiresInitCookie, registrationPropertyDescription, locales, resourceList, eventDescriptions, schemaType, supportedOptions, exportDescription, mayReturnRegistrationState, extensions);
+ List<PortletDescription> portletDescriptions = offeredPortlets.value;
+ for (int i = 0; i < portletDescriptions.size(); i++)
+ {
+ portletDescriptions.get(i).setGroupID("group" + i % 3);
+ }
+ }
+}
Property changes on: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/GroupedPortletsServiceDescriptionBehavior.java
___________________________________________________________________
Name: svn:executable
+ *
Added: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/InitCookieMarkupBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/InitCookieMarkupBehavior.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/InitCookieMarkupBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,109 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v2.behaviors;
+
+import org.gatein.pc.api.Mode;
+import org.gatein.pc.api.WindowState;
+import org.gatein.wsrp.WSRPExceptionFactory;
+import org.gatein.wsrp.test.protocol.v2.BehaviorRegistry;
+import org.gatein.wsrp.test.protocol.v2.MarkupBehavior;
+import org.oasis.wsrp.v2.AccessDenied;
+import org.oasis.wsrp.v2.Extension;
+import org.oasis.wsrp.v2.GetMarkup;
+import org.oasis.wsrp.v2.InvalidCookie;
+import org.oasis.wsrp.v2.InvalidCookieFault;
+import org.oasis.wsrp.v2.InvalidRegistration;
+import org.oasis.wsrp.v2.ModifyRegistrationRequired;
+import org.oasis.wsrp.v2.OperationFailed;
+import org.oasis.wsrp.v2.OperationFailedFault;
+import org.oasis.wsrp.v2.OperationNotSupported;
+import org.oasis.wsrp.v2.RegistrationContext;
+import org.oasis.wsrp.v2.ResourceSuspended;
+import org.oasis.wsrp.v2.UserContext;
+
+import javax.jws.WebParam;
+import java.util.List;
+
+/**
+ * @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
+ * @version $Revision: 10610 $
+ * @since 2.6
+ */
+public abstract class InitCookieMarkupBehavior extends MarkupBehavior
+{
+ protected String portletHandle;
+ protected int initCookieCallCount;
+
+ public InitCookieMarkupBehavior(BehaviorRegistry registry)
+ {
+ super(registry);
+ initPortletHandle();
+ registerHandle(portletHandle);
+ }
+
+ protected abstract void initPortletHandle();
+
+
+ protected String getMarkupString(Mode mode, WindowState windowState, String navigationalState, GetMarkup getMarkup) throws OperationFailed, InvalidCookie
+ {
+ String handle = getMarkup.getPortletContext().getPortletHandle();
+
+ if (portletHandle.equals(handle))
+ {
+ return getMarkupString(handle);
+ }
+
+ // shouldn't happen
+ throw WSRPExceptionFactory.<OperationFailed, OperationFailedFault>throwWSException(WSRPExceptionFactory.OPERATION_FAILED, "Shouldn't be happen", null);
+ }
+
+ protected String getMarkupString(String handle) throws InvalidCookie, OperationFailed
+ {
+ switch (callCount++)
+ {
+ case 0:
+ // simulate change of configuration between calls: upon receiving this, the consumer should invoke initCookie
+ throw WSRPExceptionFactory.<InvalidCookie, InvalidCookieFault>throwWSException(WSRPExceptionFactory.INVALID_COOKIE, "Simulate invalid cookie", null);
+
+ case 1:
+ return handle;
+
+ default:
+ // shouldn't be called more than twice
+ throw WSRPExceptionFactory.<OperationFailed, OperationFailedFault>throwWSException(WSRPExceptionFactory.OPERATION_FAILED, "Shouldn't be called more than twice", null);
+ }
+ }
+
+ @Override
+ public List<Extension> initCookie(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext) throws AccessDenied, InvalidRegistration, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ initCookieCallCount++;
+ return null;
+ }
+
+ public int getInitCookieCallCount()
+ {
+ return initCookieCallCount;
+ }
+}
Property changes on: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/InitCookieMarkupBehavior.java
___________________________________________________________________
Name: svn:executable
+ *
Added: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/InitCookieNotRequiredMarkupBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/InitCookieNotRequiredMarkupBehavior.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/InitCookieNotRequiredMarkupBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,72 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v2.behaviors;
+
+import org.gatein.wsrp.WSRPExceptionFactory;
+import org.gatein.wsrp.test.protocol.v2.BehaviorRegistry;
+import org.oasis.wsrp.v2.AccessDenied;
+import org.oasis.wsrp.v2.Extension;
+import org.oasis.wsrp.v2.InvalidRegistration;
+import org.oasis.wsrp.v2.ModifyRegistrationRequired;
+import org.oasis.wsrp.v2.OperationFailed;
+import org.oasis.wsrp.v2.OperationFailedFault;
+import org.oasis.wsrp.v2.OperationNotSupported;
+import org.oasis.wsrp.v2.RegistrationContext;
+import org.oasis.wsrp.v2.ResourceSuspended;
+import org.oasis.wsrp.v2.UserContext;
+
+import javax.jws.WebParam;
+import java.util.List;
+
+/**
+ * @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
+ * @version $Revision$
+ */
+public class InitCookieNotRequiredMarkupBehavior extends InitCookieMarkupBehavior
+{
+ public static final String INIT_COOKIE_NOT_REQUIRED_HANDLE = "InitCookieNotRequired";
+
+ public InitCookieNotRequiredMarkupBehavior(BehaviorRegistry registry)
+ {
+ super(registry);
+ }
+
+ protected void initPortletHandle()
+ {
+ portletHandle = INIT_COOKIE_NOT_REQUIRED_HANDLE;
+ }
+
+ @Override
+ protected String getMarkupString(String handle)
+ {
+ return handle;
+ }
+
+ @Override
+ public List<Extension> initCookie(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext) throws AccessDenied, InvalidRegistration, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ super.initCookie(registrationContext, userContext);
+ throw WSRPExceptionFactory.<OperationFailed, OperationFailedFault>throwWSException(WSRPExceptionFactory.OPERATION_FAILED, "Shouldn't be called", null);
+ }
+}
Property changes on: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/InitCookieNotRequiredMarkupBehavior.java
___________________________________________________________________
Name: svn:executable
+ *
Added: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/NullMarkupBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/NullMarkupBehavior.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/NullMarkupBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,53 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v2.behaviors;
+
+import org.gatein.pc.api.Mode;
+import org.gatein.pc.api.WindowState;
+import org.gatein.wsrp.test.protocol.v2.BehaviorRegistry;
+import org.gatein.wsrp.test.protocol.v2.MarkupBehavior;
+import org.oasis.wsrp.v2.GetMarkup;
+
+/**
+ * @author <a href="mailto:chris.laprun@jboss.com?subject=org.gatein.wsrp.v1.consumer.producer.NullMarkupBehavior">Chris
+ * Laprun</a>
+ * @version $Revision: 8784 $
+ * @since 2.6
+ */
+public class NullMarkupBehavior extends MarkupBehavior
+{
+ public static final String PORTLET_HANDLE = "NullMarkup";
+
+
+ public NullMarkupBehavior(BehaviorRegistry registry)
+ {
+ super(registry);
+ registerHandle(PORTLET_HANDLE);
+ }
+
+ public String getMarkupString(Mode mode, WindowState windowState, String navigationalState, GetMarkup getMarkup)
+ {
+ return null;
+ }
+}
Property changes on: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/NullMarkupBehavior.java
___________________________________________________________________
Name: svn:executable
+ *
Added: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/PerGroupInitCookieMarkupBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/PerGroupInitCookieMarkupBehavior.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/PerGroupInitCookieMarkupBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,73 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v2.behaviors;
+
+import org.gatein.wsrp.WSRPExceptionFactory;
+import org.gatein.wsrp.test.protocol.v2.BehaviorRegistry;
+import org.oasis.wsrp.v2.AccessDenied;
+import org.oasis.wsrp.v2.Extension;
+import org.oasis.wsrp.v2.InvalidRegistration;
+import org.oasis.wsrp.v2.ModifyRegistrationRequired;
+import org.oasis.wsrp.v2.OperationFailed;
+import org.oasis.wsrp.v2.OperationFailedFault;
+import org.oasis.wsrp.v2.OperationNotSupported;
+import org.oasis.wsrp.v2.RegistrationContext;
+import org.oasis.wsrp.v2.ResourceSuspended;
+import org.oasis.wsrp.v2.UserContext;
+
+import javax.jws.WebParam;
+import java.util.List;
+
+/**
+ * @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
+ * @version $Revision$
+ */
+public class PerGroupInitCookieMarkupBehavior extends InitCookieMarkupBehavior
+{
+ public static final String PER_GROUP_INIT_COOKIE_HANDLE = "PerGroupInitCookie";
+
+ public PerGroupInitCookieMarkupBehavior(BehaviorRegistry registry)
+ {
+ super(registry);
+ }
+
+ protected void initPortletHandle()
+ {
+ portletHandle = PER_GROUP_INIT_COOKIE_HANDLE;
+ }
+
+ @Override
+ public List<Extension> initCookie(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext) throws AccessDenied, InvalidRegistration, ModifyRegistrationRequired, OperationFailed, OperationNotSupported, ResourceSuspended
+ {
+ List<Extension> extensions = super.initCookie(registrationContext, userContext);
+
+ if (initCookieCallCount > 3)
+ {
+ throw WSRPExceptionFactory.<OperationFailed, OperationFailedFault>throwWSException(WSRPExceptionFactory.OPERATION_FAILED,
+ "Service description only defines 3 groups so initCookie should only be called 3 times!",
+ new IllegalStateException("Service description only defines 3 groups so initCookie should only be called 3 times!"));
+ }
+ return extensions;
+ }
+}
Property changes on: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/PerGroupInitCookieMarkupBehavior.java
___________________________________________________________________
Name: svn:executable
+ *
Added: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/PerUserInitCookieMarkupBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/PerUserInitCookieMarkupBehavior.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/PerUserInitCookieMarkupBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,45 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v2.behaviors;
+
+import org.gatein.wsrp.test.protocol.v2.BehaviorRegistry;
+
+/**
+ * @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
+ * @version $Revision$
+ */
+public class PerUserInitCookieMarkupBehavior extends InitCookieMarkupBehavior
+{
+ public static final String PER_USER_INIT_COOKIE_HANDLE = "PerUserInitCookie";
+
+ public PerUserInitCookieMarkupBehavior(BehaviorRegistry registry)
+ {
+ super(registry);
+ }
+
+ protected void initPortletHandle()
+ {
+ portletHandle = PER_USER_INIT_COOKIE_HANDLE;
+ }
+}
Property changes on: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/PerUserInitCookieMarkupBehavior.java
___________________________________________________________________
Name: svn:executable
+ *
Added: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/ResourceMarkupBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/ResourceMarkupBehavior.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/ResourceMarkupBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,53 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v2.behaviors;
+
+import org.gatein.pc.api.Mode;
+import org.gatein.pc.api.WindowState;
+import org.gatein.wsrp.test.protocol.v2.BehaviorRegistry;
+import org.gatein.wsrp.test.protocol.v2.MarkupBehavior;
+import org.oasis.wsrp.v2.GetMarkup;
+
+/**
+ * @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
+ * @version $Revision: 8784 $
+ * @since 2.6
+ */
+public class ResourceMarkupBehavior extends MarkupBehavior
+{
+ public static final String PORTLET_HANDLE = "resource";
+
+
+ public ResourceMarkupBehavior(BehaviorRegistry registry)
+ {
+ super(registry);
+ registerHandle(PORTLET_HANDLE);
+ }
+
+ protected String getMarkupString(Mode mode, WindowState windowState, String navigationalState, GetMarkup getMarkup)
+ {
+ return "<img src='wsrp_rewrite?wsrp-urlType=resource&wsrp-url=http%3A%2F%2Flocalhost%3A8080" +
+ "%2Ftest-resource-portlet%2Fgif%2Flogo.gif&wsrp-requiresRewrite=true/wsrp_rewrite'/>";
+ }
+}
Property changes on: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/ResourceMarkupBehavior.java
___________________________________________________________________
Name: svn:executable
+ *
Added: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/SessionMarkupBehavior.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/SessionMarkupBehavior.java (rev 0)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/SessionMarkupBehavior.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -0,0 +1,130 @@
+/*
+ * JBoss, a division of Red Hat
+ * Copyright 2010, Red Hat Middleware, LLC, and individual
+ * contributors as indicated by the @authors tag. See the
+ * copyright.txt in the distribution for a full listing of
+ * individual contributors.
+ *
+ * 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.gatein.wsrp.test.protocol.v2.behaviors;
+
+import org.gatein.pc.api.Mode;
+import org.gatein.pc.api.OpaqueStateString;
+import org.gatein.pc.api.WindowState;
+import org.gatein.wsrp.WSRPTypeFactory;
+import org.gatein.wsrp.test.protocol.v2.BehaviorRegistry;
+import org.gatein.wsrp.test.protocol.v2.MarkupBehavior;
+import org.oasis.wsrp.v2.AccessDenied;
+import org.oasis.wsrp.v2.Extension;
+import org.oasis.wsrp.v2.GetMarkup;
+import org.oasis.wsrp.v2.InconsistentParameters;
+import org.oasis.wsrp.v2.InteractionParams;
+import org.oasis.wsrp.v2.InvalidCookie;
+import org.oasis.wsrp.v2.InvalidHandle;
+import org.oasis.wsrp.v2.InvalidRegistration;
+import org.oasis.wsrp.v2.InvalidSession;
+import org.oasis.wsrp.v2.InvalidUserCategory;
+import org.oasis.wsrp.v2.MarkupParams;
+import org.oasis.wsrp.v2.MarkupResponse;
+import org.oasis.wsrp.v2.MissingParameters;
+import org.oasis.wsrp.v2.ModifyRegistrationRequired;
+import org.oasis.wsrp.v2.OperationFailed;
+import org.oasis.wsrp.v2.PortletContext;
+import org.oasis.wsrp.v2.PortletStateChangeRequired;
+import org.oasis.wsrp.v2.RegistrationContext;
+import org.oasis.wsrp.v2.ResourceSuspended;
+import org.oasis.wsrp.v2.RuntimeContext;
+import org.oasis.wsrp.v2.SessionContext;
+import org.oasis.wsrp.v2.UnsupportedLocale;
+import org.oasis.wsrp.v2.UnsupportedMimeType;
+import org.oasis.wsrp.v2.UnsupportedMode;
+import org.oasis.wsrp.v2.UnsupportedWindowState;
+import org.oasis.wsrp.v2.UpdateResponse;
+import org.oasis.wsrp.v2.UserContext;
+
+import javax.jws.WebParam;
+import javax.xml.ws.Holder;
+import java.util.List;
+
+/**
+ * @author <a href="mailto:chris.laprun@jboss.com?subject=org.gatein.wsrp.v1.consumer.producer.SessionBehavior">Chris
+ * Laprun</a>
+ * @version $Revision: 8784 $
+ * @since 2.6
+ */
+public class SessionMarkupBehavior extends MarkupBehavior
+{
+ public static final String PORTLET_HANDLE = "SecondPortletHandle";
+ public static final String SESSION_ID = "sessionID";
+ public static final String NS = "ns2";
+
+
+ private int count = 0;
+ private String sessionId;
+
+ public SessionMarkupBehavior(BehaviorRegistry registry)
+ {
+ super(registry);
+ registerHandle(PORTLET_HANDLE);
+ }
+
+ public String getMarkupString(Mode mode, WindowState windowState, String navigationalState, GetMarkup getMarkup)
+ {
+ StringBuffer markupString = new StringBuffer("portlet2:");
+ sessionId = getMarkup.getRuntimeContext().getSessionParams().getSessionID();
+
+ // if we have a session, increments count to simulate session usage
+ if (SESSION_ID.equals(sessionId))
+ {
+ count++;
+ }
+ markupString.append(count).append(":");
+
+ markupString.append(mode).append(":").append(windowState);
+ if (navigationalState != null)
+ {
+ markupString.append(":").append(navigationalState);
+ }
+
+ return markupString.toString();
+ }
+
+ @Override
+ public void performBlockingInteraction(@WebParam(name = "registrationContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RegistrationContext registrationContext, @WebParam(name = "portletContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") PortletContext portletContext, @WebParam(name = "runtimeContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") RuntimeContext runtimeContext, @WebParam(name = "userContext", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") UserContext userContext, @WebParam(name = "markupParams", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") MarkupParams markupParams, @WebParam(name = "interactionParams", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types") InteractionParams interactionParams, @WebParam(name = "updateResponse", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<UpdateResponse> updateResponse, @WebParam(name = "redirectURL", targetNamespace = "urn:oasis:na!
mes:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<String> redirectURL, @WebParam(name = "extensions", targetNamespace = "urn:oasis:names:tc:wsrp:v2:types", mode = WebParam.Mode.OUT) Holder<List<Extension>> extensions) throws AccessDenied, InconsistentParameters, InvalidCookie, InvalidHandle, InvalidRegistration, InvalidSession, InvalidUserCategory, MissingParameters, ModifyRegistrationRequired, OperationFailed, PortletStateChangeRequired, ResourceSuspended, UnsupportedLocale, UnsupportedMimeType, UnsupportedMode, UnsupportedWindowState
+ {
+ UpdateResponse ur = WSRPTypeFactory.createUpdateResponse();
+ ur.setNavigationalContext(WSRPTypeFactory.createNavigationalContextOrNull(new OpaqueStateString(NS), null));
+ updateResponse.value = ur;
+ }
+
+ public void modifyResponseIfNeeded(MarkupResponse markupResponse)
+ {
+ // fakes creation of a portlet session if not already present
+ if (count == 0 || SESSION_ID.equals(sessionId))
+ {
+ SessionContext sessionContext = WSRPTypeFactory.createSessionContext(SESSION_ID, 30);
+ markupResponse.setSessionContext(sessionContext);
+ }
+ }
+
+
+ protected String getSuffixFor(String handle)
+ {
+ return "2";
+ }
+}
Property changes on: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/protocol/v2/behaviors/SessionMarkupBehavior.java
___________________________________________________________________
Name: svn:executable
+ *
Deleted: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/support/BehaviorBackedServiceFactory.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/support/BehaviorBackedServiceFactory.java 2010-05-27 07:15:18 UTC (rev 3208)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/support/BehaviorBackedServiceFactory.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -1,229 +0,0 @@
-/*
- * JBoss, a division of Red Hat
- * Copyright 2010, Red Hat Middleware, LLC, and individual
- * contributors as indicated by the @authors tag. See the
- * copyright.txt in the distribution for a full listing of
- * individual contributors.
- *
- * 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.gatein.wsrp.test.support;
-
-import org.gatein.common.NotYetImplemented;
-import org.gatein.pc.api.Mode;
-import org.gatein.pc.api.WindowState;
-import org.gatein.wsrp.services.ServiceFactory;
-import org.gatein.wsrp.test.BehaviorRegistry;
-import org.gatein.wsrp.test.protocol.v1.MarkupBehavior;
-import org.oasis.wsrp.v1.V1AccessDenied;
-import org.oasis.wsrp.v1.V1GetMarkup;
-import org.oasis.wsrp.v1.V1InconsistentParameters;
-import org.oasis.wsrp.v1.V1InvalidCookie;
-import org.oasis.wsrp.v1.V1InvalidHandle;
-import org.oasis.wsrp.v1.V1InvalidRegistration;
-import org.oasis.wsrp.v1.V1InvalidSession;
-import org.oasis.wsrp.v1.V1InvalidUserCategory;
-import org.oasis.wsrp.v1.V1MissingParameters;
-import org.oasis.wsrp.v1.V1OperationFailed;
-import org.oasis.wsrp.v1.V1UnsupportedLocale;
-import org.oasis.wsrp.v1.V1UnsupportedMimeType;
-import org.oasis.wsrp.v1.V1UnsupportedMode;
-import org.oasis.wsrp.v1.V1UnsupportedWindowState;
-import org.oasis.wsrp.v1.WSRPV1MarkupPortType;
-import org.oasis.wsrp.v1.WSRPV1PortletManagementPortType;
-import org.oasis.wsrp.v1.WSRPV1RegistrationPortType;
-import org.oasis.wsrp.v1.WSRPV1ServiceDescriptionPortType;
-
-/**
- * @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
- * @version $Revision: 11461 $
- * @since 2.6
- */
-public class BehaviorBackedServiceFactory implements ServiceFactory
-{
- private BehaviorRegistry registry;
- private final static String MARKUP = "markup";
- private final static String SD_URL = "sd";
- private final static String M_URL = "m";
- private final static String PM_URL = "pm";
- private final static String R_URL = "r";
- private boolean initialized = false;
- private String wsdl = DEFAULT_WSDL_URL;
- public static final String DEFAULT_WSDL_URL = "http://example.com/producer?wsdl";
- private int timeout;
-
-
- public BehaviorBackedServiceFactory()
- {
- registry = new BehaviorRegistry();
- registry.registerMarkupBehavior(new SimpleMarkupBehavior());
- }
-
- public <T> T getService(Class<T> serviceClass) throws Exception
- {
- if (!isAvailable() && !isFailed())
- {
- start();
- }
-
- if (WSRPV1ServiceDescriptionPortType.class.isAssignableFrom(serviceClass))
- {
- return (T)registry.getServiceDescriptionBehavior();
- }
- if (WSRPV1MarkupPortType.class.isAssignableFrom(serviceClass))
- {
- return (T)registry.getMarkupBehaviorFor(MARKUP);
- }
- if (WSRPV1PortletManagementPortType.class.isAssignableFrom(serviceClass))
- {
- return (T)registry.getPortletManagementBehavior();
- }
- if (WSRPV1RegistrationPortType.class.isAssignableFrom(serviceClass))
- {
- return (T)registry.getRegistrationBehavior();
- }
- return null;
- }
-
- public BehaviorRegistry getRegistry()
- {
- return registry;
- }
-
- public void setRegistry(BehaviorRegistry registry)
- {
- this.registry = registry;
- }
-
- public boolean isAvailable()
- {
- return initialized;
- }
-
- public boolean isFailed()
- {
- return false;
- }
-
- public void setFailed(boolean failed)
- {
- // do nothing
- }
-
- public void setWSOperationTimeOut(int msBeforeTimeOut)
- {
- if (msBeforeTimeOut < 0)
- {
- msBeforeTimeOut = DEFAULT_TIMEOUT_MS;
- }
-
- timeout = msBeforeTimeOut;
- }
-
- public int getWSOperationTimeOut()
- {
- return timeout;
- }
-
- public String getServiceDescriptionURL()
- {
- return SD_URL;
- }
-
- public String getMarkupURL()
- {
- return M_URL;
- }
-
- public String getRegistrationURL()
- {
- return R_URL;
- }
-
- public String getPortletManagementURL()
- {
- return PM_URL;
- }
-
- public void setServiceDescriptionURL(String serviceDescriptionURL)
- {
- // do nothing
- }
-
- public void setMarkupURL(String markupURL)
- {
- // do nothing
- }
-
- public void setRegistrationURL(String registrationURL)
- {
- // do nothing
- }
-
- public void setPortletManagementURL(String portletManagementURL)
- {
- // do nothing
- }
-
- public void create() throws Exception
- {
- throw new NotYetImplemented();
- }
-
- public void start() throws Exception
- {
- initialized = true;
- }
-
- public void stop()
- {
- throw new NotYetImplemented();
- }
-
- public void setWsdlDefinitionURL(String wsdlDefinitionURL)
- {
- wsdl = wsdlDefinitionURL;
- }
-
- public String getWsdlDefinitionURL()
- {
- return wsdl;
- }
-
- public void destroy()
- {
- throw new NotYetImplemented();
- }
-
- private class SimpleMarkupBehavior extends MarkupBehavior
- {
- public SimpleMarkupBehavior()
- {
- super(BehaviorBackedServiceFactory.this.registry);
- registerHandle(MARKUP);
- }
-
- @Override
- protected String getMarkupString(Mode mode, WindowState windowState, String navigationalState, V1GetMarkup getMarkup)
- throws V1UnsupportedWindowState, V1InvalidCookie, V1InvalidSession, V1AccessDenied, V1InconsistentParameters,
- V1InvalidHandle, V1UnsupportedLocale, V1UnsupportedMode, V1OperationFailed, V1MissingParameters, V1InvalidUserCategory,
- V1InvalidRegistration, V1UnsupportedMimeType
- {
- return MARKUP;
- }
- }
-}
Modified: components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/support/MockEndpointConfigurationInfo.java
===================================================================
--- components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/support/MockEndpointConfigurationInfo.java 2010-05-27 07:15:18 UTC (rev 3208)
+++ components/wsrp/trunk/consumer/src/test/java/org/gatein/wsrp/test/support/MockEndpointConfigurationInfo.java 2010-05-27 16:51:39 UTC (rev 3209)
@@ -24,6 +24,7 @@
package org.gatein.wsrp.test.support;
import org.gatein.wsrp.consumer.EndpointConfigurationInfo;
+import org.gatein.wsrp.test.protocol.v2.BehaviorBackedServiceFactory;
/**
* @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
14 years, 7 months