Files
LuaScript/src/main/java/org/openautonomousconnection/luascript/hosts/EventHost.java

38 lines
878 B
Java
Raw Normal View History

2026-01-16 21:47:04 +01:00
package org.openautonomousconnection.luascript.hosts;
/**
* Event subscription abstraction (implemented by the client UI layer).
*/
public interface EventHost {
/**
* Subscribes to an element event.
*
* @param elementId element id
* @param eventName event name (e.g. click)
*/
void addListener(String elementId, String eventName);
/**
* Unsubscribes from an element event.
*
* @param elementId element id
* @param eventName event name
*/
void removeListener(String elementId, String eventName);
/**
* Subscribes to a global event (app/window scope).
*
* @param eventName event name
*/
void addGlobalListener(String eventName);
/**
* Unsubscribes from a global event.
*
* @param eventName event name
*/
void removeGlobalListener(String eventName);
}