Re: [Vala] Quick Question about parameter handling



On Sam, 2007-03-10 at 15:49 +0100, Zsombor wrote:
 I'm trying to create a vapi file for gnome-keyring, mapping most of
the functions are easy, but unfortunately there is a lots of methods,
which expects some 'out' parameters, and i can't figure out, how to do
that: 

It's in general similar to C#, use 'ref' for value types like int and
'out' for reference types.

For example: 
GnomeKeyringResult gnome_keyring_get_default_keyring_sync (char
**keyring);

KeyringResult get_default_keyring_sync (out string keyring);

or 
GnomeKeyringResult gnome_keyring_list_keyring_names_sync  (GList
**keyrings);

KeyringResult list_keyring_names_sync (out List<...> keyrings);

Jürg




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