diff --git a/MEOS.NET/Functions/Meos.meos.g.cs b/MEOS.NET/Functions/Meos.meos.g.cs index 757a524..dd03274 100644 --- a/MEOS.NET/Functions/Meos.meos.g.cs +++ b/MEOS.NET/Functions/Meos.meos.g.cs @@ -3136,8 +3136,19 @@ public static int[] TintValues(IntPtr temp) finally { Marshal.FreeHGlobal(_cnt); } } - public static IntPtr TbigintValues(IntPtr temp, IntPtr count) - => SafeExecution(() => Native.TbigintValues(temp, count)); + public static long[] TbigintValues(IntPtr temp) + { + IntPtr _cnt = Marshal.AllocHGlobal(sizeof(int)); + try + { + IntPtr _p = SafeExecution(() => Native.TbigintValues(temp, _cnt)); + int _n = Marshal.ReadInt32(_cnt); + long[] _out = new long[_n]; + Marshal.Copy(_p, _out, 0, _n); + return _out; + } + finally { Marshal.FreeHGlobal(_cnt); } + } public static double TnumberAvgValue(IntPtr temp) => SafeExecution(() => Native.TnumberAvgValue(temp)); diff --git a/MEOS.NET/Types/MEOSFactory.g.cs b/MEOS.NET/Types/MEOSFactory.g.cs index bf0c29c..2768a23 100644 --- a/MEOS.NET/Types/MEOSFactory.g.cs +++ b/MEOS.NET/Types/MEOSFactory.g.cs @@ -329,6 +329,30 @@ public static class MEOSFactory return wrapped; } + /// The value at as the RTreeNNCursor + /// class the model gives its runtime type. + public static RTreeNNCursor? WrapRTreeNNCursor(IntPtr ptr) + { + if (ptr == IntPtr.Zero) + { + return null; + } + + return new RTreeNNCursor(ptr); + } + + /// Every element of a C array of RTreeNNCursor pointers, wrapped. + public static RTreeNNCursor?[] WrapRTreeNNCursorArray(IntPtr[] ptrs) + { + RTreeNNCursor?[] wrapped = new RTreeNNCursor?[ptrs.Length]; + for (int i = 0; i < ptrs.Length; i++) + { + wrapped[i] = WrapRTreeNNCursor(ptrs[i]); + } + + return wrapped; + } + /// The value at as the Raquet /// class the model gives its runtime type. public static Raquet? WrapRaquet(IntPtr ptr) @@ -353,6 +377,30 @@ public static class MEOSFactory return wrapped; } + /// The value at as the SPNNCursor + /// class the model gives its runtime type. + public static SPNNCursor? WrapSPNNCursor(IntPtr ptr) + { + if (ptr == IntPtr.Zero) + { + return null; + } + + return new SPNNCursor(ptr); + } + + /// Every element of a C array of SPNNCursor pointers, wrapped. + public static SPNNCursor?[] WrapSPNNCursorArray(IntPtr[] ptrs) + { + SPNNCursor?[] wrapped = new SPNNCursor?[ptrs.Length]; + for (int i = 0; i < ptrs.Length; i++) + { + wrapped[i] = WrapSPNNCursor(ptrs[i]); + } + + return wrapped; + } + /// The value at as the SPTree /// class the model gives its runtime type. public static SPTree? WrapSPTree(IntPtr ptr) diff --git a/MEOS.NET/Types/RTreeNNCursor.g.cs b/MEOS.NET/Types/RTreeNNCursor.g.cs new file mode 100644 index 0000000..0c638b4 --- /dev/null +++ b/MEOS.NET/Types/RTreeNNCursor.g.cs @@ -0,0 +1,24 @@ +#nullable enable + +using System.Runtime.InteropServices; + +using MEOS.NET.Enums; +using MEOS.NET.Functions; +using MEOS.NET.Structures; + +namespace MEOS.NET.Types +{ + /// A walk over an R-tree's entries in order of distance from a query. MEOS registers it in no enum, so it names no temptype. + [System.CodeDom.Compiler.GeneratedCode("MEOS.NET.ObjectGen", "0.1.0")] + public class RTreeNNCursor : Value + { + internal RTreeNNCursor(IntPtr ptr) : base(ptr) { } + + public void Close() + => Meos.RtreeNnCursorClose(this.Ptr); + + public static RTreeNNCursor? Open(RTree rtree, IntPtr query) + => MEOSFactory.WrapRTreeNNCursor(Meos.RtreeNnCursorOpen(rtree.Ptr, query)); + + } +} diff --git a/MEOS.NET/Types/SPNNCursor.g.cs b/MEOS.NET/Types/SPNNCursor.g.cs new file mode 100644 index 0000000..6ad4c3a --- /dev/null +++ b/MEOS.NET/Types/SPNNCursor.g.cs @@ -0,0 +1,24 @@ +#nullable enable + +using System.Runtime.InteropServices; + +using MEOS.NET.Enums; +using MEOS.NET.Functions; +using MEOS.NET.Structures; + +namespace MEOS.NET.Types +{ + /// The SP-tree's nearest-neighbour walk, the R-tree cursor's sibling. MEOS registers it in no enum, so it names no temptype. + [System.CodeDom.Compiler.GeneratedCode("MEOS.NET.ObjectGen", "0.1.0")] + public class SPNNCursor : Value + { + internal SPNNCursor(IntPtr ptr) : base(ptr) { } + + public void Close() + => Meos.SptreeNnCursorClose(this.Ptr); + + public static SPNNCursor? Open(SPTree sptree, IntPtr query) + => MEOSFactory.WrapSPNNCursor(Meos.SptreeNnCursorOpen(sptree.Ptr, query)); + + } +} diff --git a/MEOS.NET/Types/TBigint.g.cs b/MEOS.NET/Types/TBigint.g.cs index 5105d83..8fa2835 100644 --- a/MEOS.NET/Types/TBigint.g.cs +++ b/MEOS.NET/Types/TBigint.g.cs @@ -93,6 +93,9 @@ public long StartValue() } } + public long[] Values() + => Meos.TbigintValues(this.Ptr); + public static Temporal? FromBaseTemp(long i, Temporal temp) => MEOSFactory.WrapTemporal(Meos.TbigintFromBaseTemp(i, temp.Ptr));