Package com.colorfulsoftware.atom

Examples of com.colorfulsoftware.atom.Category


      catAttrs.add(feedDoc.buildAttribute("term", "music"));
      catAttrs.add(feedDoc.buildAttribute("scheme",
          "http://mtv.com/genere"));
      catAttrs.add(feedDoc.buildAttribute("label", "music"));
      List<Category> categories = new LinkedList<Category>();
      Category category = feedDoc.buildCategory(catAttrs, null);
      categories.add(category);

      List<Attribute> linkAttrs = new LinkedList<Attribute>();
      linkAttrs.add(feedDoc
          .buildAttribute("href", "http://www.yahoo.com"));
View Full Code Here


    }

    try {
      List<Attribute> attrs = new LinkedList<Attribute>();
      attrs.add(feedDoc.buildAttribute("term", "something"));
      Category cat = feedDoc.buildCategory(attrs, "");
      assertTrue(cat != null);
      assertTrue(cat.getContent() == null);
    } catch (Exception e) {
      fail("should not get here.");
    }

    try {
      List<Attribute> attrs = new LinkedList<Attribute>();
      attrs.add(feedDoc.buildAttribute("term", "something"));
      Category cat = feedDoc.buildCategory(attrs,
          "anything should not throw exception");
      assertTrue(cat != null);
      assertTrue(cat.getContent() != null);
    } catch (Exception e) {
      fail("should not get here.");
    }
  }
View Full Code Here

      catAttrs.add(feedDoc.buildAttribute("term", "music"));
      catAttrs.add(feedDoc.buildAttribute("scheme",
          "http://mtv.com/genere"));
      catAttrs.add(feedDoc.buildAttribute("label", "music"));
      List<Category> categories = new LinkedList<Category>();
      Category category = feedDoc.buildCategory(catAttrs, null);
      categories.add(category);

      List<Attribute> linkAttrs = new LinkedList<Attribute>();
      linkAttrs.add(feedDoc
          .buildAttribute("href", "http://www.yahoo.com"));
View Full Code Here

    }

    try {
      List<Attribute> attrs = new LinkedList<Attribute>();
      attrs.add(feedDoc.buildAttribute("term", "something"));
      Category cat = feedDoc.buildCategory(attrs, "");
      assertTrue(cat != null);
      assertTrue(cat.getContent() == null);
    } catch (Exception e) {
      fail("should not get here.");
    }

    try {
      List<Attribute> attrs = new LinkedList<Attribute>();
      attrs.add(feedDoc.buildAttribute("term", "something"));
      Category cat = feedDoc.buildCategory(attrs,
          "anything should not throw exception");
      assertTrue(cat != null);
      assertTrue(cat.getContent() != null);
    } catch (Exception e) {
      fail("should not get here.");
    }
  }
View Full Code Here

      catAttrs.add(feedDoc.buildAttribute("term", "music"));
      catAttrs.add(feedDoc.buildAttribute("scheme",
          "http://mtv.com/genere"));
      catAttrs.add(feedDoc.buildAttribute("label", "music"));
      List<Category> categories = new LinkedList<Category>();
      Category category = feedDoc.buildCategory(catAttrs, null);
      categories.add(category);

      List<Attribute> linkAttrs = new LinkedList<Attribute>();
      linkAttrs.add(feedDoc
          .buildAttribute("href", "http://www.yahoo.com"));
View Full Code Here

    }

    try {
      List<Attribute> attrs = new LinkedList<Attribute>();
      attrs.add(feedDoc.buildAttribute("term", "something"));
      Category cat = feedDoc.buildCategory(attrs, "");
      assertTrue(cat != null);
      assertTrue(cat.getContent() == null);
    } catch (Exception e) {
      fail("should not get here.");
    }

    try {
      List<Attribute> attrs = new LinkedList<Attribute>();
      attrs.add(feedDoc.buildAttribute("term", "something"));
      Category cat = feedDoc.buildCategory(attrs,
          "anything should not throw exception");
      assertTrue(cat != null);
      assertTrue(cat.getContent() != null);
    } catch (Exception e) {
      fail("should not get here.");
    }
  }
View Full Code Here

      catAttrs.add(feedDoc.buildAttribute("term", "music"));
      catAttrs.add(feedDoc.buildAttribute("scheme",
          "http://mtv.com/genere"));
      catAttrs.add(feedDoc.buildAttribute("label", "music"));
      List<Category> categories = new LinkedList<Category>();
      Category category = feedDoc.buildCategory(catAttrs, null);
      categories.add(category);

      List<Attribute> linkAttrs = new LinkedList<Attribute>();
      linkAttrs.add(feedDoc
          .buildAttribute("href", "http://www.yahoo.com"));
View Full Code Here

    }

    try {
      List<Attribute> attrs = new LinkedList<Attribute>();
      attrs.add(feedDoc.buildAttribute("term", "something"));
      Category cat = feedDoc.buildCategory(attrs, "");
      assertTrue(cat != null);
      assertTrue(cat.getContent() == null);
    } catch (Exception e) {
      fail("should not get here.");
    }

    try {
      List<Attribute> attrs = new LinkedList<Attribute>();
      attrs.add(feedDoc.buildAttribute("term", "something"));
      Category cat = feedDoc.buildCategory(attrs,
          "anything should not throw exception");
      assertTrue(cat != null);
      assertTrue(cat.getContent() != null);
    } catch (Exception e) {
      fail("should not get here.");
    }
  }
View Full Code Here

TOP

Related Classes of com.colorfulsoftware.atom.Category

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.