Class Copilot

java.lang.Object
com.vaadin.copilot.Copilot
All Implemented Interfaces:
com.vaadin.base.devserver.DevToolsMessageHandler

public class Copilot extends Object implements com.vaadin.base.devserver.DevToolsMessageHandler
This is the entry point for copilot.

It is a singleton with the main purpose to forward messages to the correct CopilotSession instance, based on which session the message is related to.

  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final String
     
    static final String
     
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    handleConnect(com.vaadin.base.devserver.DevToolsInterface devToolsInterface)
     
    boolean
    handleMessage(String command, elemental.json.JsonObject data, com.vaadin.base.devserver.DevToolsInterface devToolsInterface)
     
    static boolean
    Check if copilot is running in development mode i.e.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface com.vaadin.base.devserver.DevToolsMessageHandler

    handleDisconnect
  • Field Details

  • Constructor Details

    • Copilot

      public Copilot()
  • Method Details

    • handleConnect

      public void handleConnect(com.vaadin.base.devserver.DevToolsInterface devToolsInterface)
      Specified by:
      handleConnect in interface com.vaadin.base.devserver.DevToolsMessageHandler
    • handleMessage

      public boolean handleMessage(String command, elemental.json.JsonObject data, com.vaadin.base.devserver.DevToolsInterface devToolsInterface)
      Specified by:
      handleMessage in interface com.vaadin.base.devserver.DevToolsMessageHandler
    • isDevelopmentMode

      public static boolean isDevelopmentMode()
      Check if copilot is running in development mode i.e. is being developed.

      Unrelated to Vaadin's production mode.

      Returns:
      true if copilot is running in development mode