2 * Copyright (c) 2010-2023 Contributors to the openHAB project
4 * See the NOTICE file(s) distributed with this work for additional
7 * This program and the accompanying materials are made available under the
8 * terms of the Eclipse Public License 2.0 which is available at
9 * http://www.eclipse.org/legal/epl-2.0
11 * SPDX-License-Identifier: EPL-2.0
13 package org.openhab.binding.boschindego.internal;
15 import org.eclipse.jdt.annotation.NonNullByDefault;
18 * {@link AuthorizationListener} is used for notifying
19 * {@link org.openhab.binding.boschindego.internal.handler.BoschAccountHandler}
20 * when authorization state has changed and for notifying
21 * {@link org.openhab.binding.boschindego.internal.handler.BoschIndegoHandler}
22 * when authorization flow is completed.
24 * @author Jacob Laursen - Initial contribution
27 public interface AuthorizationListener {
29 * Called upon successful OAuth authorization.
31 void onSuccessfulAuthorization();
34 * Called upon failed OAuth authorization.
36 void onFailedAuthorization(Throwable throwable);
39 * Called upon successful completion of OAuth authorization flow.
41 void onAuthorizationFlowCompleted();