From 97408589e18ecebef7fa380e019c43f5a24e1be7 Mon Sep 17 00:00:00 2001 From: Edoardo La Greca Date: Fri, 8 Aug 2025 16:38:42 +0200 Subject: change walk to use exceptions instead of error strings --- src/main/kotlin/ProtocolTranslator.kt | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/main/kotlin/ProtocolTranslator.kt') diff --git a/src/main/kotlin/ProtocolTranslator.kt b/src/main/kotlin/ProtocolTranslator.kt index 1b45252..bf29131 100644 --- a/src/main/kotlin/ProtocolTranslator.kt +++ b/src/main/kotlin/ProtocolTranslator.kt @@ -67,9 +67,11 @@ interface ProtocolTranslator { * @param newfid The proposed FID, which is going to be associated with the result of walking the hierarchy. It must * be not in use, unless it is the same as [fid]. * @param wname The successive path name elements which describe the file to walk to. - * @return a possible error. + * @throws except.InvalidMessageException if the received message is invalid. + * @throws except.RErrorException if the received message is an R-error message. + * @throws except.UnaccessibleFileException if [wname] contains one or more files that do not exist. */ - fun walk(fid: UInt, newfid: UInt, wname: List): String? + fun walk(fid: UInt, newfid: UInt, wname: List) /** * Prepare an FID for I/O on an existing file. -- cgit v1.2.3