summaryrefslogtreecommitdiff
path: root/include/mode.h
diff options
context:
space:
mode:
authorPeter Powell <petpow@saberuk.com>2019-06-12 21:46:07 +0100
committerPeter Powell <petpow@saberuk.com>2019-06-12 21:52:58 +0100
commit9433e34b2133d8f1e77fea15447ba4d0259a5fb0 (patch)
tree8e6bb357472f2e39c31c82053a1d02d4b1f7460d /include/mode.h
parent938837af9fe92d0fef811db96a5e9d6bf8e3ae11 (diff)
Show the mode syntax in ERR_INVALIDMODEPARAM.
Diffstat (limited to 'include/mode.h')
-rw-r--r--include/mode.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/mode.h b/include/mode.h
index fe02838b2..683f4b55b 100644
--- a/include/mode.h
+++ b/include/mode.h
@@ -154,6 +154,9 @@ class CoreExport ModeHandler : public ServiceProvider
/** The prefix rank required to unset this mode on channels. */
unsigned int ranktounset;
+ /** If non-empty then the syntax of the parameter for this mode. */
+ std::string syntax;
+
public:
/**
* The constructor for ModeHandler initalizes the mode handler.
@@ -329,6 +332,9 @@ class CoreExport ModeHandler : public ServiceProvider
return adding ? ranktoset : ranktounset;
}
+ /** Retrieves the syntax of the parameter for this mode. */
+ const std::string& GetSyntax() const { return syntax; }
+
friend class ModeParser;
};