You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@jackrabbit.apache.org by samiam <sa...@ams-engineering.com> on 2006/04/03 09:55:12 UTC

structure of binary content

hi there

i have some questions about binary content. i read this article [1] and
thought the only way to store binary content in my repo is to use a fileNode
(nt:file) and a subNode of this one called resNode ("jcr:content",
"nt:resource")

in the API [2] i read, that there is also a setProperty method for an
inputStream value so i am wondering if it is possible to add binary content
to every Node.

what would be the benefit auf using fileNode and resNode? maybe there is
something important i just overlooked.

tx 4 help
sam

[1] http://www-128.ibm.com/developerworks/java/library/j-jcr/
[2] http://jackrabbit.apache.org/apidocs/index.html
--
View this message in context: http://www.nabble.com/structure-of-binary-content-t1385520.html#a3721413
Sent from the Jackrabbit - Users forum at Nabble.com.


Re: structure of binary content

Posted by Jukka Zitting <ju...@gmail.com>.
Hi,

On 4/3/06, Martin Perez <mp...@gmail.com> wrote:
> On 4/3/06, samiam <sa...@ams-engineering.com> wrote:
> > what would be the benefit auf using fileNode and resNode? maybe there is
> > something important i just overlooked.
>
> The benefit is that is the structure defined by the JSR-170 spec. So if
> other tools/providers/vendors must access to your data it would be more
> intuitive to see nt:resources and jcr:content that other random properties.

Note also that the Jackrabbit full text indexer is one of these tools.
Jackrabbit only indexes the jcr:data binary properties in nt:resource
nodes with a mime type property that is understood by one of the
configured text filters.

BR,

Jukka Zitting

--
Yukatan - http://yukatan.fi/ - info@yukatan.fi
Software craftsmanship, JCR consulting, and Java development

Re: structure of binary content

Posted by Martin Perez <mp...@gmail.com>.
On 4/3/06, samiam <sa...@ams-engineering.com> wrote:
>
>
> hi there
>
> i have some questions about binary content. i read this article [1] and
> thought the only way to store binary content in my repo is to use a
> fileNode
> (nt:file) and a subNode of this one called resNode ("jcr:content",
> "nt:resource")
>
> in the API [2] i read, that there is also a setProperty method for an
> inputStream value so i am wondering if it is possible to add binary
> content
> to every Node.
>
> what would be the benefit auf using fileNode and resNode? maybe there is
> something important i just overlooked.


The benefit is that is the structure defined by the JSR-170 spec. So if
other tools/providers/vendors must access to your data it would be more
intuitive to see nt:resources and jcr:content that other random properties.
For example, if you want to use the WebDAV contribution you must follow the
standard, otherwise the DAV adaptor won't understand your content.

Martin