| | |
| | | * CDDL HEADER END |
| | | * |
| | | * |
| | | * Copyright 2013-2014 ForgeRock AS |
| | | * Copyright 2013-2015 ForgeRock AS |
| | | */ |
| | | |
| | | package org.opends.server.tools.upgrade; |
| | |
| | | } |
| | | |
| | | /** |
| | | * Performs any preparation work required before performing the upgrade task, including |
| | | * interacting with the user where needed (e.g. in order to ask for confirmation), and throw a |
| | | * {@code ClientException} if the upgrade cannot proceed. |
| | | * |
| | | * @param context |
| | | * Context through which tasks can interact with the server installation. |
| | | * @throws ClientException |
| | | * If the upgrade cannot proceed. |
| | | */ |
| | | void prepare(UpgradeContext context) throws ClientException; |
| | | |
| | | /** |
| | | * Performs this upgrade task. |
| | | * |
| | | * @param context |
| | | * Context through which tasks can interact with the server |
| | | * installation. |
| | | * Context through which tasks can interact with the server installation. |
| | | * @throws ClientException |
| | | * If an error occurred while performing the task. |
| | | */ |
| | | void perform(UpgradeContext context) |
| | | throws ClientException; |
| | | |
| | | /** |
| | | * Verifies that this upgrade task can be completed or not. |
| | | * |
| | | * @param context |
| | | * Context through which tasks can interact with the server |
| | | * installation. |
| | | * @throws ClientException |
| | | * If the upgrade cannot proceed. |
| | | */ |
| | | void verify(UpgradeContext context) |
| | | throws ClientException; |
| | | |
| | | /** |
| | | * Interacts with the user where needed (e.g. in order to ask for |
| | | * confirmation), and throw a {@code ClientException} if the upgrade cannot |
| | | * proceed. |
| | | * |
| | | * @param context |
| | | * Context through which tasks can interact with the server |
| | | * installation. |
| | | * @throws ClientException |
| | | * If the upgrade cannot proceed. |
| | | */ |
| | | void interact(UpgradeContext context) |
| | | throws ClientException; |
| | | void perform(UpgradeContext context) throws ClientException; |
| | | |
| | | /** |
| | | * This method will be invoked after all upgrade tasks have completed |