forked from vapor/postgres-kit
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathPostgreSQLMessage+0.swift
77 lines (53 loc) · 2.44 KB
/
PostgreSQLMessage+0.swift
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
// note: Please list enum cases alphabetically.
/// A frontend or backend PostgreSQL message.
enum PostgreSQLMessage {
/// One of the various authentication request message formats.
case authenticationRequest(AuthenticationRequest)
/// Identifies the message as cancellation key data.
/// The frontend must save these values if it wishes to be able to issue CancelRequest messages later.
case backendKeyData(BackendKeyData)
/// Identifies the message as a Bind command.
case bind(BindRequest)
/// Identifies the message as a Bind-complete indicator.
case bindComplete
/// Identifies the message as a command-completed response.
case close(CloseResponse)
/// Identifies the message as a data row.
case dataRow(DataRow)
/// Identifies the message as a Describe command.
case describe(DescribeRequest)
/// Identifies the message as an error.
case error(ErrorResponse)
/// Identifies the message as an Execute command.
case execute(ExecuteRequest)
/// Identifies the message as a no-data indicator.
case noData
/// Identifies the message as a notice.
case notice(ErrorResponse)
/// Identifies the message as a notification response.
case notification(Notification)
/// Identifies the message as a parameter description.
case parameterDescription(ParameterDescription)
/// Identifies the message as a run-time parameter status report.
case parameterStatus(ParameterStatus)
/// Identifies the message as a Parse command.
case parse(ParseRequest)
/// Identifies the message as a Parse-complete indicator.
case parseComplete
/// Identifies the message as a password response.
case password(PasswordMessage)
/// Identifies the message as a simple query.
case query(Query)
/// Identifies the message type. ReadyForQuery is sent whenever the backend is ready for a new query cycle.
case readyForQuery(ReadyForQuery)
/// Identifies the message as a row description.
case rowDescription(RowDescription)
/// Response after sending an sslSupportRequest message.
case sslSupportResponse(SupportResponse)
/// Asks the server if it supports SSL.
case sslSupportRequest(SSLSupportRequest)
/// Startup message
case startupMessage(StartupMessage)
/// Identifies the message as a Sync command.
case sync
}