Style Intelligence v12.0

inetsoft.uql.object
Class ObjectDataSource

java.lang.Object
  extended by inetsoft.uql.XDataSource
      extended by inetsoft.uql.util.HierDataSource
          extended by inetsoft.uql.object.ObjectDataSource
All Implemented Interfaces:
inetsoft.util.XMLSerializable, Serializable, Cloneable

public class ObjectDataSource
extends HierDataSource

Application object data source class. It contains meta data information and class to load objects.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class inetsoft.uql.util.HierDataSource
GET, POST
 
Fields inherited from class inetsoft.uql.XDataSource
CORBA, DOMAIN_DB2, DOMAIN_NONE, DOMAIN_ORACLE, DOMAIN_SQL, DOMAIN_SQLSERVER, EJB, JDBC, OBJECT, SAP, SOAP, TEXT, XML, XMLA
 
Constructor Summary
ObjectDataSource()
          Create a Object data source.
 
Method Summary
 Object clone()
          Create a clone of this object.
 Object createDataHelper()
          Creates and initializes an instance of the data helper.
 Object createInterface()
          Creates and initializes an instance of the server object interface.
static String[] findDataHelpers()
          Finds all data helper classes registered using the standard Java service loading mechanism.
static String[] findDataLoaders()
          Finds all data loader classes registered using the standard Java service loading mechanism.
 String getDataHelper()
          Get the name of data helper class.
 String getInterface()
          Get the Object server object interface class full name.
 String getRequest(int idx)
          Get the data source item name.
 int getRequestCount()
          Get the number of Object requests.
 XTypeNode getRequestInputType(String method)
          Get the input type of the specified request.
 String getRequestOutputClass(String method)
          Get the output class type of the specified request.
 XTypeNode getRequestOutputType(String method)
          Get the output type of the specified request.
 XNode getRequestParameters(String method)
          Get the parameters of the specified request.
 void importInterface(String serverclass)
          Import the Object server object interface class.
 void parseXML(Element root)
          Parse the XML element that contains information on this data source.
 void removeRequest(int idx)
           
 void setDataHelper(String helper)
          Set the fully qualified name of the data helper class.
 void setInterface(String serverclass)
          Get the Object server object interface class full name.
 void setRequestOutputClass(String method, String type)
          Set the output class type of the specified request.
 void setRequestOutputType(String method, XTypeNode type)
          Set the output type of the specified request.
 void setRequestParameters(String method, XNode params)
          Set the parameters of the specified request.
 void updateInterfaceProperties(Object iface)
          Update the initial properties for the server object interface using those of the specified object.
 void writeXML(PrintWriter writer)
          Generate the XML segment to represent this data source.
 
Methods inherited from class inetsoft.uql.util.HierDataSource
getParameters, getTypeResolver, setTypeResolver
 
Methods inherited from class inetsoft.uql.XDataSource
addFolder, equals, getDescription, getDomainType, getFolders, getFullName, getName, getRuntimeValue, getType, hashCode, isMVEnabled, removeFolder, removeFolders, setDescription, setName, toString
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ObjectDataSource

public ObjectDataSource()
Create a Object data source.

Method Detail

setDataHelper

public void setDataHelper(String helper)
Set the fully qualified name of the data helper class. The data helper must implement the DataHelper interface defined in this package.


getDataHelper

public String getDataHelper()
Get the name of data helper class.


createDataHelper

public Object createDataHelper()
                        throws Exception
Creates and initializes an instance of the data helper.

Returns:
a new data helper instance.
Throws:
Exception - if the instance could not be created.

getRequest

public String getRequest(int idx)
Get the data source item name.

Specified by:
getRequest in class HierDataSource

getRequestCount

public int getRequestCount()
Get the number of Object requests. Each Object server object method is treated as a request.

Specified by:
getRequestCount in class HierDataSource

removeRequest

public void removeRequest(int idx)

getRequestOutputType

public XTypeNode getRequestOutputType(String method)
Get the output type of the specified request.

Specified by:
getRequestOutputType in class HierDataSource
Parameters:
method - request name.
Returns:
request output type.

setRequestOutputType

public void setRequestOutputType(String method,
                                 XTypeNode type)
Set the output type of the specified request.

Parameters:
method - request name.
type - request output type.

getRequestOutputClass

public String getRequestOutputClass(String method)
Get the output class type of the specified request.

Parameters:
method - request name.
Returns:
request output type.

setRequestOutputClass

public void setRequestOutputClass(String method,
                                  String type)
Set the output class type of the specified request.

Parameters:
method - request name.
type - request output type.

getRequestInputType

public XTypeNode getRequestInputType(String method)
Get the input type of the specified request.

Specified by:
getRequestInputType in class HierDataSource
Parameters:
method - request name.
Returns:
request input type.

getRequestParameters

public XNode getRequestParameters(String method)
Get the parameters of the specified request.

Specified by:
getRequestParameters in class HierDataSource
Parameters:
method - request name.

setRequestParameters

public void setRequestParameters(String method,
                                 XNode params)
Set the parameters of the specified request.

Specified by:
setRequestParameters in class HierDataSource
Parameters:
method - request name.
params - parameters represented as a tree. It is converted to a Object object during runtime to be passed to the Object call.

getInterface

public String getInterface()
Get the Object server object interface class full name.


setInterface

public void setInterface(String serverclass)
Get the Object server object interface class full name.


updateInterfaceProperties

public void updateInterfaceProperties(Object iface)
                               throws Exception
Update the initial properties for the server object interface using those of the specified object.

Parameters:
iface - the server object interface instance.
Throws:
Exception - if the properties could not be updated.

createInterface

public Object createInterface()
                       throws Exception
Creates and initializes an instance of the server object interface.

Returns:
a new interface instance.
Throws:
Exception - if the instance could not be created.

importInterface

public void importInterface(String serverclass)
                     throws Exception
Import the Object server object interface class. The input/output types are extracted from the interface class.

Throws:
Exception

parseXML

public void parseXML(Element root)
              throws Exception
Parse the XML element that contains information on this data source.

Specified by:
parseXML in interface inetsoft.util.XMLSerializable
Overrides:
parseXML in class XDataSource
Throws:
Exception

writeXML

public void writeXML(PrintWriter writer)
Generate the XML segment to represent this data source.

Specified by:
writeXML in interface inetsoft.util.XMLSerializable
Overrides:
writeXML in class XDataSource

clone

public Object clone()
Create a clone of this object.

Overrides:
clone in class XDataSource

findDataHelpers

public static String[] findDataHelpers()
Finds all data helper classes registered using the standard Java service loading mechanism.

Returns:
the class names of all registered data helpers.
See Also:
ServiceLoader

findDataLoaders

public static String[] findDataLoaders()
Finds all data loader classes registered using the standard Java service loading mechanism.

Returns:
the class names of all registered data loaders.
See Also:
ServiceLoader

Copyright © 1996-2014 InetSoft Technology Corp. All Rights Reserved.