Have you tried

 static construct {
      ...
    }

?

(see https://live.gnome.org/Vala/Tutorial)

m.

2012/10/23 bsquared <[email protected]>:
> Hello,
>
> Is it possible to initialize a static const HashSet?
> Similar to this from Java?
>
> 8< ------------------------------------------------
>     private static final Set<String> STATIC_SET;
>
>     static {
>         STATIC_SET = new HashSet<String>();
>         STATIC_SET.add("Data One");
>         STATIC_SET.add("Data Two");
>     }
>   ------------------------------------------------- >8
>
> Thank you.
> --
> Regards,
> Brian
>
> _______________________________________________
> vala-list mailing list
> [email protected]
> https://mail.gnome.org/mailman/listinfo/vala-list
_______________________________________________
vala-list mailing list
[email protected]
https://mail.gnome.org/mailman/listinfo/vala-list

Reply via email to