Package org.uddi.api_v3

Examples of org.uddi.api_v3.CategoryBag


                FindBinding fb = new FindBinding();
                fb.setAuthInfo(authInfoJoe);
                fb.setFindQualifiers(new FindQualifiers());
                fb.getFindQualifiers().getFindQualifier().addAll(Arrays.asList(fq));
                if (cats != null) {
                        fb.setCategoryBag(new CategoryBag());
                        fb.getCategoryBag().getKeyedReference().addAll(Arrays.asList(cats));
                }
                //fb.setName(new Name(UDDIConstants.WILDCARD, null));
                inquiry.findBinding(fb);
        }
View Full Code Here


        private static CategoryBag MapCategoryBag(org.uddi.api_v2.CategoryBag categoryBag) {
                if (categoryBag == null) {
                        return null;
                }
                CategoryBag c = new CategoryBag();
                c.getKeyedReference().addAll(MapKeyedReference(categoryBag.getKeyedReference()));
                return c;
        }
View Full Code Here

                        overviewURL.setValue(wsdlURL);
                        OverviewDoc overviewDoc = new OverviewDoc();
                        overviewDoc.setOverviewURL(overviewURL);
                        tModel.getOverviewDoc().add(overviewDoc);
                        // Create the categoryBag, The tModel MUST contain a categoryBag
                        CategoryBag categoryBag = new CategoryBag();

            // the categoryBag MUST contain a keyedReference with a tModelKey of the WSDL
                        // Entity Type category system and a keyValue of "portType".
                        KeyedReference typesReference = newKeyedReference(
                                "uddi:uddi.org:wsdl:types", "uddi-org:wsdl:types", "portType");
                        categoryBag.getKeyedReference().add(typesReference);

            // If the wsdl:portType has a targetNamespace then the categoryBag MUST also contain an
                        // additional keyedReference with a tModelKey of the XML Namespace category system and a
                        // keyValue of the target namespace of the wsdl:definitions element that contains the
                        // wsdl:portType. If the targetNamespace is absent from the portType, a categoryBag
                        // MUST NOT contain a keyedReference to the XML Namespace category system.
                        if (namespace != null && !"".equals(namespace)) {
                                KeyedReference namespaceReference = newKeyedReference(
                                        "uddi:uddi.org:xml:namespace", "uddi-org:xml:namespace", namespace);
                                categoryBag.getKeyedReference().add(namespaceReference);
                        }

                        tModel.setCategoryBag(categoryBag);
                        tModels.add(tModel);
                }
