|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.sqlite.callback.Callback
org.sqlite.callback.NamedCallback
org.sqlite.udf.Function
org.sqlite.udf.AggregateFunction<T>
public abstract class AggregateFunction<T>
User-Defined aggregate function class.
JdbcConnection.createFunction(Function)
,
JdbcConnection.dropFunction(Function)
,
JdbcConnection.dropFunction(java.lang.String)
Field Summary | |
---|---|
protected java.lang.ThreadLocal<T> |
tls
thraed local storage |
Fields inherited from class org.sqlite.udf.Function |
---|
argc |
Constructor Summary | |
---|---|
AggregateFunction(java.lang.String name)
|
|
AggregateFunction(java.lang.String name,
int argc)
|
Method Summary | |
---|---|
protected T |
get()
Returns the value in the current thread's copy of this thread-local variable. |
protected abstract T |
initialValue()
Returns the current thread's "initial value" for this thread-local variable. |
protected void |
remove()
Removes the current thread's value for this thread-local variable. |
protected void |
set(T value)
Sets the current thread's copy of this thread-local variable to the specified value. |
protected abstract void |
xFinal(Context ctx)
|
protected void |
xFinal(long context)
Called from the sqlite3_step() function. |
protected void |
xFunc(Context ctx)
Called from the sqlite3_step() function. |
protected abstract void |
xStep(Context ctx)
|
Methods inherited from class org.sqlite.udf.Function |
---|
getArgumentCount, xFunc |
Methods inherited from class org.sqlite.callback.NamedCallback |
---|
getName |
Methods inherited from class org.sqlite.callback.Callback |
---|
isRegistered |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected final java.lang.ThreadLocal<T> tls
Constructor Detail |
---|
public AggregateFunction(java.lang.String name, int argc)
public AggregateFunction(java.lang.String name)
Method Detail |
---|
protected final void xFunc(Context ctx) throws java.sql.SQLException
Function
xFunc
in class Function
ctx
- sqlite3_context wrapper object
java.sql.SQLException
protected final void xFinal(long context)
context
- protected abstract T initialValue()
ThreadLocal.initialValue()
protected T get()
ThreadLocal.get()
protected void remove()
ThreadLocal.remove()
protected void set(T value)
value
- the value to be stored in the current thread's copy of this thread-local.ThreadLocal.set(Object)
protected abstract void xStep(Context ctx) throws java.sql.SQLException
java.sql.SQLException
protected abstract void xFinal(Context ctx) throws java.sql.SQLException
java.sql.SQLException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |