Panda3D
httpEntityTag.h
1 // Filename: httpEntityTag.h
2 // Created by: drose (28Jan03)
3 //
4 ////////////////////////////////////////////////////////////////////
5 //
6 // PANDA 3D SOFTWARE
7 // Copyright (c) Carnegie Mellon University. All rights reserved.
8 //
9 // All use of this software is subject to the terms of the revised BSD
10 // license. You should have received a copy of this license along
11 // with this source code in a file named "LICENSE."
12 //
13 ////////////////////////////////////////////////////////////////////
14 
15 #ifndef HTTPENTITYTAG_H
16 #define HTTPENTITYTAG_H
17 
18 #include "pandabase.h"
19 
20 ////////////////////////////////////////////////////////////////////
21 // Class : HTTPEntityTag
22 // Description : A container for an "entity tag" from an HTTP server.
23 // This is used to identify a particular version of a
24 // document or resource, particularly useful for
25 // verifying caches.
26 ////////////////////////////////////////////////////////////////////
27 class EXPCL_PANDAEXPRESS HTTPEntityTag {
28 PUBLISHED:
29  INLINE HTTPEntityTag();
30  HTTPEntityTag(const string &text);
31  INLINE HTTPEntityTag(bool weak, const string &tag);
32  INLINE HTTPEntityTag(const HTTPEntityTag &copy);
33  INLINE void operator = (const HTTPEntityTag &copy);
34 
35  INLINE bool is_weak() const;
36  INLINE const string &get_tag() const;
37  string get_string() const;
38 
39  INLINE bool strong_equiv(const HTTPEntityTag &other) const;
40  INLINE bool weak_equiv(const HTTPEntityTag &other) const;
41 
42  INLINE bool operator == (const HTTPEntityTag &other) const;
43  INLINE bool operator != (const HTTPEntityTag &other) const;
44  INLINE bool operator < (const HTTPEntityTag &other) const;
45  INLINE int compare_to(const HTTPEntityTag &other) const;
46 
47  INLINE void output(ostream &out) const;
48 
49 private:
50  bool _weak;
51  string _tag;
52 };
53 
54 INLINE ostream &operator << (ostream &out, const HTTPEntityTag &url);
55 
56 #include "httpEntityTag.I"
57 
58 #endif
A container for an "entity tag" from an HTTP server.
Definition: httpEntityTag.h:27
An STL function object class, this is intended to be used on any ordered collection of class objects ...
Definition: stl_compares.h:79