search for: nbdgetsiz

Displaying 2 results from an estimated 2 matches for "nbdgetsiz".

Did you mean: nbdgetsize
2020 Apr 15
2
Re: [PATCH nbdkit UNFINISHED] Add the ability to write plugins in golang.
...: package nbdkitplugin type NBDKitFeature int const ( NBDKitFeatureGetSize NBDKitFeature = iota NBDKitFeaturePread ...other optional methods... ) type NBDKitPlugin interface { NBDGetFeatures() []NBDKitFeature NBDOpen(readonly bool) NBDClose() NBDGetSize() int64 NBDPRead(count uint32, offset uint64, flags uint32) ([]byte) ....many other methods... } var plugin *C.struct_nbdkit_plugin var pluginImpl NBDKitPlugin func PluginInit(name string, impl NBDKitPlugin) { pluginImpl = impl features = impl.GetFeatures()...
2020 Apr 10
3
[PATCH nbdkit UNFINISHED] Add the ability to write plugins in golang.
Sorry Dan, but I really do dislike golang with a passion :-) Here is a patch that allows you to write nbdkit plugins in golang. As with C, OCaml and Rust, you can write a plugin in Go which compiles directly to a .so file that can be loaded into golang, so in that sense it works completely differently from scripting language plugins like Perl and Python where there's an