开发者

C++ Console Application MVC

Hi I'm developing a website in C++ (through FastCGI), I already 开发者_开发技巧managed to make it work, the question is more about the organization. The URL links(the query part) is threated as as commands, so if you write:

www.site.com/view/product/23230/

The /view/product/23230/ is going to be parsed and return the HTML, the problem is that a website may have too many different "commands" like: "/backoffice/addUser/", "/backOffice/chart/", etc... Without a way to organize it, it'll be a mess in no time.

So my Idea was to use MVC and for a console app is kinda strange, because in fact we have only 1 "window" that will receive all the commands. I searched a lot for implementations of MVC in console apps and found nothing(without frameworks). What do you guys suggest? The problem is not how to make the website, but how to handle too many different commands and let your code organized?

Thanks in advance.


What about something like this: http://ndk-xx.sourceforge.net/ or http://sourceforge.net/projects/cursesplusplus/ -- use MinGW to compile and then the MinGW shell as the console for robustness.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