Examples of AddressLine


Examples of org.apache.juddi.datatype.AddressLine

    Address object = new Address();
    object.setUseType("myAddressUseType");
    object.setSortCode("sortThis");
    object.setTModelKey(null);
    object.addAddressLine(new AddressLine("AddressLine1","keyNameAttr","keyValueAttr"));
    object.addAddressLine(new AddressLine("AddressLine2"));

    System.out.println();

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

Examples of org.apache.juddi.datatype.AddressLine

    this.maker = maker;
  }

  public RegistryObject unmarshal(Element element)
  {
    AddressLine obj = new AddressLine();

    // Attributes
    String keyName = element.getAttribute("keyName");
    if ((keyName != null) && (keyName.trim().length() > 0))
      obj.setKeyName(keyName);

    String keyValue = element.getAttribute("keyValue");
    if ((keyValue != null) && (keyValue.trim().length() > 0))
      obj.setKeyValue(keyValue);

    // Text Node Value
    obj.setLineValue(XMLUtils.getText(element));

    // Child Elements
    // {none}

    return obj;
View Full Code Here

Examples of org.apache.juddi.datatype.AddressLine

    return obj;
  }

  public void marshal(RegistryObject object,Element parent)
  {
    AddressLine line = (AddressLine)object;
    Element element = parent.getOwnerDocument().createElement(TAG_NAME);

    String keyName = line.getKeyName();
    if ((keyName != null) && (keyName.trim().length() > 0))
      element.setAttribute("keyName",keyName);

    String keyValue = line.getKeyValue();
    if ((keyValue != null) && (keyValue.trim().length() > 0))
      element.setAttribute("keyValue",keyValue);

    String lineValue = line.getLineValue();
    if (lineValue != null)
      element.appendChild(parent.getOwnerDocument().createTextNode(lineValue));

    parent.appendChild(element);
  }
View Full Code Here

Examples of org.apache.juddi.datatype.AddressLine

  public static void main(String args[])
    throws Exception
  {
    // create the source object
    AddressLine lineIn = new AddressLine("AddressLine1","keyNameAttr","keyValueAttr");

    // unmarshal & marshal (object->xml->object)
    HandlerMaker maker = HandlerMaker.getInstance();
    AbstractHandler handler = maker.lookup(AddressLineHandler.TAG_NAME);
    Element element = null;
    handler.marshal(lineIn,element);
    AddressLine lineOut = (AddressLine)handler.unmarshal(element);

    // compare unmarshaled with marshaled obj
    if (lineOut.equals(lineIn))
      System.out.println("Input and output are the same.");
    else
      System.out.println("Input and output are NOT the same!");
  }
View Full Code Here

Examples of org.apache.juddi.datatype.AddressLine

    Address address = new Address();
    address.setUseType("myAddressUseType");
    address.setSortCode("sortThis");
    address.setTModelKey(null);
    address.addAddressLine(new AddressLine("AddressLine1","keyNameAttr","keyValueAttr"));
    address.addAddressLine(new AddressLine("AddressLine2"));

    Contact contact = new Contact();
    contact.setUseType("myAddressUseType");
    contact.setPersonNameValue("Bob Whatever");
    contact.addDescription(new Description("Bob is a big fat jerk"));
View Full Code Here

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

        String city = postalAddress.getCity();
        String country = postalAddress.getCountry();
        String code = postalAddress.getPostalCode();
        String state = postalAddress.getStateOrProvince();

    AddressLine stnumAL = objectFactory.createAddressLine();
        stnumAL.setKeyName("STREET_NUMBER");
    if (stnum != null) {
        stnumAL.setKeyValue(stnum);
    }

    AddressLine stAL = objectFactory.createAddressLine();
        stAL.setKeyName("STREET");
    if (st != null) {
        stAL.setKeyValue(st);
    }

    AddressLine cityAL = objectFactory.createAddressLine();
        cityAL.setKeyName("CITY");
    if (city != null) {
        cityAL.setKeyValue(city);
    }

    AddressLine countryAL = objectFactory.createAddressLine();
        countryAL.setKeyName("COUNTRY");
    if (country != null) {
        countryAL.setKeyValue(country);
    }

    AddressLine codeAL = objectFactory.createAddressLine();
        codeAL.setKeyName("POSTALCODE");
    if (code != null) {
        codeAL.setKeyValue(code);
    }

    AddressLine stateAL = objectFactory.createAddressLine();
        stateAL.setKeyName("STATE");
    if (state != null) {
        stateAL.setKeyValue(state);
    }

    // Add the AddressLine to vector
    addarr[0] = stnumAL;
    addarr[1] = stAL;
