electric.service.virtual
Class VirtualService

java.lang.Object
  extended byelectric.service.virtual.VirtualService
All Implemented Interfaces:
IContextHolder, IEXMLLoggingConstants, IGLUELoggingConstants, ILoggingConstants, IReference, IService
Direct Known Subclasses:
VirtualSOAPHandler

public class VirtualService
extends java.lang.Object
implements IService, IReference, IGLUELoggingConstants

VirtualService.

Author:
webMethods

Field Summary
 
Fields inherited from interface electric.glue.IGLUELoggingConstants
CLUSTER_DEBUG_EVENT, CLUSTER_EVENT, CONSOLE_DEBUG_EVENT, DEPLOY_EVENT, DETECTORS_EVENT, HTTP_EVENT, JMS_EVENT, REBINDING_EVENT, SECURITY_DEBUG_EVENT, SECURITY_DETAIL_EVENT, SERVLET_EVENT, SOAP_EVENT
 
Fields inherited from interface electric.xml.IEXMLLoggingConstants
MAPPING_EVENT, SCHEMA_EVENT
 
Fields inherited from interface electric.util.log.ILoggingConstants
CLASSLOADER_EVENT, COMMAND_EVENT, COMMENT_EVENT, CONFIG_EVENT, DEBUG_EVENT, ELECTRIC_LOGGING_PROPERTY, ERROR_EVENT, EXCEPTION_EVENT, FILE_EVENT, LICENSE_EVENT, RESOURCES_EVENT, SECURITY_EVENT, SHUTDOWN_EVENT, SOURCE_EVENT, SQL_EVENT, STARTUP_EVENT, WARNING_EVENT
 
Constructor Summary
VirtualService(java.lang.Class[] types, java.lang.reflect.InvocationHandler handler)
           
VirtualService(java.lang.Class type, java.lang.reflect.InvocationHandler handler)
           
 
Method Summary
static void disable()
           
static void enable()
           
 Context getContext()
           
 IReference getReference()
          Return a reference to this service.
 WSDL getWSDL()
          Return WSDL for this service.
 Value invoke(java.lang.reflect.Method method, java.lang.Object[] args, Context context)
          Invoke the operation associated with a particular method, using the specified arguments.
 Value invoke(java.lang.String methodName, java.lang.Object[] args, java.lang.Class[] argTypes, Context context)
          Invoke the operation associated with a particular method, using the specified arguments and argument types.
 Value invoke(java.lang.String methodName, java.lang.String[] args, Context context)
          Invoke the operation associated with a particular method, using the specified arguments.
 void setContext(Context context)
           
 java.lang.String toString()
          Return a description of this service.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

VirtualService

public VirtualService(java.lang.Class type,
                      java.lang.reflect.InvocationHandler handler)
Parameters:
type -
handler -

VirtualService

public VirtualService(java.lang.Class[] types,
                      java.lang.reflect.InvocationHandler handler)
Parameters:
types -
handler -
Method Detail

toString

public java.lang.String toString()
Return a description of this service.


getContext

public Context getContext()
Specified by:
getContext in interface IContextHolder

setContext

public void setContext(Context context)
Specified by:
setContext in interface IContextHolder
Parameters:
context -

invoke

public Value invoke(java.lang.reflect.Method method,
                    java.lang.Object[] args,
                    Context context)
             throws java.lang.Throwable
Invoke the operation associated with a particular method, using the specified arguments.

Specified by:
invoke in interface IReference
Parameters:
method - The method to invoke
args - The arguments.
context - The context.
Throws:
java.lang.Throwable - If an exception occurs.

invoke

public Value invoke(java.lang.String methodName,
                    java.lang.Object[] args,
                    java.lang.Class[] argTypes,
                    Context context)
             throws java.lang.Throwable
Invoke the operation associated with a particular method, using the specified arguments and argument types. If more than one operation matches the method name and argument types, a NoSuchMethodException is thrown.

Specified by:
invoke in interface IReference
Parameters:
methodName - The name of the method to invoke
args - The arguments.
argTypes - The type of the arguments.
context - The context.
Throws:
java.lang.Throwable - If an exception occurs.

invoke

public Value invoke(java.lang.String methodName,
                    java.lang.String[] args,
                    Context context)
             throws java.lang.Throwable
Invoke the operation associated with a particular method, using the specified arguments. If more than one operation matches the method name and argument count, a NoSuchMethodException is thrown.

Specified by:
invoke in interface IReference
Parameters:
methodName - The name of the method to invoke
args - The arguments, expressed as strings.
context - The context.
Throws:
java.lang.Throwable - If an exception occurs.

getReference

public IReference getReference()
Return a reference to this service.

Specified by:
getReference in interface IService

getWSDL

public WSDL getWSDL()
Return WSDL for this service. The WSDL is cached for use by subsequent requests. In 5.0 this changed from "virtual" to the name of the handler as the name of the wsdl. May break backwards compatibility.

Specified by:
getWSDL in interface IService

enable

public static void enable()

disable

public static void disable()


copyright© 2001-2004 by webMethods All Rights Reserved.