Bug 886842 - Add clang trunk builds for ASan. r=froydnj
[gecko.git] / ipc / nfc / Nfc.h
blob1662a7bf6fe945b9f9b19d10d554c507b7c8a808
1 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* vim: set sw=2 ts=8 et ft=cpp: */
3 /* This Source Code Form is subject to the terms of the Mozilla Public
4 * License, v. 2.0. If a copy of the MPL was not distributed with this
5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
7 #ifndef mozilla_ipc_Nfc_h
8 #define mozilla_ipc_Nfc_h 1
10 #include <mozilla/dom/workers/Workers.h>
11 #include <mozilla/ipc/UnixSocket.h>
13 namespace mozilla {
14 namespace ipc {
16 class NfcConsumer : public mozilla::ipc::UnixSocketConsumer
18 public:
19 NfcConsumer(mozilla::dom::workers::WorkerCrossThreadDispatcher* aDispatcher);
20 virtual ~NfcConsumer() { }
21 void Shutdown();
22 private:
23 virtual void ReceiveSocketData(nsAutoPtr<UnixSocketRawData>& aMessage);
25 virtual void OnConnectSuccess();
26 virtual void OnConnectError();
27 virtual void OnDisconnect();
29 private:
30 nsRefPtr<mozilla::dom::workers::WorkerCrossThreadDispatcher> mDispatcher;
31 bool mShutdown;
34 } // namespace ipc
35 } // namepsace mozilla
37 #endif // mozilla_ipc_Nfc_h