openrave.org

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Classes | Namespaces | Functions
utils.h File Reference

(2013-03-18 10:33:00 +0900, commit:334d202)

Programming related utilities likes tokenizers, timers, name checkers, etc. More...

#include <openrave/config.h>
#include <stdint.h>
#include <string>
#include <istream>
#include <vector>
#include <boost/shared_ptr.hpp>
#include <boost/weak_ptr.hpp>
#include <boost/function.hpp>
#include <boost/assert.hpp>
#include <time.h>
#include <sys/time.h>
#include <bitset>
Include dependency graph for utils.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  OpenRAVE::utils::null_deleter
 
struct  OpenRAVE::utils::index_cmp< T >
 
struct  OpenRAVE::utils::smart_pointer_deleter< P >
 allow to add different custom deleter funtions to a shared_ptr without touching its original custom deleter More...
 

Namespaces

namespace  OpenRAVE
 The entire OpenRAVE library.
 
namespace  OpenRAVE::utils
 

Functions

void OpenRAVE::utils::GetWallTime (uint32_t &sec, uint32_t &nsec)
 
uint64_t OpenRAVE::utils::GetNanoTime ()
 
uint64_t OpenRAVE::utils::GetMicroTime ()
 
uint32_t OpenRAVE::utils::GetMilliTime ()
 
static uint64_t OpenRAVE::utils::GetNanoPerformanceTime ()
 
template<class T >
boost::shared_ptr< T > OpenRAVE::utils::sptr_from (boost::weak_ptr< T > const &wpt)
 
std::string OpenRAVE::utils::ConvertToLowerCase (const std::string &s)
 returns a lower case version of the string
 
template<typename C >
void OpenRAVE::utils::TokenizeString (std::string const &s, char const *d, C &ret)
 separates the directories from a string and returns them in a vector
 
OPENRAVE_API std::string OpenRAVE::utils::GetFilenameUntilSeparator (std::istream &sinput, char separator)
 gets the string up the next separator and strips it of leading whitespace.
 
OPENRAVE_API std::string & OpenRAVE::utils::SearchAndReplace (std::string &out, const std::string &in, const std::vector< std::pair< std::string, std::string > > &pairs)
 search and replace strings for all pairs. Internally first checks the longest strings before the shortest
 
OPENRAVE_API std::string OpenRAVE::utils::GetMD5HashString (const std::string &s)
 compute the md5 hash of a string
 
OPENRAVE_API std::string OpenRAVE::utils::GetMD5HashString (const std::vector< uint8_t > &v)
 compute the md5 hash of an array
 
template<class T >
OpenRAVE::utils::ClampOnRange (T value, T min, T max)
 
template<typename T >
OpenRAVE::utils::NormalizeCircularAngle (T theta, T min, T max)
 
template<typename T >
OpenRAVE::utils::SubtractCircularAngle (T f0, T f1)
 
template<typename T >
OpenRAVE::utils::InterpolateCircularAngle (T start, T end, T fraction, T lowerLimit, T upperLimit)
 
template<typename T >
OpenRAVE::utils::Sqr (T t)
 
bool OpenRAVE::utils::IsValidCharInName (char c)
 openrave valid characters to be used in names
 
bool OpenRAVE::utils::IsValidName (const std::string &s)
 openrave valid characters to be used in names
 
std::string OpenRAVE::utils::ConvertToOpenRAVEName (const std::string &name)
 converts improper characters to _ so the entire name is valid
 

Detailed Description

Programming related utilities likes tokenizers, timers, name checkers, etc.

This file is optional and not automatically included with openrave.h . Furthermore, it can be used stand-alone without openrave.h .

Definition in file utils.h.