drogon
C++14/17-based HTTP application framework
Loading...
Searching...
No Matches
BaseBuilder.h File Reference
#include <drogon/orm/Criteria.h>
#include <drogon/orm/DbClient.h>
#include <string_view>
#include <future>
#include <memory>
#include <string>
#include <type_traits>
#include <utility>
#include <vector>
#include <optional>
Include dependency graph for BaseBuilder.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  drogon::orm::Filter
struct  drogon::orm::JoinClause
class  drogon::orm::BaseBuilder< T, SelectAll, Single >

Namespaces

namespace  drogon
 Drogon Test is a minimal effort test framework developed because the major C++ test frameworks doesn't handle async programs well. Drogon Test's syntax is inspired by both Google Test and Catch2.

Macros

#define unimplemented()

Enumerations

enum class  drogon::orm::JoinType { InnerJoin , LeftJoin , RightJoin , FullJoin }
 Represents a SQL JOIN clause.

Functions

std::string drogon::orm::to_string (CompareOperator op)
std::string drogon::orm::to_join_string (JoinType type)
bool drogon::orm::isValidSqlIdentifier (const std::string &identifier)
 Validate that a string is a safe SQL identifier.

Detailed Description

Author
Ken Matsui

Copyright 2022, Ken Matsui. All rights reserved. https://github.com/drogonframework/drogon Use of this source code is governed by a MIT license that can be found in the License file.

Drogon

Macro Definition Documentation

◆ unimplemented

#define unimplemented ( )
Value:
assert(false && "unimplemented")

Function Documentation

◆ isValidSqlIdentifier()

bool drogon::orm::isValidSqlIdentifier ( const std::string & identifier)
inline

Validate that a string is a safe SQL identifier.

Only allows alphanumeric characters, underscores, and dots (for table.column notation). This prevents SQL injection when building JOIN clauses from user-provided identifiers.

Parameters
identifierThe identifier to validate.
Returns
true if the identifier is safe to use in SQL.