KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > jboss > tutorial > injection > bean > CalculatorBean


1 /*
2  * JBoss, the OpenSource J2EE webOS
3  *
4  * Distributable under LGPL license.
5  * See terms of license at gnu.org.
6  */

7 package org.jboss.tutorial.injection.bean;
8
9 import javax.ejb.Stateless JavaDoc;
10
11 @Stateless JavaDoc
12 public class CalculatorBean implements Calculator
13 {
14    public int add(int x, int y)
15    {
16       return x + y;
17    }
18
19    public int subtract(int x, int y)
20    {
21       return x - y;
22    }
23 }
24
Popular Tags