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 "Harding, Christopher (Student Assistant)" <Ch...@softwareag.com> on 2000/11/14 11:57:18 UTC

ContentStores

Hello,
  I have modified the exisiting MemoryDescriptorsStore to give me the
information I require, which is to interact with a Database and display
structures (FOLDERS in MS WebFolders). I want to be able to create and store
objects, to create structures I need. I know when you create a ObjectNode,
to add to the structure you need to add the new URI to the parents CHILD
list, but why can't you do this at the MemoryDescriptorStore without having
to use the StructureHelper, a higher level API. Which requires me to create
a NameAccessToken then get the Helpers that I need to create the structures.

  I can patch the MemoryDescriptorStore to allow me to do this but it's time
consuming on the running side and messy on the programming side, or using
other patches further into Slide itself, which I don't want to do. I
understand that you don't want to have the client access this "low-level",
directly, but I would say it should be available at the
MemoryDescriptorsStore level without having to use the StructureHelper.

  Is there anyway to get around using the StructureHelper within the
MemoryDescriptorStore currently?   If this is possible please can you supply
a code snippet of how this is to be done. Is there any plans to review this
in future releases of Slide?

  Thanxs for any help
 
  Chris Harding

                                  | | | | | | | | |
                 --------
                 ( o  o )
------------oo0---(    )---0oo------------
|  Chris Harding                         |
|     Christopher.Harding@sotwareag.com  |
|                                        |
|----------------------------------------|


Re: ContentStores

Posted by Remy Maucherat <re...@apache.org>.
> Hello,
>   I have modified the exisiting MemoryDescriptorsStore to give me the
> information I require, which is to interact with a Database and display
> structures (FOLDERS in MS WebFolders). I want to be able to create and
store
> objects, to create structures I need. I know when you create a ObjectNode,
> to add to the structure you need to add the new URI to the parents CHILD
> list, but why can't you do this at the MemoryDescriptorStore without
having
> to use the StructureHelper, a higher level API. Which requires me to
create
> a NameAccessToken then get the Helpers that I need to create the
structures.
>
>   I can patch the MemoryDescriptorStore to allow me to do this but it's
time
> consuming on the running side and messy on the programming side, or using
> other patches further into Slide itself, which I don't want to do. I
> understand that you don't want to have the client access this "low-level",
> directly, but I would say it should be available at the
> MemoryDescriptorsStore level without having to use the StructureHelper.
>
>   Is there anyway to get around using the StructureHelper within the
> MemoryDescriptorStore currently?   If this is possible please can you
supply
> a code snippet of how this is to be done. Is there any plans to review
this
> in future releases of Slide?

I never planned to do that. There is not a single operation in the Stores
API which involves manipulating more than one object. All the checks /
updates involving other objects are indeed done at the higher helper leve.
Imposing a more complex contract on the stores wouldn't be a good thing IMO
(and I also want the operations to be as atomic as possible).

BTW, if you want to do whatever you want, you can, since you're given a Uri,
which contains references to the other stores and the namespace to which it
belongs. So calling : uri.getNamespace().getUri("/anotherPath") will give
you another Uri object pointing to the /anotherPath node. Then you can use
newUri.getDescriptorsStore() to access the descriptors store asscoiated with
that node.

Remy