00001 #ifndef __sa_sensor_tap_api_h__ 00002 #define __sa_sensor_tap_api_h__ 00003 00004 #include "ac_app_context.h" 00005 #include "application_config.h" 00006 00007 class Sensor_tap; 00008 00009 Sensor_tap* new_Sensor_tap(ac_AppContext* aAppContext, 00010 bool aDouble, const char* aName); 00011 00012 void delete_Sensor_tap(Sensor_tap* obj); 00013 00014 // -------------------------------------------------- 00015 // sensor array integration 00016 // -------------------------------------------------- 00017 00018 #if defined(SA_ARRAY_INTEGRATION) 00019 00020 #if __SINGLETAP_ENABLED__ 00021 #define DECLARE_SENSOR_singletap Sensor_tap* iSensor_singletap 00022 #define SENSOR_SINGLETAP_DESTROY delete_Sensor_tap(self->iSensor_singletap); self->iSensor_singletap = NULL; 00023 #define SENSOR_SINGLETAP_CREATE 00024 #define SENSOR_SINGLETAP_START sa_typical_qt_sensor_create(self->iSensor_singletap = new_Sensor_tap(self->ac, false, "singletap"), "singletap sensor initialization") 00025 #define SENSOR_SINGLETAP_STOP SENSOR_SINGLETAP_DESTROY 00026 #define SENSOR_SINGLETAP_IS_RUNNING (self->iSensor_singletap != NULL) 00027 #define SENSOR_SINGLETAP_RECONFIGURE(key, value) sa_reconfigure_ignore_all_keys 00028 #else 00029 #define DECLARE_SENSOR_singletap 00030 #endif // __SINGLETAP_ENABLED__ 00031 00032 #if __DOUBLETAP_ENABLED__ 00033 #define DECLARE_SENSOR_doubletap Sensor_tap* iSensor_doubletap 00034 #define SENSOR_DOUBLETAP_DESTROY delete_Sensor_tap(self->iSensor_doubletap); self->iSensor_doubletap = NULL; 00035 #define SENSOR_DOUBLETAP_CREATE 00036 #define SENSOR_DOUBLETAP_START sa_typical_qt_sensor_create(self->iSensor_doubletap = new_Sensor_tap(self->ac, true, "doubletap"), "doubletap sensor initialization") 00037 #define SENSOR_DOUBLETAP_STOP SENSOR_DOUBLETAP_DESTROY 00038 #define SENSOR_DOUBLETAP_IS_RUNNING (self->iSensor_doubletap != NULL) 00039 #define SENSOR_DOUBLETAP_RECONFIGURE(key, value) sa_reconfigure_ignore_all_keys 00040 #else 00041 #define DECLARE_SENSOR_doubletap 00042 #endif // __DOUBLETAP_ENABLED__ 00043 00044 #endif // defined(SA_ARRAY_INTEGRATION) 00045 00046 #endif /* __sa_sensor_tap_api_h__ */ 00047 00048 /** 00049 00050 Copyright 2011 Helsinki Institute for Information Technology (HIIT) 00051 and the authors. All rights reserved. 00052 00053 Authors: Tero Hasu <tero.hasu@hut.fi> 00054 00055 Permission is hereby granted, free of charge, to any person 00056 obtaining a copy of this software and associated documentation files 00057 (the "Software"), to deal in the Software without restriction, 00058 including without limitation the rights to use, copy, modify, merge, 00059 publish, distribute, sublicense, and/or sell copies of the Software, 00060 and to permit persons to whom the Software is furnished to do so, 00061 subject to the following conditions: 00062 00063 The above copyright notice and this permission notice shall be 00064 included in all copies or substantial portions of the Software. 00065 00066 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 00067 EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 00068 MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 00069 NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS 00070 BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN 00071 ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 00072 CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 00073 SOFTWARE. 00074 00075 **/ 00076
ContextLogger2—ContextLogger2 Logger Daemon Internals—Generated on Mon May 2 13:49:56 2011 by Doxygen 1.6.1