Package twisted :: Package enterprise :: Module util |
[show private | hide private]
[frames | no frames]

## Module twisted.enterprise.util

Exceptions
`DBError` |

Function Summary
| ``defaultFactoryMethod`(rowClass, data, kw)` Used by loadObjects to create rowObject instances.
| `getKeyColumn(rowClass, name)`
| ``makeKW`(rowClass, args)` Utility method to construct a dictionary for the attributes of an object from set of args.
| ``quote`(value, typeCode, string_escaper)` Add quotes for text types and no quotes for integer types.

Variable Summary
`dict` | `dbTypeMap`
`int` | `NOQUOTE`
`int` | `USEQUOTE`

Function Details

### defaultFactoryMethod(rowClass, data, kw) Used by loadObjects to create rowObject instances.

### makeKW(rowClass, args) Utility method to construct a dictionary for the attributes of an object from set of args. This also fixes the case of column names.

### quote(value, typeCode, string_escaper=<function safe at 0x84bcaf4>) Add quotes for text types and no quotes for integer types. NOTE: uses Postgresql type codes..

Variable Details

    ### dbTypeMap Type: `dict` Value:
        {'bigint': 1,
         'bool': 2,
         'boolean': 2,
         'char': 2,
         'date': 2,
         'float4': 1,
         'float8': 1,
         'int': 1,
        ...

    ### NOQUOTE Type: `int` Value:
        1

    ### USEQUOTE Type: `int` Value:
        2

Generated by Epydoc 1.1 on Thu May 8 13:16:25 2003 | http://epydoc.sf.net