Package com.sun.syndication.feed.synd

Examples of com.sun.syndication.feed.synd.SyndLinkImpl


        myContents = new LinkedList<SyndContentImpl>();
        myContents.add(content);

        final SyndContent description = context.mock(SyndContent.class);
        final SyndEntryImpl entry = context.mock(SyndEntryImpl.class);
        final SyndLinkImpl link1 = context.mock(SyndLinkImpl.class, "link1");
        final SyndLinkImpl link2 = context.mock(SyndLinkImpl.class, "link2");

        final List<SyndLinkImpl> myLinks = new LinkedList<SyndLinkImpl>();
        myLinks.add(link1);
        myLinks.add(link2);
View Full Code Here


        myContents = new LinkedList<SyndContentImpl>();
        myContents.add(content);

        final SyndContent description = context.mock(SyndContent.class);
        final SyndEntryImpl entry = context.mock(SyndEntryImpl.class);
        final SyndLinkImpl link1 = context.mock(SyndLinkImpl.class);

        final List<SyndLinkImpl> myLinks = new LinkedList<SyndLinkImpl>();
        myLinks.add(link1);

        context.checking(new Expectations()
View Full Code Here

        HashMap<String, String> object = new HashMap<String, String>();
        object.put("title", entry.getTitle());

        for (Object linkObj : entry.getLinks())
        {
            SyndLinkImpl link = (SyndLinkImpl) linkObj;
            if (link.getRel().equals("enclosure"))
            {
                object.put("largerImage", link.getHref());
            }
            if (link.getRel().equals("alternate"))
            {
                object.put("imagePageURL", link.getHref());
            }
        }

        MediaModule media = (MediaModuleImpl) entry.getModule(MediaModule.URI);
        if (media != null && media.getMetadata().getThumbnail().length > 0)
View Full Code Here

        HashMap<String, String> object = new HashMap<String, String>();
        object.put("title", InputCleaner.stripHtml(entry.getTitle(), MAXLENGTH));

        for (Object linkObj : entry.getLinks())
        {
            SyndLinkImpl link = (SyndLinkImpl) linkObj;
            if (link.getRel().equals("enclosure"))
            {
                object.put("videoStream", InputCleaner.stripHtml(link.getHref(), MAXLENGTH));
            }
            else if (link.getRel().equals("alternate"))
            {
                object.put("videoPageUrl", InputCleaner.stripHtml(link.getHref(), MAXLENGTH));
            }
        }

        if (entry.getDescription() != null)
        {
View Full Code Here

    protected List createSyndLinks(List aLinks) {
        ArrayList sLinks = new ArrayList();
        for (Iterator iter = aLinks.iterator(); iter.hasNext();) {
            Link link = (Link)iter.next();
            SyndLink sLink = new SyndLinkImpl();
            sLink.setHref(     link.getHref());
            sLink.setType(     link.getType());
            sLink.setLength(   link.getLength());
            sLink.setHreflang( link.getHref());
            sLinks.add(sLink);
        }
        return sLinks;
    }
View Full Code Here

        return syndEntry;
    }
   
    public SyndLink createSyndLink(Feed feed, Entry entry, Link link) {
        SyndLink syndLink = new SyndLinkImpl();
        syndLink.setRel(link.getRel());
        syndLink.setType(link.getType());
        syndLink.setHref(link.getHref());
        syndLink.setHreflang(link.getHreflang());
        syndLink.setLength(link.getLength());
        return syndLink;
    }
View Full Code Here

      link.setLengthsyndEnclosure.getLength());
      return link;
    }

    public SyndLink createSyndLink(Link link) {
        SyndLink syndLink = new SyndLinkImpl();
        syndLink.setRel(     link.getRel());
        syndLink.setType(    link.getType());
        syndLink.setHref(    link.getHrefResolved());
        syndLink.setHreflang(link.getHreflang());
        syndLink.setLengthlink.getLength());
        syndLink.setTitle(   link.getTitle());
        return syndLink;
    }
View Full Code Here

        }
        return sLinks;
    }

    public SyndLink createSyndLink(Link link) {
        SyndLink syndLink = new SyndLinkImpl();
        syndLink.setRel(     link.getRel());
        syndLink.setType(    link.getType());
        syndLink.setHref(    link.getHrefResolved());
        syndLink.setTitle(   link.getTitle());
        return syndLink;
    }
View Full Code Here

    protected List createSyndLinks(List aLinks) {
        ArrayList sLinks = new ArrayList();
        for (Iterator iter = aLinks.iterator(); iter.hasNext();) {
            Link link = (Link)iter.next();
            SyndLink sLink = new SyndLinkImpl();
            sLink.setRel(      link.getRel());
            sLink.setHref(     link.getHref());
            sLink.setType(     link.getType());
            sLink.setTitle( link.getTitle());
            sLink.setLength(   link.getLength());
            sLink.setHreflang( link.getHref());
            sLinks.add(sLink);
        }
        return sLinks;
    }
View Full Code Here

        syndEncl.setLength(link.getLength());
        return syndEncl;
    }
   
    public SyndLink createSyndLink(Feed feed, Entry entry, Link link) {
        SyndLink syndLink = new SyndLinkImpl();
        syndLink.setRel(link.getRel());
        syndLink.setType(link.getType());
        syndLink.setHref(link.getHref());
        syndLink.setHreflang(link.getHreflang());
        syndLink.setLength(link.getLength());
        return syndLink;
    }
View Full Code Here

TOP

Related Classes of com.sun.syndication.feed.synd.SyndLinkImpl

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.