summaryrefslogtreecommitdiffstats
path: root/src/tdebluezioslave/bluetooth/tdeiobluetooth.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/tdebluezioslave/bluetooth/tdeiobluetooth.h')
-rw-r--r--src/tdebluezioslave/bluetooth/tdeiobluetooth.h56
1 files changed, 56 insertions, 0 deletions
diff --git a/src/tdebluezioslave/bluetooth/tdeiobluetooth.h b/src/tdebluezioslave/bluetooth/tdeiobluetooth.h
new file mode 100644
index 0000000..7b881f2
--- /dev/null
+++ b/src/tdebluezioslave/bluetooth/tdeiobluetooth.h
@@ -0,0 +1,56 @@
+//-*-c++-*-
+/***************************************************************************
+ * Copyright (C) 2003 by Fred Schaettgen *
+ * *
+ * This program 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 2 of the License, or *
+ * (at your option) any later version. *
+ ***************************************************************************/
+
+#ifndef _TDEIOBT_H_
+#define _TDEIOBT_H_
+
+#include <tdeio/forwardingslavebase.h>
+#include <vector>
+
+#include <adapterImpl.h>
+#include <objectmanagerImpl.h>
+
+class TDEioBluetooth : public TDEIO::ForwardingSlaveBase
+{
+ Q_OBJECT
+
+public:
+ TDEioBluetooth(const TQCString &protocol, const TQCString &pool_socket, const TQCString &app_socket);
+ virtual ~TDEioBluetooth();
+ virtual void closeConnection();
+ virtual void stat(const KURL &url);
+ virtual void listDir(const KURL &url);
+
+protected:
+ virtual bool rewriteURL(const KURL &url, KURL &newUrl);
+
+private:
+ void createTopLevelEntry(TDEIO::UDSEntry& entry);
+ bool listDevice(TDEIO::UDSEntry &entry, const TQString &path, const KURL &url);
+ bool listDevices(TQValueList<TDEIO::UDSEntry> &list, const KURL &url);
+ bool listServices(TQValueList<TDEIO::UDSEntry> &list, const KURL &url);
+ bool createDirEntry(TDEIO::UDSEntry &entry, const TQString &title,
+ const TQString &dir = TQString::null, const TQString &mimeType = "inode/directory");
+ void addAtom(TDEIO::UDSEntry &entry, TDEIO::UDSAtomTypes type, TQString s);
+ void addAtom(TDEIO::UDSEntry &entry, TDEIO::UDSAtomTypes type, long l);
+
+ TDEBluetooth::AdapterImpl *adapter;
+ TDEBluetooth::ObjectManagerImpl *manager;
+
+private slots:
+ void slotAddDevice(const TQString &address);
+ void slotAddService(const KURL &url, const TQString uuid);
+ void slotRemoveDevice(const TQString &address);
+ void slotAdapterPowerOnChanged(const TQString & path, bool state) ;
+
+};
+
+#endif //TDEIOBT