View Full Code Here

         * @return tModel info
         */
        public static FindTModel createFindBindingTModelForPortType(String portType, String namespace) {

                FindTModel findTModel = new FindTModel();
                CategoryBag categoryBag = new CategoryBag();

                if (namespace != null && namespace.length() != 0) {
                        KeyedReference namespaceReference = newKeyedReference(
                                "uddi:uddi.org:xml:namespace", "uddi-org:xml:namespace", namespace);
                        categoryBag.getKeyedReference().add(namespaceReference);
                }
                KeyedReference bindingReference = newKeyedReference(
                        "uddi:uddi.org:wsdl:types", "uddi-org:wsdl:types", "binding");
                categoryBag.getKeyedReference().add(bindingReference);

                KeyedReference portTypeReference = newKeyedReference(
                        "uddi:uddi.org:wsdl:porttypereference", "uddi-org:wsdl:portTypeReference", portType);
                categoryBag.getKeyedReference().add(portTypeReference);

                findTModel.setCategoryBag(categoryBag);

                if (log.isDebugEnabled()) {
                        log.debug(new PrintUDDI<FindTModel>().print(findTModel));
View Full Code Here

                Name name = new Name();
                name.setLang("en");
                name.setValue(portTypeName);
                findTModel.setName(name);

                CategoryBag categoryBag = new CategoryBag();
                if (namespace != null && namespace.length() != 0) {
                        KeyedReference namespaceReference = newKeyedReference(
                                "uddi:uddi.org:xml:namespace", "uddi-org:xml:namespace", namespace);
                        categoryBag.getKeyedReference().add(namespaceReference);
                }
                KeyedReference bindingReference = newKeyedReference(
                        "uddi:uddi.org:wsdl:types", "uddi-org:wsdl:types", "portType");
                categoryBag.getKeyedReference().add(bindingReference);

                findTModel.setCategoryBag(categoryBag);

                if (log.isDebugEnabled()) {
                        log.debug(new PrintUDDI<FindTModel>().print(findTModel));
View Full Code Here

                Name sName = new Name();
                sName.setLang(lang);
                sName.setValue(serviceQName.getLocalPart());
                service.getName().add(sName);

                CategoryBag categoryBag = new CategoryBag();

                String namespace = serviceQName.getNamespaceURI();
                if (namespace != null && namespace.length() != 0) {
                        KeyedReference namespaceReference = newKeyedReference(
                                "uddi:uddi.org:xml:namespace", "uddi-org:xml:namespace", namespace);
                        categoryBag.getKeyedReference().add(namespaceReference);
                }

                KeyedReference serviceReference = newKeyedReference(
                        "uddi:uddi.org:wsdl:types", "uddi-org:wsdl:types", "service");
                categoryBag.getKeyedReference().add(serviceReference);

                KeyedReference localNameReference = newKeyedReference(
                        "uddi:uddi.org:xml:localname", "uddi-org:xml:localName", serviceQName.getLocalPart());
                categoryBag.getKeyedReference().add(localNameReference);

                service.setCategoryBag(categoryBag);

                return service;
        }
View Full Code Here

            TModelDetail tModelDetail = clerk.getTModelDetail(findAllPortTypesForProcess);
            if (tModelDetail!=null) {
              List<TModel> tModelPortTypeList = tModelDetail.getTModel();
              if (tModelPortTypeList!=null && tModelPortTypeList.size()>0) {
                TModel bpel4WSTModel = tModelPortTypeList.get(0);
                CategoryBag categoryBag = bpel4WSTModel.getCategoryBag();
                if (categoryBag!=null && categoryBag.getKeyedReference()!=null) {
                  List<KeyedReference> portTypeTModelKeys = new ArrayList<KeyedReference>();
                  KeyedReference namespaceRef = null;
                  for (KeyedReference keyedReference : categoryBag.getKeyedReference()) {
                    if ("uddi:uddi.org:wsdl:porttypereference".equals(keyedReference.getTModelKey()) ) {
                      portTypeTModelKeys.add(keyedReference);
                    }
                    if ("uddi:uddi.org:xml:namespace".equals(keyedReference.getTModelKey()) ) {
                      namespaceRef = keyedReference;
View Full Code Here

   
    //customization to add KeyedReferences into the categoryBag of the service
    if (properties.containsKey(Property.SERVICE_CATEGORY_BAG)) {
      String serviceCategoryBag = properties.getProperty(Property.SERVICE_CATEGORY_BAG);
      log.debug("Adding KeyedReferences '" +  serviceCategoryBag + "' to service " + serviceName.getLocalPart());
      CategoryBag categoryBag = parseCategoryBag(serviceCategoryBag);
          service.setCategoryBag(categoryBag);
    }
   
    return service;
  }
View Full Code Here

      overviewURL.setValue("http://localhost:8080/bpel-console/"); //should point to the bpel of this process, maybe in guvnor
      OverviewDoc overviewDoc = new OverviewDoc();
      overviewDoc.setOverviewURL(overviewURL);
      tModel.getOverviewDoc().add(overviewDoc);
      // Set the categoryBag
      CategoryBag categoryBag = new CategoryBag();
     
      if (targetNamespace!=null) {
        KeyedReference namespaceReference = WSDL2UDDI.newKeyedReference(
          "uddi:uddi.org:xml:namespace", "uddi-org:xml:namespace", targetNamespace);
        categoryBag.getKeyedReference().add(namespaceReference);
      }
      KeyedReference typesReference = WSDL2UDDI.newKeyedReference(
          "uddi:uddi.org:bpel:types", "uddi-org:bpel:types", "process");
      categoryBag.getKeyedReference().add(typesReference);
      for (QName qName : portTypes.keySet()) {
        String portTypeKey = keyDomainURI + qName.getLocalPart();
        KeyedReference portTypeReference = WSDL2UDDI.newKeyedReference(
            "uddi:uddi.org:wsdl:porttypereference", "uddi-org:wsdl:portTypeReference", portTypeKey);
        categoryBag.getKeyedReference().add(portTypeReference);
      }
     
      tModel.setCategoryBag(categoryBag);
     
      if (log.isDebugEnabled()) {
View Full Code Here

      FindTModel findTModel = new FindTModel();
      Name name = new Name();
      //name.setLang(lang);
      name.setValue(serviceName.getLocalPart());
      findTModel.setName(name);
      CategoryBag categoryBag = new CategoryBag();
     
      String namespace = serviceName.getNamespaceURI();
      if (namespace!=null && namespace.length()!=0) {
        KeyedReference namespaceReference = WSDL2UDDI.newKeyedReference(
          "uddi:uddi.org:xml:namespace", "uddi-org:xml:namespace", namespace);
        categoryBag.getKeyedReference().add(namespaceReference);
      }
      KeyedReference typesReference = WSDL2UDDI.newKeyedReference(
          "uddi:uddi.org:bpel:types", "uddi-org:bpel:types", "process");
      categoryBag.getKeyedReference().add(typesReference);
      findTModel.setCategoryBag(categoryBag);
     
      if (log.isDebugEnabled()) {
        log.debug(new PrintUDDI<FindTModel>().print(findTModel));
      }
View Full Code Here

TOP

Related Classes of org.uddi.api_v3.CategoryBag

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.