gensaschema._column module¶
Column inspection and representation¶
Column inspection and generation.
- Copyright:
Copyright 2010 - 2023 André Malo or his licensors, as applicable
- License:
Licensed under the Apache License, Version 2.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an “AS IS” BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
- class gensaschema._column.Column(name, ctype, nullable, primary_key, autoincrement, server_default, symbols)[source]¶
Column container
- _name¶
Name
- Type:
unicode
- _ctype¶
Column type
- Type:
SA type
- _nullable¶
Nullable?
- Type:
bool
- _primary_key¶
Part of a primary key?
- Type:
bool
- _autoincrement¶
Possible autoincrement?
- Type:
bool
- _server_default¶
Default clause
- Type:
Default clause
- _symbols¶
Symbol table
- Type:
- __dict__ = mappingproxy({'__module__': 'gensaschema._column', '__doc__': '\n Column container\n\n Attributes:\n _name (unicode):\n Name\n\n _ctype (SA type):\n Column type\n\n _nullable (bool):\n Nullable?\n\n _primary_key (bool):\n Part of a primary key?\n\n _autoincrement (bool):\n Possible autoincrement?\n\n _server_default (Default clause):\n Default clause\n\n _symbols (Symbols):\n Symbol table\n ', '__init__': <function Column.__init__>, 'from_sa': <classmethod(<function Column.from_sa>)>, '__repr__': <function Column.__repr__>, '__dict__': <attribute '__dict__' of 'Column' objects>, '__weakref__': <attribute '__weakref__' of 'Column' objects>, '__annotations__': {}})¶
- __init__(name, ctype, nullable, primary_key, autoincrement, server_default, symbols)[source]¶
Initialization
- Parameters:
name (
unicode
) – Column namectype (
SA type
) – Column typenullable (
bool
) – Nullable?primary_key (
bool
) – Part of a primary key?autoincrement (
bool
) – Possible autoincrement?server_default (
Default clause
) – Default clausesymbols (gensaschema.Symbols) – Symbol table
- __module__ = 'gensaschema._column'¶
- __weakref__¶
list of weak references to the object (if defined)
- class gensaschema._column.ServerDefault(default, symbols)[source]¶
Default clause container
- _default¶
Default clause
- Type:
Default clause
- _symbols¶
Symbol table
- Type:
- __dict__ = mappingproxy({'__module__': 'gensaschema._column', '__doc__': '\n Default clause container\n\n Attributes:\n _default (Default clause):\n Default clause\n\n _symbols (Symbols):\n Symbol table\n ', '__init__': <function ServerDefault.__init__>, '__repr__': <function ServerDefault.__repr__>, '__dict__': <attribute '__dict__' of 'ServerDefault' objects>, '__weakref__': <attribute '__weakref__' of 'ServerDefault' objects>, '__annotations__': {}})¶
- __init__(default, symbols)[source]¶
Initialization
- Parameters:
default (
Default clause
) – Default clausesymbols (gensaschema.Symbols) – Symbol table
- __module__ = 'gensaschema._column'¶
- __weakref__¶
list of weak references to the object (if defined)