org.bidib.jbidibc.netbidib.client.pairingstates.PairingInteractionPublisher Maven / Gradle / Ivy
package org.bidib.jbidibc.netbidib.client.pairingstates;
import org.bidib.jbidibc.messages.enums.PairingResult;
import org.bidib.jbidibc.messages.helpers.Context;
/**
* The {@code PairingInteractionPublisher} is used to publish user interaction events based on messages or state changes
* to the UI.
*
*/
public interface PairingInteractionPublisher {
/**
* Publish the action to the user. This will call the user to perform an action.
*/
void publishUserAction(String actionKey, final Context context);
/**
* Publish the pairing result.
*
* @param pairingResult
* the pairing result
*/
void publishPairingFinished(PairingResult pairingResult);
/**
* Publish the local logon received.
*/
void publishLocalLogon(int localNodeAddr, long uniqueId);
/**
* Publish the local logoff received.
*/
void publishLocalLogoff();
/**
* Signal that an error happened.
*/
void handleError(RuntimeException ex);
}