Return-Path: X-Original-To: apmail-jackrabbit-dev-archive@www.apache.org Delivered-To: apmail-jackrabbit-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 7C97A477A for ; Thu, 7 Jul 2011 15:39:05 +0000 (UTC) Received: (qmail 73855 invoked by uid 500); 7 Jul 2011 15:39:05 -0000 Delivered-To: apmail-jackrabbit-dev-archive@jackrabbit.apache.org Received: (qmail 73775 invoked by uid 500); 7 Jul 2011 15:39:04 -0000 Mailing-List: contact dev-help@jackrabbit.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@jackrabbit.apache.org Delivered-To: mailing list dev@jackrabbit.apache.org Received: (qmail 73768 invoked by uid 99); 7 Jul 2011 15:39:04 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 07 Jul 2011 15:39:04 +0000 X-ASF-Spam-Status: No, hits=-1.0 required=5.0 tests=RCVD_IN_DNSWL_MED,SPF_PASS,URI_HEX X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of aklimets@adobe.com designates 64.18.1.27 as permitted sender) Received: from [64.18.1.27] (HELO exprod6og111.obsmtp.com) (64.18.1.27) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 07 Jul 2011 15:38:58 +0000 Received: from outbound-smtp-2.corp.adobe.com ([193.104.215.16]) by exprod6ob111.postini.com ([64.18.5.12]) with SMTP ID DSNKThXS/LIlaOVElAY2ot9vqIaUdS2u1z//@postini.com; Thu, 07 Jul 2011 08:38:37 PDT Received: from inner-relay-4.eur.adobe.com (inner-relay-4b [10.128.4.237]) by outbound-smtp-2.corp.adobe.com (8.12.10/8.12.10) with ESMTP id p67FcaVc023317 for ; Thu, 7 Jul 2011 08:38:36 -0700 (PDT) Received: from nacas01.corp.adobe.com (nacas01.corp.adobe.com [10.8.189.99]) by inner-relay-4.eur.adobe.com (8.12.10/8.12.9) with ESMTP id p67FcJMW014073 for ; Thu, 7 Jul 2011 08:38:35 -0700 (PDT) Received: from eurcas01.eur.adobe.com (10.128.4.27) by nacas01.corp.adobe.com (10.8.189.99) with Microsoft SMTP Server (TLS) id 8.3.159.3; Thu, 7 Jul 2011 08:38:22 -0700 Received: from eurmbx01.eur.adobe.com ([10.128.4.32]) by eurcas01.eur.adobe.com ([10.128.4.27]) with mapi; Thu, 7 Jul 2011 16:38:21 +0100 From: Alexander Klimetschek To: "dev@jackrabbit.apache.org" Date: Thu, 7 Jul 2011 16:38:18 +0100 Subject: Re: what we have to use instead of Query.XPATH Thread-Topic: what we have to use instead of Query.XPATH Thread-Index: Acw8u+XLQ+fGNcxDSaGZTgubEdQyAA== Message-ID: In-Reply-To: <1310019681095-3650763.post@n4.nabble.com> Accept-Language: de-DE, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: user-agent: Microsoft-MacOutlook/14.12.0.110505 acceptlanguage: de-DE, en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 It is only deprecated in the JCR 2.0 spec (and hence the javax.jcr api docs), but Jackrabbit will continue to support it, since a lot of apps on top of Jackrabbit make use of Xpath as the primary query language. Cheers, Alex On 07.07.11 08:21, "g. raaja" wrote: >Hi, > >Its showing Query.XPATH is deprecated and in API its showing > >*Deprecated. As of JCR 2.0, this language is deprecated.* > >my code is: This is for adding spellcheck > >*QueryManager qm =3D jcrSession.getWorkspace().getQueryManager(); >Query query =3D >qm.createQuery("/jcr:root[rep:spellcheck('"+content+"')]/(rep:spellcheck() >)", >Query.XPATH);* > >and in another condition > >*QueryManager qm =3D jcrSession.getWorkspace().getQueryManager(); >stmt1 =3D"//element(*,nt:resource)[jcr:contains(.,'"+content+"')]"; >Query q =3D qm.createQuery(stmt1, Query.XPATH)*; > >I am not getting an idea what I have to use instead of this. > >Please guide me what to use in the place of this Query.XPATH. > >Thanking you. > >--raaja g > >-- >View this message in context: >http://jackrabbit.510166.n4.nabble.com/what-we-have-to-use-instead-of-Quer >y-XPATH-tp3650763p3650763.html >Sent from the Jackrabbit - Dev mailing list archive at Nabble.com. > --=20 Alexander Klimetschek Developer // Adobe (Day) // Berlin - Basel