Paul Crabtree wrote:
If there are any examples of this newer method then ill happily update
the PartSource i've implemented.
Paul

I did a quick change to this method last night which I haven't had a chance to test yet. Should be able to get that this weekend (possibly tonight but we're watching the neighbors kids...).


By the way, I may change the interpretation of the uri to treat both upload:// and upload:/ identically and allow both but prefer upload:/. The only thing I can think of which would help after the slash would be to allow an xpath expression or something. Don't want to code it now, but just allow for something like it in the future.

Thanks,
Geoff

Carsten Ziegeler wrote:

Geoff Howard wrote:


[EMAIL PROTECTED] wrote:



ghoward 2003/10/22 18:45:34

Modified: src/webapp/samples/sources sitemap.xmap samples.xml
src/webapp/WEB-INF cocoon.xconf
Added: src/webapp/samples/sources/content upload.xml
src/java/org/apache/cocoon/components/source/impl
PartSource.java PartSourceFactory.java
Log:
Add new multipart file upload Part Source contributed by Paul Crabtree with samples. "Fixes" bug


http://nagoya.apache.org/bugzilla/show_bug.cgi?id=23931

...




1.1

cocoon-2.1/src/java/org/apache/cocoon/components/source/impl/PartS ource.java

...



// get the object model from the component managers

curr env.



Map objectModel =

CocoonComponentManager.getCurrentEnvironment().getObjectModel();


1) Is this really the right way to do it in 2.1?

No :)


If you need access to the objectModel use the Contextualizable

interface.


We have a ContextHelper class that fetches you the object model
out of the Context you get via contextualize.


Ok, I (and Paul obviously) found examples in the code base of the CocoonComponentManager but I found none of the other in a quick look around. I'll update that soon...


2) I know Carsten (Berin?) just overhauled the Environment handling in


2.2 - what's the right way to do this there?

The same as I mentioned above. The way using the

CocoonComponentManager


is not available in 2.2 anymore.


... and then I can copy it over to 2.2.

Thanks,
Geoff


_____________________________________________________________________ This e-mail has been scanned for viruses by MCI's Internet Managed Scanning Services - powered by MessageLabs. For further information visit http://www.mci.com







Reply via email to