Beispiel #1
0
            internal Sqlite3FunctionMarshallingProxy(IntPtr db, IntPtr functionName, IntPtr invoke)
            {
                var invokeFunction = GCHandle.FromIntPtr(invoke);

                this.invoke = invokeFunction.Target as FunctionNativeCdecl;
                invokeFunction.Free();

                this.step = null;

                this.final = null;

                this.guid       = Guid.NewGuid();
                this.guidHandle = GCHandle.Alloc(this.guid, GCHandleType.Pinned);

                this.RegisterInstance(db, functionName);
            }
Beispiel #2
0
            internal Sqlite3FunctionMarshallingProxy(IntPtr db, IntPtr aggregateName, IntPtr step, IntPtr final)
            {
                this.invoke = null;

                var stepFunction = GCHandle.FromIntPtr(step);

                this.step = stepFunction.Target as AggregateStepNativeCdecl;
                stepFunction.Free();

                var finalFunction = GCHandle.FromIntPtr(final);

                this.final = finalFunction.Target as AggregateFinalNativeCdecl;
                finalFunction.Free();

                this.guid       = Guid.NewGuid();
                this.guidHandle = GCHandle.Alloc(this.guid, GCHandleType.Pinned);

                this.RegisterInstance(db, aggregateName);
            }