View Full Code Here

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

        String city = post.getCity();
        String country = post.getCountry();
        String code = post.getPostalCode();
        String state = post.getStateOrProvince();

    AddressLine stnumAL = AddressLine.Factory.newInstance();
        stnumAL.setKeyName("STREET_NUMBER");
    if (stnum != null) {
        stnumAL.setKeyValue(stnum);
    }

    AddressLine stAL = AddressLine.Factory.newInstance();
        stAL.setKeyName("STREET");
    if (st != null) {
        stAL.setKeyValue(st);
    }

    AddressLine cityAL = AddressLine.Factory.newInstance();
        cityAL.setKeyName("CITY");
    if (city != null) {
        cityAL.setKeyValue(city);
    }

    AddressLine countryAL = AddressLine.Factory.newInstance();
        countryAL.setKeyName("COUNTRY");
    if (country != null) {
        countryAL.setKeyValue(country);
    }

    AddressLine codeAL = AddressLine.Factory.newInstance();
        codeAL.setKeyName("POSTALCODE");
    if (code != null) {
        codeAL.setKeyValue(code);
    }

    AddressLine stateAL = AddressLine.Factory.newInstance();
        stateAL.setKeyName("STATE");
    if (state != null) {
        stateAL.setKeyValue(state);
    }

    // Add the AddressLine to vector
    addarr[0] = stnumAL;
    addarr[1] = stAL;
View Full Code Here

Examples of org.uddi.api_v2.AddressLine

                List<AddressLine> r = new ArrayList<AddressLine>();
                if (addressLine == null) {
                        return r;
                }
                for (int i = 0; i < addressLine.size(); i++) {
                        AddressLine x = new AddressLine();
                        x.setKeyName(addressLine.get(i).getKeyName());
                        x.setKeyValue(addressLine.get(i).getKeyValue());
                        x.setValue(addressLine.get(i).getValue());
                        r.add(x);
                }
               
                return r;
        }
View Full Code Here

Examples of org.uddi.api_v3.AddressLine

    PersonName personName = new PersonName();
    personName.setLang("en");
    personName.setValue(data.getFirstName(true) + data.getLastName(true));
   
    //Address lines for contact.
    AddressLine addressLineOne = new AddressLine();
    addressLineOne.setKeyName("street");
    addressLineOne.setKeyValue("street");
    addressLineOne.setValue(data.getStreet(false));
   
    AddressLine addressLineTwo = new AddressLine();
    addressLineTwo.setKeyName("town");
    addressLineTwo.setKeyValue("town");
    addressLineTwo.setValue(data.getTown(false));
   
    AddressLine addressLineThree = new AddressLine();
    addressLineThree.setKeyName("zip");
    addressLineThree.setKeyValue("zip");
    addressLineThree.setValue(data.getZip(5));
   
    //One address for the contact. Can be more but only one here.
    Address address = new Address();
    address.setLang("en");
    address.setSortCode("1");
View Full Code Here

Examples of org.uddi.api_v3.AddressLine

   * @param keyValue
   * @return
   */
  public static AddressLine generateAddressLine(String value, String keyName,String keyValue)
  {
    AddressLine addressLine = new AddressLine();
    addressLine.setValue(value);
    if (keyName != null)
      addressLine.setKeyName(keyName);
    if (keyValue != null)
      addressLine.setKeyValue(keyValue);
   
    return addressLine;
  }
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.