Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
RE: [aspectj-users] How can I intercept every calltoEntityManager.<somemethod>(arg)

What do you mean by full full qualified name I didn't understand sorry
can you explain please 

-----Original Message-----
From: aspectj-users-bounces@xxxxxxxxxxx
[mailto:aspectj-users-bounces@xxxxxxxxxxx] On Behalf Of Bhaskar Maddala
Sent: Thursday, November 29, 2007 7:23 PM
To: aspectj-users@xxxxxxxxxxx
Subject: Re: [aspectj-users] How can I intercept every
calltoEntityManager.<somemethod>(arg)

>> [Xlint:invalidAbsoluteTypeName]-advice defined in
com.infrastructure.security.AspectSecurity has not been applied
[Xlint:adviceDidNotMatch]

I am guessing you are doing something like

pointcut entityMgrInvocation() : .... call(* EntityManager.*(..)) .... ;

instead of

pointcut entityMgrInvocation() : .... call(* <full qualified
EntityManager>.*(..)) .... ;

Using "call" here as I am assuming that you do not want to touch
EntityManager itself

>> I need to change the argument values of the methods

I think you need around advice

On Nov 29, 2007 10:49 AM, Meir Yanovich <meiry@xxxxxxxxxxxx> wrote:
> hi and thanks for the fast replay
>
> I simple want to capture every instance in my code that that
> Looks like for example  :
> q = entityManager.createNamedQuery(Query);
> q = entityManager.createNativeQuery(Query,Class);
> q = entityManager.find(vo);
>
> I need to change the argument values of the methods
>
> But im getting warning that says:
> no match for this type name: EntityManager
> [Xlint:invalidAbsoluteTypeName]-advice defined in
> com.infrastructure.security.AspectSecurity has not
>          been applied [Xlint:adviceDidNotMatch]
>
>
> -----Original Message-----
> From: aspectj-users-bounces@xxxxxxxxxxx
> [mailto:aspectj-users-bounces@xxxxxxxxxxx] On Behalf Of Paulo
Alexandre
> Corigo Zenida
> Sent: Thursday, November 29, 2007 5:25 PM
> To: aspectj-users@xxxxxxxxxxx
> Subject: Re: [aspectj-users] How can I intercept every callto
> EntityManager.<somemethod>(arg)
>
> Hello,
>
> I don't know if I understood what you meant but.. does the following
> help you?
>
> before() :
> execution(* EntityManager.*(..)) {
> // ...
> }
>
> Regards,
>
> Paulo Zenida
>
>
>
>
> Meir Yanovich wrote:
> > Hello all
> > Im trying hard to find pattern to intercept every instance in my
code
> > Inside methods that is looks like this:
> >
> > EntityManager.<some_kind_of_method>(arg(
> >
> > I need to change the arg in this method and insert new one based on
> some
> > checks
> >
> > Thanks allot
> > _______________________________________________
> > aspectj-users mailing list
> > aspectj-users@xxxxxxxxxxx
> > https://dev.eclipse.org/mailman/listinfo/aspectj-users
> >
>
> *** eSafe scanned this email for malicious content ***
> *** IMPORTANT: Do not open attachments from unrecognized senders  ***
>
> _______________________________________________
> aspectj-users mailing list
> aspectj-users@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/aspectj-users
>
_______________________________________________
aspectj-users mailing list
aspectj-users@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/aspectj-users


Back to the top