[Hippo-cms7-user] Direct JCR Access...where is UserSession class?

Frank van Lankvelt f.vanlankvelt at onehippo.com
Thu Sep 30 07:45:46 CEST 2010


Or, if you're developing a stand-alone tool, use the HippoRepositoryFactory
from hippo-ecm-connector.

cheers, Frank

On Thu, Sep 30, 2010 at 3:49 AM, Woonsan Ko <w.ko at onehippo.com> wrote:

>  Hi Matt,
>
> UserSession (org.hippoecm.frontend.session.UserSession) is in
> hippo-ecm-frontend-engine jar.
> Here's dependency information as an example. Version may be different.
>
> <dependency>
> <groupId>org.hippoecm</groupId>
> <artifactId>hippo-ecm-frontend-engine</artifactId>
> <version>2.12.20</version>
> </dependency>
>
> By the way, the guide in the documentation is only for CMS Plugin
> development, not for normal HST component development.
> So, if you intend to develop a custom CMS plugin, then you can use
> org.apache.wicket.Component#getSession() method and cast it to UserSession
> as documented.
> Or, if you just want to access JCR session in a HST component, you can
> directly get jcr session simply by HstRequestContext#getSession() in a
> component.
>
> Regards,
>
> Woonsan
>
>
>
> On 09/29/2010 06:17 PM, mvanbergen wrote:
>
>> Hello,
>>
>> I am looking through the documentation the JCR examples at:
>>
>>
>> http://www.onehippo.org/cms7/documentation/development/content+repository/jcr/examples.html
>>
>> Specifically:
>>
>> Session session = ((UserSession) request.getSession()).getJcrSession();
>>
>> Looks straightforward, but I can't seem to figure out what library the
>> UserSession class resides.  Is there a Maven dependency that should be
>> added
>> to the Site pom to enable me to import this class into my component class
>> (org.hippoecm.frontend.session.UserSession)?
>>
>> Thanks!
>> Matt
>>
>
>
> --
> w.ko at onehippo.com     www.onehippo.com
> NORTH AMERICA • SAN FRANCISCO - Hippo USA Inc. 185 H Street, Suite B
> Petaluma CA 94952 +1 (707) 773-4646
> EUROPE • AMSTERDAM - Hippo B.V. Oosteinde 11 1017 WT Amsterdam
> +31(0)20-5224466
>
>
> _______________________________________________
> Hippo-cms7-user mailing list and forums
> http://www.onehippo.org/cms7/support/forums.html
>



-- 
Hippo
Europe  •  Amsterdam  Oosteinde 11  •  1017 WT Amsterdam  •  +31 (0)20 522
4466
USA  • San Francisco  185 H Street Suite B  •  Petaluma CA 94952-5100 •  +1
(707) 773 4646
Canada    •   Montréal  5369 Boulevard St-Laurent #430 •  Montréal QC H2T
1S5  •  +1 (514) 316 8966
www.onehippo.com  •  www.onehippo.org  •  info at onehippo.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.onehippo.org/pipermail/hippo-cms7-user/attachments/20100930/9010832c/attachment.htm>


More information about the Hippo-cms7-user mailing list