aboutsummaryrefslogtreecommitdiff
path: root/node_modules/mysql2/lib/packets/prepared_statement_header.js
diff options
context:
space:
mode:
Diffstat (limited to 'node_modules/mysql2/lib/packets/prepared_statement_header.js')
-rw-r--r--node_modules/mysql2/lib/packets/prepared_statement_header.js16
1 files changed, 16 insertions, 0 deletions
diff --git a/node_modules/mysql2/lib/packets/prepared_statement_header.js b/node_modules/mysql2/lib/packets/prepared_statement_header.js
new file mode 100644
index 0000000..70b263a
--- /dev/null
+++ b/node_modules/mysql2/lib/packets/prepared_statement_header.js
@@ -0,0 +1,16 @@
+'use strict';
+
+class PreparedStatementHeader {
+ constructor(packet) {
+ packet.skip(1); // should be 0
+ this.id = packet.readInt32();
+ this.fieldCount = packet.readInt16();
+ this.parameterCount = packet.readInt16();
+ packet.skip(1); // should be 0
+ this.warningCount = packet.readInt16();
+ }
+}
+
+// TODO: toPacket
+
+module.exports = PreparedStatementHeader;