1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
2 * vim: sw=2 ts=2 et lcs=trail\:.,tab\:>~ :
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
5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
7 #ifndef MOZSTORAGESTATEMENTROW_H
8 #define MOZSTORAGESTATEMENTROW_H
10 #include "mozilla/Attributes.h"
11 #include "nsPIDOMWindow.h"
12 #include "nsWrapperCache.h"
21 class StatementRow final
: public nsISupports
, public nsWrapperCache
{
23 NS_DECL_CYCLE_COLLECTING_ISUPPORTS
24 NS_DECL_CYCLE_COLLECTION_WRAPPERCACHE_CLASS(StatementRow
)
26 explicit StatementRow(nsPIDOMWindowInner
* aWindow
, Statement
* aStatement
);
28 void NamedGetter(JSContext
* aCx
, const nsAString
& aName
, bool& aFound
,
29 JS::MutableHandle
<JS::Value
> aResult
,
30 mozilla::ErrorResult
& aRv
);
31 void GetSupportedNames(nsTArray
<nsString
>& aNames
);
33 JSObject
* WrapObject(JSContext
* aCx
,
34 JS::Handle
<JSObject
*> aGivenProto
) override
;
36 nsPIDOMWindowInner
* GetParentObject() const { return mWindow
; }
41 nsCOMPtr
<nsPIDOMWindowInner
> mWindow
;
42 Statement
* mStatement
;
44 friend class StatementRowHolder
;
47 } // namespace storage
48 } // namespace mozilla
50 #endif /* MOZSTORAGESTATEMENTROW_H */