|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectims.devicemanager.BluetoothDataManager
public class BluetoothDataManager
This class provides the main components that are needed for connecting with a
Bluetooth device, hold the connection and to receive and read the input of
the device.
Copyright © 2014 by Daniela Blum
This file is part of GPSChildFinder.
GPSChildFinder is free software: you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the Free
Software Foundation, either version 3 of the License, or (at your option) any
later version.
This program is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
details.
You should have received a copy of the GNU General Public License along with
this program. If not, see http://www.gnu.org/licenses.
Constructor Summary | |
---|---|
BluetoothDataManager(android.bluetooth.BluetoothSocket bluetoothSocket)
Constructor which calls setupStreamReader() to read the input
from the socket. |
Method Summary | |
---|---|
void |
close()
Cleans up this class by closing the stream and reader and setting the BluetoothConnectThread.GETTING_GPS_INPUT to false. |
double |
getLatitude()
|
double |
getLongitude()
|
void |
readNMEASentences()
Is called when the Bluetooth socket is connected to a Bluetooth device. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public BluetoothDataManager(android.bluetooth.BluetoothSocket bluetoothSocket)
setupStreamReader()
to read the input
from the socket.
bluetoothSocket
- currently connected Bluetooth socketMethod Detail |
---|
public void readNMEASentences() throws java.io.IOException
getCoordinates(String)
is
called.
java.io.IOException
- when the connection get lost.public double getLatitude()
public double getLongitude()
public void close()
BluetoothConnectThread.GETTING_GPS_INPUT
to false.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |