Examples of RelatedBusinessInfo


Examples of com.sun.xml.registry.uddi.bindings_v2_2.RelatedBusinessInfo

    /**
     * Create an instance of {@link RelatedBusinessInfo }
     *
     */
    public RelatedBusinessInfo createRelatedBusinessInfo() {
        return new RelatedBusinessInfo();
    }
View Full Code Here

Examples of org.apache.juddi.datatype.response.RelatedBusinessInfo

    AbstractHandler handler = maker.lookup(RelatedBusinessInfosHandler.TAG_NAME);
    Element parent = XMLUtils.newRootElement();
    Element child = null;

    RelatedBusinessInfos infos = new RelatedBusinessInfos();
    infos.addRelatedBusinessInfo(new RelatedBusinessInfo());
    infos.addRelatedBusinessInfo(new RelatedBusinessInfo());

    System.out.println();

    RegistryObject regObject = infos;
    handler.marshal(regObject,parent);
View Full Code Here

Examples of org.apache.juddi.datatype.response.RelatedBusinessInfo

    RelatedBusinessesList list = new RelatedBusinessesList();
    list.setGeneric("2.0");
    list.setOperator("jUDDI.org");
    list.setTruncated(true);
    list.setBusinessKey(new BusinessKey("f9f0c35f-06ab-4bec-9c7d-b1469e73f0eb"));
    list.addRelatedBusinessInfo(new RelatedBusinessInfo("abc"));
    list.addRelatedBusinessInfo(new RelatedBusinessInfo("xyz"));

    System.out.println();

    RegistryObject regObject = list;
    handler.marshal(regObject,parent);
View Full Code Here

Examples of org.apache.juddi.datatype.response.RelatedBusinessInfo

    this.maker = maker;
  }

  public RegistryObject unmarshal(Element element)
  {
    RelatedBusinessInfo obj = new RelatedBusinessInfo();
    Vector nodeList = null;
    AbstractHandler handler = null;

    // Attributes
    // {none}

    // Text Node Value
    // {none}

    // Child Elements
    nodeList = XMLUtils.getChildElementsByTagName(element,BusinessKeyHandler.TAG_NAME);
    if (nodeList.size() > 0)
    {
      handler = maker.lookup(BusinessKeyHandler.TAG_NAME);
      obj.setBusinessKey((BusinessKey)handler.unmarshal((Element)nodeList.elementAt(0)));
    }

    nodeList = XMLUtils.getChildElementsByTagName(element,NameHandler.TAG_NAME);
    for (int i=0; i<nodeList.size(); i++)
    {
      handler = maker.lookup(NameHandler.TAG_NAME);
      Name name = (Name )handler.unmarshal((Element)nodeList.elementAt(i));
      if (name != null)
        obj.addName(name);
    }

    nodeList = XMLUtils.getChildElementsByTagName(element,DescriptionHandler.TAG_NAME);
    for (int i=0; i<nodeList.size(); i++)
    {
      handler = maker.lookup(DescriptionHandler.TAG_NAME);
      Description descr = (Description)handler.unmarshal((Element)nodeList.elementAt(i));
      if (descr != null)
        obj.addDescription(descr);
    }

    nodeList = XMLUtils.getChildElementsByTagName(element,SharedRelationshipsHandler.TAG_NAME);
    if (nodeList.size() > 0)
    {
      handler = maker.lookup(SharedRelationshipsHandler.TAG_NAME);
      obj.setSharedRelationships((SharedRelationships)handler.unmarshal((Element)nodeList.elementAt(0)));
    }

    return obj;
  }
View Full Code Here

