Enum Class Difficulty

java.lang.Object
java.lang.Enum<Difficulty>
com.slinky.hackmaster.model.text.Difficulty
All Implemented Interfaces:
Serializable, Comparable<Difficulty>, Constable

public enum Difficulty extends Enum<Difficulty>
The Difficulty enum defines five distinct levels of difficulty for categorising word lists within the application. These levels represent a progressive scale of complexity, allowing developers and users to tailor their experience based on their skill level or desired challenge.

This enum is utilised across various components of the application, particularly in methods that generate or filter word lists. By selecting a specific Difficulty level, the corresponding word list will be adjusted to match the chosen difficulty, ensuring an appropriate level of challenge for different users.

The available difficulty levels are:

  • BEGINNER - Designed for those who are new to the subject matter, featuring simple and easily recognisable words.
  • INTERMEDIATE - Aimed at users with a basic understanding, offering a moderate increase in complexity.
  • ADVANCED - Intended for users with a more developed skill set, presenting challenging words that require a deeper understanding.
  • EXPERT - Tailored for users with significant expertise, incorporating complex and nuanced words that demand advanced knowledge.
  • MASTER - The highest difficulty level, reserved for those with extensive mastery, featuring the most challenging and obscure words.

Example usage:

 WordList wordList = WordList.getWordList(Difficulty.BEGINNER);
 
This example demonstrates how to retrieve a word list suited to the BEGINNER difficulty level.

Version:
1.0
Author:
Kheagen Haskins
  • Enum Constant Details

    • BEGINNER

      public static final Difficulty BEGINNER
      The easiest difficulty level, suitable for beginners.
    • INTERMEDIATE

      public static final Difficulty INTERMEDIATE
      A step up in difficulty, aimed at those with basic knowledge.
    • ADVANCED

      public static final Difficulty ADVANCED
      A challenging difficulty level for users with a good understanding of the subject.
    • EXPERT

      public static final Difficulty EXPERT
      A high difficulty level, designed for experts.
    • MASTER

      public static final Difficulty MASTER
      The most challenging difficulty level, intended for masters of the subject.
  • Method Details

    • values

      public static Difficulty[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static Difficulty valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null