Package io.vertx.core

Enum ThreadingModel

    • Enum Constant Detail

      • EVENT_LOOP

        public static final ThreadingModel EVENT_LOOP
        Tasks are scheduled on the event-loop thread of the vertx instance.
      • WORKER

        public static final ThreadingModel WORKER
        Tasks are scheduled on a worker pool of platform threads managed by the vertx instance.
      • VIRTUAL_THREAD

        public static final ThreadingModel VIRTUAL_THREAD
        Tasks are scheduled on a virtual thread, no assumption on whether virtual threads are pooled.
      • OTHER

        public static final ThreadingModel OTHER
        Tasks are scheduled on threads not managed by the current vertx instance, the nature of the thread is unknown to the vertx instance. Note that an event-loop thread of another vertx instance falls in this category.
    • Method Detail

      • values

        public static ThreadingModel[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (ThreadingModel c : ThreadingModel.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static ThreadingModel 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