aboutsummaryrefslogtreecommitdiff
path: root/chrome/code/xpcom.js
diff options
context:
space:
mode:
authorEinar Egilsson2011-08-28 23:31:04 +0200
committerEinar Egilsson2011-08-28 23:31:04 +0200
commit4fc435047afa02cf4be96a398c1a06c377901aba (patch)
treec206c0c6aa2a3f013e1dec99dd0cff238925bd23 /chrome/code/xpcom.js
parent3ba13e5bcb4177abc3aaef2da37c2b99befd6c88 (diff)
Prototype of redirecting proxy server
Diffstat (limited to 'chrome/code/xpcom.js')
-rw-r--r--chrome/code/xpcom.js13
1 files changed, 13 insertions, 0 deletions
diff --git a/chrome/code/xpcom.js b/chrome/code/xpcom.js
new file mode 100644
index 0000000..ec2232f
--- /dev/null
+++ b/chrome/code/xpcom.js
@@ -0,0 +1,13 @@
+
+var EXPORTED_SYMBOLS = [
+'Ci', 'Cc', 'Cr', 'ServerSocket', 'ScriptableInputStream', 'FileInputStream', 'ConverterInputStream', 'LocalFile'];
+
+Ci = Components.interfaces;
+Cc = Components.classes;
+Cr = Components.results;
+
+const ServerSocket = Components.Constructor("@mozilla.org/network/server-socket;1", "nsIServerSocket", "init");
+const ScriptableInputStream = Components.Constructor("@mozilla.org/scriptableinputstream;1", "nsIScriptableInputStream", "init");
+const FileInputStream = Components.Constructor("@mozilla.org/network/file-input-stream;1", "nsIFileInputStream", "init");
+const ConverterInputStream = Components.Constructor("@mozilla.org/intl/converter-input-stream;1", "nsIConverterInputStream", "init");
+const LocalFile = Components.Constructor("@mozilla.org/file/local;1", "nsILocalFile", "initWithPath");