Package org.opentcs.access

# Interface KernelServicePortal

All Known Implementing Classes:
  `RemoteKernelServicePortalProxy`

    public interface KernelServicePortal

Provides clients access to kernel services.

- ## Method Summary

  Modifier and Type | Method | Description
  --- | --- | ---
  `java.util.List<java.lang.Object>` | `fetchEvents​(long timeout)` | Fetches events buffered for the client.
  `DispatcherService` | `getDispatcherService()` | Returns the service a client can use to access methods regarding the dispatcher.
  `NotificationService` | `getNotificationService()` | Returns the service a client can use to access methods regarding user notifications.
  `PeripheralDispatcherService` | `getPeripheralDispatcherService()` | Returns the service a client can use to access methods regarding the peripheral dispatcher.
  `PeripheralJobService` | `getPeripheralJobService()` | Returns the service a client can use to access methods regarding peripheral jobs.
  `PeripheralService` | `getPeripheralService()` | Returns the service a client can use to access methods regarding peripherals.
  `PlantModelService` | `getPlantModelService()` | Returns the service a client can use to access methods regarding the plant model.
  `QueryService` | `getQueryService()` | Returns the service a client can use to access methods for generic queries.
  `RouterService` | `getRouterService()` | Returns the service a client can use to access methods regarding the router.
  `SchedulerService` | `getSchedulerService()` | Returns the service a client can use to access methods regarding the scheduler.
  `Kernel.State` | `getState()` | Returns the current state of the kernel.
  `TransportOrderService` | `getTransportOrderService()` | Returns the service a client can use to access methods regarding transport orders and order sequences.
  `VehicleService` | `getVehicleService()` | Returns the service a client can use to access methods regarding vehicles.
  `void` | `login​(java.lang.String hostName, int port)` | Logs in with/establishes a connection to the remote kernel service portal.
  `void` | `logout()` | Logs out from/clears the connection to the remote kernel service portal.
  `void` | `publishEvent​(java.lang.Object event)` | Publishes an event.

- ## Method Details

  - ### login

    void login​(@Nonnull java.lang.String hostName, int port) throws KernelRuntimeException
    Logs in with/establishes a connection to the remote kernel service portal.
    Parameters:
      `hostName` - The host on which the remote portal is running.
      `port` - The port at which we can reach the remote RMI registry.
    Throws:
      `KernelRuntimeException` - If there was a problem logging in with the remote portal.

  - ### logout

    void logout() throws KernelRuntimeException
    Logs out from/clears the connection to the remote kernel service portal.
    Throws:
      `KernelRuntimeException` - If there was a problem logging out from the remote portal, i.e. it is no longer available.

  - ### getState

    Kernel.State getState() throws KernelRuntimeException
    Returns the current state of the kernel.
    Returns:
      The current state of the kernel.
    Throws:
      `KernelRuntimeException` - In case there is an exception executing this method.

  - ### fetchEvents

    java.util.List<java.lang.Object> fetchEvents​(long timeout) throws KernelRuntimeException
    Fetches events buffered for the client.
    Parameters:
      `timeout` - A timeout (in ms) for which to wait for events to arrive.
    Returns:
      A list of events (in the order they arrived).
    Throws:
      `KernelRuntimeException` - In case there is an exception executing this method.

  - ### publishEvent

    void publishEvent​(java.lang.Object event) throws KernelRuntimeException
    Publishes an event.
    Parameters:
      `event` - The event to be published.
    Throws:
      `KernelRuntimeException` - In case there is an exception executing this method.

  - ### getPlantModelService

    @Nonnull PlantModelService getPlantModelService()
    Returns the service a client can use to access methods regarding the plant model.
    Returns:
      The service a client can use to access methods regarding the plant model.

  - ### getTransportOrderService

    @Nonnull TransportOrderService getTransportOrderService()
    Returns the service a client can use to access methods regarding transport orders and order sequences.
    Returns:
      The service a client can use to access methods regarding transport orders and order sequences.

  - ### getVehicleService

    @Nonnull VehicleService getVehicleService()
    Returns the service a client can use to access methods regarding vehicles.
    Returns:
      The service a client can use to access methods regarding vehicles.

  - ### getNotificationService

    @Nonnull NotificationService getNotificationService()
    Returns the service a client can use to access methods regarding user notifications.
    Returns:
      The service a client can use to access methods regarding user notifications.

  - ### getDispatcherService

    @Nonnull DispatcherService getDispatcherService()
    Returns the service a client can use to access methods regarding the dispatcher.
    Returns:
      The service a client can use to access methods regarding the dispatcher.

  - ### getRouterService

    @Nonnull RouterService getRouterService()
    Returns the service a client can use to access methods regarding the router.
    Returns:
      The service a client can use to access methods regarding the router.

  - ### getSchedulerService

    @Nonnull SchedulerService getSchedulerService()
    Returns the service a client can use to access methods regarding the scheduler.
    Returns:
      The service a client can use to access methods regarding the scheduler.

  - ### getQueryService

    @Nonnull QueryService getQueryService()
    Returns the service a client can use to access methods for generic queries.
    Returns:
      The service a client can use to access methods for generic queries.

  - ### getPeripheralService

    @Nonnull PeripheralService getPeripheralService()
    Returns the service a client can use to access methods regarding peripherals.
    Returns:
      The service a client can use to access methods regarding peripherals.

  - ### getPeripheralJobService

    @Nonnull PeripheralJobService getPeripheralJobService()
    Returns the service a client can use to access methods regarding peripheral jobs.
    Returns:
      The service a client can use to access methods regarding peripheral jobs.

  - ### getPeripheralDispatcherService

    @Nonnull PeripheralDispatcherService getPeripheralDispatcherService()
    Returns the service a client can use to access methods regarding the peripheral dispatcher.
    Returns:
      The service a client can use to access methods regarding the peripheral dispatcher.