Enum HarmCategory.Known

java.lang.Object
java.lang.Enum<HarmCategory.Known>
com.google.genai.types.HarmCategory.Known
All Implemented Interfaces:
Serializable, Comparable<HarmCategory.Known>
Enclosing class:
HarmCategory

public static enum HarmCategory.Known extends Enum<HarmCategory.Known>
Enum representing the known values for HarmCategory.
  • Enum Constant Details

    • HARM_CATEGORY_UNSPECIFIED

      public static final HarmCategory.Known HARM_CATEGORY_UNSPECIFIED
      The harm category is unspecified.
    • HARM_CATEGORY_HATE_SPEECH

      public static final HarmCategory.Known HARM_CATEGORY_HATE_SPEECH
      The harm category is hate speech.
    • HARM_CATEGORY_DANGEROUS_CONTENT

      public static final HarmCategory.Known HARM_CATEGORY_DANGEROUS_CONTENT
      The harm category is dangerous content.
    • HARM_CATEGORY_HARASSMENT

      public static final HarmCategory.Known HARM_CATEGORY_HARASSMENT
      The harm category is harassment.
    • HARM_CATEGORY_SEXUALLY_EXPLICIT

      public static final HarmCategory.Known HARM_CATEGORY_SEXUALLY_EXPLICIT
      The harm category is sexually explicit content.
    • HARM_CATEGORY_CIVIC_INTEGRITY

      public static final HarmCategory.Known HARM_CATEGORY_CIVIC_INTEGRITY
      Deprecated: Election filter is not longer supported. The harm category is civic integrity.
    • HARM_CATEGORY_IMAGE_HATE

      public static final HarmCategory.Known HARM_CATEGORY_IMAGE_HATE
      The harm category is image hate.
    • HARM_CATEGORY_IMAGE_DANGEROUS_CONTENT

      public static final HarmCategory.Known HARM_CATEGORY_IMAGE_DANGEROUS_CONTENT
      The harm category is image dangerous content.
    • HARM_CATEGORY_IMAGE_HARASSMENT

      public static final HarmCategory.Known HARM_CATEGORY_IMAGE_HARASSMENT
      The harm category is image harassment.
    • HARM_CATEGORY_IMAGE_SEXUALLY_EXPLICIT

      public static final HarmCategory.Known HARM_CATEGORY_IMAGE_SEXUALLY_EXPLICIT
      The harm category is image sexually explicit content.
  • Method Details

    • values

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

      public static HarmCategory.Known valueOf(String name)
      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (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 type has no constant with the specified name
      NullPointerException - if the argument is null