Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add stub dynamic network interface implementation. #99

Open
wants to merge 2 commits into
base: rolling
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions rmw_connextdds_common/include/rmw_connextdds/rmw_impl.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,14 @@ bool rmw_connextdds_find_string_in_list(
DDS_Duration_t rmw_connextdds_duration_from_ros_time(
const rmw_time_t * const ros_time);

/**
* This function returns `NULL` when either the node handle is `NULL` or when the
* node handle is from a different rmw implementation.
*
* \return rmw_ret_t non `NULL` value if successful, otherwise `NULL`
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this comment seems wrong (the function does not return NULL and it does not take a node handle as argument)

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah whoops. That is left over from the actual implementation. I will fix.

*/
rmw_ret_t rmw_notify_participant_dynamic_network_interface(rmw_context_t * context);

/******************************************************************************
* WaitSet wrapper
******************************************************************************/
Expand Down
6 changes: 6 additions & 0 deletions rmw_connextdds_common/src/common/rmw_node.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -229,3 +229,9 @@ rmw_api_connextdds_node_get_graph_guard_condition(const rmw_node_t * rmw_node)

return node_impl->graph_guard_condition();
}

rmw_ret_t
rmw_notify_participant_dynamic_network_interface(rmw_context_t * context)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor comment, which applies more to the rmw interface that this specific change, but I always prefer to pass const pointers, e.g.:

Suggested change
rmw_notify_participant_dynamic_network_interface(rmw_context_t * context)
rmw_notify_participant_dynamic_network_interface(rmw_context_t * const context)

{
return RMW_RET_INCORRECT_RMW_IMPLEMENTATION;
}