Package org.apache.wink.common.model.synd

Examples of org.apache.wink.common.model.synd.SyndText


    public SyndFeed getSyndFeed(@Context Providers providers,
                                @Context LinkBuilders linkBuilders,
                                @Context UriInfo uriInfo) throws IOException {
        SyndFeed feed = new SyndFeed();
        feed.setId("urn:com:hp:qadefects:defects");
        feed.setTitle(new SyndText("Defects"));
        feed.addAuthor(new SyndPerson("admin"));
        feed.setUpdated(new Date());

        feed.setBase(uriInfo.getAbsolutePath().toString());
View Full Code Here


                                  @Context UriInfo uriInfo,
                                  @Context LinkBuilders linkBuilders) throws IOException {
        SyndEntry entry = new SyndEntry();
        String id = defect.getId();
        entry.setId("urn:com:hp:qadefects:defect:" + id);
        entry.setTitle(new SyndText(defect.getName()));
        entry.setSummary(new SyndText(defect.getDescription()));
        entry.addAuthor(new SyndPerson(defect.getAuthor()));
        entry.addCategory(new SyndCategory("urn:com:hp:qadefects:categories:severity", defect
            .getSeverity(), null));
        entry.addCategory(new SyndCategory("urn:com:hp:qadefects:categories:status", defect
            .getStatus(), null));
View Full Code Here

    public SyndEntry getSyndEntry(@Context Providers providers,
                                  @Context UriInfo uriInfo,
                                  @Context LinkBuilders linkBuilders) throws IOException {
        SyndEntry entry = new SyndEntry();
        entry.setId("urn:com:hp:qadefects:defect:" + defect.getId());
        entry.setTitle(new SyndText(defect.getName()));
        entry.setSummary(new SyndText(defect.getDescription()));
        entry.addAuthor(new SyndPerson(defect.getAuthor()));
        entry.addCategory(new SyndCategory("urn:com:hp:qadefects:categories:severity", defect
            .getSeverity(), null));
        entry.addCategory(new SyndCategory("urn:com:hp:qadefects:categories:status", defect
            .getStatus(), null));
View Full Code Here

    public SyndFeed getSyndFeed(@Context Providers providers,
                                @Context LinkBuilders linkProcessor,
                                @Context UriInfo uriInfo) throws IOException {
        SyndFeed synd = new SyndFeed();
        synd.setId("urn:com:hp:qadefects:defects");
        synd.setTitle(new SyndText("Defects"));
        synd.addAuthor(new SyndPerson("admin"));
        synd.setUpdated(new Date());

        // set the entries
        for (DefectBean defect : defects) {
View Full Code Here

    public SyndEntry getSyndEntry(@Context Providers providers,
                                  @Context UriInfo uriInfo,
                                  @Context LinkBuilders linkProcessor) throws IOException {
        SyndEntry entry = new SyndEntry();
        entry.setId("urn:com:hp:qadefects:defect:" + defect.getId());
        entry.setTitle(new SyndText(defect.getName()));
        entry.setSummary(new SyndText(defect.getDescription()));
        entry.addAuthor(new SyndPerson(defect.getAuthor()));
        entry.addCategory(new SyndCategory("urn:com:hp:qadefects:categories:severity", defect
            .getSeverity(), null));
        entry.addCategory(new SyndCategory("urn:com:hp:qadefects:categories:status", defect
            .getStatus(), null));
View Full Code Here

    public SyndEntry getSyndEntry(@Context Providers providers,
                                  @Context UriInfo uriInfo,
                                  @Context LinkBuilders linkProcessor) throws IOException {
        SyndEntry entry = new SyndEntry();
        entry.setId("urn:com:hp:qadefects:test:" + test.getId());
        entry.setTitle(new SyndText(test.getName()));
        entry.setSummary(new SyndText(test.getDescription()));
        entry.addAuthor(new SyndPerson(test.getAuthor()));
        if (test.getCreated() != null) {
            entry.setPublished(new Date(test.getCreated().getTime()));
        }
View Full Code Here

                                                              provider);
    }

    protected SyndFeed getSyndFeed(String path) {
        SyndFeed feed = new SyndFeed();
        feed.setTitle(new SyndText("")); //$NON-NLS-1$
        feed.addLink(new SyndLink(AtomConstants.ATOM_REL_EDIT, null, path));
        return feed;
    }
View Full Code Here

            for (ServiceDocumentCollectionData subCollection : WebDAVRootResource.this
                .getCollections(uriInfo)) {
                // only collection without template URI
                if (!isTemplateUri(subCollection.getUri())) {
                    SyndFeed subFeed = new SyndFeed();
                    subFeed.setTitle(new SyndText(subCollection.getTitle()));
                    subFeed.addLink(new SyndLink(AtomConstants.ATOM_REL_EDIT, null, subCollection
                        .getUri()));
                    collectionsList.add(subFeed);
                }
            }
View Full Code Here

    static public class CollectionResource {

        @GET
        @Produces(MediaType.APPLICATION_ATOM_XML)
        public SyndFeed getCollection(@Context LinkBuilders linkBuilders, @Context UriInfo uriInfo) {
            SyndFeed feed = new SyndFeed(new SyndText("Test"), "test:1", new Date());
            feed.setBase(uriInfo.getBaseUri().toString());

            SyndEntry entry = new SyndEntry(new SyndText("Test"), "test:1", new Date());
            URI requestUri = uriInfo.getAbsolutePath();
            entry.setContent(new SyndContent(requestUri + "/csv", "text/csv", true));
            feed.addEntry(entry);

            linkBuilders.createSystemLinksBuilder().relativize(false).build(feed.getLinks());
View Full Code Here

     * Get the title field
     *
     * @return the title of the resource
     */
    public String getTitle() {
        SyndText textBean = syndFeed.getTitle();
        if (textBean != null) {
            return textBean.getValue();
        }
        return ""; //$NON-NLS-1$
    }
View Full Code Here

TOP

Related Classes of org.apache.wink.common.model.synd.SyndText

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.