Hi Marcel, Peeter and Tobias

Thanks a lot for your help

Michi

Marcel Reutegger wrote:

Hi Michi,

Michael Wechner wrote:

Does it make sense to attach the content of a file to a node as a property

InputStream in = new FileInputStream("/foo/bar.gif");
if (in != null) {
 n.setProperty("data", ...);
}


I would rather use a sub node of type nt:file, which then defines a jcr:content node of type nt:resource. nt:resource defines useful properties such as jcr:encoding, jcr:mimeType, etc. or you could also use a nt:resource node directly as a child node of your content structure.

regards,
 marcel



--
Michael Wechner
Wyona Inc.  -   Open Source Content Management   -   Apache Lenya
http://www.wyona.com                      http://lenya.apache.org
[EMAIL PROTECTED]                        [EMAIL PROTECTED]



Reply via email to