001/*
002 * CDDL HEADER START
003 *
004 * The contents of this file are subject to the terms of the
005 * Common Development and Distribution License, Version 1.0 only
006 * (the "License").  You may not use this file except in compliance
007 * with the License.
008 *
009 * You can obtain a copy of the license at legal-notices/CDDLv1_0.txt
010 * or http://forgerock.org/license/CDDLv1.0.html.
011 * See the License for the specific language governing permissions
012 * and limitations under the License.
013 *
014 * When distributing Covered Code, include this CDDL HEADER in each
015 * file and include the License file at legal-notices/CDDLv1_0.txt.
016 * If applicable, add the following below this CDDL HEADER, with the
017 * fields enclosed by brackets "[]" replaced with your own identifying
018 * information:
019 *      Portions Copyright [yyyy] [name of copyright owner]
020 *
021 * CDDL HEADER END
022 *
023 *
024 *      Copyright 2008-2009 Sun Microsystems, Inc.
025 */
026
027package org.opends.server.tools.dsreplication;
028
029/**
030 * This class is used to store the information provided by the user to
031 * initialize replication.  It is required because when we are in interactive
032 * mode the ReplicationCliArgumentParser is not enough.
033 *
034 */
035public class InitializeReplicationUserData extends ReplicationUserData
036{
037  private String hostNameSource;
038  private int portSource;
039  private String hostNameDestination;
040  private int portDestination;
041
042  /**
043   * Returns the host name of the source server.
044   * @return the host name of the source server.
045   */
046  public String getHostNameSource()
047  {
048    return hostNameSource;
049  }
050
051  /**
052   * Sets the host name of the source server.
053   * @param hostNameSource the host name of the source server.
054   */
055  public void setHostNameSource(String hostNameSource)
056  {
057    this.hostNameSource = hostNameSource;
058  }
059
060  /**
061   * Returns the port of the source server.
062   * @return the port of the source server.
063   */
064  public int getPortSource()
065  {
066    return portSource;
067  }
068
069  /**
070   * Sets the port of the source server.
071   * @param portSource the port of the source server.
072   */
073  public void setPortSource(int portSource)
074  {
075    this.portSource = portSource;
076  }
077
078  /**
079   * Returns the host name of the destination server.
080   * @return the host name of the destination server.
081   */
082  public String getHostNameDestination()
083  {
084    return hostNameDestination;
085  }
086
087  /**
088   * Sets the host name of the destination server.
089   * @param hostNameDestination the host name of the destination server.
090   */
091  public void setHostNameDestination(String hostNameDestination)
092  {
093    this.hostNameDestination = hostNameDestination;
094  }
095
096  /**
097   * Returns the port of the destination server.
098   * @return the port of the destination server.
099   */
100  public int getPortDestination()
101  {
102    return portDestination;
103  }
104
105  /**
106   * Sets the port of the destination server.
107   * @param portDestination the port of the destination server.
108   */
109  public void setPortDestination(int portDestination)
110  {
111    this.portDestination = portDestination;
112  }
113
114}