@@ -19,15 +19,15 @@ @class OFMapTable; OF_ASSUME_NONNULL_BEGIN /** - * @struct of_options_parser_option_t OFOptionsParser.h ObjFW/OFOptionsParser.h + * @struct OFOptionsParserOption OFOptionsParser.h ObjFW/OFOptionsParser.h * * @brief An option which can be parsed by an @ref OFOptionsParser. */ -struct of_options_parser_option_t { +struct OFOptionsParserOption { /** The short version (e.g. `-v`) of the option or `\0` for none. */ OFUnichar shortOption; /** * The long version (e.g. `--verbose`) of the option or `nil` for none. @@ -56,21 +56,21 @@ * An optional pointer to an `OFString *` that is set to the * argument specified for the option or `nil` for no argument. */ OFString *__autoreleasing _Nullable *_Nullable argumentPtr; }; -typedef struct of_options_parser_option_t of_options_parser_option_t; +typedef struct OFOptionsParserOption OFOptionsParserOption; /** * @class OFOptionsParser OFOptionsParser.h ObjFW/OFOptionsParser.h * * @brief A class for parsing the program options specified on the command line. */ OF_SUBCLASSING_RESTRICTED @interface OFOptionsParser: OFObject { - of_options_parser_option_t *_options; + OFOptionsParserOption *_options; OFMapTable *_longOptions; OFArray OF_GENERIC(OFString *) *_arguments; size_t _index, _subIndex; OFUnichar _lastOption; OFString *_Nullable _lastLongOption, *_Nullable _argument; @@ -117,31 +117,31 @@ OFArray OF_GENERIC(OFString *) *remainingArguments; /** * @brief Creates a new OFOptionsParser which accepts the specified options. * - * @param options An array of @ref of_options_parser_option_t specifying all + * @param options An array of @ref OFOptionsParserOption specifying all * accepted options, terminated with an option whose short * option is `\0` and long option is `nil`. * * @return A new, autoreleased OFOptionsParser */ -+ (instancetype)parserWithOptions: (const of_options_parser_option_t *)options; ++ (instancetype)parserWithOptions: (const OFOptionsParserOption *)options; - (instancetype)init OF_UNAVAILABLE; /** * @brief Initializes an already allocated OFOptionsParser so that it accepts * the specified options. * - * @param options An array of @ref of_options_parser_option_t specifying all + * @param options An array of @ref OFOptionsParserOption specifying all * accepted options, terminated with an option whose short * option is `\0` and long option is `nil`. * * @return An initialized OFOptionsParser */ -- (instancetype)initWithOptions: (const of_options_parser_option_t *)options +- (instancetype)initWithOptions: (const OFOptionsParserOption *)options OF_DESIGNATED_INITIALIZER; /** * @brief Returns the next option. *