#pragma once\r
\r
#include <boost/algorithm/string/split.hpp>\r
-#include <boost/foreach.hpp>\r
\r
#include "protocol_strategy.h"\r
#include "ProtocolStrategy.h"\r
{\r
std::basic_string<CharT> delimiter_;\r
std::basic_string<CharT> input_;\r
- protocol_strategy<CharT>::ptr strategy_;\r
+ typename protocol_strategy<CharT>::ptr strategy_;\r
public:\r
delimiter_based_chunking_strategy(\r
const std::basic_string<CharT>& delimiter, \r
- const protocol_strategy<CharT>::ptr& strategy)\r
+ const typename protocol_strategy<CharT>::ptr& strategy)\r
: delimiter_(delimiter)\r
, strategy_(strategy)\r
{\r
\r
//boost::iter_split(split, input_, boost::algorithm::first_finder(delimiter_)) was painfully slow in debug-build\r
\r
- auto delim_pos = input_.find_first_of(delimiter_);\r
+ auto delim_pos = input_.find(delimiter_);\r
while(delim_pos != std::string::npos)\r
{\r
strategy_->parse(input_.substr(0, delim_pos));\r
: public protocol_strategy_factory<CharT>\r
{\r
std::basic_string<CharT> delimiter_;\r
- protocol_strategy_factory<CharT>::ptr strategy_factory_;\r
+ typename protocol_strategy_factory<CharT>::ptr strategy_factory_;\r
public:\r
delimiter_based_chunking_strategy_factory(\r
const std::basic_string<CharT>& delimiter, \r
- const protocol_strategy_factory<CharT>::ptr& strategy_factory)\r
+ const typename protocol_strategy_factory<CharT>::ptr& strategy_factory)\r
: delimiter_(delimiter)\r
, strategy_factory_(strategy_factory)\r
{\r