enumAlignment
enum Alignment: string
implements Choice
Public API: explicitly declared with
@visibility public.The alignment attribute of a base type: the storage alignment of its values.
DefineType compares the text without regard to case, and accepts the names an unquoted type keyword is translated to: double precision reads as pg_catalog.float8, integer as pg_catalog.int4, smallint as pg_catalog.int2 and char as pg_catalog.bpchar. Source: https://www.postgresql.org/docs/17/sql-createtype.html, DefineType in src/backend/commands/typecmds.c of PostgreSQL 17.
\SqlSemantics\Platform\PostgreSql\Statement\Object\Attribute\Choice\Alignment::read('pg_catalog.int4')?->name // => 'Int'Cases§
case Char = 'char'case Short = 'int2'case Int = 'int4'case Double = 'double'Methods§
public static function read(string $text): ?selfAnswers the alignment the text names without regard to case, or null.
Parameters
$text | string |
Returns
?selfTest cases 3
Calls 2
- class-const Alignment::SPELLINGS() line 42
- function-call
strtolowerline 42
Private surface 1§
Implementation details, listed for orientation only.
private const SPELLINGS = ['double' => self::Double, 'float8' => self::Double, 'pg_catalog.float8' => sel…Test cases 7§
Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.