Annotation of parser3/src/types/pa_vresponse.h, revision 1.38
1.3 paf 1: /** @file
2: Parser: response class.
3:
1.35 paf 4: Copyright (c) 2001-2004 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.38 ! paf 11: static const char * const IDENT_VRESPONSE_H="$Date: 2005/07/28 10:02:27 $";
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.33 paf 20: class Request_info;
21: class Request_charsets;
1.9 paf 22:
1.11 parser 23: // externals
24:
1.33 paf 25: extern Methoded* response_class;
1.1 paf 26:
1.5 paf 27: /// value of type 'response'
1.33 paf 28: class VResponse: public VStateless_object {
29:
30: Request_info& finfo;
31: Request_charsets& fcharsets;
32:
33: HashStringValue ffields;
34:
1.1 paf 35: public: // Value
36:
1.33 paf 37: override const char* type() const { return "response"; }
38: override VStateless_class *get_class() { return response_class; }
1.2 paf 39:
1.5 paf 40: /// Response: ffields
1.33 paf 41: override HashStringValue* get_hash() { return &ffields; }
1.1 paf 42:
1.8 paf 43: /// Response: method,fields
1.33 paf 44: override Value* get_element(const String& aname, Value& aself, bool /*looking_up*/);
1.1 paf 45:
1.5 paf 46: /// Response: (attribute)=value
1.38 ! paf 47: override const Junction* put_element(Value& self, const String& name, Value* value, bool replace);
1.1 paf 48:
1.33 paf 49: public: // usage
1.1 paf 50:
1.33 paf 51: VResponse(Request_info& ainfo, Request_charsets& acharsets):
52: finfo(ainfo), fcharsets(acharsets) {}
1.12 parser 53:
1.33 paf 54: /// used in pa_request.C
55: HashStringValue& fields() { return ffields; }
1.1 paf 56:
1.33 paf 57: };
1.1 paf 58:
59:
60: #endif
E-mail: