1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18 package org.apache.shardingsphere.db.protocol.postgresql.packet.command.query.extended.describe;
19
20 import lombok.Getter;
21 import org.apache.shardingsphere.db.protocol.postgresql.packet.command.PostgreSQLCommandPacket;
22 import org.apache.shardingsphere.db.protocol.postgresql.packet.command.PostgreSQLCommandPacketType;
23 import org.apache.shardingsphere.db.protocol.postgresql.packet.identifier.PostgreSQLIdentifierTag;
24 import org.apache.shardingsphere.db.protocol.postgresql.payload.PostgreSQLPacketPayload;
25
26
27
28
29 @Getter
30 public final class PostgreSQLComDescribePacket extends PostgreSQLCommandPacket {
31
32 private final char type;
33
34 private final String name;
35
36 public PostgreSQLComDescribePacket(final PostgreSQLPacketPayload payload) {
37 payload.readInt4();
38 type = (char) payload.readInt1();
39 name = payload.readStringNul();
40 }
41
42 @Override
43 protected void write(final PostgreSQLPacketPayload payload) {
44 }
45
46 @Override
47 public PostgreSQLIdentifierTag getIdentifier() {
48 return PostgreSQLCommandPacketType.DESCRIBE_COMMAND;
49 }
50 }