Examples of org.apache.juddi.datatype.response.RelatedBusinessInfo

  /**
   *
   */
  public void marshal(RegistryObject object,Element parent)
  {
    RelatedBusinessInfo info = (RelatedBusinessInfo)object;
    String generic = getGeneric(null);
    String namespace = getUDDINamespace(generic);
    Element element = parent.getOwnerDocument().createElementNS(namespace,TAG_NAME);
    AbstractHandler handler = null;

    String businessKey = info.getBusinessKey();
    if (businessKey != null)
    {
      handler = maker.lookup(BusinessKeyHandler.TAG_NAME);
      handler.marshal(new BusinessKey(businessKey),element);
    }

    Vector nameVector = info.getNameVector();
    if ((nameVector!=null) && (nameVector.size() > 0))
    {
      handler = maker.lookup(NameHandler.TAG_NAME);
      for (int i=0; i < nameVector.size(); i++)
        handler.marshal((org.apache.juddi.datatype.Name)nameVector.elementAt(i),element);
    }

    Vector descVector = info.getDescriptionVector();
    if ((descVector!=null) && (descVector.size() > 0))
    {
      handler = maker.lookup(DescriptionHandler.TAG_NAME);
      for (int i=0; i < descVector.size(); i++)
        handler.marshal((Description)descVector.elementAt(i),element);
    }

    SharedRelationships relationships = info.getSharedRelationships();
    if (relationships != null)
    {
      handler = maker.lookup(SharedRelationshipsHandler.TAG_NAME);
      handler.marshal(relationships,element);
    }
View Full Code Here

Examples of org.apache.juddi.datatype.response.RelatedBusinessInfo

    HandlerMaker maker = HandlerMaker.getInstance();
    AbstractHandler handler = maker.lookup(RelatedBusinessInfoHandler.TAG_NAME);
    Element parent = XMLUtils.newRootElement();
    Element child = null;

    RelatedBusinessInfo info = new RelatedBusinessInfo();
    info.setBusinessKey("");
    info.setBusinessKey("6c0ac186-d36b-4b81-bd27-066a5fe0fc1f");
    info.addName(new Name("businessNm"));
    info.addName(new Name("businessNm2","en"));
    info.addDescription(new Description("business whatever"));
    info.addDescription(new Description("business whatever too","fr"));
    info.addKeyedReference(new KeyedReference("idBagKeyName","idBagkeyValue"));
    info.addKeyedReference(new KeyedReference("uuid:f78a135a-4769-4e79-8604-54d440314bc0","idBagKeyName2","idBagkeyValue2"));

    System.out.println();

    RegistryObject regObject = info;
    handler.marshal(regObject,parent);
View Full Code Here

Examples of org.apache.juddi.datatype.response.RelatedBusinessInfo

        String relatedKey = (String)keyVector.elementAt(i);
        BusinessInfo bizInfo = fetchBusinessInfo(relatedKey);

        if(bizInfo != null)
        {
          RelatedBusinessInfo relatedBizInfo = new  RelatedBusinessInfo();

          relatedBizInfo.setBusinessKey(bizInfo.getBusinessKey());
          relatedBizInfo.setNameVector( bizInfo.getNameVector() );
          relatedBizInfo.setDescriptionVector( bizInfo.getDescriptionVector() );

          Vector keyedReferences = PublisherAssertionTable.selectRelatedBusinesses(businessKey,relatedKey,connection);
          relatedBizInfo.setSharedRelationships(new SharedRelationships(keyedReferences));

          infoVector.addElement(relatedBizInfo);
        }
      }
    }
View Full Code Here

Examples of org.apache.juddi.datatype.response.RelatedBusinessInfo

        String relatedKey = (String)keyVector.elementAt(i);
        BusinessInfo bizInfo = fetchBusinessInfo(relatedKey);

        if(bizInfo != null)
        {
          RelatedBusinessInfo relatedBizInfo = new  RelatedBusinessInfo();

          relatedBizInfo.setBusinessKey(bizInfo.getBusinessKey());
          relatedBizInfo.setNameVector( bizInfo.getNameVector() );
          relatedBizInfo.setDescriptionVector( bizInfo.getDescriptionVector() );

          Vector keyedReferences = PublisherAssertionTable.selectRelatedBusinesses(businessKey,relatedKey,connection);
          relatedBizInfo.setSharedRelationships(new SharedRelationships(keyedReferences));

          infoVector.addElement(relatedBizInfo);
        }
      }
    }
View Full Code Here

Examples of org.apache.juddi.datatype.response.RelatedBusinessInfo

    handler = ( RelatedBusinessInfoHandler)maker.lookup( RelatedBusinessInfoHandler.TAG_NAME);
  }

  private RegistryObject getRegistryObject()
  {
    RelatedBusinessInfo object = new RelatedBusinessInfo();
    object.setBusinessKey("");
    object.setBusinessKey("6c0ac186-d36b-4b81-bd27-066a5fe0fc1f");
    object.addName(new Name("businessNm"));
    object.addName(new Name("businessNm2","en"));
    object.addDescription(new Description("business whatever"));
    object.addDescription(new Description("business whatever too","fr"));
    object.addKeyedReference(new KeyedReference("idBagKeyName","idBagkeyValue"));
    object.addKeyedReference(new KeyedReference("uuid:f78a135a-4769-4e79-8604-54d440314bc0","idBagKeyName2","idBagkeyValue2"));

    return object;

  }
View Full Code Here

Examples of org.apache.juddi.datatype.response.RelatedBusinessInfo

    AbstractHandler handler = maker.lookup(RelatedBusinessInfosHandler.TAG_NAME);
    Element parent = XMLUtils.newRootElement();
    Element child = null;

    RelatedBusinessInfos infos = new RelatedBusinessInfos();
    infos.addRelatedBusinessInfo(new RelatedBusinessInfo());
    infos.addRelatedBusinessInfo(new RelatedBusinessInfo());

    System.out.println();

    RegistryObject regObject = infos;
    handler.marshal(regObject,parent);
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.