bes
Updated for version 3.20.6
|
40 #include <BESCatalog.h>
44 static std::string rfc822_date(
const time_t t);
46 static std::string entity(
char c);
62 static std::string
www2id(
const std::string &in,
const std::string &escape =
"%",
const std::string &except =
"");
63 static std::string unhexstring(std::string s);
66 static std::string
lowercase(
const std::string &s);
69 static std::string
unescape(
const std::string &s);
72 static void check_path(
const std::string &path,
const std::string &root,
bool follow_sym_links);
82 static std::string
id2xml(std::string in,
const std::string ¬_allowed =
"><&'\"");
85 static std::string
xml2id(std::string in);
88 static void explode(
char delim,
const std::string &str, std::list<std::string> &values);
91 static std::string
implode(
const std::list<std::string> &values,
char delim);
105 static std::string
assemblePath(
const std::string &firstPart,
const std::string &secondPart,
bool leadingSlash =
false,
bool trailingSlash =
false);
106 static std::string
pathConcat(
const std::string &firstPart,
const std::string &secondPart,
char separator=
'/');
108 static bool endsWith(std::string
const &fullString, std::string
const &ending);
111 static void replace_all(std::string &s, std::string find_this, std::string replace_with_this);
112 static std::string
normalize_path(
const std::string &path,
bool leading_separator,
bool trailing_separator,
const std::string separator =
"/");
113 static void tokenize(
const std::string& str, std::vector<std::string>& tokens,
const std::string& delimiters =
"/");
114 static std::string
get_time(
bool use_local_time =
false);
115 static std::string
get_time(time_t the_time,
bool use_local_time =
false);
116 static std::vector<std::string>
split(
const std::string &s,
char delim=
'/',
bool skip_empty=
true);
118 static BESCatalog *separateCatalogFromPath(std::string &path);
121 #endif // E_BESUtil_h
static void replace_all(std::string &s, std::string find_this, std::string replace_with_this)
Operates on the string 's' to replaces every occurrence of the value of the string 'find_this' with t...
static void tokenize(const std::string &str, std::vector< std::string > &tokens, const std::string &delimiters="/")
static void set_mime_html(std::ostream &strm)
Generate an HTTP 1.0 response header for a html document.
static std::string normalize_path(const std::string &path, bool leading_separator, bool trailing_separator, const std::string separator="/")
Removes duplicate separators and provides leading and trailing separators as directed.
static void check_path(const std::string &path, const std::string &root, bool follow_sym_links)
Check if the specified path is valid.
static void conditional_timeout_cancel()
static std::string www2id(const std::string &in, const std::string &escape="%", const std::string &except="")
static std::string get_time(bool use_local_time=false)
static std::string assemblePath(const std::string &firstPart, const std::string &secondPart, bool leadingSlash=false, bool trailingSlash=false)
Assemble path fragments making sure that they are separated by a single '/' character.
static void set_mime_text(std::ostream &strm)
Generate an HTTP 1.0 response header for a text document.
static char * fastpidconverter(char *buf, int base)
static void url_explode(const std::string &url_str, BESUtil::url &url_parts)
Given a url, break the url into its different parts.
static bool endsWith(std::string const &fullString, std::string const &ending)
static std::string xml2id(std::string in)
static std::string id2xml(std::string in, const std::string ¬_allowed="><&'\"")
static void explode(char delim, const std::string &str, std::list< std::string > &values)
static std::vector< std::string > split(const std::string &s, char delim='/', bool skip_empty=true)
Splits the string s into the return vector of tokens using the delimiter delim and skipping empty val...
static std::string lowercase(const std::string &s)
static std::string implode(const std::list< std::string > &values, char delim)
static std::string unescape(const std::string &s)
Catalogs provide a hierarchical organization for data.
static std::string pathConcat(const std::string &firstPart, const std::string &secondPart, char separator='/')
Concatenate path fragments making sure that they are separated by a single '/' character.
static void removeLeadingAndTrailingBlanks(std::string &key)