You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tomee.apache.org by an...@apache.org on 2014/07/15 23:55:19 UTC
svn commit: r1610862 [12/44] - in /tomee/tomee/trunk/itests: ./ failover-ejb/
failover-ejb/src/main/java/org/apache/openejb/itest/failover/ejb/ failover/
failover/src/main/java/org/apache/openejb/itest/failover/
failover/src/main/java/org/apache/openej...
Modified: tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/singleton/EncSingletonObject.java
URL: http://svn.apache.org/viewvc/tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/singleton/EncSingletonObject.java?rev=1610862&r1=1610861&r2=1610862&view=diff
==============================================================================
--- tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/singleton/EncSingletonObject.java (original)
+++ tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/singleton/EncSingletonObject.java Tue Jul 15 21:55:09 2014
@@ -20,32 +20,52 @@ import java.rmi.RemoteException;
import org.apache.openejb.test.TestFailureException;
-public interface EncSingletonObject extends javax.ejb.EJBObject{
+public interface EncSingletonObject extends javax.ejb.EJBObject {
+
+ public void lookupEntityBean() throws TestFailureException, RemoteException;
+
+ public void lookupStatefulBean() throws TestFailureException, RemoteException;
- public void lookupEntityBean() throws TestFailureException, RemoteException;
- public void lookupStatefulBean() throws TestFailureException, RemoteException;
public void lookupSingletonBean() throws TestFailureException, RemoteException;
public void lookupSingletonBusinessLocal() throws TestFailureException, RemoteException;
+
public void lookupSingletonBusinessLocalBean() throws TestFailureException, RemoteException;
+
public void lookupSingletonBusinessRemote() throws TestFailureException, RemoteException;
+
public void lookupStatefulBusinessLocal() throws TestFailureException, RemoteException;
+
public void lookupStatefulBusinessRemote() throws TestFailureException, RemoteException;
+
public void lookupStatefulBusinessLocalBean() throws TestFailureException, RemoteException;
-
+
public void lookupResource() throws TestFailureException, RemoteException;
+
public void lookupJMSConnectionFactory() throws TestFailureException, RemoteException;
+
public void lookupPersistenceUnit() throws TestFailureException, RemoteException;
+
public void lookupPersistenceContext() throws TestFailureException, RemoteException;
+
public void lookupSessionContext() throws TestFailureException, RemoteException;
- public void lookupStringEntry() throws TestFailureException, RemoteException;
- public void lookupDoubleEntry() throws TestFailureException, RemoteException;
- public void lookupLongEntry() throws TestFailureException, RemoteException;
- public void lookupFloatEntry() throws TestFailureException, RemoteException;
+
+ public void lookupStringEntry() throws TestFailureException, RemoteException;
+
+ public void lookupDoubleEntry() throws TestFailureException, RemoteException;
+
+ public void lookupLongEntry() throws TestFailureException, RemoteException;
+
+ public void lookupFloatEntry() throws TestFailureException, RemoteException;
+
public void lookupIntegerEntry() throws TestFailureException, RemoteException;
- public void lookupShortEntry() throws TestFailureException, RemoteException;
+
+ public void lookupShortEntry() throws TestFailureException, RemoteException;
+
public void lookupBooleanEntry() throws TestFailureException, RemoteException;
- public void lookupByteEntry() throws TestFailureException, RemoteException;
- public void lookupCharacterEntry() throws TestFailureException, RemoteException;
+
+ public void lookupByteEntry() throws TestFailureException, RemoteException;
+
+ public void lookupCharacterEntry() throws TestFailureException, RemoteException;
}
Modified: tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/singleton/FieldInjectionSingletonBean.java
URL: http://svn.apache.org/viewvc/tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/singleton/FieldInjectionSingletonBean.java?rev=1610862&r1=1610861&r2=1610862&view=diff
==============================================================================
--- tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/singleton/FieldInjectionSingletonBean.java (original)
+++ tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/singleton/FieldInjectionSingletonBean.java Tue Jul 15 21:55:09 2014
@@ -78,7 +78,7 @@ public class FieldInjectionSingletonBean
public void lookupEntityBean() throws TestFailureException {
try {
Assert.assertNotNull("The EJBObject is null", bmpHome);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
@@ -86,7 +86,7 @@ public class FieldInjectionSingletonBean
public void lookupStatefulBean() throws TestFailureException {
try {
Assert.assertNotNull("The EJBObject is null", statefulHome);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
@@ -94,155 +94,155 @@ public class FieldInjectionSingletonBean
public void lookupSingletonBean() throws TestFailureException {
try {
Assert.assertNotNull("The EJBObject is null", singletonHome);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
- public void lookupSingletonBusinessLocal() throws TestFailureException{
- try{
- Assert.assertNotNull("The EJB BusinessLocal is null", singletonBusinessLocal );
- } catch (AssertionFailedError afe){
+ public void lookupSingletonBusinessLocal() throws TestFailureException {
+ try {
+ Assert.assertNotNull("The EJB BusinessLocal is null", singletonBusinessLocal);
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
- public void lookupSingletonBusinessLocalBean() throws TestFailureException{
- try{
- Assert.assertNotNull("The EJB BusinessLocalBean is null", singletonBusinessLocalBean );
- } catch (AssertionFailedError afe){
+ public void lookupSingletonBusinessLocalBean() throws TestFailureException {
+ try {
+ Assert.assertNotNull("The EJB BusinessLocalBean is null", singletonBusinessLocalBean);
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
- public void lookupSingletonBusinessRemote() throws TestFailureException{
- try{
- Assert.assertNotNull("The EJB BusinessRemote is null", singletonBusinessRemote );
- } catch (AssertionFailedError afe){
+ public void lookupSingletonBusinessRemote() throws TestFailureException {
+ try {
+ Assert.assertNotNull("The EJB BusinessRemote is null", singletonBusinessRemote);
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
- public void lookupStatefulBusinessLocal() throws TestFailureException{
- try{
- Assert.assertNotNull("The EJB BusinessLocal is null", statefulBusinessLocal );
- } catch (AssertionFailedError afe){
+ public void lookupStatefulBusinessLocal() throws TestFailureException {
+ try {
+ Assert.assertNotNull("The EJB BusinessLocal is null", statefulBusinessLocal);
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
- public void lookupStatefulBusinessLocalBean() throws TestFailureException{
- try{
- Assert.assertNotNull("The EJB BusinessLocalBean is null", statefulBusinessLocalBean );
- } catch (AssertionFailedError afe){
+ public void lookupStatefulBusinessLocalBean() throws TestFailureException {
+ try {
+ Assert.assertNotNull("The EJB BusinessLocalBean is null", statefulBusinessLocalBean);
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
- public void lookupStatefulBusinessRemote() throws TestFailureException{
- try{
- Assert.assertNotNull("The EJB BusinessRemote is null", statefulBusinessRemote );
- } catch (AssertionFailedError afe){
+ public void lookupStatefulBusinessRemote() throws TestFailureException {
+ try {
+ Assert.assertNotNull("The EJB BusinessRemote is null", statefulBusinessRemote);
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
-
+
public void lookupStringEntry() throws TestFailureException {
try {
- String expected = new String("1");
+ final String expected = new String("1");
Assert.assertNotNull("The String looked up is null", striing);
Assert.assertEquals(expected, striing);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
public void lookupDoubleEntry() throws TestFailureException {
try {
- Double expected = new Double(1.0D);
+ final Double expected = new Double(1.0D);
Assert.assertNotNull("The Double looked up is null", doouble);
Assert.assertEquals(expected, doouble);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
public void lookupLongEntry() throws TestFailureException {
try {
- Long expected = new Long(1L);
+ final Long expected = new Long(1L);
Assert.assertNotNull("The Long looked up is null", loong);
Assert.assertEquals(expected, loong);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
public void lookupFloatEntry() throws TestFailureException {
try {
- Float expected = new Float(1.0F);
+ final Float expected = new Float(1.0F);
Assert.assertNotNull("The Float looked up is null", flooat);
Assert.assertEquals(expected, flooat);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
public void lookupIntegerEntry() throws TestFailureException {
try {
- Integer expected = new Integer(1);
+ final Integer expected = new Integer(1);
Assert.assertNotNull("The Integer looked up is null", inteeger);
Assert.assertEquals(expected, inteeger);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
public void lookupShortEntry() throws TestFailureException {
try {
- Short expected = new Short((short) 1);
+ final Short expected = new Short((short) 1);
Assert.assertNotNull("The Short looked up is null", shoort);
Assert.assertEquals(expected, shoort);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
public void lookupBooleanEntry() throws TestFailureException {
try {
- Boolean expected = new Boolean(true);
+ final Boolean expected = new Boolean(true);
Assert.assertNotNull("The Boolean looked up is null", booolean);
Assert.assertEquals(expected, booolean);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
public void lookupByteEntry() throws TestFailureException {
try {
- Byte expected = new Byte((byte) 1);
+ final Byte expected = new Byte((byte) 1);
Assert.assertNotNull("The Byte looked up is null", byyte);
Assert.assertEquals(expected, byyte);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
public void lookupCharacterEntry() throws TestFailureException {
try {
- Character expected = new Character('D');
+ final Character expected = new Character('D');
Assert.assertNotNull("The Character looked up is null", chaaracter);
Assert.assertEquals(expected, chaaracter);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
@@ -250,30 +250,30 @@ public class FieldInjectionSingletonBean
public void lookupResource() throws TestFailureException {
try {
Assert.assertNotNull("The DataSource is null", daataSource);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
- public void lookupJMSConnectionFactory() throws TestFailureException{
- try{
- try{
+ public void lookupJMSConnectionFactory() throws TestFailureException {
+ try {
+ try {
testJmsConnection(coonnectionFactory.createConnection());
testJmsConnection(queueCoonnectionFactory.createConnection());
testJmsConnection(topicCoonnectionFactory.createConnection());
- } catch (Exception e){
+ } catch (final Exception e) {
e.printStackTrace();
- Assert.fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
+ Assert.fail("Received Exception " + e.getClass() + " : " + e.getMessage());
}
- } catch (AssertionFailedError afe){
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
- private void testJmsConnection(javax.jms.Connection connection) throws JMSException {
- Session session = connection.createSession(false, Session.DUPS_OK_ACKNOWLEDGE);
- Topic topic = session.createTopic("test");
- MessageProducer producer = session.createProducer(topic);
+ private void testJmsConnection(final javax.jms.Connection connection) throws JMSException {
+ final Session session = connection.createSession(false, Session.DUPS_OK_ACKNOWLEDGE);
+ final Topic topic = session.createTopic("test");
+ final MessageProducer producer = session.createProducer(topic);
producer.send(session.createMessage());
producer.close();
session.close();
@@ -283,7 +283,7 @@ public class FieldInjectionSingletonBean
public void lookupPersistenceUnit() throws TestFailureException {
try {
Assert.assertNotNull("The EntityManagerFactory is null", emf);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
@@ -295,10 +295,10 @@ public class FieldInjectionSingletonBean
try {
// call a do nothing method to assure entity manager actually exists
em.getFlushMode();
- } catch (Exception e) {
+ } catch (final Exception e) {
Assert.fail("Received Exception " + e.getClass() + " : " + e.getMessage());
}
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
@@ -307,7 +307,7 @@ public class FieldInjectionSingletonBean
try {
// TODO: DMB: Can't seem to find where to make this work
// Assert.assertNotNull("The SessionContext is null", ejbContext);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
@@ -322,10 +322,10 @@ public class FieldInjectionSingletonBean
public void ejbRemove() throws EJBException, RemoteException {
}
- public void setSessionContext(SessionContext sessionContext) throws EJBException, RemoteException {
+ public void setSessionContext(final SessionContext sessionContext) throws EJBException, RemoteException {
}
-
- public String remove(String arg) {
+
+ public String remove(final String arg) {
return arg;
}
}
Modified: tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/singleton/RmiIiopSingletonBean.java
URL: http://svn.apache.org/viewvc/tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/singleton/RmiIiopSingletonBean.java?rev=1610862&r1=1610861&r2=1610862&view=diff
==============================================================================
--- tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/singleton/RmiIiopSingletonBean.java (original)
+++ tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/singleton/RmiIiopSingletonBean.java Tue Jul 15 21:55:09 2014
@@ -28,19 +28,19 @@ import javax.naming.InitialContext;
import org.apache.openejb.test.object.ObjectGraph;
-public class RmiIiopSingletonBean implements javax.ejb.SessionBean{
-
+public class RmiIiopSingletonBean implements javax.ejb.SessionBean {
+
private String name;
private SessionContext ejbContext;
-
-
+
+
//=============================
// Home interface methods
//
//
// Home interface methods
//=============================
-
+
//=============================
// Remote interface methods
@@ -48,172 +48,172 @@ public class RmiIiopSingletonBean implem
/*-------------------------------------------------*/
/* String */
/*-------------------------------------------------*/
-
- public String returnStringObject(String data) {
+
+ public String returnStringObject(final String data) {
return data;
}
-
- public String[] returnStringObjectArray(String[] data) {
+
+ public String[] returnStringObjectArray(final String[] data) {
return data;
}
/*-------------------------------------------------*/
/* Character */
/*-------------------------------------------------*/
-
- public Character returnCharacterObject(Character data) {
+
+ public Character returnCharacterObject(final Character data) {
return data;
}
-
- public char returnCharacterPrimitive(char data) {
+
+ public char returnCharacterPrimitive(final char data) {
return data;
}
-
- public Character[] returnCharacterObjectArray(Character[] data) {
+
+ public Character[] returnCharacterObjectArray(final Character[] data) {
return data;
}
-
- public char[] returnCharacterPrimitiveArray(char[] data) {
+
+ public char[] returnCharacterPrimitiveArray(final char[] data) {
return data;
}
/*-------------------------------------------------*/
/* Boolean */
/*-------------------------------------------------*/
-
- public Boolean returnBooleanObject(Boolean data) {
+
+ public Boolean returnBooleanObject(final Boolean data) {
return data;
}
-
- public boolean returnBooleanPrimitive(boolean data) {
+
+ public boolean returnBooleanPrimitive(final boolean data) {
return data;
}
-
- public Boolean[] returnBooleanObjectArray(Boolean[] data) {
+
+ public Boolean[] returnBooleanObjectArray(final Boolean[] data) {
return data;
}
-
- public boolean[] returnBooleanPrimitiveArray(boolean[] data) {
+
+ public boolean[] returnBooleanPrimitiveArray(final boolean[] data) {
return data;
}
/*-------------------------------------------------*/
/* Byte */
/*-------------------------------------------------*/
-
- public Byte returnByteObject(Byte data) {
+
+ public Byte returnByteObject(final Byte data) {
return data;
}
-
- public byte returnBytePrimitive(byte data) {
+
+ public byte returnBytePrimitive(final byte data) {
return data;
}
-
- public Byte[] returnByteObjectArray(Byte[] data) {
+
+ public Byte[] returnByteObjectArray(final Byte[] data) {
return data;
}
-
- public byte[] returnBytePrimitiveArray(byte[] data) {
+
+ public byte[] returnBytePrimitiveArray(final byte[] data) {
return data;
}
/*-------------------------------------------------*/
/* Short */
/*-------------------------------------------------*/
-
- public Short returnShortObject(Short data) {
+
+ public Short returnShortObject(final Short data) {
return data;
}
-
- public short returnShortPrimitive(short data) {
+
+ public short returnShortPrimitive(final short data) {
return data;
}
-
- public Short[] returnShortObjectArray(Short[] data) {
+
+ public Short[] returnShortObjectArray(final Short[] data) {
return data;
}
-
- public short[] returnShortPrimitiveArray(short[] data) {
+
+ public short[] returnShortPrimitiveArray(final short[] data) {
return data;
}
/*-------------------------------------------------*/
/* Integer */
/*-------------------------------------------------*/
-
- public Integer returnIntegerObject(Integer data) {
+
+ public Integer returnIntegerObject(final Integer data) {
return data;
}
-
- public int returnIntegerPrimitive(int data) {
+
+ public int returnIntegerPrimitive(final int data) {
return data;
}
-
- public Integer[] returnIntegerObjectArray(Integer[] data) {
+
+ public Integer[] returnIntegerObjectArray(final Integer[] data) {
return data;
}
-
- public int[] returnIntegerPrimitiveArray(int[] data) {
+
+ public int[] returnIntegerPrimitiveArray(final int[] data) {
return data;
}
/*-------------------------------------------------*/
/* Long */
/*-------------------------------------------------*/
-
- public Long returnLongObject(Long data) {
+
+ public Long returnLongObject(final Long data) {
return data;
}
-
- public long returnLongPrimitive(long data) {
+
+ public long returnLongPrimitive(final long data) {
return data;
}
-
- public Long[] returnLongObjectArray(Long[] data) {
+
+ public Long[] returnLongObjectArray(final Long[] data) {
return data;
}
-
- public long[] returnLongPrimitiveArray(long[] data) {
+
+ public long[] returnLongPrimitiveArray(final long[] data) {
return data;
}
/*-------------------------------------------------*/
/* Float */
/*-------------------------------------------------*/
-
- public Float returnFloatObject(Float data) {
+
+ public Float returnFloatObject(final Float data) {
return data;
}
-
- public float returnFloatPrimitive(float data) {
+
+ public float returnFloatPrimitive(final float data) {
return data;
}
-
- public Float[] returnFloatObjectArray(Float[] data) {
+
+ public Float[] returnFloatObjectArray(final Float[] data) {
return data;
}
-
- public float[] returnFloatPrimitiveArray(float[] data) {
+
+ public float[] returnFloatPrimitiveArray(final float[] data) {
return data;
}
/*-------------------------------------------------*/
/* Double */
/*-------------------------------------------------*/
-
- public Double returnDoubleObject(Double data) {
+
+ public Double returnDoubleObject(final Double data) {
return data;
}
-
- public double returnDoublePrimitive(double data) {
+
+ public double returnDoublePrimitive(final double data) {
return data;
}
-
- public Double[] returnDoubleObjectArray(Double[] data) {
+
+ public Double[] returnDoubleObjectArray(final Double[] data) {
return data;
}
-
- public double[] returnDoublePrimitiveArray(double[] data) {
+
+ public double[] returnDoublePrimitiveArray(final double[] data) {
return data;
}
@@ -221,172 +221,172 @@ public class RmiIiopSingletonBean implem
/*-------------------------------------------------*/
/* EJBHome */
/*-------------------------------------------------*/
-
- public EJBHome returnEJBHome(EJBHome data) {
+
+ public EJBHome returnEJBHome(final EJBHome data) {
return data;
}
-
- public EJBHome returnEJBHome() throws javax.ejb.EJBException{
+
+ public EJBHome returnEJBHome() throws javax.ejb.EJBException {
EJBHome data = null;
- try{
- InitialContext ctx = new InitialContext();
+ try {
+ final InitialContext ctx = new InitialContext();
- data = (EJBHome)ctx.lookup("java:comp/env/singleton/rmi-iiop/home");
+ data = (EJBHome) ctx.lookup("java:comp/env/singleton/rmi-iiop/home");
- } catch (Exception e){
+ } catch (final Exception e) {
e.printStackTrace();
throw new javax.ejb.EJBException(e);
}
return data;
}
- public ObjectGraph returnNestedEJBHome() throws javax.ejb.EJBException{
- ObjectGraph data = null;
+ public ObjectGraph returnNestedEJBHome() throws javax.ejb.EJBException {
+ ObjectGraph data = null;
- try{
- InitialContext ctx = new InitialContext();
+ try {
+ final InitialContext ctx = new InitialContext();
- Object object = ctx.lookup("java:comp/env/singleton/rmi-iiop/home");
- data = new ObjectGraph(object);
+ final Object object = ctx.lookup("java:comp/env/singleton/rmi-iiop/home");
+ data = new ObjectGraph(object);
- } catch (Exception e){
+ } catch (final Exception e) {
throw new javax.ejb.EJBException(e);
}
return data;
}
- public EJBHome[] returnEJBHomeArray(EJBHome[] data) {
+ public EJBHome[] returnEJBHomeArray(final EJBHome[] data) {
return data;
}
/*-------------------------------------------------*/
/* EJBObject */
/*-------------------------------------------------*/
-
- public EJBObject returnEJBObject(EJBObject data) {
+
+ public EJBObject returnEJBObject(final EJBObject data) {
return data;
}
-
- public EJBObject returnEJBObject() throws javax.ejb.EJBException{
+
+ public EJBObject returnEJBObject() throws javax.ejb.EJBException {
EncSingletonObject data = null;
- try{
- InitialContext ctx = new InitialContext();
+ try {
+ final InitialContext ctx = new InitialContext();
- EncSingletonHome home = (EncSingletonHome)ctx.lookup("java:comp/env/singleton/rmi-iiop/home");
- data = home.create();
+ final EncSingletonHome home = (EncSingletonHome) ctx.lookup("java:comp/env/singleton/rmi-iiop/home");
+ data = home.create();
- } catch (Exception e){
+ } catch (final Exception e) {
throw new javax.ejb.EJBException(e);
}
return data;
}
-
- public ObjectGraph returnNestedEJBObject() throws javax.ejb.EJBException{
+
+ public ObjectGraph returnNestedEJBObject() throws javax.ejb.EJBException {
ObjectGraph data = null;
- try{
- InitialContext ctx = new InitialContext();
+ try {
+ final InitialContext ctx = new InitialContext();
- EncSingletonHome home = (EncSingletonHome)ctx.lookup("java:comp/env/singleton/rmi-iiop/home");
- EncSingletonObject object = home.create();
- data = new ObjectGraph(object);
+ final EncSingletonHome home = (EncSingletonHome) ctx.lookup("java:comp/env/singleton/rmi-iiop/home");
+ final EncSingletonObject object = home.create();
+ data = new ObjectGraph(object);
- } catch (Exception e){
+ } catch (final Exception e) {
throw new javax.ejb.EJBException(e);
}
return data;
}
-
- public EJBObject[] returnEJBObjectArray(EJBObject[] data) {
+
+ public EJBObject[] returnEJBObjectArray(final EJBObject[] data) {
return data;
}
/*-------------------------------------------------*/
/* EJBMetaData */
/*-------------------------------------------------*/
-
- public EJBMetaData returnEJBMetaData(EJBMetaData data) {
+
+ public EJBMetaData returnEJBMetaData(final EJBMetaData data) {
return data;
}
-
- public EJBMetaData returnEJBMetaData() throws javax.ejb.EJBException{
+
+ public EJBMetaData returnEJBMetaData() throws javax.ejb.EJBException {
EJBMetaData data = null;
- try{
- InitialContext ctx = new InitialContext();
+ try {
+ final InitialContext ctx = new InitialContext();
- EncSingletonHome home = (EncSingletonHome)ctx.lookup("java:comp/env/singleton/rmi-iiop/home");
- data = home.getEJBMetaData();
+ final EncSingletonHome home = (EncSingletonHome) ctx.lookup("java:comp/env/singleton/rmi-iiop/home");
+ data = home.getEJBMetaData();
- } catch (Exception e){
+ } catch (final Exception e) {
throw new javax.ejb.EJBException(e);
}
return data;
}
-
- public ObjectGraph returnNestedEJBMetaData() throws javax.ejb.EJBException{
+
+ public ObjectGraph returnNestedEJBMetaData() throws javax.ejb.EJBException {
ObjectGraph data = null;
- try{
- InitialContext ctx = new InitialContext();
+ try {
+ final InitialContext ctx = new InitialContext();
- EncSingletonHome home = (EncSingletonHome)ctx.lookup("java:comp/env/singleton/rmi-iiop/home");
- EJBMetaData object = home.getEJBMetaData();
- data = new ObjectGraph(object);
+ final EncSingletonHome home = (EncSingletonHome) ctx.lookup("java:comp/env/singleton/rmi-iiop/home");
+ final EJBMetaData object = home.getEJBMetaData();
+ data = new ObjectGraph(object);
- } catch (Exception e){
+ } catch (final Exception e) {
throw new javax.ejb.EJBException(e);
}
return data;
}
-
- public EJBMetaData[] returnEJBMetaDataArray(EJBMetaData[] data) {
+
+ public EJBMetaData[] returnEJBMetaDataArray(final EJBMetaData[] data) {
return data;
}
/*-------------------------------------------------*/
/* Handle */
/*-------------------------------------------------*/
-
- public Handle returnHandle(Handle data) {
+
+ public Handle returnHandle(final Handle data) {
return data;
}
-
- public Handle returnHandle() throws javax.ejb.EJBException{
+
+ public Handle returnHandle() throws javax.ejb.EJBException {
Handle data = null;
- try{
- InitialContext ctx = new InitialContext();
+ try {
+ final InitialContext ctx = new InitialContext();
- EncSingletonHome home = (EncSingletonHome)ctx.lookup("java:comp/env/singleton/rmi-iiop/home");
- EncSingletonObject object = home.create();
- data = object.getHandle();
+ final EncSingletonHome home = (EncSingletonHome) ctx.lookup("java:comp/env/singleton/rmi-iiop/home");
+ final EncSingletonObject object = home.create();
+ data = object.getHandle();
- } catch (Exception e){
+ } catch (final Exception e) {
throw new javax.ejb.EJBException(e);
}
return data;
}
-
- public ObjectGraph returnNestedHandle() throws javax.ejb.EJBException{
+
+ public ObjectGraph returnNestedHandle() throws javax.ejb.EJBException {
ObjectGraph data = null;
- try{
- InitialContext ctx = new InitialContext();
+ try {
+ final InitialContext ctx = new InitialContext();
- EncSingletonHome home = (EncSingletonHome)ctx.lookup("java:comp/env/singleton/rmi-iiop/home");
- EncSingletonObject object = home.create();
- data = new ObjectGraph(object.getHandle());
+ final EncSingletonHome home = (EncSingletonHome) ctx.lookup("java:comp/env/singleton/rmi-iiop/home");
+ final EncSingletonObject object = home.create();
+ data = new ObjectGraph(object.getHandle());
- } catch (Exception e){
+ } catch (final Exception e) {
throw new javax.ejb.EJBException(e);
}
return data;
}
-
- public Handle[] returnHandleArray(Handle[] data) {
+
+ public Handle[] returnHandleArray(final Handle[] data) {
return data;
}
@@ -395,30 +395,30 @@ public class RmiIiopSingletonBean implem
/* Class */
/*-------------------------------------------------*/
- public Class returnClass(Class data) {
+ public Class returnClass(final Class data) {
return data;
}
- public Class[] returnClassArray(Class[] data) {
+ public Class[] returnClassArray(final Class[] data) {
return data;
}
/*-------------------------------------------------*/
/* ObjectGraph */
/*-------------------------------------------------*/
-
- public ObjectGraph returnObjectGraph(ObjectGraph data) {
+
+ public ObjectGraph returnObjectGraph(final ObjectGraph data) {
return data;
}
-
- public ObjectGraph[] returnObjectGraphArray(ObjectGraph[] data) {
+
+ public ObjectGraph[] returnObjectGraphArray(final ObjectGraph[] data) {
return data;
}
-
- public String remove(String arg) {
+
+ public String remove(final String arg) {
return arg;
}
-
+
//
// Remote interface methods
//=============================
@@ -427,27 +427,29 @@ public class RmiIiopSingletonBean implem
//================================
// SessionBean interface methods
//
+
/**
* Set the associated session context. The container calls this method
* after the instance creation.
*/
- public void setSessionContext(SessionContext ctx) throws EJBException,RemoteException {
+ public void setSessionContext(final SessionContext ctx) throws EJBException, RemoteException {
ejbContext = ctx;
}
+
/**
- *
- * @exception javax.ejb.CreateException
+ * @throws javax.ejb.CreateException
*/
- public void ejbCreate() throws javax.ejb.CreateException{
+ public void ejbCreate() throws javax.ejb.CreateException {
this.name = "nameless automaton";
}
+
/**
* A container invokes this method before it ends the life of the session
* object. This happens as a result of a client's invoking a remove
* operation, or when a container decides to terminate the session object
* after a timeout.
*/
- public void ejbRemove() throws EJBException,RemoteException {
+ public void ejbRemove() throws EJBException, RemoteException {
}
/**
@@ -455,15 +457,16 @@ public class RmiIiopSingletonBean implem
* from its "passive" state. The instance should acquire any resource
* that it has released earlier in the ejbPassivate() method.
*/
- public void ejbActivate() throws EJBException,RemoteException {
+ public void ejbActivate() throws EJBException, RemoteException {
// Should never called.
}
+
/**
* The passivate method is called before the instance enters
* the "passive" state. The instance should release any resources that
* it can re-acquire later in the ejbActivate() method.
*/
- public void ejbPassivate() throws EJBException,RemoteException {
+ public void ejbPassivate() throws EJBException, RemoteException {
// Should never called.
}
Modified: tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/singleton/RmiIiopSingletonHome.java
URL: http://svn.apache.org/viewvc/tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/singleton/RmiIiopSingletonHome.java?rev=1610862&r1=1610861&r2=1610862&view=diff
==============================================================================
--- tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/singleton/RmiIiopSingletonHome.java (original)
+++ tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/singleton/RmiIiopSingletonHome.java Tue Jul 15 21:55:09 2014
@@ -20,5 +20,5 @@ package org.apache.openejb.test.singleto
public interface RmiIiopSingletonHome extends javax.ejb.EJBHome {
public RmiIiopSingletonObject create()
- throws javax.ejb.CreateException, java.rmi.RemoteException;
+ throws javax.ejb.CreateException, java.rmi.RemoteException;
}
Modified: tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/singleton/RmiIiopSingletonObject.java
URL: http://svn.apache.org/viewvc/tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/singleton/RmiIiopSingletonObject.java?rev=1610862&r1=1610861&r2=1610862&view=diff
==============================================================================
--- tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/singleton/RmiIiopSingletonObject.java (original)
+++ tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/singleton/RmiIiopSingletonObject.java Tue Jul 15 21:55:09 2014
@@ -25,111 +25,111 @@ import javax.ejb.Handle;
import org.apache.openejb.test.object.ObjectGraph;
-public interface RmiIiopSingletonObject extends javax.ejb.EJBObject{
-
- public String returnStringObject(String data) throws RemoteException;
+public interface RmiIiopSingletonObject extends javax.ejb.EJBObject {
- public String[] returnStringObjectArray(String[] data) throws RemoteException;
+ public String returnStringObject(String data) throws RemoteException;
- public Character returnCharacterObject(Character data) throws RemoteException;
+ public String[] returnStringObjectArray(String[] data) throws RemoteException;
- public char returnCharacterPrimitive(char data) throws RemoteException;
+ public Character returnCharacterObject(Character data) throws RemoteException;
- public Character[] returnCharacterObjectArray(Character[] data) throws RemoteException;
+ public char returnCharacterPrimitive(char data) throws RemoteException;
- public char[] returnCharacterPrimitiveArray(char[] data) throws RemoteException;
+ public Character[] returnCharacterObjectArray(Character[] data) throws RemoteException;
- public Boolean returnBooleanObject(Boolean data) throws RemoteException;
+ public char[] returnCharacterPrimitiveArray(char[] data) throws RemoteException;
- public boolean returnBooleanPrimitive(boolean data) throws RemoteException;
+ public Boolean returnBooleanObject(Boolean data) throws RemoteException;
- public Boolean[] returnBooleanObjectArray(Boolean[] data) throws RemoteException;
+ public boolean returnBooleanPrimitive(boolean data) throws RemoteException;
- public boolean[] returnBooleanPrimitiveArray(boolean[] data) throws RemoteException;
+ public Boolean[] returnBooleanObjectArray(Boolean[] data) throws RemoteException;
- public Byte returnByteObject(Byte data) throws RemoteException;
+ public boolean[] returnBooleanPrimitiveArray(boolean[] data) throws RemoteException;
- public byte returnBytePrimitive(byte data) throws RemoteException;
+ public Byte returnByteObject(Byte data) throws RemoteException;
- public Byte[] returnByteObjectArray(Byte[] data) throws RemoteException;
+ public byte returnBytePrimitive(byte data) throws RemoteException;
- public byte[] returnBytePrimitiveArray(byte[] data) throws RemoteException;
+ public Byte[] returnByteObjectArray(Byte[] data) throws RemoteException;
- public Short returnShortObject(Short data) throws RemoteException;
+ public byte[] returnBytePrimitiveArray(byte[] data) throws RemoteException;
- public short returnShortPrimitive(short data) throws RemoteException;
+ public Short returnShortObject(Short data) throws RemoteException;
- public Short[] returnShortObjectArray(Short[] data) throws RemoteException;
+ public short returnShortPrimitive(short data) throws RemoteException;
- public short[] returnShortPrimitiveArray(short[] data) throws RemoteException;
+ public Short[] returnShortObjectArray(Short[] data) throws RemoteException;
- public Integer returnIntegerObject(Integer data) throws RemoteException;
+ public short[] returnShortPrimitiveArray(short[] data) throws RemoteException;
- public int returnIntegerPrimitive(int data) throws RemoteException;
+ public Integer returnIntegerObject(Integer data) throws RemoteException;
- public Integer[] returnIntegerObjectArray(Integer[] data) throws RemoteException;
+ public int returnIntegerPrimitive(int data) throws RemoteException;
- public int[] returnIntegerPrimitiveArray(int[] data) throws RemoteException;
+ public Integer[] returnIntegerObjectArray(Integer[] data) throws RemoteException;
- public Long returnLongObject(Long data) throws RemoteException;
+ public int[] returnIntegerPrimitiveArray(int[] data) throws RemoteException;
- public long returnLongPrimitive(long data) throws RemoteException;
+ public Long returnLongObject(Long data) throws RemoteException;
- public Long[] returnLongObjectArray(Long[] data) throws RemoteException;
+ public long returnLongPrimitive(long data) throws RemoteException;
- public long[] returnLongPrimitiveArray(long[] data) throws RemoteException;
+ public Long[] returnLongObjectArray(Long[] data) throws RemoteException;
- public Float returnFloatObject(Float data) throws RemoteException;
+ public long[] returnLongPrimitiveArray(long[] data) throws RemoteException;
- public float returnFloatPrimitive(float data) throws RemoteException;
+ public Float returnFloatObject(Float data) throws RemoteException;
- public Float[] returnFloatObjectArray(Float[] data) throws RemoteException;
+ public float returnFloatPrimitive(float data) throws RemoteException;
- public float[] returnFloatPrimitiveArray(float[] data) throws RemoteException;
+ public Float[] returnFloatObjectArray(Float[] data) throws RemoteException;
- public Double returnDoubleObject(Double data) throws RemoteException;
+ public float[] returnFloatPrimitiveArray(float[] data) throws RemoteException;
- public double returnDoublePrimitive(double data) throws RemoteException;
+ public Double returnDoubleObject(Double data) throws RemoteException;
- public Double[] returnDoubleObjectArray(Double[] data) throws RemoteException;
+ public double returnDoublePrimitive(double data) throws RemoteException;
- public double[] returnDoublePrimitiveArray(double[] data) throws RemoteException;
+ public Double[] returnDoubleObjectArray(Double[] data) throws RemoteException;
+
+ public double[] returnDoublePrimitiveArray(double[] data) throws RemoteException;
public EJBHome returnEJBHome(EJBHome data) throws RemoteException;
- public EJBHome returnEJBHome() throws RemoteException;
+ public EJBHome returnEJBHome() throws RemoteException;
- public ObjectGraph returnNestedEJBHome() throws RemoteException;
+ public ObjectGraph returnNestedEJBHome() throws RemoteException;
- public EJBHome[] returnEJBHomeArray(EJBHome[] data) throws RemoteException;
+ public EJBHome[] returnEJBHomeArray(EJBHome[] data) throws RemoteException;
- public EJBObject returnEJBObject(EJBObject data) throws RemoteException;
+ public EJBObject returnEJBObject(EJBObject data) throws RemoteException;
- public EJBObject returnEJBObject() throws RemoteException;
+ public EJBObject returnEJBObject() throws RemoteException;
- public ObjectGraph returnNestedEJBObject() throws RemoteException;
+ public ObjectGraph returnNestedEJBObject() throws RemoteException;
- public EJBObject[] returnEJBObjectArray(EJBObject[] data) throws RemoteException;
+ public EJBObject[] returnEJBObjectArray(EJBObject[] data) throws RemoteException;
- public EJBMetaData returnEJBMetaData(EJBMetaData data) throws RemoteException;
+ public EJBMetaData returnEJBMetaData(EJBMetaData data) throws RemoteException;
- public EJBMetaData returnEJBMetaData() throws RemoteException;
+ public EJBMetaData returnEJBMetaData() throws RemoteException;
- public ObjectGraph returnNestedEJBMetaData() throws RemoteException;
+ public ObjectGraph returnNestedEJBMetaData() throws RemoteException;
- public EJBMetaData[] returnEJBMetaDataArray(EJBMetaData[] data) throws RemoteException;
+ public EJBMetaData[] returnEJBMetaDataArray(EJBMetaData[] data) throws RemoteException;
- public Handle returnHandle(Handle data) throws RemoteException;
+ public Handle returnHandle(Handle data) throws RemoteException;
- public Handle returnHandle() throws RemoteException;
+ public Handle returnHandle() throws RemoteException;
- public ObjectGraph returnNestedHandle() throws RemoteException;
+ public ObjectGraph returnNestedHandle() throws RemoteException;
- public Handle[] returnHandleArray(Handle[] data) throws RemoteException;
+ public Handle[] returnHandleArray(Handle[] data) throws RemoteException;
- public ObjectGraph returnObjectGraph(ObjectGraph data) throws RemoteException;
+ public ObjectGraph returnObjectGraph(ObjectGraph data) throws RemoteException;
- public ObjectGraph[] returnObjectGraphArray(ObjectGraph[] data) throws RemoteException;
+ public ObjectGraph[] returnObjectGraphArray(ObjectGraph[] data) throws RemoteException;
public Class returnClass(Class data) throws RemoteException;
Modified: tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/singleton/SetterInjectionSingletonBean.java
URL: http://svn.apache.org/viewvc/tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/singleton/SetterInjectionSingletonBean.java?rev=1610862&r1=1610861&r2=1610862&view=diff
==============================================================================
--- tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/singleton/SetterInjectionSingletonBean.java (original)
+++ tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/singleton/SetterInjectionSingletonBean.java Tue Jul 15 21:55:09 2014
@@ -77,7 +77,7 @@ public class SetterInjectionSingletonBea
return statefulBusinessLocalField;
}
- public void setStatefulBusinessLocal(BasicStatefulBusinessLocal statefulBusinessLocal) {
+ public void setStatefulBusinessLocal(final BasicStatefulBusinessLocal statefulBusinessLocal) {
this.statefulBusinessLocalField = statefulBusinessLocal;
}
@@ -85,7 +85,7 @@ public class SetterInjectionSingletonBea
return statefulBusinessLocalFieldBean;
}
- public void setStatefulBusinessLocalBean(BasicStatefulPojoBean statefulBusinessLocalBean) {
+ public void setStatefulBusinessLocalBean(final BasicStatefulPojoBean statefulBusinessLocalBean) {
this.statefulBusinessLocalFieldBean = statefulBusinessLocalBean;
}
@@ -93,7 +93,7 @@ public class SetterInjectionSingletonBea
return statefulBusinessRemoteField;
}
- public void setStatefulBusinessRemote(BasicStatefulBusinessRemote statefulBusinessRemote) {
+ public void setStatefulBusinessRemote(final BasicStatefulBusinessRemote statefulBusinessRemote) {
this.statefulBusinessRemoteField = statefulBusinessRemote;
}
@@ -101,7 +101,7 @@ public class SetterInjectionSingletonBea
return singletonBusinessLocalField;
}
- public void setSingletonBusinessLocal(BasicSingletonBusinessLocal singletonBusinessLocal) {
+ public void setSingletonBusinessLocal(final BasicSingletonBusinessLocal singletonBusinessLocal) {
this.singletonBusinessLocalField = singletonBusinessLocal;
}
@@ -109,7 +109,7 @@ public class SetterInjectionSingletonBea
return singletonBusinessLocalFieldBean;
}
- public void setSingletonBusinessLocalBean(BasicSingletonPojoBean singletonBusinessLocalBean) {
+ public void setSingletonBusinessLocalBean(final BasicSingletonPojoBean singletonBusinessLocalBean) {
this.singletonBusinessLocalFieldBean = singletonBusinessLocalBean;
}
@@ -117,7 +117,7 @@ public class SetterInjectionSingletonBea
return singletonBusinessRemoteField;
}
- public void setSingletonBusinessRemote(BasicSingletonBusinessRemote singletonBusinessRemote) {
+ public void setSingletonBusinessRemote(final BasicSingletonBusinessRemote singletonBusinessRemote) {
this.singletonBusinessRemoteField = singletonBusinessRemote;
}
@@ -125,7 +125,7 @@ public class SetterInjectionSingletonBea
return bmpHomeField;
}
- public void setBmpHome(BasicBmpHome bmpHome) {
+ public void setBmpHome(final BasicBmpHome bmpHome) {
this.bmpHomeField = bmpHome;
}
@@ -133,7 +133,7 @@ public class SetterInjectionSingletonBea
return boooleanField;
}
- public void setBooolean(Boolean booolean) {
+ public void setBooolean(final Boolean booolean) {
this.boooleanField = booolean;
}
@@ -141,7 +141,7 @@ public class SetterInjectionSingletonBea
return byyteField;
}
- public void setByyte(Byte byyte) {
+ public void setByyte(final Byte byyte) {
this.byyteField = byyte;
}
@@ -149,7 +149,7 @@ public class SetterInjectionSingletonBea
return chaaracterField;
}
- public void setChaaracter(Character chaaracter) {
+ public void setChaaracter(final Character chaaracter) {
this.chaaracterField = chaaracter;
}
@@ -157,7 +157,7 @@ public class SetterInjectionSingletonBea
return daataSourceField;
}
- public void setDaataSource(DataSource daataSource) {
+ public void setDaataSource(final DataSource daataSource) {
this.daataSourceField = daataSource;
}
@@ -165,7 +165,7 @@ public class SetterInjectionSingletonBea
return coonnectionFactory;
}
- public void setCoonnectionFactory(ConnectionFactory coonnectionFactory) {
+ public void setCoonnectionFactory(final ConnectionFactory coonnectionFactory) {
this.coonnectionFactory = coonnectionFactory;
}
@@ -173,7 +173,7 @@ public class SetterInjectionSingletonBea
return queueCoonnectionFactory;
}
- public void setQueueCoonnectionFactory(QueueConnectionFactory queueCoonnectionFactory) {
+ public void setQueueCoonnectionFactory(final QueueConnectionFactory queueCoonnectionFactory) {
this.queueCoonnectionFactory = queueCoonnectionFactory;
}
@@ -181,7 +181,7 @@ public class SetterInjectionSingletonBea
return topicCoonnectionFactory;
}
- public void setTopicCoonnectionFactory(TopicConnectionFactory topicCoonnectionFactory) {
+ public void setTopicCoonnectionFactory(final TopicConnectionFactory topicCoonnectionFactory) {
this.topicCoonnectionFactory = topicCoonnectionFactory;
}
@@ -189,7 +189,7 @@ public class SetterInjectionSingletonBea
return dooubleField;
}
- public void setDoouble(Double doouble) {
+ public void setDoouble(final Double doouble) {
this.dooubleField = doouble;
}
@@ -197,7 +197,7 @@ public class SetterInjectionSingletonBea
return eemField;
}
- public void setEem(EntityManager eem) {
+ public void setEem(final EntityManager eem) {
this.eemField = eem;
}
@@ -205,7 +205,7 @@ public class SetterInjectionSingletonBea
return ejbContextField;
}
- public void setEjbContext(SessionContext ejbContext) {
+ public void setEjbContext(final SessionContext ejbContext) {
this.ejbContextField = ejbContext;
}
@@ -213,7 +213,7 @@ public class SetterInjectionSingletonBea
return emField;
}
- public void setEm(EntityManager em) {
+ public void setEm(final EntityManager em) {
this.emField = em;
}
@@ -221,7 +221,7 @@ public class SetterInjectionSingletonBea
return emfField;
}
- public void setEmf(EntityManagerFactory emf) {
+ public void setEmf(final EntityManagerFactory emf) {
this.emfField = emf;
}
@@ -229,7 +229,7 @@ public class SetterInjectionSingletonBea
return flooatField;
}
- public void setFlooat(Float flooat) {
+ public void setFlooat(final Float flooat) {
this.flooatField = flooat;
}
@@ -237,7 +237,7 @@ public class SetterInjectionSingletonBea
return inteegerField;
}
- public void setInteeger(Integer inteeger) {
+ public void setInteeger(final Integer inteeger) {
this.inteegerField = inteeger;
}
@@ -245,7 +245,7 @@ public class SetterInjectionSingletonBea
return loongField;
}
- public void setLoong(Long loong) {
+ public void setLoong(final Long loong) {
this.loongField = loong;
}
@@ -253,7 +253,7 @@ public class SetterInjectionSingletonBea
return pemField;
}
- public void setPem(EntityManager pem) {
+ public void setPem(final EntityManager pem) {
this.pemField = pem;
}
@@ -261,7 +261,7 @@ public class SetterInjectionSingletonBea
return shoortField;
}
- public void setShoort(Short shoort) {
+ public void setShoort(final Short shoort) {
this.shoortField = shoort;
}
@@ -269,7 +269,7 @@ public class SetterInjectionSingletonBea
return statefulHomeField;
}
- public void setStatefulHome(BasicStatefulHome statefulHome) {
+ public void setStatefulHome(final BasicStatefulHome statefulHome) {
this.statefulHomeField = statefulHome;
}
@@ -277,7 +277,7 @@ public class SetterInjectionSingletonBea
return singletonHomeField;
}
- public void setSingletonHome(BasicSingletonHome singletonHome) {
+ public void setSingletonHome(final BasicSingletonHome singletonHome) {
this.singletonHomeField = singletonHome;
}
@@ -285,7 +285,7 @@ public class SetterInjectionSingletonBea
return striingField;
}
- public void setStriing(String striing) {
+ public void setStriing(final String striing) {
this.striingField = striing;
}
@@ -295,7 +295,7 @@ public class SetterInjectionSingletonBea
public void lookupEntityBean() throws TestFailureException {
try {
Assert.assertNotNull("The EJBObject is null", bmpHomeField);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
@@ -303,7 +303,7 @@ public class SetterInjectionSingletonBea
public void lookupStatefulBean() throws TestFailureException {
try {
Assert.assertNotNull("The EJBObject is null", statefulHomeField);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
@@ -311,55 +311,55 @@ public class SetterInjectionSingletonBea
public void lookupSingletonBean() throws TestFailureException {
try {
Assert.assertNotNull("The EJBObject is null", singletonHomeField);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
- public void lookupSingletonBusinessLocal() throws TestFailureException{
- try{
- Assert.assertNotNull("The EJB BusinessLocal is null", singletonBusinessLocalField );
- } catch (AssertionFailedError afe){
+ public void lookupSingletonBusinessLocal() throws TestFailureException {
+ try {
+ Assert.assertNotNull("The EJB BusinessLocal is null", singletonBusinessLocalField);
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
- public void lookupSingletonBusinessLocalBean() throws TestFailureException{
- try{
- Assert.assertNotNull("The EJB BusinessLocalBean is null", singletonBusinessLocalFieldBean );
- } catch (AssertionFailedError afe){
+ public void lookupSingletonBusinessLocalBean() throws TestFailureException {
+ try {
+ Assert.assertNotNull("The EJB BusinessLocalBean is null", singletonBusinessLocalFieldBean);
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
- public void lookupSingletonBusinessRemote() throws TestFailureException{
- try{
- Assert.assertNotNull("The EJB BusinessRemote is null", singletonBusinessRemoteField );
- } catch (AssertionFailedError afe){
+ public void lookupSingletonBusinessRemote() throws TestFailureException {
+ try {
+ Assert.assertNotNull("The EJB BusinessRemote is null", singletonBusinessRemoteField);
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
- public void lookupStatefulBusinessLocal() throws TestFailureException{
- try{
- Assert.assertNotNull("The EJB BusinessLocal is null", statefulBusinessLocalField );
- } catch (AssertionFailedError afe){
+ public void lookupStatefulBusinessLocal() throws TestFailureException {
+ try {
+ Assert.assertNotNull("The EJB BusinessLocal is null", statefulBusinessLocalField);
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
- public void lookupStatefulBusinessLocalBean() throws TestFailureException{
- try{
- Assert.assertNotNull("The EJB BusinessLocalBean is null", statefulBusinessLocalFieldBean );
- } catch (AssertionFailedError afe){
+ public void lookupStatefulBusinessLocalBean() throws TestFailureException {
+ try {
+ Assert.assertNotNull("The EJB BusinessLocalBean is null", statefulBusinessLocalFieldBean);
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
- public void lookupStatefulBusinessRemote() throws TestFailureException{
- try{
- Assert.assertNotNull("The EJB BusinessRemote is null", statefulBusinessRemoteField );
- } catch (AssertionFailedError afe){
+ public void lookupStatefulBusinessRemote() throws TestFailureException {
+ try {
+ Assert.assertNotNull("The EJB BusinessRemote is null", statefulBusinessRemoteField);
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
@@ -367,100 +367,100 @@ public class SetterInjectionSingletonBea
public void lookupStringEntry() throws TestFailureException {
try {
- String expected = new String("1");
+ final String expected = new String("1");
Assert.assertNotNull("The String looked up is null", striingField);
Assert.assertEquals(expected, striingField);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
public void lookupDoubleEntry() throws TestFailureException {
try {
- Double expected = new Double(1.0D);
+ final Double expected = new Double(1.0D);
Assert.assertNotNull("The Double looked up is null", dooubleField);
Assert.assertEquals(expected, dooubleField);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
public void lookupLongEntry() throws TestFailureException {
try {
- Long expected = new Long(1L);
+ final Long expected = new Long(1L);
Assert.assertNotNull("The Long looked up is null", loongField);
Assert.assertEquals(expected, loongField);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
public void lookupFloatEntry() throws TestFailureException {
try {
- Float expected = new Float(1.0F);
+ final Float expected = new Float(1.0F);
Assert.assertNotNull("The Float looked up is null", flooatField);
Assert.assertEquals(expected, flooatField);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
public void lookupIntegerEntry() throws TestFailureException {
try {
- Integer expected = new Integer(1);
+ final Integer expected = new Integer(1);
Assert.assertNotNull("The Integer looked up is null", inteegerField);
Assert.assertEquals(expected, inteegerField);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
public void lookupShortEntry() throws TestFailureException {
try {
- Short expected = new Short((short) 1);
+ final Short expected = new Short((short) 1);
Assert.assertNotNull("The Short looked up is null", shoortField);
Assert.assertEquals(expected, shoortField);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
public void lookupBooleanEntry() throws TestFailureException {
try {
- Boolean expected = new Boolean(true);
+ final Boolean expected = new Boolean(true);
Assert.assertNotNull("The Boolean looked up is null", boooleanField);
Assert.assertEquals(expected, boooleanField);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
public void lookupByteEntry() throws TestFailureException {
try {
- Byte expected = new Byte((byte) 1);
+ final Byte expected = new Byte((byte) 1);
Assert.assertNotNull("The Byte looked up is null", byyteField);
Assert.assertEquals(expected, byyteField);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
public void lookupCharacterEntry() throws TestFailureException {
try {
- Character expected = new Character('D');
+ final Character expected = new Character('D');
Assert.assertNotNull("The Character looked up is null", chaaracterField);
Assert.assertEquals(expected, chaaracterField);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
@@ -468,30 +468,30 @@ public class SetterInjectionSingletonBea
public void lookupResource() throws TestFailureException {
try {
Assert.assertNotNull("The DataSource is null", daataSourceField);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
- public void lookupJMSConnectionFactory() throws TestFailureException{
- try{
- try{
+ public void lookupJMSConnectionFactory() throws TestFailureException {
+ try {
+ try {
testJmsConnection(coonnectionFactory.createConnection());
testJmsConnection(queueCoonnectionFactory.createConnection());
testJmsConnection(topicCoonnectionFactory.createConnection());
- } catch (Exception e){
+ } catch (final Exception e) {
e.printStackTrace();
- Assert.fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
+ Assert.fail("Received Exception " + e.getClass() + " : " + e.getMessage());
}
- } catch (AssertionFailedError afe){
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
- private void testJmsConnection(javax.jms.Connection connection) throws JMSException {
- Session session = connection.createSession(false, Session.DUPS_OK_ACKNOWLEDGE);
- Topic topic = session.createTopic("test");
- MessageProducer producer = session.createProducer(topic);
+ private void testJmsConnection(final javax.jms.Connection connection) throws JMSException {
+ final Session session = connection.createSession(false, Session.DUPS_OK_ACKNOWLEDGE);
+ final Topic topic = session.createTopic("test");
+ final MessageProducer producer = session.createProducer(topic);
producer.send(session.createMessage());
producer.close();
session.close();
@@ -501,7 +501,7 @@ public class SetterInjectionSingletonBea
public void lookupPersistenceUnit() throws TestFailureException {
try {
Assert.assertNotNull("The EntityManagerFactory is null", emfField);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
@@ -513,10 +513,10 @@ public class SetterInjectionSingletonBea
try {
// call a do nothing method to assure entity manager actually exists
emField.getFlushMode();
- } catch (Exception e) {
+ } catch (final Exception e) {
Assert.fail("Received Exception " + e.getClass() + " : " + e.getMessage());
}
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
@@ -525,7 +525,7 @@ public class SetterInjectionSingletonBea
try {
// TODO: DMB: Can't seem to find where to make this work
// Assert.assertNotNull("The SessionContext is null", ejbContext);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
@@ -540,6 +540,6 @@ public class SetterInjectionSingletonBea
public void ejbRemove() throws EJBException, RemoteException {
}
- public void setSessionContext(SessionContext sessionContext) throws EJBException, RemoteException {
+ public void setSessionContext(final SessionContext sessionContext) throws EJBException, RemoteException {
}
}
Modified: tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/stateful/AnnotatedFieldInjectionStatefulBean.java
URL: http://svn.apache.org/viewvc/tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/stateful/AnnotatedFieldInjectionStatefulBean.java?rev=1610862&r1=1610861&r2=1610862&view=diff
==============================================================================
--- tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/stateful/AnnotatedFieldInjectionStatefulBean.java (original)
+++ tomee/tomee/trunk/itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/stateful/AnnotatedFieldInjectionStatefulBean.java Tue Jul 15 21:55:09 2014
@@ -70,11 +70,11 @@ public class AnnotatedFieldInjectionStat
@Resource
private Integer inteeger = 1;
@Resource
- private Short shoort = (short)1;
+ private Short shoort = (short) 1;
@Resource
private Boolean booolean = true;
@Resource
- private Byte byyte = (byte)1;
+ private Byte byyte = (byte) 1;
@Resource
private Character chaaracter = 'D';
@Resource
@@ -104,17 +104,17 @@ public class AnnotatedFieldInjectionStat
@Init
- public void create(String name) {
+ public void create(final String name) {
}
@Remove
- public void remove(){
+ public void remove() {
}
-
+
public void lookupEntityBean() throws TestFailureException {
try {
Assert.assertNotNull("The EJBObject is null", bmpHome);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
@@ -122,7 +122,7 @@ public class AnnotatedFieldInjectionStat
public void lookupStatefulBean() throws TestFailureException {
try {
Assert.assertNotNull("The EJBObject is null", statefulHome);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
@@ -130,7 +130,7 @@ public class AnnotatedFieldInjectionStat
public void lookupStatelessBean() throws TestFailureException {
try {
Assert.assertNotNull("The EJBObject is null", statelessHome);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
@@ -138,7 +138,7 @@ public class AnnotatedFieldInjectionStat
public void lookupStatelessBusinessLocal() throws TestFailureException {
try {
Assert.assertNotNull("The EJB BusinessLocal is null", statelessBusinessLocal);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
@@ -146,7 +146,7 @@ public class AnnotatedFieldInjectionStat
public void lookupStatelessBusinessLocalBean() throws TestFailureException {
try {
Assert.assertNotNull("The EJB BusinessLocalBean is null", statelessBusinessLocalBean);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
@@ -154,7 +154,7 @@ public class AnnotatedFieldInjectionStat
public void lookupStatelessBusinessRemote() throws TestFailureException {
try {
Assert.assertNotNull("The EJB BusinessRemote is null", statelessBusinessRemote);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
@@ -162,7 +162,7 @@ public class AnnotatedFieldInjectionStat
public void lookupStatefulBusinessLocal() throws TestFailureException {
try {
Assert.assertNotNull("The EJB BusinessLocal is null", statefulBusinessLocal);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
@@ -170,7 +170,7 @@ public class AnnotatedFieldInjectionStat
public void lookupStatefulBusinessLocalBean() throws TestFailureException {
try {
Assert.assertNotNull("The EJB BusinessLocalBean is null", statefulBusinessLocalBean);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
@@ -178,107 +178,107 @@ public class AnnotatedFieldInjectionStat
public void lookupStatefulBusinessRemote() throws TestFailureException {
try {
Assert.assertNotNull("The EJB BusinessRemote is null", statefulBusinessRemote);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
public void lookupStringEntry() throws TestFailureException {
try {
- String expected = new String("1");
+ final String expected = new String("1");
Assert.assertNotNull("The String looked up is null", striing);
Assert.assertEquals(expected, striing);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
public void lookupDoubleEntry() throws TestFailureException {
try {
- Double expected = new Double(1.0D);
+ final Double expected = new Double(1.0D);
Assert.assertNotNull("The Double looked up is null", doouble);
Assert.assertEquals(expected, doouble);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
public void lookupLongEntry() throws TestFailureException {
try {
- Long expected = new Long(1L);
+ final Long expected = new Long(1L);
Assert.assertNotNull("The Long looked up is null", loong);
Assert.assertEquals(expected, loong);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
public void lookupFloatEntry() throws TestFailureException {
try {
- Float expected = new Float(1.0F);
+ final Float expected = new Float(1.0F);
Assert.assertNotNull("The Float looked up is null", flooat);
Assert.assertEquals(expected, flooat);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
public void lookupIntegerEntry() throws TestFailureException {
try {
- Integer expected = new Integer(1);
+ final Integer expected = new Integer(1);
Assert.assertNotNull("The Integer looked up is null", inteeger);
Assert.assertEquals(expected, inteeger);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
public void lookupShortEntry() throws TestFailureException {
try {
- Short expected = new Short((short) 1);
+ final Short expected = new Short((short) 1);
Assert.assertNotNull("The Short looked up is null", shoort);
Assert.assertEquals(expected, shoort);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
public void lookupBooleanEntry() throws TestFailureException {
try {
- Boolean expected = new Boolean(true);
+ final Boolean expected = new Boolean(true);
Assert.assertNotNull("The Boolean looked up is null", booolean);
Assert.assertEquals(expected, booolean);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
public void lookupByteEntry() throws TestFailureException {
try {
- Byte expected = new Byte((byte) 1);
+ final Byte expected = new Byte((byte) 1);
Assert.assertNotNull("The Byte looked up is null", byyte);
Assert.assertEquals(expected, byyte);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
public void lookupCharacterEntry() throws TestFailureException {
try {
- Character expected = new Character('D');
+ final Character expected = new Character('D');
Assert.assertNotNull("The Character looked up is null", chaaracter);
Assert.assertEquals(expected, chaaracter);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
@@ -286,30 +286,30 @@ public class AnnotatedFieldInjectionStat
public void lookupResource() throws TestFailureException {
try {
Assert.assertNotNull("The DataSource is null", daataSource);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
- public void lookupJMSConnectionFactory() throws TestFailureException{
- try{
- try{
+ public void lookupJMSConnectionFactory() throws TestFailureException {
+ try {
+ try {
testJmsConnection(coonnectionFactory.createConnection());
testJmsConnection(queueCoonnectionFactory.createConnection());
testJmsConnection(topicCoonnectionFactory.createConnection());
- } catch (Exception e){
+ } catch (final Exception e) {
e.printStackTrace();
- Assert.fail("Received Exception "+e.getClass()+ " : "+e.getMessage());
+ Assert.fail("Received Exception " + e.getClass() + " : " + e.getMessage());
}
- } catch (AssertionFailedError afe){
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
- private void testJmsConnection(javax.jms.Connection connection) throws JMSException {
- Session session = connection.createSession(false, Session.DUPS_OK_ACKNOWLEDGE);
- Topic topic = session.createTopic("test");
- MessageProducer producer = session.createProducer(topic);
+ private void testJmsConnection(final javax.jms.Connection connection) throws JMSException {
+ final Session session = connection.createSession(false, Session.DUPS_OK_ACKNOWLEDGE);
+ final Topic topic = session.createTopic("test");
+ final MessageProducer producer = session.createProducer(topic);
producer.send(session.createMessage());
producer.close();
session.close();
@@ -319,7 +319,7 @@ public class AnnotatedFieldInjectionStat
public void lookupPersistenceUnit() throws TestFailureException {
try {
Assert.assertNotNull("The EntityManagerFactory is null", emf);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
@@ -331,10 +331,10 @@ public class AnnotatedFieldInjectionStat
try {
// call a do nothing method to assure entity manager actually exists
em.getFlushMode();
- } catch (Exception e) {
+ } catch (final Exception e) {
Assert.fail("Received Exception " + e.getClass() + " : " + e.getMessage());
}
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}
}
@@ -343,7 +343,7 @@ public class AnnotatedFieldInjectionStat
try {
// TODO: DMB: Can't seem to find where to make this work
// Assert.assertNotNull("The SessionContext is null", ejbContext);
- } catch (AssertionFailedError afe) {
+ } catch (final AssertionFailedError afe) {
throw new TestFailureException(afe);
}