| | |
| | | * |
| | | * |
| | | * Copyright 2009-2010 Sun Microsystems, Inc. |
| | | * Portions Copyright 2011 ForgeRock AS |
| | | */ |
| | | |
| | | package org.opends.guitools.controlpanel; |
| | |
| | | private BooleanArgument trustAllArg = null; |
| | | |
| | | /** |
| | | * The 'remoteArg' global argument. |
| | | */ |
| | | private BooleanArgument remoteArg = null; |
| | | |
| | | /** |
| | | * Argument to specify the connect timeout. |
| | | */ |
| | | private IntegerArgument connectTimeoutArg = null; |
| | |
| | | trustAllArg.setPropertyName(OPTION_LONG_TRUSTALL); |
| | | addArgument(trustAllArg); |
| | | |
| | | remoteArg = new BooleanArgument("remote", OPTION_SHORT_REMOTE, |
| | | OPTION_LONG_REMOTE, INFO_DESCRIPTION_REMOTE.get()); |
| | | remoteArg.setPropertyName(OPTION_LONG_REMOTE); |
| | | addArgument(remoteArg); |
| | | |
| | | int defaultTimeout = ConnectionUtils.getDefaultLDAPTimeout(); |
| | | connectTimeoutArg = new IntegerArgument(OPTION_LONG_CONNECT_TIMEOUT, |
| | | null, OPTION_LONG_CONNECT_TIMEOUT, |
| | |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * Returns whether the user specified to connect to a remote server. |
| | | * @return whether the user specified to connect to a remote server. |
| | | */ |
| | | public boolean isRemote() |
| | | { |
| | | return remoteArg.isPresent(); |
| | | } |
| | | |
| | | } |