From 329e205ff8ee0775e4ad36052f7ed0ff4f1e34f1 Mon Sep 17 00:00:00 2001 From: Edoardo La Greca Date: Thu, 24 Jul 2025 20:59:40 +0200 Subject: add documentation and arguments to version method from NinePTranslator --- src/main/kotlin/NinePTranslator.kt | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/src/main/kotlin/NinePTranslator.kt b/src/main/kotlin/NinePTranslator.kt index c976cd9..0bbcb9d 100644 --- a/src/main/kotlin/NinePTranslator.kt +++ b/src/main/kotlin/NinePTranslator.kt @@ -12,8 +12,18 @@ TODO: interface NinePTranslator { /** * Negotiate protocol version. + * + * This must be the first message sent on the 9P connection and no other requests can be issued until a response has + * been received. + * Tag should be NOTAG ((ushort)~0). + * + * @param tag Should be NOTAG ((ushort)~0). + * @param msize The maximum length, in bytes, that the client will ever generate or expect to receive in a single + * 9P message. + * @param version Should be "9P2000", which is the only defined value. + * @return a possible error. */ - fun version() + fun version(tag: SizedMessageField, msize: SizedMessageField, version: String): String? /** * Perform authentication. -- cgit v1.2.3