TableNameService
class TableNameService (View source)
Methods
string
getTable(PdnsTable $table)
Get table name with prefix using enum (preferred method)
array
getTables(PdnsTable ...$tables)
Get multiple table names at once using enums
string
validateOrderBy(string $column, array $allowedColumns)
Only ever returns a value present in $allowedColumns, so the result is safe to interpolate into ORDER BY.
string
validateDirection(string $direction)
Only ever returns 'ASC' or 'DESC', so the result is safe to interpolate.
int
validateLimit(int $limit, int $maxLimit = 10000)
No description
int
validateOffset(int $offset)
No description
Details
__construct(ConfigurationInterface $config)
No description
string
getTable(PdnsTable $table)
Get table name with prefix using enum (preferred method)
array
getTables(PdnsTable ...$tables)
Get multiple table names at once using enums
string
validateOrderBy(string $column, array $allowedColumns)
Only ever returns a value present in $allowedColumns, so the result is safe to interpolate into ORDER BY.
string
validateDirection(string $direction)
Only ever returns 'ASC' or 'DESC', so the result is safe to interpolate.
int
validateLimit(int $limit, int $maxLimit = 10000)
No description
int
validateOffset(int $offset)
No description