001package org.andromda.core.server;
002
003import java.net.ConnectException;
004import org.andromda.core.configuration.Configuration;
005
006/**
007 * A client used to connect to an AndroMDA
008 * {@link Server} instance.
009 *
010 * @see Server
011 * @author Chad Brandon
012 */
013public interface Client
014{
015    /**
016     * Connects to and starts an AndroMDA server with the given <code>configuration</code>.
017     *
018     * @param configuration the AndroMDA configuration instance.
019     * @throws ConnectException if the client can not connect to an
020     *         AndroMDA server instance.
021     */
022    public void start(final Configuration configuration)
023        throws ConnectException;
024
025    /**
026     * Connects to and stops an AndroMDA server with the given <code>configuration</code>.
027     *
028     * @param configuration the AndroMDA configuration instance.
029     * @throws ConnectException if the client can not connect to an
030     *         AndroMDA server instance.
031     */
032    public void stop(final Configuration configuration)
033        throws ConnectException;
034}