2012-02-07 17:22:30 +00:00
|
|
|
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2; -*- */
|
2012-05-21 11:12:37 +00:00
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
2012-02-07 17:22:30 +00:00
|
|
|
|
|
|
|
#ifndef COMPONENTS_JSINSPECTOR_H
|
|
|
|
#define COMPONENTS_JSINSPECTOR_H
|
|
|
|
|
|
|
|
#include "nsIJSInspector.h"
|
2012-07-18 16:12:55 +00:00
|
|
|
#include "mozilla/Attributes.h"
|
2013-11-06 10:45:59 +00:00
|
|
|
#include "nsCycleCollectionParticipant.h"
|
2013-04-09 11:17:03 +00:00
|
|
|
#include "nsTArray.h"
|
|
|
|
#include "js/Value.h"
|
2013-11-06 10:45:59 +00:00
|
|
|
#include "js/RootingAPI.h"
|
2012-02-07 17:22:30 +00:00
|
|
|
|
|
|
|
namespace mozilla {
|
|
|
|
namespace jsinspector {
|
|
|
|
|
2015-03-21 16:28:04 +00:00
|
|
|
class nsJSInspector final : public nsIJSInspector
|
2012-02-07 17:22:30 +00:00
|
|
|
{
|
|
|
|
public:
|
2013-11-06 10:45:59 +00:00
|
|
|
NS_DECL_CYCLE_COLLECTING_ISUPPORTS
|
|
|
|
NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(nsJSInspector)
|
2012-02-07 17:22:30 +00:00
|
|
|
NS_DECL_NSIJSINSPECTOR
|
|
|
|
|
|
|
|
nsJSInspector();
|
|
|
|
|
|
|
|
private:
|
|
|
|
~nsJSInspector();
|
|
|
|
|
2012-08-22 15:56:38 +00:00
|
|
|
uint32_t mNestedLoopLevel;
|
2013-11-06 10:45:59 +00:00
|
|
|
nsTArray<JS::Heap<JS::Value> > mRequestors;
|
|
|
|
JS::Heap<JS::Value> mLastRequestor;
|
2012-02-07 17:22:30 +00:00
|
|
|
};
|
|
|
|
|
2015-07-13 15:25:42 +00:00
|
|
|
} // namespace jsinspector
|
|
|
|
} // namespace mozilla
|
2012-02-07 17:22:30 +00:00
|
|
|
|
|
|
|
#endif
|