Copy as Markdown

Other Tools

/* THIS FILE IS AUTOGENERATED FROM BrowserSessionStore.webidl BY Codegen.py - DO NOT EDIT */
#ifndef DOM_BROWSERSESSIONSTOREBINDING_H_
#define DOM_BROWSERSESSIONSTOREBINDING_H_
#include "js/CallAndConstruct.h"
#include "js/RootingAPI.h"
#include "js/TypeDecls.h"
#include "mozilla/dom/BindingDeclarations.h"
#include "mozilla/dom/Nullable.h"
#include "mozilla/dom/PrototypeList.h"
#include "mozilla/dom/SessionStoreFormData.h"
#include "mozilla/dom/SessionStoreScrollData.h"
namespace mozilla {
namespace dom {
struct NativePropertyHooks;
class ProtoAndIfaceCache;
struct SessionStoreDisplaySize;
struct SessionStoreDisplaySizeAtoms;
class SessionStoreFormData;
class SessionStoreScrollData;
struct SessionStoreZoomDataAtoms;
struct UpdateSessionStoreDataAtoms;
} // namespace dom
} // namespace mozilla
namespace mozilla::dom {
struct SessionStoreDisplaySize : public DictionaryBase
{
MOZ_INIT_OUTSIDE_CTOR Optional<uint32_t> mHeight;
MOZ_INIT_OUTSIDE_CTOR Optional<uint32_t> mWidth;
SessionStoreDisplaySize();
explicit inline SessionStoreDisplaySize(const FastDictionaryInitializer& )
{
// Do nothing here; this is used by our "Fast" subclass
}
SessionStoreDisplaySize(SessionStoreDisplaySize&& aOther) = default;
explicit inline SessionStoreDisplaySize(const SessionStoreDisplaySize& aOther)
{
*this = aOther;
}
bool
Init(const char* sourceDescription = "Value", bool passedToJSImpl = false);
bool
ToObjectInternal(JSContext* cx, JS::MutableHandle<JS::Value> rval) const;
void
TraceDictionary(JSTracer* trc);
SessionStoreDisplaySize&
operator=(const SessionStoreDisplaySize& aOther);
bool
operator==(const SessionStoreDisplaySize& aOther) const;
private:
static bool
InitIds(JSContext* cx, SessionStoreDisplaySizeAtoms* atomsCache);
};
namespace binding_detail {
struct FastSessionStoreDisplaySize : public SessionStoreDisplaySize
{
inline FastSessionStoreDisplaySize()
: SessionStoreDisplaySize(FastDictionaryInitializer())
{
// Doesn't matter what int we pass to the parent constructor
}
};
} // namespace binding_detail
struct UpdateSessionStoreData : public DictionaryBase
{
MOZ_INIT_OUTSIDE_CTOR Optional<nsCString> mDisallow;
MOZ_INIT_OUTSIDE_CTOR Optional<RefPtr<mozilla::dom::SessionStoreFormData>> mFormdata;
MOZ_INIT_OUTSIDE_CTOR Optional<bool> mIsPrivate;
MOZ_INIT_OUTSIDE_CTOR Optional<RefPtr<mozilla::dom::SessionStoreScrollData>> mScroll;
UpdateSessionStoreData();
explicit inline UpdateSessionStoreData(const FastDictionaryInitializer& )
{
// Do nothing here; this is used by our "Fast" subclass
}
UpdateSessionStoreData(UpdateSessionStoreData&& aOther) = default;
explicit inline UpdateSessionStoreData(const UpdateSessionStoreData& aOther)
{
*this = aOther;
}
bool
Init(const char* sourceDescription = "Value", bool passedToJSImpl = false);
bool
ToObjectInternal(JSContext* cx, JS::MutableHandle<JS::Value> rval) const;
void
TraceDictionary(JSTracer* trc);
inline void
TraverseForCC(nsCycleCollectionTraversalCallback& aCallback, uint32_t aFlags)
{
ImplCycleCollectionTraverse(aCallback, mFormdata, "mFormdata", aFlags);
ImplCycleCollectionTraverse(aCallback, mScroll, "mScroll", aFlags);
}
inline void
UnlinkForCC()
{
ImplCycleCollectionUnlink(mFormdata);
ImplCycleCollectionUnlink(mScroll);
}
UpdateSessionStoreData&
operator=(const UpdateSessionStoreData& aOther);
private:
static bool
InitIds(JSContext* cx, UpdateSessionStoreDataAtoms* atomsCache);
};
namespace binding_detail {
struct FastUpdateSessionStoreData : public UpdateSessionStoreData
{
inline FastUpdateSessionStoreData()
: UpdateSessionStoreData(FastDictionaryInitializer())
{
// Doesn't matter what int we pass to the parent constructor
}
};
} // namespace binding_detail
struct SessionStoreZoomData : public DictionaryBase
{
MOZ_INIT_OUTSIDE_CTOR Optional<SessionStoreDisplaySize> mDisplaySize;
MOZ_INIT_OUTSIDE_CTOR Optional<double> mResolution;
SessionStoreZoomData();
explicit inline SessionStoreZoomData(const FastDictionaryInitializer& )
{
// Do nothing here; this is used by our "Fast" subclass
}
SessionStoreZoomData(SessionStoreZoomData&& aOther) = default;
explicit inline SessionStoreZoomData(const SessionStoreZoomData& aOther)
{
*this = aOther;
}
bool
Init(const char* sourceDescription = "Value", bool passedToJSImpl = false);
bool
ToObjectInternal(JSContext* cx, JS::MutableHandle<JS::Value> rval) const;
void
TraceDictionary(JSTracer* trc);
SessionStoreZoomData&
operator=(const SessionStoreZoomData& aOther);
private:
static bool
InitIds(JSContext* cx, SessionStoreZoomDataAtoms* atomsCache);
};
namespace binding_detail {
struct FastSessionStoreZoomData : public SessionStoreZoomData
{
inline FastSessionStoreZoomData()
: SessionStoreZoomData(FastDictionaryInitializer())
{
// Doesn't matter what int we pass to the parent constructor
}
};
} // namespace binding_detail
namespace SessionStoreFormData_Binding {
typedef mozilla::dom::SessionStoreFormData NativeType;
bool
ConstructorEnabled(JSContext* aCx, JS::Handle<JSObject*> aObj);
bool
Wrap(JSContext* aCx, mozilla::dom::SessionStoreFormData* aObject, nsWrapperCache* aCache, JS::Handle<JSObject*> aGivenProto, JS::MutableHandle<JSObject*> aReflector);
template <class T>
inline JSObject* Wrap(JSContext* aCx, T* aObject, JS::Handle<JSObject*> aGivenProto)
{
JS::Rooted<JSObject*> reflector(aCx);
return Wrap(aCx, aObject, aObject, aGivenProto, &reflector) ? reflector.get() : nullptr;
}
void
ClearCachedUrlValue(mozilla::dom::SessionStoreFormData* aObject);
void
ClearCachedIdValue(mozilla::dom::SessionStoreFormData* aObject);
void
ClearCachedXpathValue(mozilla::dom::SessionStoreFormData* aObject);
void
ClearCachedInnerHTMLValue(mozilla::dom::SessionStoreFormData* aObject);
void
ClearCachedChildrenValue(mozilla::dom::SessionStoreFormData* aObject);
void
CreateInterfaceObjects(JSContext* aCx, JS::Handle<JSObject*> aGlobal, ProtoAndIfaceCache& aProtoAndIfaceCache, bool aDefineOnGlobal);
inline JS::Handle<JSObject*> GetProtoObjectHandle(JSContext* aCx)
{
/* Get the interface prototype object for this class. This will create the
object as needed. */
return GetPerInterfaceObjectHandle(aCx, prototypes::id::SessionStoreFormData,
&CreateInterfaceObjects,
/* aDefineOnGlobal = */ true);
}
inline JS::Handle<JSObject*> GetConstructorObjectHandle(JSContext* aCx, bool aDefineOnGlobal = true)
{
/* Get the interface object for this class. This will create the object as
needed. */
return GetPerInterfaceObjectHandle(aCx, constructors::id::SessionStoreFormData,
&CreateInterfaceObjects,
aDefineOnGlobal);
}
JSObject*
GetConstructorObject(JSContext* aCx);
} // namespace SessionStoreFormData_Binding
namespace SessionStoreScrollData_Binding {
typedef mozilla::dom::SessionStoreScrollData NativeType;
bool
ConstructorEnabled(JSContext* aCx, JS::Handle<JSObject*> aObj);
bool
Wrap(JSContext* aCx, mozilla::dom::SessionStoreScrollData* aObject, nsWrapperCache* aCache, JS::Handle<JSObject*> aGivenProto, JS::MutableHandle<JSObject*> aReflector);
template <class T>
inline JSObject* Wrap(JSContext* aCx, T* aObject, JS::Handle<JSObject*> aGivenProto)
{
JS::Rooted<JSObject*> reflector(aCx);
return Wrap(aCx, aObject, aObject, aGivenProto, &reflector) ? reflector.get() : nullptr;
}
void
ClearCachedScrollValue(mozilla::dom::SessionStoreScrollData* aObject);
void
ClearCachedChildrenValue(mozilla::dom::SessionStoreScrollData* aObject);
void
CreateInterfaceObjects(JSContext* aCx, JS::Handle<JSObject*> aGlobal, ProtoAndIfaceCache& aProtoAndIfaceCache, bool aDefineOnGlobal);
inline JS::Handle<JSObject*> GetProtoObjectHandle(JSContext* aCx)
{
/* Get the interface prototype object for this class. This will create the
object as needed. */
return GetPerInterfaceObjectHandle(aCx, prototypes::id::SessionStoreScrollData,
&CreateInterfaceObjects,
/* aDefineOnGlobal = */ true);
}
inline JS::Handle<JSObject*> GetConstructorObjectHandle(JSContext* aCx, bool aDefineOnGlobal = true)
{
/* Get the interface object for this class. This will create the object as
needed. */
return GetPerInterfaceObjectHandle(aCx, constructors::id::SessionStoreScrollData,
&CreateInterfaceObjects,
aDefineOnGlobal);
}
JSObject*
GetConstructorObject(JSContext* aCx);
} // namespace SessionStoreScrollData_Binding
} // namespace mozilla::dom
#endif // DOM_BROWSERSESSIONSTOREBINDING_H_