Annotation of parser3/src/types/pa_vresponse.h, revision 1.25
1.3 paf 1: /** @file
2: Parser: response class.
3:
1.20 paf 4: Copyright (c) 2001, 2002 ArtLebedev Group (http://www.artlebedev.com)
1.21 paf 5: Author: Alexandr Petrosian <paf@design.ru> (http://paf.design.ru)
1.1 paf 6: */
7:
8: #ifndef PA_VRESPONSE_H
9: #define PA_VRESPONSE_H
1.23 paf 10:
1.25 ! paf 11: static const char* IDENT_VRESPONSE_H="$Date: 2002/08/01 11:41:24 $";
1.1 paf 12:
1.3 paf 13: #include "pa_vstateless_object.h"
1.1 paf 14: #include "pa_string.h"
1.19 paf 15: #include "classes.h"
16:
17: // forwards
18:
19: class Response;
1.9 paf 20:
1.11 parser 21: // externals
22:
1.9 paf 23: extern Methoded *response_class;
1.1 paf 24:
1.5 paf 25: /// value of type 'response'
1.3 paf 26: class VResponse : public VStateless_object {
1.1 paf 27: public: // Value
28:
29: const char *type() const { return "response"; }
1.22 paf 30: VStateless_class *get_class() { return response_class; }
1.2 paf 31:
1.5 paf 32: /// Response: ffields
1.16 parser 33: Hash *get_hash(const String * /*source*/) { return &ffields; }
1.1 paf 34:
1.8 paf 35: /// Response: method,fields
1.19 paf 36: Value *get_element(const String& name);
1.1 paf 37:
1.5 paf 38: /// Response: (attribute)=value
1.19 paf 39: void put_element(const String& name, Value *value);
1.1 paf 40:
41: public: // usage
42:
1.22 paf 43: VResponse(Pool& apool) : VStateless_object(apool),
1.1 paf 44: ffields(apool) {
45: }
1.11 parser 46: public:
1.12 parser 47:
1.1 paf 48: Hash& fields() { return ffields; }
49:
50: private:
51:
52: Hash ffields;
53:
54: };
55:
56: #endif
E-mail: