branches/gmyth-0.1b/src/gmyth_util.h
branchtrunk
changeset 360 6d5596b9eb95
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/branches/gmyth-0.1b/src/gmyth_util.h	Wed Feb 14 21:28:49 2007 +0000
     1.3 @@ -0,0 +1,66 @@
     1.4 +/**
     1.5 +* GMyth Library
     1.6 +*
     1.7 +* @file gmyth/gmyth_util.h
     1.8 +* 
     1.9 +* @brief <p> This component provides utility functions.
    1.10 +* 
    1.11 +* Copyright (C) 2006 INdT - Instituto Nokia de Tecnologia.
    1.12 +* @author Hallyson Luiz de Morais Melo <hallyson.melo@indt.org.br>
    1.13 +*
    1.14 +*//*
    1.15 +* 
    1.16 +* This program is free software; you can redistribute it and/or modify
    1.17 +* it under the terms of the GNU Lesser General Public License as published by
    1.18 +* the Free Software Foundation; either version 2 of the License, or
    1.19 +* (at your option) any later version.
    1.20 +*
    1.21 +* This program is distributed in the hope that it will be useful,
    1.22 +* but WITHOUT ANY WARRANTY; without even the implied warranty of
    1.23 +* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    1.24 +* GNU General Public License for more details.
    1.25 +*
    1.26 +* You should have received a copy of the GNU Lesser General Public License
    1.27 +* along with this program; if not, write to the Free Software
    1.28 +* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
    1.29 +*/
    1.30 +
    1.31 +#ifndef GMYTH_UTIL_H_
    1.32 +#define GMYTH_UTIL_H_
    1.33 +
    1.34 +#include <time.h>
    1.35 +#include <glib.h>
    1.36 +
    1.37 +#include "gmyth_stringlist.h"
    1.38 +#include "gmyth_backendinfo.h"
    1.39 +
    1.40 +G_BEGIN_DECLS
    1.41 +
    1.42 +GString 		*gmyth_util_time_to_isoformat(time_t time_value);
    1.43 +GString 		*gmyth_util_time_to_string   (time_t time_value);
    1.44 +time_t      gmyth_util_string_to_time   (GString* time_str);
    1.45 +gint64     	gmyth_util_decode_long_long (GMythStringList *strlist, 
    1.46 +                                         guint offset);
    1.47 +
    1.48 +gchar* 			gmyth_util_time_to_isoformat_from_time_val_fmt ( const gchar *fmt_string, const GTimeVal* time_val );
    1.49 +
    1.50 +GTimeVal		*gmyth_util_string_to_time_val_fmt ( const gchar *fmt_string, const gchar* time_str );
    1.51 +
    1.52 +GTimeVal		*gmyth_util_string_to_time_val ( const gchar* time_str );
    1.53 +
    1.54 +gchar 			*gmyth_util_time_to_isoformat_from_time_val( const GTimeVal *time);
    1.55 +gchar			*gmyth_util_time_to_mythformat_from_time_val ( const GTimeVal* time );
    1.56 +
    1.57 +gchar				*gmyth_util_time_to_string_only_date ( const GTimeVal* time );
    1.58 +
    1.59 +gchar				*gmyth_util_time_to_string_only_time ( const GTimeVal* time );
    1.60 +
    1.61 +gchar				*gmyth_util_time_to_string_from_time_val ( const GTimeVal *time_val );
    1.62 +
    1.63 +struct tm		*gmyth_util_time_val_to_date ( const GTimeVal* time );
    1.64 +
    1.65 +gboolean 		gmyth_util_file_exists (GMythBackendInfo *backend_info, const gchar* filename);
    1.66 +
    1.67 +G_END_DECLS
    1.68 +	
    1.69 +#endif /*GMYTH_UTIL_H_*/