Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documentation for translating IDL files. #2

Open
VorpalBlade opened this issue Feb 22, 2018 · 0 comments
Open

Documentation for translating IDL files. #2

VorpalBlade opened this issue Feb 22, 2018 · 0 comments

Comments

@VorpalBlade
Copy link

I have been looking into how to manually translate IDL files (or perhaps write a tool at some point to do so) to the required ctypes definitions used in this library, but I'm somewhat confused as to how sequences are handled. Are you supposed to represent something like this:

struct SomeElement
{
    string someData;
    // ... and some other fields
};

struct SomeKey
{
    unsigned long long low;   // first eight bytes
    unsigned long long high;  // last eight bytes
};

struct SomeSequence
{
    long id;
    unsigned long sequenceIndex;
    sequence<SomeElement> elements;
};
#pragma keylist SomeSequence id.low id.high sequenceIndex

Specifically I'm unsure of how to handle:

  1. Sequences. Do I have to use DDSSequence and manually serialize the elements to the _buffer member? (I don't really know how the low level API used by the generated files from idlpp works, I have previously only used the isocpp2 generator, I looked at the code now and it seems to treat everything as void* pointers and call C API functions to allocate for example arrays)
  2. Keys: Do I actually need to care about this at all? Looking at DDSKeyValue for example I don't see anything specific to mark what part is the key, like in the IDL file.

It would be great to either have some slightly non-trivial examples included, or perhaps some basic documentation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant