mirror of
https://github.com/Relintai/rcpp_framework.git
synced 2025-04-20 01:43:12 +02:00
Added a simple new Model and Controller class.
This commit is contained in:
parent
7cfeb13982
commit
304a2a19c9
18
core/http/controller.cpp
Normal file
18
core/http/controller.cpp
Normal file
@ -0,0 +1,18 @@
|
||||
|
||||
#include "controller.h"
|
||||
|
||||
#include "request.h"
|
||||
|
||||
void Controller::handle_request_main(Request *request) {
|
||||
}
|
||||
|
||||
void Controller::create_validators() {
|
||||
}
|
||||
|
||||
|
||||
Controller::Controller() {
|
||||
create_validators();
|
||||
}
|
||||
|
||||
Controller::~Controller() {
|
||||
}
|
19
core/http/controller.h
Normal file
19
core/http/controller.h
Normal file
@ -0,0 +1,19 @@
|
||||
#ifndef HTTP_CONTROLLER_H
|
||||
#define HTTP_CONTROLLER_H
|
||||
|
||||
#include "core/object.h"
|
||||
|
||||
class Request;
|
||||
|
||||
class Controller : public Object {
|
||||
public:
|
||||
virtual void handle_request_main(Request *request);
|
||||
virtual void create_validators();
|
||||
|
||||
Controller();
|
||||
~Controller();
|
||||
|
||||
protected:
|
||||
};
|
||||
|
||||
#endif
|
20
core/http/model.cpp
Normal file
20
core/http/model.cpp
Normal file
@ -0,0 +1,20 @@
|
||||
|
||||
#include "model.h"
|
||||
|
||||
void Model::create_table() {
|
||||
|
||||
}
|
||||
|
||||
void Model::drop_table() {
|
||||
|
||||
}
|
||||
|
||||
void Model::migrate() {
|
||||
|
||||
}
|
||||
|
||||
Model::Model() {
|
||||
}
|
||||
|
||||
Model::~Model() {
|
||||
}
|
18
core/http/model.h
Normal file
18
core/http/model.h
Normal file
@ -0,0 +1,18 @@
|
||||
#ifndef HTTP_MODEL_H
|
||||
#define HTTP_MODEL_H
|
||||
|
||||
#include "core/object.h"
|
||||
|
||||
class Model : public Object {
|
||||
public:
|
||||
virtual void create_table();
|
||||
virtual void drop_table();
|
||||
virtual void migrate();
|
||||
|
||||
Model();
|
||||
~Model();
|
||||
|
||||
protected:
|
||||
};
|
||||
|
||||
#endif
|
Loading…
Reference in New Issue
Block a user