diff --git a/owlps-positioning/src/stock.hh b/owlps-positioning/src/stock.hh index db58fd3..ed540b5 100644 --- a/owlps-positioning/src/stock.hh +++ b/owlps-positioning/src/stock.hh @@ -68,6 +68,8 @@ public: /** @name Mobile operations */ //@{ + /// Returns the number of mobiles + static unsigned int nb_mobiles(void) ; /// Reads the Mobile corresponding to a given MAC address static const Mobile& get_mobile(const std::string &mac) ; /// \brief Searches for a Mobile given its MAC address and creates @@ -178,6 +180,12 @@ find_create_waypoint(const Waypoint &point) /* *** Mobile operations *** */ +inline unsigned int Stock::nb_mobiles() +{ + return mobiles.size() ; +} + + /** * If the Mobile corresponding to \em mac does not exist, it is created. * @param mac The MAC address of the Mobile to search for. It must be a