#include "ros_bridge/include/ROSCommunicator.h"

bool ROSBridge::Communicator::messagesAvailable()
{
    return !_receiveBuffer.empty() || _stagedMessage;
}

bool ROSBridge::Communicator::showMessageTag(ROSBridge::Communicator::Tag &tag)
{
    if (!_stagedMessage)
        _stagedMessage = _receiveBuffer.pop();
    return ROSBridge::Communicator::CasePacker::showTag(*_stagedMessage.get(), tag);
}
