예제 #1
0
파일: main.cpp 프로젝트: libyuni/libyuni
int main()
{
	// Welcome !
	logs.notice() << "Yuni DBI Example";
	logs.info() << "using the SQLite default adapter";
	logs.info(); // empty line

	return RunExample() ? 0 : EXIT_FAILURE;
}
예제 #2
0
int main(int, char**)
{
	// Welcome !
	logs.notice() << "Yuni REST Server Example";
	logs.info() << "http://www.libyuni.org";
	logs.info(); // empty line

	// The service itself
	Messaging::Service  service;

	// Prepare the API
	PrepareTheAPI(service);
	// Preparing all transports
	PrepareTransports(service);

	// Starting the new service
	if (not StartService(service))
		return EXIT_FAILURE;

	// Waiting for the end of the server
	service.wait();

	return 0;
}