LCOV - code coverage report
Current view: top level - dom/base - Crypto.h (source / functions) Hit Total Coverage
Test: output.info Lines: 1 3 33.3 %
Date: 2017-07-14 16:53:18 Functions: 1 8 12.5 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
       2             : /* vim: set ts=8 sts=2 et sw=2 tw=80: */
       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 file,
       5             :  * You can obtain one at http://mozilla.org/MPL/2.0/. */
       6             : #ifndef mozilla_dom_Crypto_h
       7             : #define mozilla_dom_Crypto_h
       8             : 
       9             : #include "nsIDOMCrypto.h"
      10             : #include "mozilla/dom/SubtleCrypto.h"
      11             : #include "nsIGlobalObject.h"
      12             : 
      13             : #include "nsWrapperCache.h"
      14             : #include "mozilla/dom/TypedArray.h"
      15             : #define NS_DOMCRYPTO_CID \
      16             :   {0x929d9320, 0x251e, 0x11d4, { 0x8a, 0x7c, 0x00, 0x60, 0x08, 0xc8, 0x44, 0xc3} }
      17             : 
      18             : namespace mozilla {
      19             : 
      20             : class ErrorResult;
      21             : 
      22             : namespace dom {
      23             : 
      24             : class Crypto : public nsIDOMCrypto,
      25             :                public nsWrapperCache
      26             : {
      27             : protected:
      28             :   virtual ~Crypto();
      29             : 
      30             : public:
      31             :   Crypto();
      32             : 
      33             :   NS_DECL_NSIDOMCRYPTO
      34             : 
      35             :   NS_DECL_CYCLE_COLLECTING_ISUPPORTS
      36           2 :   NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(Crypto)
      37             : 
      38             :   void
      39             :   GetRandomValues(JSContext* aCx, const ArrayBufferView& aArray,
      40             :                   JS::MutableHandle<JSObject*> aRetval,
      41             :                   ErrorResult& aRv);
      42             : 
      43             :   SubtleCrypto*
      44             :   Subtle();
      45             : 
      46             :   // WebIDL
      47             : 
      48             :   nsIGlobalObject*
      49           0 :   GetParentObject() const
      50             :   {
      51           0 :     return mParent;
      52             :   }
      53             : 
      54             :   virtual JSObject*
      55             :   WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto) override;
      56             : 
      57             : private:
      58             :   nsCOMPtr<nsIGlobalObject> mParent;
      59             :   RefPtr<SubtleCrypto> mSubtle;
      60             : };
      61             : 
      62             : } // namespace dom
      63             : } // namespace mozilla
      64             : 
      65             : #endif // mozilla_dom_Crypto_h

Generated by: LCOV version 1.13