Package com.jbidwatcher.util.xml

Examples of com.jbidwatcher.util.xml.XMLElement.parseString()


    MQFactory.getConcrete("multisnipe_xml").registerListener(new MessageQueue.Listener() {
      public void messageAction(Object deQ) {
        String idXMLPair = (String)deQ;
        String identifier = idXMLPair.substring(0, idXMLPair.indexOf(' '));
        XMLElement element = new XMLElement();
        element.parseString(idXMLPair, identifier.length() + 1);
        MultiSnipe ms = MultiSnipe.loadFromXML(element);
        addAuctionToMultisnipe(identifier, ms);
      }
    });
View Full Code Here


      //noinspection ThrowableInstanceNeverThrown
      JConfig.log().handleException("loadFromString Failed with a null pointer!", new Exception("Updater got incorrect XML file."));
    } else {
      XMLElement xmlUpdate = new XMLElement(true);

      xmlUpdate.parseString(sb.toString());
      if (xmlUpdate.getTagName().equalsIgnoreCase(packageName)) {
        fromXML(xmlUpdate);
      } else {
        throw new XMLParseException(xmlUpdate.getTagName(), "Updater got incorrect XML file.");
      }
View Full Code Here

      if(type == htmlToken.HTML_TAG || type == htmlToken.HTML_SINGLETAG) {
        if(tok.getToken().startsWith("!")) continue;

        try {
          xe.reset();
          xe.parseString("<" + tok.getToken() + "/>");
        } catch(XMLParseException xpe) {
          JConfig.log().logVerboseDebug("eBay's HTML still sucks.");
          continue;
        }
        String itemprop = xe.getProperty("itemprop");
View Full Code Here

    public void addInput(String newTag) {
      XMLElement inputTag = new XMLElement();

      try {
        inputTag.parseString('<' + newTag + "/>");
      } catch (XMLParseException e) {
        if(XMLElement.rejectingBadHTML()) throw e;
        JConfig.log().handleException("Bad input tag", e);
        return;
      }
View Full Code Here

      if(inputTag.getTagName().equals("button")) {
        XMLElement tempTag = new XMLElement();
        String name = createProperty("name", inputTag, "");
        String value= createProperty("value", inputTag, "");
        String type = createProperty("type", inputTag, "button");
        tempTag.parseString("<input " + type + name + value + "/>");
        inputType = tempTag.getProperty("type");
        inputTag = tempTag;
      }

      boolean showInputs = JConfig.queryConfiguration("debug.showInputs", "false").equals("true");
View Full Code Here

    if (username.length() == 0 || password.length() == 0) return false;
    StringBuffer sb = getRawAccountXML(username, password);
    if(sb == null) return false;

    XMLElement xml = new XMLElement();
    xml.parseString(sb.toString());
    XMLInterface sync = xml.getChild("syncq");
    XMLInterface snipe = xml.getChild("snipeq");
    XMLInterface expires = xml.getChild("expiry");
    XMLInterface listingsRemaining = xml.getChild("listings");
    XMLInterface categoriesRemaining = xml.getChild("categories");
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.