You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@jackrabbit.apache.org by ruchi goel <Ru...@Sun.COM> on 2007/02/28 08:12:11 UTC

use of BindableRepository and RepositoryImpl ?

Hi,


  Both org.apache.jackrabbit.core.jndi.BindableRepository  and  
org.apache.jackrabbit.core.RepositoryImpl implements javax.jcr.Repository
How do make a choice /


I am using   the following :

RegistryHelper.registerRepository(ctx, REPOSITORY_NAME, 
REPOSITORY_CONFIG, REPOSITORY_DIR, true);
Repository repository = (RepositoryImpl) ctx.lookup(REPOSITORY_NAME);

The repository which gets returned is BindableRepository.

Should I be using RepositoryImpl and its respective methods ? What is 
the difference ?

Thanks,
Ruchi



Re: use of BindableRepository and RepositoryImpl ?

Posted by Stefan Guggisberg <st...@gmail.com>.
hi ruchi

On 2/28/07, ruchi goel <Ru...@sun.com> wrote:
> Hi,
>
>
>   Both org.apache.jackrabbit.core.jndi.BindableRepository  and
> org.apache.jackrabbit.core.RepositoryImpl implements javax.jcr.Repository
> How do make a choice /
>
>
> I am using   the following :
>
> RegistryHelper.registerRepository(ctx, REPOSITORY_NAME,
> REPOSITORY_CONFIG, REPOSITORY_DIR, true);
> Repository repository = (RepositoryImpl) ctx.lookup(REPOSITORY_NAME);
>
> The repository which gets returned is BindableRepository.
>
> Should I be using RepositoryImpl and its respective methods ? What is
> the difference ?

normally you shouldn't care about the specific class implementing the interface.
unless you have to use implementation specific methods you should always
just use the JCR api, e.g. javax.jcr.Repository.

wrt the difference between BindableRepository and RepositoryImpl:
the javadoc of BindableRepository should answer your questions.

cheers
stefan
>
> Thanks,
> Ruchi
>
>
>