summaryrefslogtreecommitdiffabout
path: root/include
authorMichael Krelin <hacker@klever.net>2008-03-03 17:06:17 (UTC)
committer Michael Krelin <hacker@klever.net>2008-03-03 17:06:17 (UTC)
commit374985b5317d559b561d7f557034661e314f5605 (patch) (unidiff)
treea29c5c415cb046330d8e046c0ad9b7b94bc76593 /include
parentc28479399ef0fedeb6bf14ec665bb4c427654356 (diff)
downloadlibopkele-374985b5317d559b561d7f557034661e314f5605.zip
libopkele-374985b5317d559b561d7f557034661e314f5605.tar.gz
libopkele-374985b5317d559b561d7f557034661e314f5605.tar.bz2
removed basic_message::fields_t typedef
Signed-off-by: Michael Krelin <hacker@klever.net>
Diffstat (limited to 'include') (more/less context) (ignore whitespace changes)
-rw-r--r--include/opkele/types.h1
1 files changed, 0 insertions, 1 deletions
diff --git a/include/opkele/types.h b/include/opkele/types.h
index 64f165c..bf50e2b 100644
--- a/include/opkele/types.h
+++ b/include/opkele/types.h
@@ -75,97 +75,96 @@ namespace opkele {
75 public: 75 public:
76 76
77 virtual ~association_t() { } 77 virtual ~association_t() { }
78 78
79 /** 79 /**
80 * retrieve the server with which association was established. 80 * retrieve the server with which association was established.
81 * @return server name 81 * @return server name
82 */ 82 */
83 virtual string server() const = 0; 83 virtual string server() const = 0;
84 /** 84 /**
85 * retrieve the association handle. 85 * retrieve the association handle.
86 * @return handle 86 * @return handle
87 */ 87 */
88 virtual string handle() const = 0; 88 virtual string handle() const = 0;
89 /** 89 /**
90 * retrieve the association type. 90 * retrieve the association type.
91 * @return association type 91 * @return association type
92 */ 92 */
93 virtual string assoc_type() const = 0; 93 virtual string assoc_type() const = 0;
94 /** 94 /**
95 * retrieve the association secret. 95 * retrieve the association secret.
96 * @return association secret 96 * @return association secret
97 */ 97 */
98 virtual secret_t secret() const = 0; 98 virtual secret_t secret() const = 0;
99 /** 99 /**
100 * retrieve the number of seconds the association expires in. 100 * retrieve the number of seconds the association expires in.
101 * @return seconds till expiration 101 * @return seconds till expiration
102 */ 102 */
103 virtual int expires_in() const = 0; 103 virtual int expires_in() const = 0;
104 /** 104 /**
105 * check whether the association is stateless. 105 * check whether the association is stateless.
106 * @return true if stateless 106 * @return true if stateless
107 */ 107 */
108 virtual bool stateless() const = 0; 108 virtual bool stateless() const = 0;
109 /** 109 /**
110 * check whether the association is expired. 110 * check whether the association is expired.
111 * @return true if expired 111 * @return true if expired
112 */ 112 */
113 virtual bool is_expired() const = 0; 113 virtual bool is_expired() const = 0;
114 }; 114 };
115 115
116 /** 116 /**
117 * the shared_ptr<> for association_t object type 117 * the shared_ptr<> for association_t object type
118 */ 118 */
119 typedef tr1mem::shared_ptr<association_t> assoc_t; 119 typedef tr1mem::shared_ptr<association_t> assoc_t;
120 120
121 class basic_message { 121 class basic_message {
122 public: 122 public:
123 typedef list<string> fields_t;
124 typedef util::forward_iterator_proxy< 123 typedef util::forward_iterator_proxy<
125 string,const string&,const string* 124 string,const string&,const string*
126 > fields_iterator; 125 > fields_iterator;
127 126
128 basic_message() { } 127 basic_message() { }
129 virtual ~basic_message() { } 128 virtual ~basic_message() { }
130 basic_message(const basic_message& x); 129 basic_message(const basic_message& x);
131 void copy_to(basic_message& x) const; 130 void copy_to(basic_message& x) const;
132 void append_to(basic_message& x) const; 131 void append_to(basic_message& x) const;
133 132
134 virtual bool has_field(const string& n) const = 0; 133 virtual bool has_field(const string& n) const = 0;
135 virtual const string& get_field(const string& n) const = 0; 134 virtual const string& get_field(const string& n) const = 0;
136 135
137 virtual fields_iterator fields_begin() const = 0; 136 virtual fields_iterator fields_begin() const = 0;
138 virtual fields_iterator fields_end() const = 0; 137 virtual fields_iterator fields_end() const = 0;
139 138
140 virtual string append_query(const string& url,const char *pfx=0) const; 139 virtual string append_query(const string& url,const char *pfx=0) const;
141 virtual string query_string(const char *pfx=0) const; 140 virtual string query_string(const char *pfx=0) const;
142 141
143 virtual void reset_fields(); 142 virtual void reset_fields();
144 virtual void set_field(const string& n,const string& v); 143 virtual void set_field(const string& n,const string& v);
145 virtual void reset_field(const string& n); 144 virtual void reset_field(const string& n);
146 145
147 }; 146 };
148 147
149 class basic_openid_message : public basic_message { 148 class basic_openid_message : public basic_message {
150 public: 149 public:
151 typedef list<string> fields_t; 150 typedef list<string> fields_t;
152 typedef util::forward_iterator_proxy< 151 typedef util::forward_iterator_proxy<
153 string,const string&,const string* 152 string,const string&,const string*
154 > fields_iterator; 153 > fields_iterator;
155 154
156 basic_openid_message() { } 155 basic_openid_message() { }
157 basic_openid_message(const basic_openid_message& x); 156 basic_openid_message(const basic_openid_message& x);
158 157
159 virtual bool has_ns(const string& uri) const; 158 virtual bool has_ns(const string& uri) const;
160 virtual string get_ns(const string& uri) const; 159 virtual string get_ns(const string& uri) const;
161 160
162 virtual string append_query(const string& url,const char *pfx="openid.") const { 161 virtual string append_query(const string& url,const char *pfx="openid.") const {
163 return basic_message::append_query(url,pfx); } 162 return basic_message::append_query(url,pfx); }
164 virtual string query_string(const char *pfx="openid.") const { 163 virtual string query_string(const char *pfx="openid.") const {
165 return basic_message::query_string(pfx); } 164 return basic_message::query_string(pfx); }
166 165
167 virtual void from_keyvalues(const string& kv); 166 virtual void from_keyvalues(const string& kv);
168 virtual void to_keyvalues(ostream& o) const; 167 virtual void to_keyvalues(ostream& o) const;
169 168
170 virtual void to_htmlhiddens(ostream& o,const char* pfx=0) const; 169 virtual void to_htmlhiddens(ostream& o,const char* pfx=0) const;
171 170