CDMA client API  3.1.0
CDMA core library
org.gumtree.data.utils.Utilities Class Reference

This class defines main type used by the CDMA and some conversion methods. More...

List of all members.

Classes

enum  ModelType
 Public enumeration. More...
enum  ParameterType

Static Public Member Functions

static ModelType checkModelType (final Object signal)
static Object findObject (URI uri, String dictionaryPath) throws FileAccessException
static Object findObject (URI uri, String dictionaryPath, IFactory factory) throws FileAccessException
static ModelType checkDataType (final URI uri, final String dictionaryPath) throws FileAccessException
static IArray reshapeArray (final IArray array, final int[] shape) throws InvalidArrayTypeException
static IArray copyToDoubleArray (final IArray array)
static IArray copyToPositiveDoubleArray (final IArray array)
static void copyTo (final IArray array1, final IArray array2, int length) throws DimensionNotSupportedException
static String getKeyFromValue (IGroup group, String shortName)

Detailed Description

This class defines main type used by the CDMA and some conversion methods.


Member Function Documentation

static ModelType org.gumtree.data.utils.Utilities.checkDataType ( final URI  uri,
final String  dictionaryPath 
) throws FileAccessException [static]

Check the data type in the location referenced by the URI.

Parameters:
uriURI object
dictionaryPathin String type
Returns:
CDMA DataType object
Exceptions:
FileAccessException
static ModelType org.gumtree.data.utils.Utilities.checkModelType ( final Object  signal) [static]

Check the CDMA type of the object.

Parameters:
signalObject type
Returns:
CDMA DataType
static void org.gumtree.data.utils.Utilities.copyTo ( final IArray  array1,
final IArray  array2,
int  length 
) throws DimensionNotSupportedException [static]

Helper method for copying the given number of items from one array to another. If the length is not given (length<0), as many items in array1 will be copied to array2 up to the smaller size of the two arrays.

Parameters:
array1IArray object
array2IArray object
lengthan int value
Exceptions:
DimensionNotSupportedException

Copy the array to a new array with double type storage.

Parameters:
arraynew IArray with new storage
Returns:
new IArray

Copy the array to a new array with double type storage.

Parameters:
arraynew IArray with new storage
Returns:
new IArray
static Object org.gumtree.data.utils.Utilities.findObject ( URI  uri,
String  dictionaryPath 
) throws FileAccessException [static]

Retrieve the object that referenced by the URI.

Parameters:
uriURI object
dictionaryPathin String type
Returns:
Object type
Exceptions:
FileAccessExceptionfile access error
static Object org.gumtree.data.utils.Utilities.findObject ( URI  uri,
String  dictionaryPath,
IFactory  factory 
) throws FileAccessException [static]

Retrieve the object that referenced by the URI.

Parameters:
uriURI object
dictionaryPathin String type
factorydata model factory
Returns:
Object type
Exceptions:
FileAccessExceptionfile access error
static String org.gumtree.data.utils.Utilities.getKeyFromValue ( IGroup  group,
String  shortName 
) [static]

Reverse the dictionary. Return the key if given a value.

Parameters:
group
shortName
Returns:
static IArray org.gumtree.data.utils.Utilities.reshapeArray ( final IArray  array,
final int[]  shape 
) throws InvalidArrayTypeException [static]

Create an new IArray by reshaping an IArray to a new shape. The total size of the new IArray must be same as the old IArray. The new IArray will use a new storage space.

Parameters:
arrayCDMA IArray type
shapejava array of integer
Returns:
CDMA IArray
Exceptions:
InvalidArrayTypeException

The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables