public static int optionLength ( final String option ) { // Any arguments used for the doclet need to be recognized here. Many javadoc plugins (ie. gradle) // automatically add some such as "-doctitle", "-windowtitle", which we ignore. if ( option . equals ( DOC_TITLE_OPTION ) || option . equals ( WINDOW_TITLE_OPTION ) || option . equals ( SETTINGS_DIR_OPTION ) || option . equals ( DESTINATION_DIR_OPTION ) || option . equals ( BUILD_TIMESTAMP_OPTION ) || option . equals ( ABSOLUTE_VERSION_OPTION ) || option . equals ( OUTPUT_FILE_EXTENSION_OPTION ) || option . equals ( INDEX_FILE_EXTENSION_OPTION ) ) { return 2 ; } else if ( option . equals ( QUIET_OPTION ) || option . equals ( USE_DEFAULT_TEMPLATES_OPTION ) ) { return 1 ; } else { logger . error ( "The Javadoc command line option is not recognized by the Barclay doclet: " + option ) ; return 0 ; } }
Validates the given options against options supported by this doclet .