branches/gmyth-0.1b/src/gmyth_epg.h
branchtrunk
changeset 320 22a17127789e
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/branches/gmyth-0.1b/src/gmyth_epg.h	Thu Feb 01 18:42:01 2007 +0000
     1.3 @@ -0,0 +1,75 @@
     1.4 +/**
     1.5 + * GMyth Library
     1.6 + *
     1.7 + * @file gmyth/gmyth_epg.h
     1.8 + * 
     1.9 + * @brief <p> GMythEPG class provides access to the program and channel data
    1.10 + * from the Electronic Program Guide (EPG) of the Mythtv backend.
    1.11 + *
    1.12 + * Copyright (C) 2006 INdT - Instituto Nokia de Tecnologia.
    1.13 + * @author Leonardo Sobral Cunha <leonardo.cunha@indt.org.br>
    1.14 + *
    1.15 + *//*
    1.16 + * 
    1.17 + * This program is free software; you can redistribute it and/or modify
    1.18 + * it under the terms of the GNU Lesser General Public License as published by
    1.19 + * the Free Software Foundation; either version 2 of the License, or
    1.20 + * (at your option) any later version.
    1.21 + *
    1.22 + * This program is distributed in the hope that it will be useful,
    1.23 + * but WITHOUT ANY WARRANTY; without even the implied warranty of
    1.24 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    1.25 + * GNU General Public License for more details.
    1.26 + *
    1.27 + * You should have received a copy of the GNU Lesser General Public License
    1.28 + * along with this program; if not, write to the Free Software
    1.29 + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
    1.30 + */
    1.31 +
    1.32 +#ifndef GMYTH_EPG_H_
    1.33 +#define GMYTH_EPG_H_
    1.34 +
    1.35 +#include <glib-object.h>
    1.36 +
    1.37 +#include "gmyth_query.h"
    1.38 +#include "gmyth_common.h"
    1.39 +
    1.40 +G_BEGIN_DECLS
    1.41 +
    1.42 +#define GMYTH_EPG_TYPE               (gmyth_epg_get_type ())
    1.43 +#define GMYTH_EPG(obj)               (G_TYPE_CHECK_INSTANCE_CAST ((obj), GMYTH_EPG_TYPE, GMythEPG))
    1.44 +#define GMYTH_EPG_CLASS(klass)       (G_TYPE_CHECK_CLASS_CAST ((klass), GMYTH_EPG_TYPE, GMythEPGClass))
    1.45 +#define IS_GMYTH_EPG(obj)            (G_TYPE_CHECK_INSTANCE_CAST ((obj), GMYTH_EPG_TYPE))
    1.46 +#define IS_GMYTH_EPG_CLASS(klass)    (G_TYPE_CHECK_CLASS_CAST ((klass), GMYTH_EPG_TYPE))
    1.47 +#define GMYTH_EPG_GET_CLASS(obj)     (G_TYPE_INSTANCE_GET_CLASS ((obj), GMYTH_EPG_TYPE, GMythEPGClass))
    1.48 +
    1.49 +typedef struct _GMythEPG         GMythEPG;
    1.50 +typedef struct _GMythEPGClass    GMythEPGClass;
    1.51 +
    1.52 +struct _GMythEPGClass
    1.53 +{
    1.54 +  GObjectClass parent_class;
    1.55 +
    1.56 +  /* callbacks */
    1.57 +  /* no one for now */
    1.58 +};
    1.59 +
    1.60 +struct _GMythEPG
    1.61 +{
    1.62 +    GObject parent;
    1.63 +
    1.64 +	GMythQuery *sqlquery;
    1.65 +};
    1.66 +
    1.67 +GType          gmyth_epg_get_type (void);
    1.68 +
    1.69 +GMythEPG* gmyth_epg_new (void);
    1.70 +
    1.71 +gboolean gmyth_epg_connect (GMythEPG *gmyth_epg, GMythBackendInfo *backend_info);
    1.72 +gboolean gmyth_epg_disconnect (GMythEPG *gmyth_epg);
    1.73 +
    1.74 +gint gmyth_epg_get_channel_list (GMythEPG *gmyth_epg, GList **glist_ptr);
    1.75 +gint gmyth_epg_get_program_list (GMythEPG *gmyth_epg, GList **proglist,
    1.76 +		const gint chanNum, GTimeVal *starttime, GTimeVal *endtime);
    1.77 +
    1.78 +#endif /*GMYTH_EPG_H_*/