see responses inline:

On Mon, Apr 21, 2008 at 1:07 PM, Zach Cox <[EMAIL PROTECTED]> wrote:

> I would like to have URLs for this feed something like this:
>
> http://site.com/feed/1234
>
>
This should be possible by mounting the feed resource with a "nice" url from
within your WebApplication class:

public class MyApplication extends WebApplication {
  public void init() {
    mountSharedResource("/view/rss", new ResourceReference("myFeed") {
      protected FeedResource newResource() {
        return new MyFeedResource();
      }
    }.getSharedResourceKey());
  }
}








> That way users can add that URL to their feed readers and always get
> the latest info for object 1234.  All of the wicketstuff-rome examples
> I've seen seem to create the FeedResource instance once and then make
> it a shared resource.  I'm currently doing that but the feeds seem to
> disappear and cannot be read in a feed reader after some time.


This would be a question for the wicket folks and not a wicketstuff-rome
issue.  Is there any known limitation for feed resources?



> Since wicketstuff-rome provides a Resource subclass (FeedResource) and
> not a WebPage subclass I'm confused as to how to do the following:
>  - get bookmarkable URLs with a parameter for the feed


You can grab request params by using the getParameters() method within your
FeedResource

public class MyFeedResource extends FeedResource {

  protected SyndFeed getFeed() {
    Long id = getParameters().getLong("id");
  }

}


  - have a new FeedResource created & returned when user accesses that URL


need to ask the wicket folks why this isn't happening...

Reply via email to