You are viewing a plain text version of this content. The canonical link for it is here.
Posted to slide-user@jakarta.apache.org by Brandon Dove <bc...@ureach.com> on 2005/07/22 16:08:17 UTC

Which event to listen for?

Hi -- I'm writing some code that will:

1. Extended ContentAdaptor to listen for "create" ContentEvents.
2. Determine if the resource being created is an image.
3. Get an InputStream from that resource to do some further
processing of the image.

The problem I've run into is that I'm notified of the "create"
event, but at this point the resource doesn't actually exist in
the slide repository so attempting to get an InputStream from
that resource is useless. I've tried listening for other
ContentEvents like "store" but they seem to have the same
result. What event should I be listening for in this situation?

Thanks again for your help.

Cheers,

Brandon

________________________________________________
Get your own "800" number
Voicemail, fax, email, and a lot more
http://www.ureach.com/reg/tag

---------------------------------------------------------------------
To unsubscribe, e-mail: slide-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: slide-user-help@jakarta.apache.org


Re: Which event to listen for?

Posted by Thomas Bellembois <th...@univ-rennes1.fr>.
Hi,

Have you tried with the DetailedWebdavListener ? The "putAfter" event is 
thrown just after a resource is put on the server.
You should be able to retrieve your inputStream using the WebdavEvent.

Hope it helps.

Thomas


Brandon Dove wrote:

>Hi -- I'm writing some code that will:
>
>1. Extended ContentAdaptor to listen for "create" ContentEvents.
>2. Determine if the resource being created is an image.
>3. Get an InputStream from that resource to do some further
>processing of the image.
>
>The problem I've run into is that I'm notified of the "create"
>event, but at this point the resource doesn't actually exist in
>the slide repository so attempting to get an InputStream from
>that resource is useless. I've tried listening for other
>ContentEvents like "store" but they seem to have the same
>result. What event should I be listening for in this situation?
>
>Thanks again for your help.
>
>Cheers,
>
>Brandon
>
>________________________________________________
>Get your own "800" number
>Voicemail, fax, email, and a lot more
>http://www.ureach.com/reg/tag
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: slide-user-unsubscribe@jakarta.apache.org
>For additional commands, e-mail: slide-user-help@jakarta.apache.org
>
>
>  
>


-- 
+---=(    Thomas Bellembois    )=---+
| CRI - University of Rennes 1 - FR |
| thomas.bellembois@univ-rennes1.fr |
| +33 2 23 23 69 60                 |
+-----------------------------------+


---------------------------------------------------------------------
To unsubscribe, e-mail: slide-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: slide-user-help@jakarta.apache.org