xpcom/ds/nsISupportsPrimitives.idl

Sat, 03 Jan 2015 20:18:00 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Sat, 03 Jan 2015 20:18:00 +0100
branch
TOR_BUG_3246
changeset 7
129ffea94266
permissions
-rw-r--r--

Conditionally enable double key logic according to:
private browsing mode or privacy.thirdparty.isolate preference and
implement in GetCookieStringCommon and FindCookie where it counts...
With some reservations of how to convince FindCookie users to test
condition and pass a nullptr when disabling double key logic.

michael@0 1 /* -*- Mode: IDL; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
michael@0 2 /* This Source Code Form is subject to the terms of the Mozilla Public
michael@0 3 * License, v. 2.0. If a copy of the MPL was not distributed with this
michael@0 4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
michael@0 5
michael@0 6 /* nsISupports wrappers for single primitive pieces of data. */
michael@0 7
michael@0 8 #include "nsISupports.idl"
michael@0 9
michael@0 10 /**
michael@0 11 * Primitive base interface.
michael@0 12 *
michael@0 13 * These first three are pointer types and do data copying
michael@0 14 * using the nsIMemory. Be careful!
michael@0 15 */
michael@0 16
michael@0 17 [scriptable, uuid(d0d4b136-1dd1-11b2-9371-f0727ef827c0)]
michael@0 18 interface nsISupportsPrimitive : nsISupports
michael@0 19 {
michael@0 20 const unsigned short TYPE_ID = 1;
michael@0 21 const unsigned short TYPE_CSTRING = 2;
michael@0 22 const unsigned short TYPE_STRING = 3;
michael@0 23 const unsigned short TYPE_PRBOOL = 4;
michael@0 24 const unsigned short TYPE_PRUINT8 = 5;
michael@0 25 const unsigned short TYPE_PRUINT16 = 6;
michael@0 26 const unsigned short TYPE_PRUINT32 = 7;
michael@0 27 const unsigned short TYPE_PRUINT64 = 8;
michael@0 28 const unsigned short TYPE_PRTIME = 9;
michael@0 29 const unsigned short TYPE_CHAR = 10;
michael@0 30 const unsigned short TYPE_PRINT16 = 11;
michael@0 31 const unsigned short TYPE_PRINT32 = 12;
michael@0 32 const unsigned short TYPE_PRINT64 = 13;
michael@0 33 const unsigned short TYPE_FLOAT = 14;
michael@0 34 const unsigned short TYPE_DOUBLE = 15;
michael@0 35 const unsigned short TYPE_VOID = 16;
michael@0 36 const unsigned short TYPE_INTERFACE_POINTER = 17;
michael@0 37
michael@0 38 readonly attribute unsigned short type;
michael@0 39 };
michael@0 40
michael@0 41 /**
michael@0 42 * Scriptable storage for nsID structures
michael@0 43 */
michael@0 44
michael@0 45 [scriptable, uuid(d18290a0-4a1c-11d3-9890-006008962422)]
michael@0 46 interface nsISupportsID : nsISupportsPrimitive
michael@0 47 {
michael@0 48 attribute nsIDPtr data;
michael@0 49 string toString();
michael@0 50 };
michael@0 51
michael@0 52 /**
michael@0 53 * Scriptable storage for ASCII strings
michael@0 54 */
michael@0 55
michael@0 56 [scriptable, uuid(d65ff270-4a1c-11d3-9890-006008962422)]
michael@0 57 interface nsISupportsCString : nsISupportsPrimitive
michael@0 58 {
michael@0 59 attribute ACString data;
michael@0 60 string toString();
michael@0 61 };
michael@0 62
michael@0 63 /**
michael@0 64 * Scriptable storage for Unicode strings
michael@0 65 */
michael@0 66
michael@0 67 [scriptable, uuid(d79dc970-4a1c-11d3-9890-006008962422)]
michael@0 68 interface nsISupportsString : nsISupportsPrimitive
michael@0 69 {
michael@0 70 attribute AString data;
michael@0 71 wstring toString();
michael@0 72 };
michael@0 73
michael@0 74 /**
michael@0 75 * The rest are truly primitive and are passed by value
michael@0 76 */
michael@0 77
michael@0 78 /**
michael@0 79 * Scriptable storage for booleans
michael@0 80 */
michael@0 81
michael@0 82 [scriptable, uuid(ddc3b490-4a1c-11d3-9890-006008962422)]
michael@0 83 interface nsISupportsPRBool : nsISupportsPrimitive
michael@0 84 {
michael@0 85 attribute boolean data;
michael@0 86 string toString();
michael@0 87 };
michael@0 88
michael@0 89 /**
michael@0 90 * Scriptable storage for 8-bit integers
michael@0 91 */
michael@0 92
michael@0 93 [scriptable, uuid(dec2e4e0-4a1c-11d3-9890-006008962422)]
michael@0 94 interface nsISupportsPRUint8 : nsISupportsPrimitive
michael@0 95 {
michael@0 96 attribute uint8_t data;
michael@0 97 string toString();
michael@0 98 };
michael@0 99
michael@0 100 /**
michael@0 101 * Scriptable storage for unsigned 16-bit integers
michael@0 102 */
michael@0 103
michael@0 104 [scriptable, uuid(dfacb090-4a1c-11d3-9890-006008962422)]
michael@0 105 interface nsISupportsPRUint16 : nsISupportsPrimitive
michael@0 106 {
michael@0 107 attribute uint16_t data;
michael@0 108 string toString();
michael@0 109 };
michael@0 110
michael@0 111 /**
michael@0 112 * Scriptable storage for unsigned 32-bit integers
michael@0 113 */
michael@0 114
michael@0 115 [scriptable, uuid(e01dc470-4a1c-11d3-9890-006008962422)]
michael@0 116 interface nsISupportsPRUint32 : nsISupportsPrimitive
michael@0 117 {
michael@0 118 attribute uint32_t data;
michael@0 119 string toString();
michael@0 120 };
michael@0 121
michael@0 122 /**
michael@0 123 * Scriptable storage for 64-bit integers
michael@0 124 */
michael@0 125
michael@0 126 [scriptable, uuid(e13567c0-4a1c-11d3-9890-006008962422)]
michael@0 127 interface nsISupportsPRUint64 : nsISupportsPrimitive
michael@0 128 {
michael@0 129 attribute uint64_t data;
michael@0 130 string toString();
michael@0 131 };
michael@0 132
michael@0 133 /**
michael@0 134 * Scriptable storage for NSPR date/time values
michael@0 135 */
michael@0 136
michael@0 137 [scriptable, uuid(e2563630-4a1c-11d3-9890-006008962422)]
michael@0 138 interface nsISupportsPRTime : nsISupportsPrimitive
michael@0 139 {
michael@0 140 attribute PRTime data;
michael@0 141 string toString();
michael@0 142 };
michael@0 143
michael@0 144 /**
michael@0 145 * Scriptable storage for single character values
michael@0 146 * (often used to store an ASCII character)
michael@0 147 */
michael@0 148
michael@0 149 [scriptable, uuid(e2b05e40-4a1c-11d3-9890-006008962422)]
michael@0 150 interface nsISupportsChar : nsISupportsPrimitive
michael@0 151 {
michael@0 152 attribute char data;
michael@0 153 string toString();
michael@0 154 };
michael@0 155
michael@0 156 /**
michael@0 157 * Scriptable storage for 16-bit integers
michael@0 158 */
michael@0 159
michael@0 160 [scriptable, uuid(e30d94b0-4a1c-11d3-9890-006008962422)]
michael@0 161 interface nsISupportsPRInt16 : nsISupportsPrimitive
michael@0 162 {
michael@0 163 attribute int16_t data;
michael@0 164 string toString();
michael@0 165 };
michael@0 166
michael@0 167 /**
michael@0 168 * Scriptable storage for 32-bit integers
michael@0 169 */
michael@0 170
michael@0 171 [scriptable, uuid(e36c5250-4a1c-11d3-9890-006008962422)]
michael@0 172 interface nsISupportsPRInt32 : nsISupportsPrimitive
michael@0 173 {
michael@0 174 attribute int32_t data;
michael@0 175 string toString();
michael@0 176 };
michael@0 177
michael@0 178 /**
michael@0 179 * Scriptable storage for 64-bit integers
michael@0 180 */
michael@0 181
michael@0 182 [scriptable, uuid(e3cb0ff0-4a1c-11d3-9890-006008962422)]
michael@0 183 interface nsISupportsPRInt64 : nsISupportsPrimitive
michael@0 184 {
michael@0 185 attribute int64_t data;
michael@0 186 string toString();
michael@0 187 };
michael@0 188
michael@0 189 /**
michael@0 190 * Scriptable storage for floating point numbers
michael@0 191 */
michael@0 192
michael@0 193 [scriptable, uuid(abeaa390-4ac0-11d3-baea-00805f8a5dd7)]
michael@0 194 interface nsISupportsFloat : nsISupportsPrimitive
michael@0 195 {
michael@0 196 attribute float data;
michael@0 197 string toString();
michael@0 198 };
michael@0 199
michael@0 200 /**
michael@0 201 * Scriptable storage for doubles
michael@0 202 */
michael@0 203
michael@0 204 [scriptable, uuid(b32523a0-4ac0-11d3-baea-00805f8a5dd7)]
michael@0 205 interface nsISupportsDouble : nsISupportsPrimitive
michael@0 206 {
michael@0 207 attribute double data;
michael@0 208 string toString();
michael@0 209 };
michael@0 210
michael@0 211 /**
michael@0 212 * Scriptable storage for generic pointers
michael@0 213 */
michael@0 214
michael@0 215 [scriptable, uuid(464484f0-568d-11d3-baf8-00805f8a5dd7)]
michael@0 216 interface nsISupportsVoid : nsISupportsPrimitive
michael@0 217 {
michael@0 218 [noscript] attribute voidPtr data;
michael@0 219 string toString();
michael@0 220 };
michael@0 221
michael@0 222 /**
michael@0 223 * Scriptable storage for other XPCOM objects
michael@0 224 */
michael@0 225
michael@0 226 [scriptable, uuid(995ea724-1dd1-11b2-9211-c21bdd3e7ed0)]
michael@0 227 interface nsISupportsInterfacePointer : nsISupportsPrimitive
michael@0 228 {
michael@0 229 attribute nsISupports data;
michael@0 230 attribute nsIDPtr dataIID;
michael@0 231
michael@0 232 string toString();
michael@0 233 };
michael@0 234
michael@0 235

mercurial