[complement-svn] SF.net SVN: complement: [1649] trunk/complement/explore/include/stem/Event. h
Status: Pre-Alpha
Brought to you by:
complement
From: <com...@us...> - 2007-07-27 11:37:59
|
Revision: 1649 http://complement.svn.sourceforge.net/complement/?rev=1649&view=rev Author: complement Date: 2007-07-27 04:37:55 -0700 (Fri, 27 Jul 2007) Log Message: ----------- add constructors with reasonable defaults for gaddr_type Modified Paths: -------------- trunk/complement/explore/include/stem/Event.h Modified: trunk/complement/explore/include/stem/Event.h =================================================================== --- trunk/complement/explore/include/stem/Event.h 2007-07-27 10:58:07 UTC (rev 1648) +++ trunk/complement/explore/include/stem/Event.h 2007-07-27 11:37:55 UTC (rev 1649) @@ -28,6 +28,7 @@ #include <stem/EvPack.h> #include <mt/uid.h> +#include <mt/xmt.h> #ifndef STLPORT #include <bits/cpp_type_traits.h> @@ -102,12 +103,24 @@ addr( badaddr ) { } - gaddr_type( const xmt::uuid_type& _hid, pid_t _pid, stem::addr_type _addr ) : + explicit gaddr_type( const xmt::uuid_type& _hid, pid_t _pid, stem::addr_type _addr ) : hid( _hid ), pid( _pid ), addr( _addr ) { } + explicit gaddr_type( pid_t _pid, stem::addr_type _addr ) : + hid( xmt::hostid() ), + pid( _pid ), + addr( _addr ) + { } + + explicit gaddr_type( stem::addr_type _addr ) : + hid( xmt::hostid() ), + pid( xmt::getpid() ), + addr( _addr ) + { } + gaddr_type( const gaddr_type& g ) : hid( g.hid ), pid( g.pid ), This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |