Re: [Vala] writing a vapi

Most of them a self-explanatory like cheader_filename and lower_case_cprefix
but for

My wild guess is that this one is for DBus signatures.

IntegerType (rank = 6)

This is for types that are wrappers of integral types (int, byte, ...)
I believe the rank is to help vala determine which of these can be
safely cast to each other.


This appears to be for types that are actually wrappers of types that
gobject knows about (int, string, GBoxed, ...)


This denotes the position of the instance argument in a method, e.g.:
C signature: int fputs(const char *s, FILE *stream);
Vala signature:
[CCode (cname = "fputs", instance_pos = -1)]
public void puts (string s);

Here, instance_pos being -1 signifies that stream is the last argument.

There are a couple of non-gobject vapis distributed with vala, like
the sdl ones, that might be helpful.


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]