/* lowlevel.c generated by valac 0.14.2, the Vala compiler
 * generated from lowlevel.vala, do not modify */


#include <glib.h>
#include <glib-object.h>
#include <fsobasics.h>
#include <stdlib.h>
#include <string.h>


#define FSO_GSM_TYPE_LOW_LEVEL (fso_gsm_low_level_get_type ())
#define FSO_GSM_LOW_LEVEL(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), FSO_GSM_TYPE_LOW_LEVEL, FsoGsmLowLevel))
#define FSO_GSM_IS_LOW_LEVEL(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), FSO_GSM_TYPE_LOW_LEVEL))
#define FSO_GSM_LOW_LEVEL_GET_INTERFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), FSO_GSM_TYPE_LOW_LEVEL, FsoGsmLowLevelIface))

typedef struct _FsoGsmLowLevel FsoGsmLowLevel;
typedef struct _FsoGsmLowLevelIface FsoGsmLowLevelIface;

#define FSO_GSM_TYPE_NULL_LOW_LEVEL (fso_gsm_null_low_level_get_type ())
#define FSO_GSM_NULL_LOW_LEVEL(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), FSO_GSM_TYPE_NULL_LOW_LEVEL, FsoGsmNullLowLevel))
#define FSO_GSM_NULL_LOW_LEVEL_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), FSO_GSM_TYPE_NULL_LOW_LEVEL, FsoGsmNullLowLevelClass))
#define FSO_GSM_IS_NULL_LOW_LEVEL(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), FSO_GSM_TYPE_NULL_LOW_LEVEL))
#define FSO_GSM_IS_NULL_LOW_LEVEL_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), FSO_GSM_TYPE_NULL_LOW_LEVEL))
#define FSO_GSM_NULL_LOW_LEVEL_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), FSO_GSM_TYPE_NULL_LOW_LEVEL, FsoGsmNullLowLevelClass))

typedef struct _FsoGsmNullLowLevel FsoGsmNullLowLevel;
typedef struct _FsoGsmNullLowLevelClass FsoGsmNullLowLevelClass;
typedef struct _FsoGsmNullLowLevelPrivate FsoGsmNullLowLevelPrivate;

struct _FsoGsmLowLevelIface {
	GTypeInterface parent_iface;
	gboolean (*poweron) (FsoGsmLowLevel* self);
	gboolean (*poweroff) (FsoGsmLowLevel* self);
	gboolean (*suspend) (FsoGsmLowLevel* self);
	gboolean (*resume) (FsoGsmLowLevel* self);
};

struct _FsoGsmNullLowLevel {
	FsoFrameworkAbstractObject parent_instance;
	FsoGsmNullLowLevelPrivate * priv;
};

struct _FsoGsmNullLowLevelClass {
	FsoFrameworkAbstractObjectClass parent_class;
};


static gpointer fso_gsm_null_low_level_parent_class = NULL;
static FsoGsmLowLevelIface* fso_gsm_null_low_level_fso_gsm_low_level_parent_iface = NULL;

GType fso_gsm_low_level_get_type (void) G_GNUC_CONST;
gboolean fso_gsm_low_level_poweron (FsoGsmLowLevel* self);
gboolean fso_gsm_low_level_poweroff (FsoGsmLowLevel* self);
gboolean fso_gsm_low_level_suspend (FsoGsmLowLevel* self);
gboolean fso_gsm_low_level_resume (FsoGsmLowLevel* self);
GType fso_gsm_null_low_level_get_type (void) G_GNUC_CONST;
enum  {
	FSO_GSM_NULL_LOW_LEVEL_DUMMY_PROPERTY
};
static gchar* fso_gsm_null_low_level_real_repr (FsoFrameworkAbstractObject* base);
static gboolean fso_gsm_null_low_level_real_poweron (FsoGsmLowLevel* base);
static gboolean fso_gsm_null_low_level_real_poweroff (FsoGsmLowLevel* base);
static gboolean fso_gsm_null_low_level_real_suspend (FsoGsmLowLevel* base);
static gboolean fso_gsm_null_low_level_real_resume (FsoGsmLowLevel* base);
FsoGsmNullLowLevel* fso_gsm_null_low_level_new (void);
FsoGsmNullLowLevel* fso_gsm_null_low_level_construct (GType object_type);


