Interface KRunnable

Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public interface KRunnable
The KRunnable interface should be implemented by any class whose instances are intended to be executed by a thread. The class must define a method of no arguments called run.

This interface is designed to provide a common protocol for objects that wish to execute code while they are active.

Since:
1.0
Author:
yingzhan
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    run()
    When an object implementing interface KRunnable is used to create a thread, starting the thread causes the object's run method to be called in that separately executing thread.
  • Method Details

    • run

      void run() throws KException
      When an object implementing interface KRunnable is used to create a thread, starting the thread causes the object's run method to be called in that separately executing thread.

      The general contract of the method run is that it may take any action whatsoever.

      Throws:
      KException - if exception occurs