KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > jboss > ejb3 > dd > EjbRelation


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.ejb3.dd;
8
9 import java.util.ArrayList JavaDoc;
10 import java.util.List JavaDoc;
11
12 /**
13  * Represents an ejb-relation element of the ejb-jar.xml deployment descriptor
14  * for the 1.4 schema
15  *
16  * @version <tt>$Revision: 1.3.2.1 $</tt>
17  * @author <a HREF="mailto:bdecoste@jboss.com">William DeCoste</a>
18  */

19 public class EjbRelation
20 {
21
22    private String JavaDoc ejbRelationName = null;
23
24    private List JavaDoc ejbRelationshipRoles = new ArrayList JavaDoc();
25
26    public String JavaDoc getEjbRelationName()
27    {
28       return ejbRelationName;
29    }
30
31    public void setEjbRelationName(String JavaDoc ejbRelationName)
32    {
33       this.ejbRelationName = ejbRelationName;
34    }
35
36    public List JavaDoc getEjbRelationshipRoles()
37    {
38       return ejbRelationshipRoles;
39    }
40
41    public void setEjbRelationshipRoles(List JavaDoc ejbRelationshipRoles)
42    {
43       this.ejbRelationshipRoles = ejbRelationshipRoles;
44    }
45
46    public void addEjbRelationshipRole(EjbRelationshipRole role)
47    {
48       ejbRelationshipRoles.add(role);
49    }
50
51    public String JavaDoc toString()
52    {
53       StringBuffer JavaDoc sb = new StringBuffer JavaDoc(100);
54       sb.append("[");
55       sb.append("ejbRelationName=").append(ejbRelationName);
56       sb.append("]");
57       return sb.toString();
58    }
59 }
60
Popular Tags