Class IsSpace


public class IsSpace extends PrimitiveFunction
Determines whether a character is whitespace.
  • Constructor Details

    • IsSpace

      public IsSpace()
  • Method Details

    • name

      public Name name()
      Gets the qualified name of this primitive function.
      Specified by:
      name in class PrimitiveFunction
      Returns:
      the name "hydra.lib.chars.isSpace"
    • type

      public TypeScheme type()
      Gets the type scheme for this function.
      Specified by:
      type in class PrimitiveFunction
      Returns:
      the type scheme representing int32 to boolean function
    • implementation

      protected Function<List<Term>,Flow<Graph,Term>> implementation()
      Provides the implementation of this primitive function.
      Specified by:
      implementation in class PrimitiveFunction
      Returns:
      a function that takes a list of terms and returns a flow producing a boolean term
    • apply

      public static boolean apply(int codePoint)
      Checks whether the given code point is whitespace.
      Parameters:
      codePoint - the Unicode code point to test
      Returns:
      true if the code point is whitespace, false otherwise