Re: [Cppcms-users] Question about multiples mount_point
Brought to you by:
artyom-beilis
From: Marcel H. <ke...@co...> - 2012-02-23 08:13:57
|
look at the chat example. what you are doing looks.. .. interesting (: regards -- Diese Nachricht wurde von meinem Android-Mobiltelefon mit K-9 Mail gesendet. Joffrey Romero <jof...@ya...> schrieb: Hello, I'm working on a cppcms project with asynchronous classes : Is that the right way to create my asynchronous modules ? <code> int main(int argc, char **argv, char **env) { try { cppcms::service srv(argc,argv); booster::intrusive_ptr<ad_connection> c = new ad_connection(srv); srv.applications_pool().mount( c, cppcms::mount_point("/ad_connection/(.*)",1) ); srv.applications_pool().mount( cppcms::applications_factory<program>(), cppcms::mount_point("^/((?:(?!ad_connection/).)*)",1) ); srv.run(); } catch(std::exception const &e) { std::cerr<<e.what()<<std::endl; } } </code> The code works well, but just for curiosity, I wondered if it was the right way.. Thanks, Joffrey |