Class: PG::TextEncoder::Identifier
- Inherits:
-
SimpleEncoder
- Object
- Coder
- SimpleCoder
- SimpleEncoder
- PG::TextEncoder::Identifier
- Defined in:
- ext/pg_text_encoder.c
Overview
This is the encoder class for PostgreSQL identifiers.
An Array value can be used for identifiers of the kind “schema.table.column”. This ensures that each element is properly quoted:
PG::TextEncoder::Identifier.new.encode(['schema', 'table', 'column'])
=> '"schema"."table"."column"'
This encoder can also be used per PG::Connection#quote_ident .
Constant Summary
Constants inherited from Coder
Coder::FORMAT_ERROR_MASK, Coder::FORMAT_ERROR_TO_PARTIAL, Coder::FORMAT_ERROR_TO_RAISE, Coder::FORMAT_ERROR_TO_STRING, Coder::TIMESTAMP_APP_LOCAL, Coder::TIMESTAMP_APP_UTC, Coder::TIMESTAMP_DB_LOCAL, Coder::TIMESTAMP_DB_UTC
Instance Attribute Summary
Attributes inherited from Coder
Method Summary
Methods inherited from Coder
#==, #dup, #flags, #flags=, #format, #format=, #initialize, #inspect, #inspect_short, #marshal_dump, #marshal_load, #oid, #oid=, #to_h
Constructor Details
This class inherits a constructor from PG::Coder