GammaLib 2.0.0
|
Abstract URL base class. More...
#include <GUrl.hpp>
Public Member Functions | |
GUrl (void) | |
Void constructor. | |
GUrl (const GUrl &url) | |
Copy constructor. | |
virtual | ~GUrl (void) |
Destructor. | |
GUrl & | operator= (const GUrl &url) |
Assignment operator. | |
virtual void | clear (void)=0 |
Clear object. | |
virtual GUrl * | clone (void) const =0 |
Clones object. | |
virtual std::string | classname (void) const =0 |
Return class name. | |
virtual void | open (const std::string &url, const std::string &mode)=0 |
virtual void | close (void)=0 |
virtual int | read (void *buffer, const int &nbyte)=0 |
virtual int | write (const void *buffer, const int &nbyte)=0 |
virtual int | get_char (void) const =0 |
virtual void | put_char (const int &character)=0 |
virtual void | scanf (const char *format,...)=0 |
virtual void | printf (const char *format,...)=0 |
virtual std::string | print (const GChatter &chatter=NORMAL) const =0 |
Print content of object. | |
Public Member Functions inherited from GBase | |
virtual | ~GBase (void) |
Destructor. | |
Protected Member Functions | |
void | init_members (void) |
Initialise class members. | |
void | copy_members (const GUrl &url) |
Copy class members. | |
void | free_members (void) |
Delete class members. | |
Abstract URL base class.
This class defines the abstract interface for all URL classes. The URL classes implement handling of various URL types through a standard interface. This allows to develop URL independent code.
GUrl::GUrl | ( | void | ) |
GUrl::GUrl | ( | const GUrl & | url | ) |
Copy constructor.
[in] | url | URL. |
Definition at line 66 of file GUrl.cpp.
References copy_members(), and init_members().
|
virtual |
|
pure virtual |
Return class name.
Returns the class name for non-abstract classes in a human readable way.
Implements GBase.
Implemented in GUrlFile, and GUrlString.
|
pure virtual |
Clear object.
Sets the object to a clean initial state. After calling the method the object will be in the same state as it were if an empty instance of the object would have been created.
Implements GBase.
Implemented in GUrlFile, and GUrlString.
|
pure virtual |
Clones object.
Creates a deep copy of the object and returns a pointer to the object.
Implements GBase.
Implemented in GUrlFile, and GUrlString.
|
pure virtual |
Implemented in GUrlFile, and GUrlString.
|
protected |
Copy class members.
[in] | url | URL. |
Definition at line 153 of file GUrl.cpp.
Referenced by GUrl(), and operator=().
|
protected |
Delete class members.
Definition at line 163 of file GUrl.cpp.
Referenced by GUrlFile::clear(), GUrlString::clear(), operator=(), and ~GUrl().
|
pure virtual |
Implemented in GUrlFile, and GUrlString.
Referenced by GXml::parse().
|
protected |
Initialise class members.
Definition at line 141 of file GUrl.cpp.
Referenced by GUrlFile::clear(), GUrlString::clear(), GUrl(), GUrl(), and operator=().
|
pure virtual |
Implemented in GUrlFile, and GUrlString.
Assignment operator.
[in] | url | URL. |
Definition at line 104 of file GUrl.cpp.
References copy_members(), free_members(), and init_members().
Referenced by GUrlFile::operator=(), and GUrlString::operator=().
Print content of object.
[in] | chatter | Chattiness (defaults to NORMAL). |
Formats the content in a standard way and puts this content in a C++ string that is returned.
Implements GBase.
Implemented in GUrlFile, and GUrlString.
|
pure virtual |
Implemented in GUrlFile, and GUrlString.
Referenced by GXmlAttribute::write(), GXmlComment::write(), GXmlDocument::write(), GXmlElement::write(), GXmlPI::write(), and GXmlText::write().
|
pure virtual |
Implemented in GUrlFile, and GUrlString.
|
pure virtual |
Implemented in GUrlFile, and GUrlString.
|
pure virtual |
Implemented in GUrlFile, and GUrlString.
|
pure virtual |
Implemented in GUrlFile, and GUrlString.