Utility methods for NT types.
More...
#include "ntutils.h"
|
static bool | is_a (const std::string &u1, const std::string &u2) |
|
Utility methods for NT types.
- Author
- mse
Definition at line 19 of file ntutils.h.
bool epics::nt::NTUtils::is_a |
( |
const std::string & |
u1, |
|
|
const std::string & |
u2 |
|
) |
| |
|
static |
Checks whether NT types are compatible by checking their IDs, i.e. their names and major version must match.
- Parameters
-
u1 | the first URI. |
u2 | the second URI. |
- Returns
- true if URIs are compatible, false otherwise.
Definition at line 14 of file ntutils.cpp.
17 size_t pos1 = u1.find_last_of(
'.');
18 std::string su1 = (pos1 == string::npos) ? u1 : u1.substr(0, pos1);
21 size_t pos2 = u2.find_last_of(
'.');
22 std::string su2 = (pos2 == string::npos) ? u2 : u2.substr(0, pos2);
The documentation for this class was generated from the following files: