internal Instance(IntPtr handle, StringAllocator allocator) { this.handle = handle; this.allocator = allocator; impl = Marshal.PtrToStructure <LilvInstanceImpl> (handle); descriptor = Marshal.PtrToStructure <LV2Sharp.LV2Descriptor> (impl.Lv2Descriptor); }
internal static Instance Get(IntPtr handle, StringAllocator allocator) => handle == IntPtr.Zero ? null : new Instance(handle, allocator);