/* * Copyright (C) 2012 - Juan Ferrer Toribio * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ #ifndef DB_ROW_H #define DB_ROW_H #include #define DB_TYPE_ROW (db_row_get_type()) typedef struct _DbRow DbRow; /** * DbRow: * @value:(array): a #GValue array * @position: the position of the row in the DbModel * @len: the number of fields * * Holds the data and information of a row. **/ struct _DbRow { GValue * value; gint position; gint len; }; GType db_row_get_type (); DbRow * db_row_new (gint len, gint position); void db_row_free (DbRow * row); DbRow * db_row_copy (const DbRow * row); const GValue * db_row_get_value (const DbRow * row, gint index); gint db_row_get_position (const DbRow * row); #endif