1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/js/src/ctypes/Library.h Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,37 @@ 1.4 +/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2; -*- */ 1.5 +/* This Source Code Form is subject to the terms of the Mozilla Public 1.6 + * License, v. 2.0. If a copy of the MPL was not distributed with this 1.7 + * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ 1.8 + 1.9 +#ifndef ctypes_Library_h 1.10 +#define ctypes_Library_h 1.11 + 1.12 +#include "js/TypeDecls.h" 1.13 + 1.14 +struct JSCTypesCallbacks; 1.15 +struct PRLibrary; 1.16 + 1.17 +namespace js { 1.18 +namespace ctypes { 1.19 + 1.20 +enum LibrarySlot { 1.21 + SLOT_LIBRARY = 0, 1.22 + LIBRARY_SLOTS 1.23 +}; 1.24 + 1.25 +namespace Library 1.26 +{ 1.27 + bool Name(JSContext* cx, unsigned argc, JS::Value *vp); 1.28 + 1.29 + JSObject* Create(JSContext* cx, JS::Value path, JSCTypesCallbacks* callbacks); 1.30 + 1.31 + bool IsLibrary(JSObject* obj); 1.32 + PRLibrary* GetLibrary(JSObject* obj); 1.33 + 1.34 + bool Open(JSContext* cx, unsigned argc, JS::Value* vp); 1.35 +} 1.36 + 1.37 +} 1.38 +} 1.39 + 1.40 +#endif /* ctypes_Library_h */