monotone

monotone Mtn Source Tree

Root/vocab_terms.hh

1// copyright (C) 2002, 2003 graydon hoare <graydon@pobox.com>
2// all rights reserved.
3// licensed to the public under the terms of the GNU GPL (>= 2)
4// see the file COPYING for details
5
6// this fragment is included into both vocab.hh and vocab.cc,
7// in order to facilitate external instantiation of most of the
8// vocabulary, minimize code duplication, speed up compilation, etc.
9
10ATOMIC(external); // "external" string in unknown system charset
11ATOMIC(utf8); // unknown string in UTF8 charset
12ATOMIC(ace); // unknown string in ACE form
13
14ATOMIC(id); // hash of data
15ATOMIC(data); // meaningless blob
16ATOMIC(delta); // xdelta between 2 datas
17
18ATOMIC(local_path); // non-absolute file
19ATOMIC(file_path); // non-absolute, non-bookeeping file
20
21ATOMIC(cert_name); // symbol-of-your-choosing
22ATOMIC(cert_value); // symbol-of-your-choosing
23
24// some domains: "database" (+ default_server, default_collection),
25// server_key (+ servername/key)
26// branch_alias (+ short form/long form)
27// trust_seed (+ branch/seed)
28ATOMIC(var_domain); // symbol-of-your-choosing
29ATOMIC(var_name); // symbol-of-your-choosing
30ATOMIC(var_value); // symbol-of-your-choosing
31
32ATOMIC(rsa_keypair_id); // keyname@domain.you.own
33ATOMIC(rsa_pub_key); // some nice numbers
34ATOMIC(rsa_priv_key); // some nice numbers
35ATOMIC(rsa_sha1_signature); // some other nice numbers
36
37DECORATE(revision); // thing associated with a revision
38DECORATE(manifest); // thing associated with a manifest
39DECORATE(file); // thing associated with a file
40DECORATE(epoch); // thing associated with an epoch
41
42ENCODING(gzip); // thing which is gzipped
43ENCODING(hexenc); // thing which is hex-encoded
44ENCODING(base64); // thing which is base64-encoded
45ENCODING(arc4); // thing which is arc4-encrypted
46
47ATOMIC(prefix); // raw encoding of a merkle tree prefix
48ATOMIC(merkle); // raw encoding of a merkle tree node
49
50// instantiate those bits of the template vocabulary actually in use.
51
52EXTERN template class hexenc<id>;
53EXTERN template class revision< hexenc<id> >;
54EXTERN template class manifest< hexenc<id> >;
55EXTERN template class file< hexenc<id> >;
56EXTERN template class epoch< hexenc<id> >;
57
58EXTERN template class hexenc<data>;
59EXTERN template class epoch< hexenc<data> >;
60
61EXTERN template class gzip<data>;
62EXTERN template class base64< gzip<data> >;
63EXTERN template class revision< base64< gzip<data> > >;
64EXTERN template class manifest< base64< gzip<data> > >;
65EXTERN template class file< base64< gzip<data> > >;
66
67EXTERN template class gzip<delta>;
68EXTERN template class base64< gzip<delta> >;
69EXTERN template class manifest< base64< gzip<delta> > >;
70EXTERN template class file< base64< gzip<delta> > >;
71
72EXTERN template class arc4<rsa_priv_key>;
73EXTERN template class base64< arc4<rsa_priv_key> >;
74EXTERN template class base64< rsa_pub_key >;
75EXTERN template class base64< rsa_sha1_signature >;
76EXTERN template class hexenc< rsa_sha1_signature >;
77EXTERN template class base64< cert_value >;
78
79EXTERN template class base64< var_name >;
80EXTERN template class base64< var_value >;
81
82EXTERN template class hexenc<prefix>;
83EXTERN template class base64<merkle>;
84EXTERN template class base64<data>;
85
86// instantiate those bits of the stream operator vocab (again) actually in
87// use. "again" since stream operators are friends, not members.
88
89EXTERN template std::ostream & operator<< <>(std::ostream &, hexenc<id> const &);
90EXTERN template std::ostream & operator<< <>(std::ostream &, revision< hexenc<id> > const &);
91EXTERN template std::ostream & operator<< <>(std::ostream &, manifest< hexenc<id> > const &);
92EXTERN template std::ostream & operator<< <>(std::ostream &, file< hexenc<id> > const &);
93EXTERN template std::ostream & operator<< <>(std::ostream &, epoch< hexenc<id> > const &);
94
95EXTERN template std::ostream & operator<< <>(std::ostream &, hexenc<data> const &);
96EXTERN template std::ostream & operator<< <>(std::ostream &, epoch< hexenc<data> > const &);
97
98EXTERN template std::ostream & operator<< <>(std::ostream &, gzip<data> const &);
99EXTERN template std::ostream & operator<< <>(std::ostream &, base64< gzip<data> > const &);
100EXTERN template std::ostream & operator<< <>(std::ostream &, revision< base64< gzip<data> > > const &);
101EXTERN template std::ostream & operator<< <>(std::ostream &, manifest< base64< gzip<data> > > const &);
102EXTERN template std::ostream & operator<< <>(std::ostream &, file< base64< gzip<data> > > const &);
103
104EXTERN template std::ostream & operator<< <>(std::ostream &, gzip<delta> const &);
105EXTERN template std::ostream & operator<< <>(std::ostream &, base64< gzip<delta> > const &);
106EXTERN template std::ostream & operator<< <>(std::ostream &, manifest< base64< gzip<delta> > > const &);
107EXTERN template std::ostream & operator<< <>(std::ostream &, file< base64< gzip<delta> > > const &);
108
109EXTERN template std::ostream & operator<< <>(std::ostream &, arc4<rsa_priv_key> const &);
110EXTERN template std::ostream & operator<< <>(std::ostream &, base64< arc4<rsa_priv_key> > const &);
111EXTERN template std::ostream & operator<< <>(std::ostream &, base64< rsa_pub_key > const &);
112EXTERN template std::ostream & operator<< <>(std::ostream &, base64< rsa_sha1_signature > const &);
113EXTERN template std::ostream & operator<< <>(std::ostream &, hexenc< rsa_sha1_signature > const &);
114EXTERN template std::ostream & operator<< <>(std::ostream &, base64< cert_value > const &);
115
116EXTERN template std::ostream & operator<< <>(std::ostream &, hexenc<prefix> const &);
117EXTERN 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