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

          Line data    Source code
       1             : /* THIS FILE IS AUTOGENERATED FROM CSSLexer.webidl BY Codegen.py - DO NOT EDIT */
       2             : 
       3             : #ifndef mozilla_dom_CSSLexerBinding_h
       4             : #define mozilla_dom_CSSLexerBinding_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 CSSLexer;
      16             : struct CSSLexerAtoms;
      17             : struct CSSTokenAtoms;
      18             : struct NativePropertyHooks;
      19             : class ProtoAndIfaceCache;
      20             : 
      21             : } // namespace dom
      22             : } // namespace mozilla
      23             : 
      24             : namespace mozilla {
      25             : namespace dom {
      26             : 
      27             : enum class CSSTokenType : uint8_t {
      28             :   Whitespace,
      29             :   Comment,
      30             :   Ident,
      31             :   Function,
      32             :   At,
      33             :   Id,
      34             :   Hash,
      35             :   Number,
      36             :   Dimension,
      37             :   Percentage,
      38             :   String,
      39             :   Bad_string,
      40             :   Url,
      41             :   Bad_url,
      42             :   Symbol,
      43             :   Includes,
      44             :   Dashmatch,
      45             :   Beginsmatch,
      46             :   Endsmatch,
      47             :   Containsmatch,
      48             :   Urange,
      49             :   Htmlcomment,
      50             :   EndGuard_
      51             : };
      52             : 
      53             : namespace CSSTokenTypeValues {
      54             : extern const EnumEntry strings[23];
      55             : } // namespace CSSTokenTypeValues
      56             : 
      57             : bool
      58             : ToJSValue(JSContext* aCx, CSSTokenType aArgument, JS::MutableHandle<JS::Value> aValue);
      59             : 
      60             : 
      61           0 : struct CSSToken : public DictionaryBase
      62             : {
      63             :   MOZ_INIT_OUTSIDE_CTOR uint32_t mEndOffset;
      64             :   MOZ_INIT_OUTSIDE_CTOR Optional<bool> mHasSign;
      65             :   MOZ_INIT_OUTSIDE_CTOR Optional<bool> mIsInteger;
      66             :   MOZ_INIT_OUTSIDE_CTOR Optional<double> mNumber;
      67             :   MOZ_INIT_OUTSIDE_CTOR uint32_t mStartOffset;
      68             :   MOZ_INIT_OUTSIDE_CTOR Optional<nsString> mText;
      69             :   MOZ_INIT_OUTSIDE_CTOR CSSTokenType mTokenType;
      70             : 
      71             :   CSSToken();
      72             : 
      73             :   explicit inline CSSToken(const FastDictionaryInitializer& )
      74             :   {
      75             :     // Do nothing here; this is used by our "Fast" subclass
      76             :   }
      77             : 
      78             :   explicit inline CSSToken(const CSSToken& aOther)
      79             :   {
      80             :     *this = aOther;
      81             :   }
      82             : 
      83             :   bool
      84             :   Init(JSContext* cx, JS::Handle<JS::Value> val, const char* sourceDescription = "Value", bool passedToJSImpl = false);
      85             : 
      86             :   bool
      87             :   Init(const nsAString& aJSON);
      88             : 
      89             :   bool
      90             :   ToObjectInternal(JSContext* cx, JS::MutableHandle<JS::Value> rval) const;
      91             : 
      92             :   bool
      93             :   ToJSON(nsAString& aJSON) const;
      94             : 
      95             :   void
      96             :   TraceDictionary(JSTracer* trc);
      97             : 
      98             :   CSSToken&
      99             :   operator=(const CSSToken& aOther);
     100             : 
     101             : private:
     102             :   static bool
     103             :   InitIds(JSContext* cx, CSSTokenAtoms* atomsCache);
     104             : };
     105             : 
     106             : namespace binding_detail {
     107             : struct FastCSSToken : public CSSToken
     108             : {
     109             :   inline FastCSSToken()
     110             :     : CSSToken(FastDictionaryInitializer())
     111             :   {
     112             :     // Doesn't matter what int we pass to the parent constructor
     113             :   }
     114             : };
     115             : } // namespace binding_detail
     116             : 
     117             : 
     118             : namespace CSSLexerBinding {
     119             : 
     120             :   typedef mozilla::dom::CSSLexer NativeType;
     121             : 
     122             :   bool
     123             :   ConstructorEnabled(JSContext* aCx, JS::Handle<JSObject*> aObj);
     124             : 
     125             :   JSObject*
     126             :   DefineDOMInterface(JSContext* aCx, JS::Handle<JSObject*> aGlobal, JS::Handle<jsid> id, bool aDefineOnGlobal);
     127             : 
     128             :   const JSClass*
     129             :   GetJSClass();
     130             : 
     131             :   bool
     132             :   Wrap(JSContext* aCx, mozilla::dom::CSSLexer* aObject, JS::Handle<JSObject*> aGivenProto, JS::MutableHandle<JSObject*> aReflector);
     133             : 
     134             :   // We declare this as an array so that retrieving a pointer to this
     135             :   // binding's property hooks only requires compile/link-time resolvable
     136             :   // address arithmetic.  Declaring it as a pointer instead would require
     137             :   // doing a run-time load to fetch a pointer to this binding's property
     138             :   // hooks.  And then structures which embedded a pointer to this structure
     139             :   // would require a run-time load for proper initialization, which would
     140             :   // then induce static constructors.  Lots of static constructors.
     141             :   extern const NativePropertyHooks sNativePropertyHooks[];
     142             : 
     143             :   void
     144             :   CreateInterfaceObjects(JSContext* aCx, JS::Handle<JSObject*> aGlobal, ProtoAndIfaceCache& aProtoAndIfaceCache, bool aDefineOnGlobal);
     145             : 
     146             :   JS::Handle<JSObject*>
     147             :   GetProtoObjectHandle(JSContext* aCx);
     148             : 
     149             :   JS::Handle<JSObject*>
     150             :   GetConstructorObjectHandle(JSContext* aCx, bool aDefineOnGlobal = true);
     151             : 
     152             :   JSObject*
     153             :   GetConstructorObject(JSContext* aCx);
     154             : 
     155             : } // namespace CSSLexerBinding
     156             : 
     157             : 
     158             : 
     159             : } // namespace dom
     160             : } // namespace mozilla
     161             : 
     162             : #endif // mozilla_dom_CSSLexerBinding_h

Generated by: LCOV version 1.13