/**
     * Power the device and prepare for AT mode
     **/
gboolean fso_gsm_low_level_poweron (FsoGsmLowLevel* self) {
	g_return_val_if_fail (self != NULL, FALSE);
	return FSO_GSM_LOW_LEVEL_GET_INTERFACE (self)->poweron (self);
}


/**
     * Power off the device
     **/
gboolean fso_gsm_low_level_poweroff (FsoGsmLowLevel* self) {
	g_return_val_if_fail (self != NULL, FALSE);
	return FSO_GSM_LOW_LEVEL_GET_INTERFACE (self)->poweroff (self);
}


/**
     * Prepare device for suspend
     **/
gboolean fso_gsm_low_level_suspend (FsoGsmLowLevel* self) {
	g_return_val_if_fail (self != NULL, FALSE);
	return FSO_GSM_LOW_LEVEL_GET_INTERFACE (self)->suspend (self);
}


/**
     * Recover from suspend
     **/
gboolean fso_gsm_low_level_resume (FsoGsmLowLevel* self) {
	g_return_val_if_fail (self != NULL, FALSE);
	return FSO_GSM_LOW_LEVEL_GET_INTERFACE (self)->resume (self);
}


static void fso_gsm_low_level_base_init (FsoGsmLowLevelIface * iface) {
	static gboolean initialized = FALSE;
	if (!initialized) {
		initialized = TRUE;
	}
}


GType fso_gsm_low_level_get_type (void) {
	static volatile gsize fso_gsm_low_level_type_id__volatile = 0;
	if (g_once_init_enter (&fso_gsm_low_level_type_id__volatile)) {
		static const GTypeInfo g_define_type_info = { sizeof (FsoGsmLowLevelIface), (GBaseInitFunc) fso_gsm_low_level_base_init, (GBaseFinalizeFunc) NULL, (GClassInitFunc) NULL, (GClassFinalizeFunc) NULL, NULL, 0, 0, (GInstanceInitFunc) NULL, NULL };
		GType fso_gsm_low_level_type_id;
		fso_gsm_low_level_type_id = g_type_register_static (G_TYPE_INTERFACE, "FsoGsmLowLevel", &g_define_type_info, 0);
		g_type_interface_add_prerequisite (fso_gsm_low_level_type_id, FSO_FRAMEWORK_TYPE_ABSTRACT_OBJECT);
		g_once_init_leave (&fso_gsm_low_level_type_id__volatile, fso_gsm_low_level_type_id);
	}
	return fso_gsm_low_level_type_id__volatile;
}


static gchar* fso_gsm_null_low_level_real_repr (FsoFrameworkAbstractObject* base) {
	FsoGsmNullLowLevel * self;
	gchar* result = NULL;
	gchar* _tmp0_;
	self = (FsoGsmNullLowLevel*) base;
	_tmp0_ = g_strdup ("");
	result = _tmp0_;
	return result;
}


static gboolean fso_gsm_null_low_level_real_poweron (FsoGsmLowLevel* base) {
	FsoGsmNullLowLevel * self;
	gboolean result = FALSE;
	FsoFrameworkLogger* _tmp0_;
	self = (FsoGsmNullLowLevel*) base;
	_tmp0_ = ((FsoFrameworkAbstractObject*) self)->logger;
	fso_framework_logger_warning (_tmp0_, "NullLowlevel::poweron() - this is probably not what you want");
	result = TRUE;
	return result;
}


static gboolean fso_gsm_null_low_level_real_poweroff (FsoGsmLowLevel* base) {
	FsoGsmNullLowLevel * self;
	gboolean result = FALSE;
	FsoFrameworkLogger* _tmp0_;
	self = (FsoGsmNullLowLevel*) base;
	_tmp0_ = ((FsoFrameworkAbstractObject*) self)->logger;
	fso_framework_logger_warning (_tmp0_, "NullLowlevel::poweroff() - this is probably not what you want");
	result = TRUE;
	return result;
}


