de.netseeker.ejoe.ext.crispy
Class EJExecutor

java.lang.Object
  extended by net.sf.crispy.Executor
      extended by de.netseeker.ejoe.ext.crispy.EJExecutor

public class EJExecutor
extends net.sf.crispy.Executor

A dynamic proxy implementation for the great Crispy framework. EJExcecutor makes it possible to use EJOE as service within Crispy:

       Properties prop = new Properties(); 
       prop.put(Property.EXECUTOR_CLASS, EJExecutor.class.getName()); 
       prop.put(EJExecutor.EJOE_SERIALIZATION_ADAPTER, ObjectStreamAdapter.class.getName());
       prop.put(Property.REMOTE_URL_AND_PORT, "socket://localhost:12577"); 
         prop.put(EJExecutor.EJOE_USE_PERSISTENT_CONNECTION, Boolean.toString(true));
       //prop.put(EJExecutor.EJOE_IN_JVM, Boolean.toString(true)); 
       ServiceManager manager = new ServiceManager(prop); 
       Echo e = (Echo) manager.createService(Echo.class);
       ...
 

Since:
0.3.9.1
Author:
netseeker
See Also:
http://crispy.sourceforge.net/index.html, de.netseeker.ejoe.test.crispy.EJCrispyTest

Field Summary
static java.lang.String EJOE_CONNECTION_TIMEOUT
          Tells the underlying EJClient how long it will wait for server response until it will assume a connection timeout
static java.lang.String EJOE_IN_JVM
          Tells the underlying EJClient if it should use an existent In-JVM instance of EJServer, no socket connections will be used
static java.lang.String EJOE_SERIALIZATION_ADAPTER
          Tells the underlying EJClient which SerializationAdapter should be used
static java.lang.String EJOE_USE_COMPRESSION
          Tells the underlying EJClient if it should compress serialized objects when sending them through the socket
static java.lang.String EJOE_USE_PERSISTENT_CONNECTION
          Tells the underlying EJClient if it should request and use a persistent connection from the EJServer
static java.lang.String EJOE_USE_REMOTE_CLASSLOADER
          Tells the underlying EJClient if it should try to use EJOE remote classloading feature, eg. load unknown response types from the server via the EJClassLoader
 
Fields inherited from class net.sf.crispy.Executor
log
 
Constructor Summary
EJExecutor()
           
 
Method Summary
 java.lang.Object execute(java.lang.Class pvProxyClass, java.lang.Object pvProxy, java.lang.reflect.Method pvMethod, java.lang.Object[] pvArgs)
           
 net.sf.crispy.InvocationStrategy getDefaultInvocationStrategy()
           
 java.lang.String getDefaultUrlAndPort()
           
 
Methods inherited from class net.sf.crispy.Executor
getInvocationStrategy, getProperties, getUrlAndPort, setInvocationStrategy, setProperties, setUrlAndPort, withConverter
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

EJOE_SERIALIZATION_ADAPTER

public static final java.lang.String EJOE_SERIALIZATION_ADAPTER
Tells the underlying EJClient which SerializationAdapter should be used

See Also:
Constant Field Values

EJOE_USE_COMPRESSION

public static final java.lang.String EJOE_USE_COMPRESSION
Tells the underlying EJClient if it should compress serialized objects when sending them through the socket

See Also:
Constant Field Values

EJOE_USE_PERSISTENT_CONNECTION

public static final java.lang.String EJOE_USE_PERSISTENT_CONNECTION
Tells the underlying EJClient if it should request and use a persistent connection from the EJServer

See Also:
Constant Field Values

EJOE_CONNECTION_TIMEOUT

public static final java.lang.String EJOE_CONNECTION_TIMEOUT
Tells the underlying EJClient how long it will wait for server response until it will assume a connection timeout

See Also:
Constant Field Values

EJOE_USE_REMOTE_CLASSLOADER

public static final java.lang.String EJOE_USE_REMOTE_CLASSLOADER
Tells the underlying EJClient if it should try to use EJOE remote classloading feature, eg. load unknown response types from the server via the EJClassLoader

See Also:
Constant Field Values

EJOE_IN_JVM

public static final java.lang.String EJOE_IN_JVM
Tells the underlying EJClient if it should use an existent In-JVM instance of EJServer, no socket connections will be used

See Also:
Constant Field Values
Constructor Detail

EJExecutor

public EJExecutor()
Method Detail

getDefaultUrlAndPort

public java.lang.String getDefaultUrlAndPort()
Specified by:
getDefaultUrlAndPort in class net.sf.crispy.Executor

getDefaultInvocationStrategy

public net.sf.crispy.InvocationStrategy getDefaultInvocationStrategy()
Overrides:
getDefaultInvocationStrategy in class net.sf.crispy.Executor

execute

public java.lang.Object execute(java.lang.Class pvProxyClass,
                                java.lang.Object pvProxy,
                                java.lang.reflect.Method pvMethod,
                                java.lang.Object[] pvArgs)
                         throws java.lang.Exception
Specified by:
execute in class net.sf.crispy.Executor
Throws:
java.lang.Exception


Copyright © 2005-2007 netseeker. All Rights Reserved.