Bug 460926 A11y hierachy is broken on Ubuntu 8.10 (GNOME 2.24), r=Evan.Yan sr=roc
[wine-gecko.git] / security / nss / lib / base / nssbaset.h
blob2282d768fbd26bf15222d67664c695d36aad2be2
1 /* ***** BEGIN LICENSE BLOCK *****
2 * Version: MPL 1.1/GPL 2.0/LGPL 2.1
4 * The contents of this file are subject to the Mozilla Public License Version
5 * 1.1 (the "License"); you may not use this file except in compliance with
6 * the License. You may obtain a copy of the License at
7 * http://www.mozilla.org/MPL/
9 * Software distributed under the License is distributed on an "AS IS" basis,
10 * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
11 * for the specific language governing rights and limitations under the
12 * License.
14 * The Original Code is the Netscape security libraries.
16 * The Initial Developer of the Original Code is
17 * Netscape Communications Corporation.
18 * Portions created by the Initial Developer are Copyright (C) 1994-2000
19 * the Initial Developer. All Rights Reserved.
21 * Contributor(s):
23 * Alternatively, the contents of this file may be used under the terms of
24 * either the GNU General Public License Version 2 or later (the "GPL"), or
25 * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
26 * in which case the provisions of the GPL or the LGPL are applicable instead
27 * of those above. If you wish to allow use of your version of this file only
28 * under the terms of either the GPL or the LGPL, and not to allow others to
29 * use your version of this file under the terms of the MPL, indicate your
30 * decision by deleting the provisions above and replace them with the notice
31 * and other provisions required by the GPL or the LGPL. If you do not delete
32 * the provisions above, a recipient may use your version of this file under
33 * the terms of any one of the MPL, the GPL or the LGPL.
35 * ***** END LICENSE BLOCK ***** */
37 #ifndef NSSBASET_H
38 #define NSSBASET_H
40 #ifdef DEBUG
41 static const char NSSBASET_CVS_ID[] = "@(#) $RCSfile: nssbaset.h,v $ $Revision: 1.7 $ $Date: 2008/10/05 20:59:16 $";
42 #endif /* DEBUG */
45 * nssbaset.h
47 * This file contains the most low-level, fundamental public types.
50 #include "nspr.h"
51 #include "nssilock.h"
54 * NSS_EXTERN, NSS_IMPLEMENT, NSS_EXTERN_DATA, NSS_IMPLEMENT_DATA
56 * NSS has its own versions of these NSPR macros, in a form which
57 * does not confuse ctags and other related utilities. NSPR
58 * defines these macros to take the type as an argument, because
59 * of a requirement to support win16 dlls. We do not have that
60 * requirement, so we can drop that restriction.
63 #define DUMMY /* dummy */
64 #define NSS_EXTERN extern
65 #define NSS_EXTERN_DATA extern
66 #define NSS_IMPLEMENT
67 #define NSS_IMPLEMENT_DATA
69 PR_BEGIN_EXTERN_C
72 * NSSError
74 * Calls to NSS routines may result in one or more errors being placed
75 * on the calling thread's "error stack." Every possible error that
76 * may be returned from a function is declared where the function is
77 * prototyped. All errors are of the following type.
80 typedef PRInt32 NSSError;
83 * NSSArena
85 * Arenas are logical sets of heap memory, from which memory may be
86 * allocated. When an arena is destroyed, all memory allocated within
87 * that arena is implicitly freed. These arenas are thread-safe:
88 * an arena pointer may be used by multiple threads simultaneously.
89 * However, as they are not backed by shared memory, they may only be
90 * used within one process.
93 struct NSSArenaStr;
94 typedef struct NSSArenaStr NSSArena;
97 * NSSItem
99 * This is the basic type used to refer to an unconstrained datum of
100 * arbitrary size.
103 struct NSSItemStr {
104 void *data;
105 PRUint32 size;
107 typedef struct NSSItemStr NSSItem;
111 * NSSBER
113 * Data packed according to the Basic Encoding Rules of ASN.1.
116 typedef NSSItem NSSBER;
119 * NSSDER
121 * Data packed according to the Distinguished Encoding Rules of ASN.1;
122 * this form is also known as the Canonical Encoding Rules form (CER).
125 typedef NSSBER NSSDER;
128 * NSSBitString
130 * Some ASN.1 types use "bit strings," which are passed around as
131 * octet strings but whose length is counted in bits. We use this
132 * typedef of NSSItem to point out the occasions when the length
133 * is counted in bits, not octets.
136 typedef NSSItem NSSBitString;
139 * NSSUTF8
141 * Character strings encoded in UTF-8, as defined by RFC 2279.
144 typedef char NSSUTF8;
147 * NSSASCII7
149 * Character strings guaranteed to be 7-bit ASCII.
152 typedef char NSSASCII7;
154 PR_END_EXTERN_C
156 #endif /* NSSBASET_H */