Package com.google.gdata.model.atom

Examples of com.google.gdata.model.atom.Link


      public boolean startElement(XmlWriter xw, Element parent, Element e,
          ElementMetadata<?, ?> metadata) throws IOException {
        if (!(e instanceof Link)) {
          return super.startElement(xw, parent, e, metadata);
        }
        Link link = (Link) e;
        String rel = link.getRel();
        String type = link.getType();
        String href = link.getHref();
        long length = link.getLength();

        if (rel != null && rel.equals("enclosure")) {
          generateEnclosure(xw, type, href, length);
        } else if ("comments".equals(rel)) {
          xw.simpleElement(Namespaces.rssNs, "comments", null, href);
View Full Code Here


        TextContent title = source.getTitle();
        if (title != null) {
          xw.simpleElement(Namespaces.rssNs, "title", null,
              title.getPlainText());
        }
        Link htmlLink = source.getHtmlLink();
        if (htmlLink != null) {
          xw.simpleElement(Namespaces.rssNs, "link", null, htmlLink.getHref());
        }
        xw.endElement(Namespaces.rssNs, "image");

        return false;
      }
View Full Code Here

TOP

Related Classes of com.google.gdata.model.atom.Link

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.