renamed foreign class to entity, introduced interface class query_result_reader
This commit is contained in:
@@ -8,7 +8,7 @@
|
||||
#include "matador/utils/cascade_type.hpp"
|
||||
#include "matador/utils/field_attributes.hpp"
|
||||
|
||||
#include "matador/sql/foreign.hpp"
|
||||
#include "matador/sql/entity.hpp"
|
||||
|
||||
#include <string>
|
||||
|
||||
@@ -21,7 +21,7 @@ struct airplane
|
||||
: id(id)
|
||||
, brand(std::move(b))
|
||||
, model(std::move(m)) {}
|
||||
unsigned long id;
|
||||
unsigned long id{};
|
||||
std::string brand;
|
||||
std::string model;
|
||||
|
||||
|
||||
@@ -7,15 +7,15 @@
|
||||
#include "matador/utils/cascade_type.hpp"
|
||||
#include "matador/utils/field_attributes.hpp"
|
||||
|
||||
#include "matador/sql/foreign.hpp"
|
||||
#include "matador/sql/entity.hpp"
|
||||
|
||||
#include <string>
|
||||
|
||||
namespace matador::test {
|
||||
|
||||
struct flight {
|
||||
unsigned long id;
|
||||
sql::foreign<test::airplane> airplane;
|
||||
unsigned long id{};
|
||||
sql::entity<test::airplane> airplane;
|
||||
std::string pilot_name;
|
||||
|
||||
template<class Operator>
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
#include "matador/utils/cascade_type.hpp"
|
||||
#include "matador/utils/field_attributes.hpp"
|
||||
|
||||
#include "matador/sql/foreign.hpp"
|
||||
#include "matador/sql/entity.hpp"
|
||||
|
||||
#include <string>
|
||||
|
||||
@@ -17,8 +17,8 @@ namespace matador::test {
|
||||
struct product
|
||||
{
|
||||
std::string product_name;
|
||||
sql::foreign<test::supplier> supplier;
|
||||
sql::foreign<test::category> category;
|
||||
sql::entity<test::supplier> supplier;
|
||||
sql::entity<test::category> category;
|
||||
std::string quantity_per_unit;
|
||||
unsigned int unit_price;
|
||||
unsigned int units_in_stock;
|
||||
|
||||
Reference in New Issue
Block a user