prefix_ senf::UNAddress::UNAddress()
//:path("")
{
- path = boost::filesystem::path("");
+ path = "";
}
-prefix_ senf::UNAddress::UNAddress(boost::filesystem::path p)
+prefix_ senf::UNAddress::UNAddress(std::string p)
{
path = p;
}
prefix_ senf::UNAddress::UNAddress senf::UNAddress::fromString(std::string & s)
{
- return senf::UNAddress::UNAddress(boost::filesystem::path(s));
+ return senf::UNAddress::UNAddress(s);
}
-prefix_ senf::UNAddress::UNAddress senf::UNAddress::fromPath(boost::filesystem::path & p){
- return senf::UNAddress::UNAddress(p);
-}
prefix_ std::string senf::UNAddress::pathString()
const
{
- return path.string();
+ return path;
}
prefix_ senf::UNAddress::UNAddress senf::UNAddress::clone()
// Custom includes
#include <string>
#include <boost/operators.hpp>
-#include <boost/filesystem/path.hpp>
#include "../../../Utils/safe_bool.hh"
//#include "UNAddress.mpp"
\ingroup addr_group
*/
class UNAddress
- : public boost::filesystem::path,
- public comparable_safe_bool<UNAddress>
+ : public comparable_safe_bool<UNAddress>
{
public:
UNAddress(); ///< Construct an empty address
- explicit UNAddress(boost::filesystem::path);///< Construct an address constant from given path
+ explicit UNAddress(std::string);///< Construct an address constant from given path
static UNAddress fromString(std::string & s); ///< Convert string to address by interpreting the string as path
- static UNAddress fromPath(boost::filesystem::path & p);///< Convert path to address
UNAddress clone(); ///< Clone object
std::string pathString() const; ///< Return the path of the address as string
struct AddressException : public std::exception {};
private:
- boost::filesystem::path path;
+ std::string path;
};
std::ostream & operator<<(std::ostream & os, UNAddress const & addr);
// Custom includes
#include <stdio.h>
#include <boost/operators.hpp>
-#include <boost/filesystem/path.hpp>
#define prefix_
///////////////////////////////cc.p////////////////////////////////////////
-prefix_ senf::UNSocketAddress::UNSocketAddress(boost::filesystem::path p)
+prefix_ senf::UNSocketAddress::UNSocketAddress(std::string p)
{
sockAddr.sun_family = AF_UNIX;
- strcpy(sockAddr.sun_path, p.string().c_str());
+ strcpy(sockAddr.sun_path, p.c_str());
}
prefix_ senf::UNSocketAddress fromString(std::string s) {
- return senf::UNSocketAddress::UNSocketAddress(boost::filesystem::path(s));
+ return senf::UNSocketAddress::UNSocketAddress(s);
}
-prefix_ senf::UNSocketAddress fromPath(boost::filesystem::path p)
-{
- return senf::UNSocketAddress::UNSocketAddress(p);
-}
prefix_ std::string senf::UNSocketAddress::path()
const
#include <sys/un.h>
#include <boost/cstdint.hpp>
#include <boost/operators.hpp>
-#include "boost/filesystem/path.hpp"
#include "../../../Socket/SocketPolicy.hh"
#include "../../../Socket/ClientSocketHandle.hh"
#include "../../../Socket/CommunicationPolicy.hh"
public:
//UNSocketAddress();
- explicit UNSocketAddress(boost::filesystem::path p);
+ explicit UNSocketAddress(std::string p);
///< Construct an address constant from given path
static UNSocketAddress from_string(std::string const s); ///< Create UNSocketAddress from string
- static UNSocketAddress from_path(boost::filesystem::path const p); ///< Create UNSocketAddress from path
std::string path() const ; ///< Return path as string
struct sockaddr_un sockaddr();
struct sockaddr * sockaddr_p() ;