Re: [Vala] Need help with string

2009-09-03 Thread Nicolas
Hi Abderrahim, I use this: using GLib; public static void main(string[] args) { string contents; try { FileUtils.get_contents(test.txt, out contents); } catch (FileError err) { stdout.printf(error); } var info = contents.str([INFO]); if (info != null) { var needed_text =

Re: [Vala] Wrapping Errors

2009-09-03 Thread Phil Housley
2009/8/22 Jan Hudec b...@ucw.cz: On Thu, Aug 20, 2009 at 22:09:21 -0400, Yu Feng wrote: GError doesn't support error wrapping as Java does. Is GLib is purposely avoiding it? If not, it will become a useful feature as the number of libraries that uses GError grows, as the feature has already

Re: [Vala] Need help with string

2009-09-03 Thread George Farris
On Wed, 2009-09-02 at 23:33 +0200, Nicolas wrote: Hi Matías, Thanks for your response, i will try tomorrow. But my file is not like this : [INFO] test=yes test=no but like this : [INFO] blah bla here blah blah there blah blah again This kind of file turns out to be

Re: [Vala] Wrapping Errors

2009-09-03 Thread Yu Feng
On Thu, 2009-09-03 at 13:38 +0100, Phil Housley wrote: 2009/8/22 Jan Hudec b...@ucw.cz: On Thu, Aug 20, 2009 at 22:09:21 -0400, Yu Feng wrote: GError doesn't support error wrapping as Java does. Is GLib is purposely avoiding it? If not, it will become a useful feature as the number of

[Vala] Very basic question.. about strings and arrays...

2009-09-03 Thread Arkadi Viner
Hello every body. I have some function in my code: public void execProgram(string working_dir, string[] argv) This function executes some program. Here is how I can call it successfully: execProgram(/,{ls, -l ,-h}); But, I want to call it another way. something like that: public void