LCOV - code coverage report
Current view: top level - obj-x86_64-pc-linux-gnu/dist/include/mozilla/dom - MediaKeySystemAccessBinding.h (source / functions) Hit Total Coverage
Test: output.info Lines: 0 13 0.0 %
Date: 2017-07-14 16:53:18 Functions: 0 5 0.0 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : /* THIS FILE IS AUTOGENERATED FROM MediaKeySystemAccess.webidl BY Codegen.py - DO NOT EDIT */
       2             : 
       3             : #ifndef mozilla_dom_MediaKeySystemAccessBinding_h
       4             : #define mozilla_dom_MediaKeySystemAccessBinding_h
       5             : 
       6             : #include "js/RootingAPI.h"
       7             : #include "jspubtd.h"
       8             : #include "mozilla/ErrorResult.h"
       9             : #include "mozilla/dom/BindingDeclarations.h"
      10             : #include "mozilla/dom/Nullable.h"
      11             : 
      12             : namespace mozilla {
      13             : namespace dom {
      14             : 
      15             : class MediaKeySystemAccess;
      16             : struct MediaKeySystemAccessAtoms;
      17             : struct MediaKeySystemConfigurationAtoms;
      18             : struct MediaKeySystemMediaCapability;
      19             : struct MediaKeySystemMediaCapabilityAtoms;
      20             : struct NativePropertyHooks;
      21             : class ProtoAndIfaceCache;
      22             : 
      23             : } // namespace dom
      24             : } // namespace mozilla
      25             : 
      26             : namespace mozilla {
      27             : namespace dom {
      28             : 
      29             : enum class MediaKeysRequirement : uint8_t {
      30             :   Required,
      31             :   Optional,
      32             :   Not_allowed,
      33             :   EndGuard_
      34             : };
      35             : 
      36             : namespace MediaKeysRequirementValues {
      37             : extern const EnumEntry strings[4];
      38             : } // namespace MediaKeysRequirementValues
      39             : 
      40             : bool
      41             : ToJSValue(JSContext* aCx, MediaKeysRequirement aArgument, JS::MutableHandle<JS::Value> aValue);
      42             : 
      43             : 
      44           0 : struct MediaKeySystemMediaCapability : public DictionaryBase
      45             : {
      46             :   MOZ_INIT_OUTSIDE_CTOR nsString mContentType;
      47             :   MOZ_INIT_OUTSIDE_CTOR nsString mRobustness;
      48             : 
      49             :   MediaKeySystemMediaCapability();
      50             : 
      51             :   explicit inline MediaKeySystemMediaCapability(const FastDictionaryInitializer& )
      52             :   {
      53             :     // Do nothing here; this is used by our "Fast" subclass
      54             :   }
      55             : 
      56           0 :   explicit inline MediaKeySystemMediaCapability(const MediaKeySystemMediaCapability& aOther)
      57           0 :   {
      58           0 :     *this = aOther;
      59           0 :   }
      60             : 
      61             :   bool
      62             :   Init(JSContext* cx, JS::Handle<JS::Value> val, const char* sourceDescription = "Value", bool passedToJSImpl = false);
      63             : 
      64             :   bool
      65             :   Init(const nsAString& aJSON);
      66             : 
      67             :   bool
      68             :   ToObjectInternal(JSContext* cx, JS::MutableHandle<JS::Value> rval) const;
      69             : 
      70             :   bool
      71             :   ToJSON(nsAString& aJSON) const;
      72             : 
      73             :   void
      74             :   TraceDictionary(JSTracer* trc);
      75             : 
      76             :   MediaKeySystemMediaCapability&
      77             :   operator=(const MediaKeySystemMediaCapability& aOther);
      78             : 
      79             : private:
      80             :   static bool
      81             :   InitIds(JSContext* cx, MediaKeySystemMediaCapabilityAtoms* atomsCache);
      82             : };
      83             : 
      84             : namespace binding_detail {
      85             : struct FastMediaKeySystemMediaCapability : public MediaKeySystemMediaCapability
      86             : {
      87             :   inline FastMediaKeySystemMediaCapability()
      88             :     : MediaKeySystemMediaCapability(FastDictionaryInitializer())
      89             :   {
      90             :     // Doesn't matter what int we pass to the parent constructor
      91             :   }
      92             : };
      93             : } // namespace binding_detail
      94             : 
      95             : 
      96           0 : struct MediaKeySystemConfiguration : public DictionaryBase
      97             : {
      98             :   MOZ_INIT_OUTSIDE_CTOR Sequence<MediaKeySystemMediaCapability> mAudioCapabilities;
      99             :   MOZ_INIT_OUTSIDE_CTOR MediaKeysRequirement mDistinctiveIdentifier;
     100             :   MOZ_INIT_OUTSIDE_CTOR Sequence<nsString> mInitDataTypes;
     101             :   MOZ_INIT_OUTSIDE_CTOR nsString mLabel;
     102             :   MOZ_INIT_OUTSIDE_CTOR MediaKeysRequirement mPersistentState;
     103             :   MOZ_INIT_OUTSIDE_CTOR Optional<Sequence<nsString>> mSessionTypes;
     104             :   MOZ_INIT_OUTSIDE_CTOR Sequence<MediaKeySystemMediaCapability> mVideoCapabilities;
     105             : 
     106             :   MediaKeySystemConfiguration();
     107             : 
     108             :   explicit inline MediaKeySystemConfiguration(const FastDictionaryInitializer& )
     109             :   {
     110             :     // Do nothing here; this is used by our "Fast" subclass
     111             :   }
     112             : 
     113           0 :   explicit inline MediaKeySystemConfiguration(const MediaKeySystemConfiguration& aOther)
     114           0 :   {
     115           0 :     *this = aOther;
     116           0 :   }
     117             : 
     118             :   bool
     119             :   Init(JSContext* cx, JS::Handle<JS::Value> val, const char* sourceDescription = "Value", bool passedToJSImpl = false);
     120             : 
     121             :   bool
     122             :   Init(const nsAString& aJSON);
     123             : 
     124             :   bool
     125             :   ToObjectInternal(JSContext* cx, JS::MutableHandle<JS::Value> rval) const;
     126             : 
     127             :   bool
     128             :   ToJSON(nsAString& aJSON) const;
     129             : 
     130             :   void
     131             :   TraceDictionary(JSTracer* trc);
     132             : 
     133             :   MediaKeySystemConfiguration&
     134             :   operator=(const MediaKeySystemConfiguration& aOther);
     135             : 
     136             : private:
     137             :   static bool
     138             :   InitIds(JSContext* cx, MediaKeySystemConfigurationAtoms* atomsCache);
     139             : };
     140             : 
     141             : namespace binding_detail {
     142             : struct FastMediaKeySystemConfiguration : public MediaKeySystemConfiguration
     143             : {
     144             :   inline FastMediaKeySystemConfiguration()
     145             :     : MediaKeySystemConfiguration(FastDictionaryInitializer())
     146             :   {
     147             :     // Doesn't matter what int we pass to the parent constructor
     148             :   }
     149             : };
     150             : } // namespace binding_detail
     151             : 
     152             : 
     153             : namespace MediaKeySystemAccessBinding {
     154             : 
     155             :   typedef mozilla::dom::MediaKeySystemAccess NativeType;
     156             : 
     157             :   JSObject*
     158             :   DefineDOMInterface(JSContext* aCx, JS::Handle<JSObject*> aGlobal, JS::Handle<jsid> id, bool aDefineOnGlobal);
     159             : 
     160             :   const JSClass*
     161             :   GetJSClass();
     162             : 
     163             :   bool
     164             :   Wrap(JSContext* aCx, mozilla::dom::MediaKeySystemAccess* aObject, nsWrapperCache* aCache, JS::Handle<JSObject*> aGivenProto, JS::MutableHandle<JSObject*> aReflector);
     165             : 
     166             :   template <class T>
     167           0 :   inline JSObject* Wrap(JSContext* aCx, T* aObject, JS::Handle<JSObject*> aGivenProto)
     168             :   {
     169           0 :     JS::Rooted<JSObject*> reflector(aCx);
     170           0 :     return Wrap(aCx, aObject, aObject, aGivenProto, &reflector) ? reflector.get() : nullptr;
     171             :   }
     172             : 
     173             :   // We declare this as an array so that retrieving a pointer to this
     174             :   // binding's property hooks only requires compile/link-time resolvable
     175             :   // address arithmetic.  Declaring it as a pointer instead would require
     176             :   // doing a run-time load to fetch a pointer to this binding's property
     177             :   // hooks.  And then structures which embedded a pointer to this structure
     178             :   // would require a run-time load for proper initialization, which would
     179             :   // then induce static constructors.  Lots of static constructors.
     180             :   extern const NativePropertyHooks sNativePropertyHooks[];
     181             : 
     182             :   void
     183             :   CreateInterfaceObjects(JSContext* aCx, JS::Handle<JSObject*> aGlobal, ProtoAndIfaceCache& aProtoAndIfaceCache, bool aDefineOnGlobal);
     184             : 
     185             :   JS::Handle<JSObject*>
     186             :   GetProtoObjectHandle(JSContext* aCx);
     187             : 
     188             :   JS::Handle<JSObject*>
     189             :   GetConstructorObjectHandle(JSContext* aCx, bool aDefineOnGlobal = true);
     190             : 
     191             :   JSObject*
     192             :   GetConstructorObject(JSContext* aCx);
     193             : 
     194             : } // namespace MediaKeySystemAccessBinding
     195             : 
     196             : 
     197             : 
     198             : } // namespace dom
     199             : } // namespace mozilla
     200             : 
     201             : #endif // mozilla_dom_MediaKeySystemAccessBinding_h

Generated by: LCOV version 1.13