![]() |
Home | Libraries | People | FAQ | More |
boost::date_time::find_match — Find index of a string in either of 2 arrays.
// In header: <boost/date_time/find_match.hpp> template<typename charT> short (const charT *const * short_names, const charT *const * long_names, short size, const charT > & s);
find_match searches both arrays for a match to 's'. Both arrays must contain 'size' elements. The index of the match is returned. If no match is found, 'size' is returned. Ex. "Jan" returns 0, "Dec" returns 11, "Tue" returns 2. 'size' can be sent in with: (greg_month::max)() (which 12), (greg_weekday::max)() + 1 (which is 7) or date_time::NumSpecialValues