small formatting issues and helper api
This commit is contained in:
parent
6bd5a6c73b
commit
815f07506c
3 changed files with 9 additions and 7 deletions
|
|
@ -25,10 +25,12 @@ namespace fc {
|
||||||
const T& operator[]( size_t pos )const { assert( pos < N); return data[pos]; }
|
const T& operator[]( size_t pos )const { assert( pos < N); return data[pos]; }
|
||||||
|
|
||||||
|
|
||||||
T* begin() { return &data[0]; }
|
|
||||||
const T* begin()const { return &data[0]; }
|
const T* begin()const { return &data[0]; }
|
||||||
const T* end()const { return &data[N]; }
|
const T* end()const { return &data[N]; }
|
||||||
|
|
||||||
|
T* begin() { return &data[0]; }
|
||||||
|
T* end() { return &data[N]; }
|
||||||
|
|
||||||
size_t size()const { return N; }
|
size_t size()const { return N; }
|
||||||
|
|
||||||
T data[N];
|
T data[N];
|
||||||
|
|
|
||||||
|
|
@ -31,7 +31,7 @@ namespace fc {
|
||||||
path();
|
path();
|
||||||
~path();
|
~path();
|
||||||
path( const boost::filesystem::path& );
|
path( const boost::filesystem::path& );
|
||||||
path( const fc::string& p );
|
path( const std::string& p );
|
||||||
/// Constructor to build path using unicode native characters.
|
/// Constructor to build path using unicode native characters.
|
||||||
path(const std::wstring& p);
|
path(const std::wstring& p);
|
||||||
path( const char* );
|
path( const char* );
|
||||||
|
|
@ -54,12 +54,12 @@ namespace fc {
|
||||||
fc::path extension()const;
|
fc::path extension()const;
|
||||||
fc::path filename()const;
|
fc::path filename()const;
|
||||||
fc::path parent_path()const;
|
fc::path parent_path()const;
|
||||||
fc::string string()const;
|
std::string string()const;
|
||||||
fc::string generic_string()const;
|
std::string generic_string()const;
|
||||||
/** On windows, returns a path where all path separators are '\' suitable for displaying
|
/** On windows, returns a path where all path separators are '\' suitable for displaying
|
||||||
* to users. On other platforms, it does the same as generic_string()
|
* to users. On other platforms, it does the same as generic_string()
|
||||||
*/
|
*/
|
||||||
fc::string preferred_string() const;
|
std::string preferred_string() const;
|
||||||
|
|
||||||
std::wstring wstring() const;
|
std::wstring wstring() const;
|
||||||
std::wstring generic_wstring() const;
|
std::wstring generic_wstring() const;
|
||||||
|
|
@ -77,7 +77,7 @@ namespace fc {
|
||||||
*
|
*
|
||||||
* @note not part of boost::filesystem::path
|
* @note not part of boost::filesystem::path
|
||||||
*/
|
*/
|
||||||
fc::string windows_string()const;
|
std::string windows_string()const;
|
||||||
|
|
||||||
bool is_relative()const;
|
bool is_relative()const;
|
||||||
bool is_absolute()const;
|
bool is_absolute()const;
|
||||||
|
|
|
||||||
|
|
@ -61,7 +61,7 @@ namespace fc {
|
||||||
*
|
*
|
||||||
* @code
|
* @code
|
||||||
* void write_message() {
|
* void write_message() {
|
||||||
* boost::unique_lock<cmt::mutex> lock(sock->write_lock);
|
* boost::unique_lock<fc::mutex> lock(sock->write_lock);
|
||||||
* sock->write(part1); // may yield
|
* sock->write(part1); // may yield
|
||||||
* sock->write(part2); // may yield
|
* sock->write(part2); // may yield
|
||||||
* sock->write(part3); // may yield
|
* sock->write(part3); // may yield
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue