LCOV - code coverage report
Current view: top level - obj-x86_64-pc-linux-gnu/dom/bindings - StorageTypeBinding.cpp (source / functions) Hit Total Coverage
Test: output.info Lines: 0 8 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 StorageType.webidl BY Codegen.py - DO NOT EDIT */
       2             : 
       3             : #include "StorageTypeBinding.h"
       4             : #include "jsapi.h"
       5             : #include "mozilla/dom/BindingDeclarations.h"
       6             : #include "mozilla/dom/NonRefcountedDOMObject.h"
       7             : 
       8             : namespace mozilla {
       9             : namespace dom {
      10             : 
      11             : namespace StorageTypeValues {
      12             : extern const EnumEntry strings[4] = {
      13             :   {"persistent", 10},
      14             :   {"temporary", 9},
      15             :   {"default", 7},
      16             :   { nullptr, 0 }
      17             : };
      18             : } // namespace StorageTypeValues
      19             : 
      20             : bool
      21           0 : ToJSValue(JSContext* aCx, StorageType aArgument, JS::MutableHandle<JS::Value> aValue)
      22             : {
      23           0 :   MOZ_ASSERT(uint32_t(aArgument) < ArrayLength(StorageTypeValues::strings));
      24             :   JSString* resultStr =
      25           0 :     JS_NewStringCopyN(aCx, StorageTypeValues::strings[uint32_t(aArgument)].value,
      26           0 :                       StorageTypeValues::strings[uint32_t(aArgument)].length);
      27           0 :   if (!resultStr) {
      28           0 :     return false;
      29             :   }
      30           0 :   aValue.setString(resultStr);
      31           0 :   return true;
      32             : }
      33             : 
      34             : 
      35             : } // namespace dom
      36             : } // namespace mozilla

Generated by: LCOV version 1.13