summaryrefslogtreecommitdiff
path: root/ACE/ace/DEV_Addr.inl
diff options
context:
space:
mode:
authorWilliam R. Otte <wotte@dre.vanderbilt.edu>2008-03-04 14:51:23 +0000
committerWilliam R. Otte <wotte@dre.vanderbilt.edu>2008-03-04 14:51:23 +0000
commit99aa8c60282c7b8072eb35eb9ac815702f5bf586 (patch)
treebda96bf8c3a4c2875a083d7b16720533c8ffeaf4 /ACE/ace/DEV_Addr.inl
parentc4078c377d74290ebe4e66da0b4975da91732376 (diff)
downloadATCD-99aa8c60282c7b8072eb35eb9ac815702f5bf586.tar.gz
undoing accidental deletion
Diffstat (limited to 'ACE/ace/DEV_Addr.inl')
-rw-r--r--ACE/ace/DEV_Addr.inl51
1 files changed, 51 insertions, 0 deletions
diff --git a/ACE/ace/DEV_Addr.inl b/ACE/ace/DEV_Addr.inl
new file mode 100644
index 00000000000..820b961d1d0
--- /dev/null
+++ b/ACE/ace/DEV_Addr.inl
@@ -0,0 +1,51 @@
+// -*- C++ -*-
+//
+// $Id$
+
+#include "ace/OS_NS_string.h"
+#include "ace/Global_Macros.h"
+#include "ace/os_include/sys/os_socket.h"
+
+ACE_BEGIN_VERSIONED_NAMESPACE_DECL
+
+ACE_INLINE void
+ACE_DEV_Addr::set (const ACE_TCHAR *devname)
+{
+ ACE_TRACE ("ACE_DEV_Addr::set");
+
+ this->ACE_Addr::base_set
+ (AF_DEV, static_cast<int> (ACE_OS::strlen (devname)));
+ ACE_OS::strsncpy (this->devname_, devname, ACE_DEV_Addr::DEVNAME_LENGTH);
+}
+
+// Compare two addresses for equality.
+
+ACE_INLINE bool
+ACE_DEV_Addr::operator == (const ACE_DEV_Addr &sap) const
+{
+ ACE_TRACE ("ACE_DEV_Addr::operator ==");
+
+ return ACE_OS::strcmp (this->devname_, sap.devname_) == 0;
+}
+
+// Compare two addresses for inequality.
+
+ACE_INLINE bool
+ACE_DEV_Addr::operator != (const ACE_DEV_Addr &sap) const
+{
+ ACE_TRACE ("ACE_DEV_Addr::operator !=");
+
+ return !((*this) == sap); // This is lazy, of course... ;-).
+}
+
+// Return the path name used for the rendezvous point.
+
+ACE_INLINE const ACE_TCHAR *
+ACE_DEV_Addr::get_path_name (void) const
+{
+ ACE_TRACE ("ACE_DEV_Addr::get_path_name");
+
+ return this->devname_;
+}
+
+ACE_END_VERSIONED_NAMESPACE_DECL