Bumping manifests a=b2g-bump
[gecko.git] / dom / nfc / MozIsoDepTech.h
blob4f8f1adbf92ecaecb005e487bd020403c6a6ba05
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
2 * vim: set ts=2 et sw=2 tw=80:
4 * This Source Code Form is subject to the terms of the Mozilla Public
5 * License, v. 2.0. If a copy of the MPL was not distributed with this
6 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
8 #ifndef mozilla_dom_nfc_MozIsoDepTech_h__
9 #define mozilla_dom_nfc_MozIsoDepTech_h__
11 #include "mozilla/dom/MozNFCTagBinding.h"
12 #include "mozilla/dom/MozIsoDepTechBinding.h"
13 #include "nsCycleCollectionParticipant.h"
14 #include "nsWrapperCache.h"
15 #include "nsISupportsImpl.h"
16 #include "nsPIDOMWindow.h"
18 namespace mozilla {
19 namespace dom {
21 class Promise;
23 class MozIsoDepTech : public nsISupports,
24 public nsWrapperCache
26 public:
27 NS_DECL_CYCLE_COLLECTING_ISUPPORTS
28 NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(MozIsoDepTech)
30 already_AddRefed<Promise> Transceive(const Uint8Array& aCommand,
31 ErrorResult& aRv);
33 nsPIDOMWindow* GetParentObject() const { return mWindow; }
35 virtual JSObject* WrapObject(JSContext* aCx) MOZ_OVERRIDE;
37 static already_AddRefed<MozIsoDepTech>
38 Constructor(const GlobalObject& aGlobal, MozNFCTag& aNFCTag,
39 ErrorResult& aRv);
41 private:
42 MozIsoDepTech(nsPIDOMWindow* aWindow, MozNFCTag& aNFCTag);
43 virtual ~MozIsoDepTech();
45 nsRefPtr<nsPIDOMWindow> mWindow;
46 nsRefPtr<MozNFCTag> mTag;
48 static const NFCTechType mTechnology = NFCTechType::ISO_DEP;
51 } // namespace dom
52 } // namespace mozilla
54 #endif // mozilla_dom_nfc_MozIsoDepTech_h__