Definition at line 23 of file ExternalFunction.cs.
Deveel.Data.Routines.ExternalFunction.ExternalFunction |
( |
FunctionInfo |
functionInfo | ) |
|
|
inline |
Definition at line 26 of file ExternalFunction.cs.
27 : base(functionInfo) {
29 throw new ArgumentException(
"The information specified are not pointing to any external function.");
FunctionType FunctionType
object [] Deveel.Data.Routines.ExternalFunction.ConvertArguments |
( |
MethodInfo |
methodInfo, |
|
|
DataObject[] |
args |
|
) |
| |
|
inlineprivate |
Definition at line 55 of file ExternalFunction.cs.
56 var methodParams = methodInfo.GetParameters();
58 if (methodParams.Length != args.Length)
59 throw new InvalidOperationException();
61 var values =
new object[args.Length];
62 for (
int i = 0; i < args.Length; i++) {
63 var paramType = methodParams[i].ParameterType;
66 values[i] = sqlType.
ConvertTo(args[i].Value, paramType);
Provides some helper functions for resolving and creating SqlType instances that are primitive to the...
virtual object ConvertTo(ISqlObject obj, Type destType)
static SqlType FromType(Type type)
DataObject Deveel.Data.Routines.ExternalFunction.ConvertValue |
( |
object |
value, |
|
|
SqlType |
sqlType |
|
) |
| |
|
inlineprivate |
MethodInfo Deveel.Data.Routines.ExternalFunction.DiscoverMethod |
( |
| ) |
|
|
inlineprivate |
Definition at line 79 of file ExternalFunction.cs.
82 if (
String.IsNullOrEmpty(methodName))
85 throw new NotImplementedException();
A long string in the system.
string ExternalMethodName
ObjectName RoutineName
Gets the name of the routine that uniquely identifies it in a system context.
FunctionInfo FunctionInfo
Executes the function and provides a result.
- Parameters
-
context | The context of the execution. |
- Returns
- Returns a InvokeResult instance that encapsulates the returned value of the function.
- See also
- InvokeResult.ReturnValue
Implements Deveel.Data.Routines.Function.
Definition at line 32 of file ExternalFunction.cs.
37 throw new InvalidOperationException();
39 var args = context.EvaluatedArguments;
43 var result =
method.Invoke(null, methodArgs);
DataObject ConvertValue(object value, SqlType sqlType)
object[] ConvertArguments(MethodInfo methodInfo, DataObject[] args)
SqlType ReturnType()
Gets the function static return type
MethodInfo DiscoverMethod()
Resolves the function return type against the given context.
- Parameters
-
context | The execution context used to resolve the function return type. |
- Returns
- Returns an instance of SqlType that defines the type of the returned value resolved against the given execution context..
Reimplemented from Deveel.Data.Routines.Function.
Definition at line 72 of file ExternalFunction.cs.
76 return base.ReturnType(context);
MethodInfo DiscoverMethod()
MethodInfo Deveel.Data.Routines.ExternalFunction.method |
|
private |
The documentation for this class was generated from the following file:
- /var/calculate/remote/distfiles/egit-src/deveeldb.git/src/deveeldb/Deveel.Data.Routines/ExternalFunction.cs