mirror of
https://github.com/panda3d/panda3d.git
synced 2025-09-30 16:58:40 -04:00
*** empty log message ***
This commit is contained in:
parent
6a612fe439
commit
5a56af5c67
@ -37,6 +37,7 @@
|
|||||||
#begin test_bin_target
|
#begin test_bin_target
|
||||||
#define TARGET test_datagram
|
#define TARGET test_datagram
|
||||||
#define LOCAL_LIBS net
|
#define LOCAL_LIBS net
|
||||||
|
#define OTHER_LIBS pystub
|
||||||
|
|
||||||
#define SOURCES \
|
#define SOURCES \
|
||||||
test_datagram.cxx
|
test_datagram.cxx
|
||||||
@ -46,6 +47,7 @@
|
|||||||
#begin test_bin_target
|
#begin test_bin_target
|
||||||
#define TARGET test_spam_client
|
#define TARGET test_spam_client
|
||||||
#define LOCAL_LIBS net
|
#define LOCAL_LIBS net
|
||||||
|
#define OTHER_LIBS pystub
|
||||||
|
|
||||||
#define SOURCES \
|
#define SOURCES \
|
||||||
datagram_ui.cxx datagram_ui.h test_spam_client.cxx
|
datagram_ui.cxx datagram_ui.h test_spam_client.cxx
|
||||||
@ -55,6 +57,7 @@
|
|||||||
#begin test_bin_target
|
#begin test_bin_target
|
||||||
#define TARGET test_spam_server
|
#define TARGET test_spam_server
|
||||||
#define LOCAL_LIBS net
|
#define LOCAL_LIBS net
|
||||||
|
#define OTHER_LIBS pystub
|
||||||
|
|
||||||
#define SOURCES \
|
#define SOURCES \
|
||||||
datagram_ui.cxx datagram_ui.h test_spam_server.cxx
|
datagram_ui.cxx datagram_ui.h test_spam_server.cxx
|
||||||
@ -64,6 +67,7 @@
|
|||||||
#begin test_bin_target
|
#begin test_bin_target
|
||||||
#define TARGET test_tcp_client
|
#define TARGET test_tcp_client
|
||||||
#define LOCAL_LIBS net
|
#define LOCAL_LIBS net
|
||||||
|
#define OTHER_LIBS pystub
|
||||||
|
|
||||||
#define SOURCES \
|
#define SOURCES \
|
||||||
datagram_ui.cxx datagram_ui.h test_tcp_client.cxx
|
datagram_ui.cxx datagram_ui.h test_tcp_client.cxx
|
||||||
@ -73,6 +77,7 @@
|
|||||||
#begin test_bin_target
|
#begin test_bin_target
|
||||||
#define TARGET test_tcp_server
|
#define TARGET test_tcp_server
|
||||||
#define LOCAL_LIBS net
|
#define LOCAL_LIBS net
|
||||||
|
#define OTHER_LIBS pystub
|
||||||
|
|
||||||
#define SOURCES \
|
#define SOURCES \
|
||||||
datagram_ui.cxx datagram_ui.h test_tcp_server.cxx
|
datagram_ui.cxx datagram_ui.h test_tcp_server.cxx
|
||||||
@ -82,6 +87,7 @@
|
|||||||
#begin test_bin_target
|
#begin test_bin_target
|
||||||
#define TARGET test_udp
|
#define TARGET test_udp
|
||||||
#define LOCAL_LIBS net
|
#define LOCAL_LIBS net
|
||||||
|
#define OTHER_LIBS pystub
|
||||||
|
|
||||||
#define SOURCES \
|
#define SOURCES \
|
||||||
datagram_ui.cxx datagram_ui.h test_udp.cxx
|
datagram_ui.cxx datagram_ui.h test_udp.cxx
|
||||||
|
@ -48,11 +48,16 @@ ConnectionManager::
|
|||||||
// Function: ConnectionManager::open_UDP_connection
|
// Function: ConnectionManager::open_UDP_connection
|
||||||
// Access: Public
|
// Access: Public
|
||||||
// Description: Opens a socket for sending and/or receiving UDP
|
// Description: Opens a socket for sending and/or receiving UDP
|
||||||
// packets. If the port is non-negative, it will be
|
// packets. If the port number is negative, it will not
|
||||||
// bound to the connection; this is primarily a useful
|
// be bound to a socket; this is generally a pointless
|
||||||
// to do when the UDP connection will be used for
|
// thing to do. If the port number is zero, a random
|
||||||
// reading. Use a ConnectionReader and
|
// socket will be chosen. Otherwise, the specified
|
||||||
// ConnectionWriter to handle the actual communication.
|
// port number is used. Normally, you don't care what
|
||||||
|
// port a UDP connection is opened on, so you should use
|
||||||
|
// the default value of zero.
|
||||||
|
//
|
||||||
|
// Use a ConnectionReader and ConnectionWriter to handle
|
||||||
|
// the actual communication.
|
||||||
////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////
|
||||||
PT(Connection) ConnectionManager::
|
PT(Connection) ConnectionManager::
|
||||||
open_UDP_connection(int port) {
|
open_UDP_connection(int port) {
|
||||||
|
@ -40,7 +40,7 @@ public:
|
|||||||
ConnectionManager();
|
ConnectionManager();
|
||||||
virtual ~ConnectionManager();
|
virtual ~ConnectionManager();
|
||||||
|
|
||||||
PT(Connection) open_UDP_connection(int port = -1);
|
PT(Connection) open_UDP_connection(int port = 0);
|
||||||
|
|
||||||
PT(Connection) open_TCP_server_rendezvous(int port, int backlog);
|
PT(Connection) open_TCP_server_rendezvous(int port, int backlog);
|
||||||
PT(Connection) open_TCP_client_connection(const NetAddress &address,
|
PT(Connection) open_TCP_client_connection(const NetAddress &address,
|
||||||
|
@ -35,7 +35,9 @@ main(int argc, char *argv[]) {
|
|||||||
exit(1);
|
exit(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
nout << "Successfully opened UDP connection on port " << port << "\n";
|
nout << "Successfully opened UDP connection on port "
|
||||||
|
<< c->get_address().get_port() << " and IP "
|
||||||
|
<< c->get_address().get_ip() << "\n";
|
||||||
|
|
||||||
RecentConnectionReader reader(&cm);
|
RecentConnectionReader reader(&cm);
|
||||||
reader.add_connection(c);
|
reader.add_connection(c);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user