libdap Updated for version 3.21.1
libdap4 is an implementation of OPeNDAP's DAP protocol.
|
Associate a rule with an ancillary resource. More...
#include <Resource.h>
Public Types | |
enum | rule { overwrite , replace , fallback } |
How are ancillary resources used. More... | |
Public Member Functions | |
virtual Resource::rule | get_rule () const |
virtual string | get_url () const |
Resource () | |
Resource (const string &u) | |
Resource (const string &u, const rule &r) | |
Resource (const string &u, const string &r) throw (Error) | |
virtual void | set_rule (const Resource::rule &r) |
virtual void | set_url (const string &u) |
virtual | ~Resource () |
Friends | |
ostream & | operator<< (ostream &os, const Resource &r) |
Associate a rule with an ancillary resource.
Bind an ancillary resource with the rule that should be used when combining it with a primary resource. Ancillary resources are always specified using URLs. If an ancillary resource is a local file, use file://
URLs.
Note that operator<< is defined for Resource as a function.
Definition at line 49 of file Resource.h.
How are ancillary resources used.
The AIS uses this enumeration to describe how a given ancillary should be merged into a primary data source.
Enumerator | |
---|---|
overwrite | |
replace | |
fallback |
Definition at line 68 of file Resource.h.
|
inline |
Build a Resource with a null URL and set the combination rule to the default.
Definition at line 72 of file Resource.h.
|
inline |
Build a resource. Set the combination rule to the default value, which is overwrite.
u | The ancillary resource URL. |
Definition at line 77 of file Resource.h.
Build a Resource.
u | The ancillary resource URL. |
r | The combination rule. |
Definition at line 82 of file Resource.h.
Build a Resource.
Note: If this is used in a callback, make sure to check the value of r
before calling this constructor. Exceptions thrown within callbacks are not portable. Valid values are "overwrite", "replace" and "fallback". The constructor accepts "default" as a synonym for "overwrite".
u | The ancillary resource URL. |
r | The name of the combination rule. |
Definition at line 94 of file Resource.h.
|
inlinevirtual |
Definition at line 105 of file Resource.h.
|
inlinevirtual |
Return combination rule for this resource.
Definition at line 115 of file Resource.h.
|
inlinevirtual |
Return the resource URL.
Definition at line 108 of file Resource.h.
|
inlinevirtual |
Set the resource's combination rule.
r | The combination rule. |
Definition at line 119 of file Resource.h.
|
inlinevirtual |
Write the XML for this resource. This function is defined in AISResoruces.
os | Write to this ostream. @paran r The Resource to write. |
Output the XML fragment for a Resource. This function is a friend of the Resource class.
os | output stream |
r | Resource to write out. |
Definition at line 45 of file AISResources.cc.