Package com.io7m.cedarbridge.runtime.api

# Interface CBBooleanType

All Superinterfaces:
  `CBSerializableType`, `Formattable`

All Known Implementing Classes:
  `CBFalse`, `CBTrue`

public sealed interface CBBooleanType extends Formattable, CBSerializableType permits CBFalse, CBTrue
The boolean type.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `boolean`
  `asBoolean()`
  `static CBBooleanType`
  `deserialize(CBSerializationContextType context)`
  Deserialize the given value.
  `static CBBooleanType`
  `fromBoolean(boolean b)`
  A boolean from the given boolean value.
  `static void`
  `serialize(CBSerializationContextType context, CBBooleanType x)`
  Serialize the given value.

  ### Methods inherited from interface java.util.Formattable

  `formatTo`

- ## Method Details

  - ### asBoolean

    boolean asBoolean()
    Returns:
      This value as a Java boolean

  - ### fromBoolean

    static CBBooleanType fromBoolean(boolean b)
    A boolean from the given boolean value.
    Parameters:
      `b` - The Java boolean
    Returns:
      The boolean

  - ### serialize

    static void serialize(CBSerializationContextType context, CBBooleanType x) throws IOException
    Serialize the given value.
    Parameters:
      `context` - The serialization context
      `x` - The value
    Throws:
      `IOException` - On errors

  - ### deserialize

    static CBBooleanType deserialize(CBSerializationContextType context) throws IOException
    Deserialize the given value.
    Parameters:
      `context` - The serialization context
    Returns:
      The deserialized value
    Throws:
      `IOException` - On errors