static gboolean fso_gsm_null_low_level_real_suspend (FsoGsmLowLevel* base) {
	FsoGsmNullLowLevel * self;
	gboolean result = FALSE;
	FsoFrameworkLogger* _tmp0_;
	self = (FsoGsmNullLowLevel*) base;
	_tmp0_ = ((FsoFrameworkAbstractObject*) self)->logger;
	fso_framework_logger_warning (_tmp0_, "NullLowlevel::suspend() - this is probably not what you want");
	result = TRUE;
	return result;
}


static gboolean fso_gsm_null_low_level_real_resume (FsoGsmLowLevel* base) {
	FsoGsmNullLowLevel * self;
	gboolean result = FALSE;
	FsoFrameworkLogger* _tmp0_;
	self = (FsoGsmNullLowLevel*) base;
	_tmp0_ = ((FsoFrameworkAbstractObject*) self)->logger;
	fso_framework_logger_warning (_tmp0_, "NullLowlevel::resume() - this is probably not what you want");
	result = TRUE;
	return result;
}


FsoGsmNullLowLevel* fso_gsm_null_low_level_construct (GType object_type) {
	FsoGsmNullLowLevel * self = NULL;
	self = (FsoGsmNullLowLevel*) fso_framework_abstract_object_construct (object_type);
	return self;
}


FsoGsmNullLowLevel* fso_gsm_null_low_level_new (void) {
	return fso_gsm_null_low_level_construct (FSO_GSM_TYPE_NULL_LOW_LEVEL);
}


static void fso_gsm_null_low_level_class_init (FsoGsmNullLowLevelClass * klass) {
	fso_gsm_null_low_level_parent_class = g_type_class_peek_parent (klass);
	FSO_FRAMEWORK_ABSTRACT_OBJECT_CLASS (klass)->repr = fso_gsm_null_low_level_real_repr;
}


static void fso_gsm_null_low_level_fso_gsm_low_level_interface_init (FsoGsmLowLevelIface * iface) {
	fso_gsm_null_low_level_fso_gsm_low_level_parent_iface = g_type_interface_peek_parent (iface);
	iface->poweron = (gboolean (*)(FsoGsmLowLevel*)) fso_gsm_null_low_level_real_poweron;
	iface->poweroff = (gboolean (*)(FsoGsmLowLevel*)) fso_gsm_null_low_level_real_poweroff;
	iface->suspend = (gboolean (*)(FsoGsmLowLevel*)) fso_gsm_null_low_level_real_suspend;
	iface->resume = (gboolean (*)(FsoGsmLowLevel*)) fso_gsm_null_low_level_real_resume;
}


static void fso_gsm_null_low_level_instance_init (FsoGsmNullLowLevel * self) {
}


GType fso_gsm_null_low_level_get_type (void) {
	static volatile gsize fso_gsm_null_low_level_type_id__volatile = 0;
	if (g_once_init_enter (&fso_gsm_null_low_level_type_id__volatile)) {
		static const GTypeInfo g_define_type_info = { sizeof (FsoGsmNullLowLevelClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) fso_gsm_null_low_level_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (FsoGsmNullLowLevel), 0, (GInstanceInitFunc) fso_gsm_null_low_level_instance_init, NULL };
		static const GInterfaceInfo fso_gsm_low_level_info = { (GInterfaceInitFunc) fso_gsm_null_low_level_fso_gsm_low_level_interface_init, (GInterfaceFinalizeFunc) NULL, NULL};
		GType fso_gsm_null_low_level_type_id;
		fso_gsm_null_low_level_type_id = g_type_register_static (FSO_FRAMEWORK_TYPE_ABSTRACT_OBJECT, "FsoGsmNullLowLevel", &g_define_type_info, 0);
		g_type_add_interface_static (fso_gsm_null_low_level_type_id, FSO_GSM_TYPE_LOW_LEVEL, &fso_gsm_low_level_info);
		g_once_init_leave (&fso_gsm_null_low_level_type_id__volatile, fso_gsm_null_low_level_type_id);
	}
	return fso_gsm_null_low_level_type_id__volatile;
}



