class Row(CStruct): """ Examples: Column name: oid Table OID: 1247 Column index: 65534 Type OID: 26 Column length: 4 Type modifier: -1 Format: Text (0) Column name: typbasetype Table OID: 1247 Column index: 24 Type OID: 26 Column length: 4 Type modifier: -1 Format: Text (0) """ name = CString(length=AUTOSIZED) oid = CInt() attr_num = CUShort() datatype_oid = CInt() datatype_size = CShort() type_modifier = CInt() format_code = CShort()
class MarketStatus(CStruct): exchange = CUChar() length_of_market_type = CUShort() market_type = CString(length = "length_of_market_type") length_of_status = CUShort() status = CString(length = "length_of_status")
class ExchangeMessage(CStruct): exchange = CUChar() length = CUShort() message = CString(length = "length") exchange_time_stamp = CUInt()
class ParameterStatus(CStruct): type = CUChar(always=ord('S')) length = CInt() parameter_name = CString(length=AUTOSIZED) parameter_value = CString(length=AUTOSIZED)
class CommandComplete(CStruct): type = CUChar(always=ord('C')) length = CInt() tag = CString(length=AUTOSIZED)
class Query(CStruct): type = CUChar(always=ord('Q')) length = CInt() query = CString(length=AUTOSIZED)
class Startup(CStruct): protocol_version = CInt() parameter_name = CString(length=AUTOSIZED) parameter_value = CString(length=AUTOSIZED)
class NoticeResponse(CStruct): type = CUChar(always=ord('N')) length = CInt() message = CString(length=AUTOSIZED)
class ErrorResponse(CStruct): type = CUChar(always=ord('E')) length = CInt() message = CString(length=AUTOSIZED)
class ColumnValue(CStruct): length = CInt() bytes = CString(length="length")