Re: csv (comma separated value) file
- From: Andrea Zagli <azagli inwind it>
- To: gtk-list gnome org, gtk-app-devel-list gnome org
- Subject: Re: csv (comma separated value) file
- Date: Mon, 03 Aug 2009 19:01:57 +0200
Il giorno lun 03 ago 2009 18:45:28 CEST, Tristan Van Berkom ha scritto:
On Mon, Aug 3, 2009 at 12:03 PM, Andrea Zagli<azagli inwind it> wrote:
i didn't find nothing about to manage (read/write) csv files with glib
do you know about something that i didn't find?
Currently its pretty easy using g_file_get_contents()/g_strsplit() if you
can have it all in ram, or using GIO and again, g_strsplit() on a per line
basis if you need to stream it.
yet in fact i developed like this for a very small project. but i
wanted to recycle the code by putting/found it in a library
and with a more accurate parsing; for example i cannot split by ","
beacause "," can be inside string fields
then i thought to make a more accurate function with some parameters
(ex. the character separating the fields, if the first line of the
file are the names of the fields, etc.)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]