monotone

monotone Mtn Source Tree

Root/vocab_terms.hh

1// Copyright (C) 2002 Graydon Hoare <graydon@pobox.com>
2//
3// This program is made available under the GNU GPL version 2.0 or
4// greater. See the accompanying file COPYING for details.
5//
6// This program is distributed WITHOUT ANY WARRANTY; without even the
7// implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
8// PURPOSE.
9
10// this fragment is included into both vocab.hh and vocab.cc,
11// in order to facilitate external instantiation of most of the
12// vocabulary, minimize code duplication, speed up compilation, etc.
13
14ATOMIC_NOVERIFY(external); // "external" string in unknown system charset
15ATOMIC_NOVERIFY(utf8); // unknown string in UTF8 charset
16ATOMIC(ace); // unknown string in ACE form
17ATOMIC(symbol); // valid basic io symbol (alphanumeric or _ chars)
18
19ATOMIC(path_component); // piece of a path (see paths.hh)
20
21ATOMIC_NOVERIFY(id); // hash of data
22ATOMIC_NOVERIFY(data); // meaningless blob
23ATOMIC_NOVERIFY(delta); // xdelta between 2 datas
24ATOMIC_NOVERIFY(inodeprint); // fingerprint of an inode
25
26ATOMIC(cert_name); // symbol-of-your-choosing
27ATOMIC_NOVERIFY(cert_value); // symbol-of-your-choosing
28
29// some domains: "database" (+ default_server, default_pattern),
30// server_key (+ servername/key)
31// branch_alias (+ short form/long form)
32// trust_seed (+ branch/seed)
33ATOMIC_NOVERIFY(var_domain); // symbol-of-your-choosing
34ATOMIC_NOVERIFY(var_name); // symbol-of-your-choosing
35ATOMIC_NOVERIFY(var_value); // symbol-of-your-choosing
36
37ATOMIC(rsa_keypair_id); // keyname@domain.you.own
38ATOMIC_NOVERIFY(rsa_pub_key); // some nice numbers
39ATOMIC_NOVERIFY(rsa_priv_key); // some nice numbers
40ATOMIC_NOVERIFY(rsa_sha1_signature); // some other nice numbers
41ATOMIC_NOVERIFY(rsa_oaep_sha_data);
42
43ATOMIC(netsync_session_key); // key for netsync session HMAC
44ATOMIC(netsync_hmac_value); // 160-bit SHA-1 HMAC
45
46ATOMIC_NOVERIFY(attr_key);
47ATOMIC_NOVERIFY(attr_value);
48
49DECORATE(revision); // thing associated with a revision
50DECORATE(roster); // thing associated with a roster
51DECORATE(manifest); // thing associated with a manifest
52DECORATE(file); // thing associated with a file
53DECORATE(key); // thing associated with a key
54DECORATE(epoch); // thing associated with an epoch
55
56ENCODING(gzip); // thing which is gzipped
57ENCODING(hexenc); // thing which is hex-encoded
58ENCODING(base64); // thing which is base64-encoded
59ENCODING(arc4); // thing which is arc4-encrypted
60
61ATOMIC_NOVERIFY(prefix); // raw encoding of a merkle tree prefix
62ATOMIC_NOVERIFY(merkle); // raw encoding of a merkle tree node
63
64// instantiate those bits of the template vocabulary actually in use.
65
66EXTERN template class hexenc<id>;
67EXTERN template class revision< hexenc<id> >;
68EXTERN template class roster< hexenc<id> >;
69EXTERN template class manifest< hexenc<id> >;
70EXTERN template class file< hexenc<id> >;
71EXTERN template class key< hexenc<id> >;
72EXTERN template class epoch< hexenc<id> >;
73
74EXTERN template class hexenc<inodeprint>;
75
76EXTERN template class hexenc<data>;
77EXTERN template class epoch< hexenc<data> >;
78
79EXTERN template class gzip<data>;
80EXTERN template class base64< gzip<data> >;
81
82EXTERN template class revision< data >;
83EXTERN template class roster< data >;
84EXTERN template class manifest< data >;
85EXTERN template class file< data >;
86
87EXTERN template class gzip<delta>;
88EXTERN template class base64< gzip<delta> >;
89
90EXTERN template class manifest< delta >;
91EXTERN template class file< delta >;
92
93EXTERN template class arc4<rsa_priv_key>;
94EXTERN template class base64< arc4<rsa_priv_key> >;
95EXTERN template class base64< rsa_pub_key >;
96EXTERN template class base64< rsa_priv_key >;
97EXTERN template class base64< rsa_sha1_signature >;
98EXTERN template class hexenc< rsa_sha1_signature >;
99EXTERN template class base64< cert_value >;
100
101EXTERN template class base64< var_name >;
102EXTERN template class base64< var_value >;
103
104EXTERN template class hexenc<prefix>;
105EXTERN template class base64<merkle>;
106EXTERN template class base64<data>;
107
108// instantiate those bits of the stream operator vocab (again) actually in
109// use. "again" since stream operators are friends, not members.
110
111EXTERN template std::ostream & operator<< <>(std::ostream &, hexenc<id> const &);
112EXTERN template std::ostream & operator<< <>(std::ostream &, revision< hexenc<id> > const &);
113EXTERN template std::ostream & operator<< <>(std::ostream &, roster< hexenc<id> > const &);
114EXTERN template std::ostream & operator<< <>(std::ostream &, manifest< hexenc<id> > const &);
115EXTERN template std::ostream & operator<< <>(std::ostream &, file< hexenc<id> > const &);
116EXTERN template std::ostream & operator<< <>(std::ostream &, epoch< hexenc<id> > const &);
117
118EXTERN template std::ostream & operator<< <>(std::ostream &, hexenc<inodeprint> const &);
119
120EXTERN template std::ostream & operator<< <>(std::ostream &, roster<data> const &);
121
122EXTERN template std::ostream & operator<< <>(std::ostream &, hexenc<data> const &);
123EXTERN template std::ostream & operator<< <>(std::ostream &, epoch< hexenc<data> > const &);
124
125EXTERN template std::ostream & operator<< <>(std::ostream &, gzip<data> const &);
126EXTERN template std::ostream & operator<< <>(std::ostream &, base64< gzip<data> > const &);
127EXTERN template std::ostream & operator<< <>(std::ostream &, revision< base64< gzip<data> > > const &);
128EXTERN template std::ostream & operator<< <>(std::ostream &, manifest< base64< gzip<data> > > const &);
129EXTERN template std::ostream & operator<< <>(std::ostream &, file< base64< gzip<data> > > const &);
130
131EXTERN template std::ostream & operator<< <>(std::ostream &, gzip<delta> const &);
132EXTERN template std::ostream & operator<< <>(std::ostream &, base64< gzip<delta> > const &);
133EXTERN template std::ostream & operator<< <>(std::ostream &, manifest< base64< gzip<delta> > > const &);
134EXTERN template std::ostream & operator<< <>(std::ostream &, file< base64< gzip<delta> > > const &);
135
136EXTERN template std::ostream & operator<< <>(std::ostream &, arc4<rsa_priv_key> const &);
137EXTERN template std::ostream & operator<< <>(std::ostream &, base64< arc4<rsa_priv_key> > const &);
138EXTERN template std::ostream & operator<< <>(std::ostream &, base64< rsa_pub_key > const &);
139EXTERN template std::ostream & operator<< <>(std::ostream &, base64< rsa_sha1_signature > const &);
140EXTERN template std::ostream & operator<< <>(std::ostream &, hexenc< rsa_sha1_signature > const &);
141EXTERN template std::ostream & operator<< <>(std::ostream &, base64< cert_value > const &);
142
143EXTERN template std::ostream & operator<< <>(std::ostream &, hexenc<prefix> const &);
144EXTERN template std::ostream & operator<< <>(std::ostream &, base64<merkle> const &);

Archive Download this file

Branches

Tags

Quick Links:     www.monotone.ca    -     Downloads    -     Documentation    -     Wiki    -     Code Forge    -     Build Status