You are viewing a plain text version of this content. The canonical link for it is here.
Posted to xindice-users@xml.apache.org by Wouter de Vaal <wo...@hotmail.com> on 2004/03/19 16:06:05 UTC

Meta data for binaries

Hi,

I'm trying to store meta data on a binary resource and I get the following error:

org.xmldb.api.base.XMLDBException: :The resource associated with key 'bin' in collection '/db/publications/testxmlcollection' is not XML document
 at org.apache.xindice.client.xmldb.xmlrpc.CollectionImpl.runRemoteCommand(CollectionImpl.java:201)
 at org.apache.xindice.client.xmldb.xmlrpc.CollectionImpl.setMetaData(CollectionImpl.java:764)
 at nl.relate4u.publications.xmldb.XMLCollection.setMetaData(XMLCollection.java:729)
 ... 24 more

I see there is not binary type defined in the MetaData class. Does this mean MetaData is not supported for binary resources?

What I'm trying to accomplish is storing the mime-type with the binary (for example image/jpeg) and I figured MetaData would be a good place for this.

Regards,
Wouter

Re: Meta data for binaries

Posted by Vadim Gritsenko <va...@reverycodes.com>.
Wouter de Vaal wrote:

> I'm trying to store meta data on a binary resource and I get the 
> following error:
>  
> org.xmldb.api.base.XMLDBException: :The resource associated with key 
> 'bin' in collection '/db/publications/testxmlcollection' is not XML 
> document
>  at 
> org.apache.xindice.client.xmldb.xmlrpc.CollectionImpl.runRemoteCommand(CollectionImpl.java:201)
>  at 
> org.apache.xindice.client.xmldb.xmlrpc.CollectionImpl.setMetaData(CollectionImpl.java:764)
>  at 
> nl.relate4u.publications.xmldb.XMLCollection.setMetaData(XMLCollection.java:729)
>  ... 24 more
>  
> I see there is not binary type defined in the MetaData class. Does 
> this mean MetaData is not supported for binary resources?


Fixed in the CVS. See BinaryResourceTest, last method.

Vadim