source: branches/nanovis2/packages/vizservers/nanovis/socket/ClientSocket.h @ 3305

Last change on this file since 3305 was 3305, checked in by ldelgass, 11 years ago

sync with trunk

  • Property svn:eol-style set to native
File size: 962 bytes
Line 
1/* -*- mode: c++; c-basic-offset: 4; indent-tabs-mode: nil -*- */
2/* ======================================================================
3 *  AUTHOR:  Wei Qiao <qiaow@purdue.edu>
4 *           Purdue Rendering and Perceptualization Lab (PURPL)
5 *
6 *  Copyright (c) 2004-2012  HUBzero Foundation, LLC
7 *
8 *  See the file "license.terms" for information on usage and
9 *  redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
10 * ======================================================================
11 */
12#ifndef CLIENTSOCKET_H
13#define CLIENTSOCKET_H
14
15#include "Socket.h"
16
17class ClientSocket : private Socket
18{
19public:
20    ClientSocket(std::string host, int port);
21    virtual ~ClientSocket()
22    {}
23
24    const ClientSocket& operator <<(const std::string&) const;
25    const ClientSocket& operator >>(std::string&) const;
26
27    bool send(char* s, int size) const;
28    int recv(char* s, int size) const;
29
30    void set_non_blocking(bool val);
31};
32
33#endif
Note: See TracBrowser for help on using the repository browser.