src/SocketHandler.h
branchv_0
changeset 2 fb399fd4f053
parent 1 e3265afd1111
child 3 e701e06ff561
equal deleted inserted replaced
1:e3265afd1111 2:fb399fd4f053
    52 
    52 
    53 public:
    53 public:
    54 
    54 
    55 	SocketHandler(Configuration configuration) : configuration(configuration) {
    55 	SocketHandler(Configuration configuration) : configuration(configuration) {
    56 		// TODO: do not throw exception from the constructor: Socket::open()
    56 		// TODO: do not throw exception from the constructor: Socket::open()
    57 		socket = std::make_shared<Socket>(); // TODO: create a TCP, UDP… socket
    57 		// socket = std::make_shared<TCPSocket>(); // TODO: create a TCP, UDP… socket
       
    58 		socket.reset(SocketFactory::find("tcp://TODO:connectionString")->open("tcp://TODO:connectionString2")); // TODO: connection string
    58 	}
    59 	}
    59 
    60 
    60 	void startRelation(relpipe::common::type::StringX name, std::vector<relpipe::reader::handlers::AttributeMetadata> attributes) override {
    61 	void startRelation(relpipe::common::type::StringX name, std::vector<relpipe::reader::handlers::AttributeMetadata> attributes) override {
    61 		currentRelation = CurrentRelation{name, attributes};
    62 		currentRelation = CurrentRelation{name, attributes};
    62 	}
    63 	}