Package org.oasis.wsrp.v1

Examples of org.oasis.wsrp.v1.V1CacheControl


   public static V1TelephoneNum toV1TelephoneNum(TelephoneNum telephoneNum)
   {
      if (telephoneNum != null)
      {
         V1TelephoneNum v1TelephoneNum = new V1TelephoneNum();
         v1TelephoneNum.setComment(telephoneNum.getComment());
         v1TelephoneNum.setExt(telephoneNum.getExt());
         v1TelephoneNum.setIntcode(telephoneNum.getIntcode());
         v1TelephoneNum.setLoccode(telephoneNum.getLoccode());
         v1TelephoneNum.setNumber(telephoneNum.getNumber());

         List<Extension> extensions = telephoneNum.getExtensions();
         if (extensions != null)
         {
            v1TelephoneNum.getExtensions().addAll(WSRPUtils.transform(extensions, EXTENSION));
         }

         return v1TelephoneNum;
      }
      else
View Full Code Here


   public static V1Templates toV1Templates(Templates templates)
   {
      if (templates != null)
      {
         //TODO: should we be using the WSRP1TypeFactory,createTemplates(PortletInvocationContext) instead?
         V1Templates v1Templates = new V1Templates();
         v1Templates.setBlockingActionTemplate(templates.getBlockingActionTemplate());
         v1Templates.setDefaultTemplate(templates.getDefaultTemplate());
         v1Templates.setRenderTemplate(templates.getRenderTemplate());
         v1Templates.setResourceTemplate(templates.getResourceTemplate());
         v1Templates.setSecureBlockingActionTemplate(templates.getSecureBlockingActionTemplate());
         v1Templates.setSecureRenderTemplate(templates.getSecureRenderTemplate());
         v1Templates.setSecureResourceTemplate(templates.getSecureResourceTemplate());

         List<Extension> extensions = templates.getExtensions();
         if (extensions != null)
         {
            v1Templates.getExtensions().addAll(WSRPUtils.transform(extensions, EXTENSION));
         }

         return v1Templates;
      }
      else
View Full Code Here

   public static V1BlockingInteractionResponse toV1BlockingInteractionResponse(BlockingInteractionResponse blockingInteractionResponse)
   {
      if (blockingInteractionResponse != null)
      {
         V1BlockingInteractionResponse result;
         V1UpdateResponse updateResponse = toV1UpdateResponse(blockingInteractionResponse.getUpdateResponse());
         String redirectURL = blockingInteractionResponse.getRedirectURL();
         if (redirectURL != null)
         {
            result = WSRP1TypeFactory.createBlockingInteractionResponse(redirectURL);
         }
View Full Code Here

   public static V1UpdateResponse toV1UpdateResponse(UpdateResponse updateResponse)
   {
      if (updateResponse != null)
      {
         V1UpdateResponse v1UpdateResponse = WSRP1TypeFactory.createUpdateResponse();
         v1UpdateResponse.setMarkupContext(toV1MarkupContext(updateResponse.getMarkupContext()));
         v1UpdateResponse.setNavigationalState(updateResponse.getNavigationalContext().getOpaqueValue());
         v1UpdateResponse.setNewWindowState(updateResponse.getNewWindowState());
         v1UpdateResponse.setPortletContext(toV1PortletContext(updateResponse.getPortletContext()));
         v1UpdateResponse.setSessionContext(toV1SessionContext(updateResponse.getSessionContext()));
         v1UpdateResponse.setNewMode(updateResponse.getNewMode());
         return v1UpdateResponse;
      }
      else
      {
         return null;
View Full Code Here

      public V1UploadContext apply(UploadContext uploadContext)
      {
         if (uploadContext != null)
         {
            V1UploadContext result = WSRP1TypeFactory.createUploadContext(uploadContext.getMimeType(), uploadContext.getUploadData());

            List<Extension> extensions = uploadContext.getExtensions();
            if (extensions != null)
            {
               result.getExtensions().addAll(Lists.transform(extensions, EXTENSION));
            }

            List<NamedString> mimeAttributes = uploadContext.getMimeAttributes();
            if (mimeAttributes != null)
            {
               result.getMimeAttributes().addAll(Lists.transform(mimeAttributes, NAMEDSTRING));
            }

            return result;
         }
         else
View Full Code Here

   public static V1UserContext toV1UserContext(UserContext userContext)
   {
      if (userContext != null)
      {
         V1UserContext v1UserContext = WSRP1TypeFactory.createUserContext(userContext.getUserContextKey());

         v1UserContext.setProfile(toV1UserProfile(userContext.getProfile()));

         List<Extension> extensions = userContext.getExtensions();
         if (extensions != null)
         {
            v1UserContext.getExtensions().addAll(WSRPUtils.transform(extensions, EXTENSION));
         }

         if (userContext.getUserCategories() != null)
         {
            v1UserContext.getUserCategories().addAll(userContext.getUserCategories());
         }

         return v1UserContext;
      }
      else
View Full Code Here

   public static V1UserProfile toV1UserProfile(UserProfile userProfile)
   {
      if (userProfile != null)
      {
         V1UserProfile v1UserProfile = new V1UserProfile();
         v1UserProfile.setBdate(userProfile.getBdate());
         v1UserProfile.setBusinessInfo(toV1Context(userProfile.getBusinessInfo()));
         v1UserProfile.setEmployerInfo(toV1EmployerInfo(userProfile.getEmployerInfo()));
         v1UserProfile.setGender(userProfile.getGender());
         v1UserProfile.setHomeInfo(toV1Context(userProfile.getHomeInfo()));
         v1UserProfile.setName(toV1PersonName(userProfile.getName()));

         return v1UserProfile;
      }
      else
      {
View Full Code Here

            Class portTypeClass = null;
            try
            {
               portTypeClass = WSRPV1MarkupPortType.class;
               WSRPV1MarkupPortType markupPortType = wsService.getPort(WSRPV1MarkupPortType.class);
               markupURL = (String)((BindingProvider)markupPortType).getRequestContext().get(BindingProvider.ENDPOINT_ADDRESS_PROPERTY);

               portTypeClass = WSRPV1ServiceDescriptionPortType.class;
               WSRPV1ServiceDescriptionPortType sdPort = wsService.getPort(WSRPV1ServiceDescriptionPortType.class);
               serviceDescriptionURL = (String)((BindingProvider)sdPort).getRequestContext().get(BindingProvider.ENDPOINT_ADDRESS_PROPERTY);
View Full Code Here

         WSRPV2MarkupPortType port = getService(WSRPV2MarkupPortType.class);
         return new V2MarkupService(port);
      }
      else
      {
         WSRPV1MarkupPortType port = getService(WSRPV1MarkupPortType.class);
         return new V1MarkupService(port);
      }
   }
View Full Code Here

         URL wsdlURL = new URL(wsdlDefinitionURL);

         Service service = Service.create(wsdlURL, SERVICE);

//         WSRPV1MarkupPortType markupPortType = service.getPort(WSRPBaseService, WSRPV1MarkupPortType.class);
         WSRPV1MarkupPortType markupPortType = service.getPort(WSRPV1MarkupPortType.class);
         services.put(WSRPV1MarkupPortType.class, markupPortType);
         markupURL = (String)((BindingProvider)markupPortType).getRequestContext().get(BindingProvider.ENDPOINT_ADDRESS_PROPERTY);

//         WSRPV1ServiceDescriptionPortType sdPort = service.getPort(WSRPServiceDescriptionService, WSRPV1ServiceDescriptionPortType.class);
         WSRPV1ServiceDescriptionPortType sdPort = service.getPort(WSRPV1ServiceDescriptionPortType.class);
View Full Code Here

TOP

Related Classes of org.oasis.wsrp.v1.V1CacheControl

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.