Examples of CategoryBag


Examples of org.apache.juddi.datatype.CategoryBag

          // fetch the TModel CategoryBag
          Vector catVector = TModelCategoryTable.select(tModelKey,connection);
          if ((catVector != null) && (catVector.size() != 0))
          {
            CategoryBag catBag = new CategoryBag();
            catBag.setKeyedReferenceVector(catVector);
            tModel.setCategoryBag(catBag);
          }

          // fetch the TModel IdentifierBag
          Vector idVector = TModelIdentifierTable.select(tModelKey,connection);
View Full Code Here

Examples of org.apache.ws.scout.model.uddi.v2.CategoryBag

                bs.setServiceKey(service.getKey().getId());
            } else {
                bs.setServiceKey("");
            }

            CategoryBag catBag = getCategoryBagFromClassifications(service.getClassifications());
            if (catBag!=null) {
                bs.setCategoryBag(catBag);
            }

            //Add the ServiceBinding information
View Full Code Here

Examples of org.apache.ws.scout.uddi.CategoryBag

                bs.setServiceKey(serve.getKey().getId());
            } else {
                bs.setServiceKey("");
            }

            CategoryBag catBag = getCategoryBagFromClassifications(serve.getClassifications());
            if (catBag!=null) {
                bs.setCategoryBag(catBag);
            }

            //Add the ServiceBinding information
View Full Code Here

Examples of org.uddi.api_v2.CategoryBag

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

Examples of org.uddi.api_v3.CategoryBag

   @Test
   public void testParsingCategoryBagInput() {
     AnnotationProcessor ap = new AnnotationProcessor();
     String categoryBagStr="keyedReference=keyName=uddi-org:types:wsdl;keyValue=wsdlDeployment;tModelKey=uddi:uddi.org:categorization:types," +
        "keyedReference=keyName=uddi-org:types:wsdl2;keyValue=wsdlDeployment2;tModelKey=uddi:uddi.org:categorization:types2";
     CategoryBag categoryBag = ap.parseCategoryBag(categoryBagStr);
     assertEquals(2,categoryBag.getKeyedReference().size());
     KeyedReference keyedReference = categoryBag.getKeyedReference().get(0);
     assertEquals("uddi-org:types:wsdl",keyedReference.getKeyName());
     assertEquals("wsdlDeployment",keyedReference.getKeyValue());
     assertEquals("uddi:uddi.org:categorization:types",keyedReference.getTModelKey());
     KeyedReference keyedReference2 = categoryBag.getKeyedReference().get(1);
     assertEquals("uddi-org:types:wsdl2",keyedReference2.getKeyName());
     assertEquals("wsdlDeployment2",keyedReference2.getKeyValue());
     assertEquals("uddi:uddi.org:categorization:types2",keyedReference2.getTModelKey());
   }
View Full Code Here

Examples of org.uddi.api_v3.CategoryBag

      description.setValue(TokenResolver.replaceTokens(uddiService.description(),properties));
      service.getDescription().add(description);
     
      //categoryBag on the service
      if (!"".equals(uddiService.categoryBag())) {
        CategoryBag categoryBag = parseCategoryBag(uddiService.categoryBag());
            service.setCategoryBag(categoryBag);
      }
     
      //bindingTemplate on service
      BindingTemplate bindingTemplate = parseServiceBinding(clazz, lang, webServiceAnnotation, properties);
View Full Code Here

Examples of org.uddi.api_v3.CategoryBag

          bindingTemplate.getTModelInstanceDetails().getTModelInstanceInfo().add(instanceInfo);
        }
      }
      //categoryBag on the binding
      if (!"".equals(uddiServiceBinding.categoryBag())) {
        CategoryBag categoryBag = parseCategoryBag(uddiServiceBinding.categoryBag());
            bindingTemplate.setCategoryBag(categoryBag);
      }
    } else {
      log.error("Missing UDDIServiceBinding annotation in class " + classWithAnnotations);
    }
View Full Code Here

Examples of org.uddi.api_v3.CategoryBag

   * @param categoryBagStr
   * @return
   */
  protected CategoryBag parseCategoryBag(String categoryBagStr) {
   
    CategoryBag categoryBag = new CategoryBag();
    log.debug("CategoryBag Annotation=" + categoryBagStr);
    if (!"".equals(categoryBagStr)) {
      String[] sections = categoryBagStr.split(",");
          for (String section : sections) {
            if (section.startsWith(KEYED_REFERENCE)) {
                String keyedReferenceStr = section.substring(KEYED_REFERENCE.length(),section.length());
                log.debug("Found KeyedReference=" + keyedReferenceStr);
                String[] keyedReferences = keyedReferenceStr.split(";");
                KeyedReference keyedReference = new KeyedReference();
                for (String key : keyedReferences) {
            if (key.startsWith(KEY_NAME)) keyedReference.setKeyName(key.substring(KEY_NAME.length(),key.length()));
            if (key.startsWith(KEY_VALUE)) keyedReference.setKeyValue(key.substring(KEY_VALUE.length(),key.length()));
            if (key.startsWith(TMODEL_KEY)) keyedReference.setTModelKey(key.substring(TMODEL_KEY.length(),key.length()));
          }
                log.debug("KeyedReference = " + KEY_NAME + keyedReference.getKeyName() + " "
                                          + KEY_VALUE + keyedReference.getKeyValue() + " "
                                          + TMODEL_KEY + keyedReference.getTModelKey());
                categoryBag.getKeyedReference().add(keyedReference);
            } else {
              log.warn("Ignoring " + section);
                   //TODO add support for KeyedReferenceGroups?
            }
          }
View Full Code Here

Examples of org.uddi.api_v3.CategoryBag

      result.setProperty(Property.JUDDI_ROOT_PARTITION, rootKeyGen);
     
      // The node Id is defined as the business key of the business entity categorized as a node.  This entity is saved as part of the install.
      // Only one business entity should be categorized as a node.
      String nodeId = "";
      CategoryBag categoryBag = new CategoryBag();
      KeyedReference keyedRef = new KeyedReference();
      keyedRef.setTModelKey(Constants.NODE_CATEGORY_TMODEL);
      keyedRef.setKeyValue(Constants.NODE_KEYVALUE);
      categoryBag.getKeyedReference().add(keyedRef);
      List<?> keyList = FindBusinessByCategoryQuery.select(em, new FindQualifiers(), categoryBag, null);
      if (keyList != null && keyList.size() > 1)
        throw new ConfigurationException("Only one business entity can be categorized as the node.");
     
      if (keyList != null && keyList.size() > 0) {
View Full Code Here

Examples of org.uddi.api_v3.CategoryBag

      result.setProperty(Property.JUDDI_ROOT_PARTITION, rootKeyGen);
     
      // The node Id is defined as the business key of the business entity categorized as a node.  This entity is saved as part of the install.
      // Only one business entity should be categorized as a node.
      String nodeId = "";
      CategoryBag categoryBag = new CategoryBag();
      KeyedReference keyedRef = new KeyedReference();
      keyedRef.setTModelKey(Constants.NODE_CATEGORY_TMODEL);
      keyedRef.setKeyValue(Constants.NODE_KEYVALUE);
      categoryBag.getKeyedReference().add(keyedRef);
      List<?> keyList = FindBusinessByCategoryQuery.select(em, new FindQualifiers(), categoryBag, null);
      if (keyList != null && keyList.size() > 1)
        throw new ConfigurationException("Only one business entity can be categorized as the node.");
     
      if (keyList != null && keyList.size() > 0) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.