Return-Path: Delivered-To: apmail-cxf-users-archive@www.apache.org Received: (qmail 68809 invoked from network); 14 Apr 2009 17:28:30 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 14 Apr 2009 17:28:30 -0000 Received: (qmail 44438 invoked by uid 500); 14 Apr 2009 17:28:29 -0000 Delivered-To: apmail-cxf-users-archive@cxf.apache.org Received: (qmail 44352 invoked by uid 500); 14 Apr 2009 17:28:29 -0000 Mailing-List: contact users-help@cxf.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@cxf.apache.org Delivered-To: mailing list users@cxf.apache.org Received: (qmail 44342 invoked by uid 99); 14 Apr 2009 17:28:29 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 14 Apr 2009 17:28:29 +0000 X-ASF-Spam-Status: No, hits=-4.0 required=10.0 tests=RCVD_IN_DNSWL_MED,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of Hamlet.DArcy@pearson.com designates 159.182.31.244 as permitted sender) Received: from [159.182.31.244] (HELO usicsmtp2.mx.pearson.com) (159.182.31.244) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 14 Apr 2009 17:28:20 +0000 Received: from IOWACSRVE3WM02.NCSP.PEROOT.COM (Not Verified[10.25.5.29]) by usicsmtp2.mx.pearson.com with MailMarshal (v6,4,1,5038) id ; Tue, 14 Apr 2009 12:27:59 -0500 Received: from IOWACSRVE3MX01.NCSP.PEROOT.COM ([10.25.4.27]) by IOWACSRVE3WM02.NCSP.PEROOT.COM with Microsoft SMTPSVC(6.0.3790.3959); Tue, 14 Apr 2009 12:27:59 -0500 Received: from BGTMNSRVE3MX01.NCSP.PEROOT.COM ([159.182.250.165]) by IOWACSRVE3MX01.NCSP.PEROOT.COM with Microsoft SMTPSVC(6.0.3790.3959); Tue, 14 Apr 2009 12:27:59 -0500 X-MimeOLE: Produced By Microsoft Exchange V6.5 Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Subject: RE: How to get Class of service implementor in an Interceptor? Date: Tue, 14 Apr 2009 12:27:58 -0500 Message-ID: <79F7A365EB1F6B4BB1117651A3888CBA02474FF0@BGTMNSRVE3MX01.NCSP.PEROOT.COM> In-Reply-To: <79F7A365EB1F6B4BB1117651A3888CBA02474FEF@BGTMNSRVE3MX01.NCSP.PEROOT.COM> X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: How to get Class of service implementor in an Interceptor? Thread-Index: Acm85nCxLwJaL9oAQhqts6DSt7RDtwAJ4DQQAAYRPtA= References: <23036393.post@talk.nabble.com> <79F7A365EB1F6B4BB1117651A3888CBA02474FEF@BGTMNSRVE3MX01.NCSP.PEROOT.COM> From: "D'Arcy, Hamlet B" To: X-OriginalArrivalTime: 14 Apr 2009 17:27:59.0474 (UTC) FILETIME=[5B49CD20:01C9BD26] X-Virus-Checked: Checked by ClamAV on apache.org I was able to do this... But it feels hokey.=20 public void handleMessage(Message message) throws Fault { final Exchange exchange =3D message.getExchange(); final BindingOperationInfo operationInfo =3D exchange.get(BindingOperationInfo.class); final Service service =3D exchange.get(Service.class); final MethodDispatcher dispatcher =3D (MethodDispatcher)service.get(MethodDispatcher.class.getName()); final Method method =3D dispatcher.getMethod(operationInfo); ... } -- Hamlet D'Arcy hamlet.darcy@pearson.com > -----Original Message----- > From: D'Arcy, Hamlet B [mailto:Hamlet.DArcy@Pearson.com]=20 > Sent: Tuesday, April 14, 2009 9:36 AM > To: users@cxf.apache.org > Subject: How to get Class of service implementor in an Interceptor?=20 >=20 > Is there a way for me to get the Class reference for my service > implementer within an interceptor?=20 >=20 > Each WebMethod on my service class is annotated with some permissions > information. I want to write an interceptor that reads that permission > information and enforces them.=20 >=20 > My service class is created through Spring. I'll need a=20 > reference to the > Class of the bean and a way to get the name of the method (or Method > object) being invoked.=20 >=20 > Thanks in advance!=20 >=20 > -- > Hamlet D'Arcy > hamlet.darcy@pearson.com >=20