forked from geoloqi/MapAttack-iPhone
-
Notifications
You must be signed in to change notification settings - Fork 1
/
GeoloqiSocketClient.h
45 lines (38 loc) · 1.18 KB
/
GeoloqiSocketClient.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
//
// GeoloqiSocketClient.h
//
// Created by Aaron Parecki on 4/9/11.
// Copyright 2011 Geoloqi LLC. All rights reserved.
//
#import <Foundation/Foundation.h>
#import <CoreLocation/CoreLocation.h>
#include "FTLocationSimulator.h"
//#import "Database.h"
#import "sqlite3.h" // Import SQLITE3 header file
#define LQ_SOCKET_HOST @"loki.geoloqi.com"
#define LQ_SOCKET_PORT 40000
@class AsyncUdpSocket;
// class GeoloqiSocketClient extends NSObject implements CLLocationManagerDelegate
@interface GeoloqiSocketClient : NSObject <CLLocationManagerDelegate>
{
AsyncUdpSocket *asyncSocket;
GeoloqiSocketClient *geoloqiClient;
sqlite3 *db; // Create an object of the type sqlite3d
#ifdef FAKE_CORE_LOCATION
FTLocationSimulator *locationManager;
#else
CLLocationManager *locationManager;
#endif
CLLocation *currentLocation;
BOOL locationUpdatesOn;
CLLocationDistance distanceFilterDistance;
NSTimeInterval trackingFrequency;
NSTimeInterval sendingFrequency;
}
- (void)normalConnect;
- (NSData *)dataFromLocation:(CLLocation *)location;
- (void)startMonitoringLocation;
- (void)stopMonitoringLocation;
// TODO: Make a delegate protocol.
// TODO: Send CLLocation to server.
@end