"mounou" wrote : Hi everyone, 
  | I've problems using metadata on Jboss AOP!
  | Here is my example:
  | 
  | The main class:
  | 
  | 
  | package jboss.aop2;
  | 
  | public class CompteBancaire {
  | 
  |     private double tauxInteret =0;
  |     private double solde = 0;
  |     public CompteBancaire( double tauxInteret, double solde, String client 
){
  |             this.tauxInteret = tauxInteret;
  |             this.solde = solde;
  |             System.out.println("");
  |     }
  |     
  |     /*
  |      * @@aTracer 
  |      */
  |      
  |      
  |     public void crediter( double montant ){
  |     this.solde += montant;
  |     System.out.println("methode crediter");
  |     }
  | 
  |     
  | 
  |     public void debiter( double montant ) throws Exception{
  |             if (montant > this.solde){
  |                     throw new Exception();
  |             }
  |             this.solde -= montant;
  |             System.out.println("methode debiter");
  |     }
  |     
  |     /*
  |      *@@aTracer
  |      */
  |      
  |     public void mettreAJourSolde(){
  |             this.solde *= 1.0 + this.tauxInteret / 100.0;
  |     System.out.println("methode mettreAJour");
  |     }
  |     
  |     
  |     public static void main( String[] args ) throws Exception {
  |             CompteBancaire c1 = new CompteBancaire( 2.5, 100000.0, "Mouna " 
);
  |             CompteBancaire c2 = new CompteBancaire( 3.25, 200000.0, "Kouka" 
);
  |             c1.crediter(100);
  |             c2.debiter(500);
  |             c1.mettreAJourSolde();
  |             new Calendrier(c1).getDate();
  |     }
  | 
  | }
  | 
  | the two methods I want to trace are mettreAJour() and crediter().
  | My jboss-aop.xml looks like:
  | 
  | <?xml version="1.0" encoding="UTF-8" standalone="yes" ?> 
  | 
  |  
  |    
  |  
  |  
  |    
  |  
  | 
  | 
  | and the ant build file: (I wonder if I'm obliged to use a build.xml file or 
not!!)
  | 
  | <?xml version="1.0" encoding="UTF-8"?>
  | 
  |     
  |             
  |                     
  |             
  |             
  |                     
  |             
  |             
  |                     
  |             
  |             
  |                     
  |             
  |             
  |                     
  |             
  |             
  |                     
  |             
  |             
  |                     
  |                     
  |                     
  |                     
  |                     
  |                     
  |             
  |             
  |     
  | 
  |     
  |             
  |             
  |          
  |     
  | 
  | 
  | 
  | 
  | 
  | 
  | I have this error when running my programm:
  | [annotationc] Working directory ignored when same JVM is used
  | Notice that I have no space or "_" in my work directory 
  | 
  | Any suggestion please? Is my build.xml correct?
  | thanks in advance
  | Mouna

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3931895#3931895

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3931895


-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
_______________________________________________
JBoss-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to