You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

37 lines
880 B

  1. #include "Statement.h"
  2. #include "StatementBuilder.h"
  3. #include "InsertStatementBuilder.h"
  4. #include "SelectStatementBuilder.h"
  5. #include "UpdateStatementBuilder.h"
  6. #include "DeleteStatementBuilder.h"
  7. namespace db {
  8. namespace statements {
  9. namespace builder {
  10. InsertStatementBuilder Statement::insert() {
  11. return InsertStatementBuilder{};
  12. }
  13. SelectStatementBuilder Statement::select() {
  14. return SelectStatementBuilder{};
  15. }
  16. UpdateStatementBuilder Statement::update() {
  17. return UpdateStatementBuilder{};
  18. }
  19. DeleteStatementBuilder Statement::remove() {
  20. return DeleteStatementBuilder{};
  21. }
  22. std::string Statement::str() const {
  23. return body + "\n";
  24. }
  25. std::ostream &operator<<(std::ostream &os, const Statement &s) {
  26. return os << s.body << std::endl;
  27. }
  28. }
  29. }
  30. }