You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@roller.apache.org by Ady Das OToole <ad...@optaros.com> on 2007/05/17 01:49:54 UTC

Re: Re: Roller Atom Propono - retrieve/edit comment

What is the right api call to make to retrieve Comments related to an 
entry in Roller. The code below is a test case using The Propono client 
code - I can't seem to find Comment entries related to the specifc Blog 
entries

 for (Iterator it = service.getWorkspaces().iterator(); it.hasNext();) {
            ClientWorkspace space = (ClientWorkspace) it.next();
            System.out.println (space.getTitle());           
            System.out.println ("Workspace: " + space.getTitle());
            for (Iterator colit = space.getCollections().iterator(); 
colit.hasNext();) {
                ClientCollection col = (ClientCollection) colit.next();
//                System.out.println ("   Collection: " + col.getTitle() 
+ " Accepts: " + col.getAccept());
//                System.out.println ("      href: " + col.getHref());
                System.out.println ("\t" + col.getTitle() + "\t" + 
col.getHref());
               
                for (Iterator entries = col.getEntries(); 
entries.hasNext();) {
                    Entry e = (Entry) entries.next();
                    System.out.println (e.getTitle());
                   
                   
                    Iterator contentIter = e.getContents().iterator();
                    while(contentIter.hasNext()){
                        Content content = (Content) contentIter.next();
                        System.out.println("\t" + content.getValue());
                    }
                   
                    Iterator catIter = e.getCategories().iterator();
                    while (catIter.hasNext()){
                        Category cat = (Category)catIter.next();
                        System.out.println("\t" + cat.getTerm());
                    }
                }
               
            }
        }

Ady Das-OToole


Re: Re: Roller Atom Propono - retrieve/edit comment

Posted by Dave <sn...@gmail.com>.
Roller's Atom Publising Protocol (APP) implementation allows you to
create, retrieve, update and delete (CRUD) entries and file-uploads.
There is no support for comments.

Personally, I'd like to see APP CRUD support for all elements of a
weblog (entries, comments, bookmarks, categories, file-uploads,
settings, etc.). And APP CRUD support for user and blog provisioning
(to replace the existing RAP, which is not APP compliant). These items
*may* be on my TODO list after 4.0.

- Dave



On 5/16/07, Ady Das OToole <ad...@optaros.com> wrote:
> What is the right api call to make to retrieve Comments related to an
> entry in Roller. The code below is a test case using The Propono client
> code - I can't seem to find Comment entries related to the specifc Blog
> entries
>
>  for (Iterator it = service.getWorkspaces().iterator(); it.hasNext();) {
>             ClientWorkspace space = (ClientWorkspace) it.next();
>             System.out.println (space.getTitle());
>             System.out.println ("Workspace: " + space.getTitle());
>             for (Iterator colit = space.getCollections().iterator();
> colit.hasNext();) {
>                 ClientCollection col = (ClientCollection) colit.next();
> //                System.out.println ("   Collection: " + col.getTitle()
> + " Accepts: " + col.getAccept());
> //                System.out.println ("      href: " + col.getHref());
>                 System.out.println ("\t" + col.getTitle() + "\t" +
> col.getHref());
>
>                 for (Iterator entries = col.getEntries();
> entries.hasNext();) {
>                     Entry e = (Entry) entries.next();
>                     System.out.println (e.getTitle());
>
>
>                     Iterator contentIter = e.getContents().iterator();
>                     while(contentIter.hasNext()){
>                         Content content = (Content) contentIter.next();
>                         System.out.println("\t" + content.getValue());
>                     }
>
>                     Iterator catIter = e.getCategories().iterator();
>                     while (catIter.hasNext()){
>                         Category cat = (Category)catIter.next();
>                         System.out.println("\t" + cat.getTerm());
>                     }
>                 }
>
>             }
>         }
>
> Ady Das-OToole
>
>