mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-23 06:32:10 +02:00
[cleanup] fix terminal copyright headers and beautify
This commit is contained in:
parent
f8dc09d4f8
commit
0c39b8153e
33 changed files with 324 additions and 208 deletions
|
@ -1,28 +1,27 @@
|
|||
################################################################################
|
||||
# Copyright (c) 2006 Wind River Systems, Inc. and others.
|
||||
###############################################################################
|
||||
# Copyright (c) 2003, 2006 Wind River Systems, Inc. and others.
|
||||
# All rights reserved. This program and the accompanying materials
|
||||
# are made available under the terms of the Eclipse Public License v1.0
|
||||
# which accompanies this distribution, and is available at
|
||||
# http://www.eclipse.org/legal/epl-v10.html
|
||||
#
|
||||
# Initial Contributors:
|
||||
# The following Wind River employees contributed to the Terminal component
|
||||
# that contains this file: Chris Thew, Fran Litterio, Stephen Lamb,
|
||||
# Helmut Haigermoser and Ted Williams.
|
||||
#
|
||||
# Contributors:
|
||||
# Wind River Systems, Inc. - initial API and implementation
|
||||
# Ted Williams (Wind River) - refactored into org.eclipse.tm.terminal
|
||||
# Michael Scharf (Wind River) - separated into core, serial and view plugins
|
||||
# Martin Oberhuber (Wind River) - fix copyrights, legal docs, missing files
|
||||
################################################################################
|
||||
# Michael Scharf (Wind River) - split into core, view and connector plugins
|
||||
# Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
###############################################################################
|
||||
bin.includes = .,\
|
||||
src/,\
|
||||
META-INF/,\
|
||||
plugin.xml,\
|
||||
.classpath,\
|
||||
.project,\
|
||||
build.properties,\
|
||||
plugin.properties,\
|
||||
schema/,\
|
||||
.settings/,\
|
||||
.options
|
||||
|
||||
source.. = src/
|
||||
output.. = bin/
|
||||
src.includes = schema/,\
|
||||
src/
|
||||
|
|
@ -1,6 +1,18 @@
|
|||
##########################################################################
|
||||
# Copyright 2004 Wind River Systems, Inc. All rights reserved.
|
||||
##########################################################################
|
||||
|
||||
###############################################################################
|
||||
# Copyright (c) 2003, 2006 Wind River Systems, Inc. and others.
|
||||
# All rights reserved. This program and the accompanying materials
|
||||
# are made available under the terms of the Eclipse Public License v1.0
|
||||
# which accompanies this distribution, and is available at
|
||||
# http://www.eclipse.org/legal/epl-v10.html
|
||||
#
|
||||
# Initial Contributors:
|
||||
# The following Wind River employees contributed to the Terminal component
|
||||
# that contains this file: Chris Thew, Fran Litterio, Stephen Lamb,
|
||||
# Helmut Haigermoser and Ted Williams.
|
||||
#
|
||||
# Contributors:
|
||||
# Michael Scharf (Wind River) - split into core, view and connector plugins
|
||||
# Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
###############################################################################
|
||||
pluginName = Terminal
|
||||
providerName = Eclipse.org
|
||||
|
|
|
@ -1,5 +1,21 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<?eclipse version="3.0"?>
|
||||
<!--
|
||||
# Copyright (c) 2003, 2006 Wind River Systems, Inc. and others.
|
||||
# All rights reserved. This program and the accompanying materials
|
||||
# are made available under the terms of the Eclipse Public License v1.0
|
||||
# which accompanies this distribution, and is available at
|
||||
# http://www.eclipse.org/legal/epl-v10.html
|
||||
#
|
||||
# Initial Contributors:
|
||||
# The following Wind River employees contributed to the Terminal component
|
||||
# that contains this file: Chris Thew, Fran Litterio, Stephen Lamb,
|
||||
# Helmut Haigermoser and Ted Williams.
|
||||
#
|
||||
# Contributors:
|
||||
# Michael Scharf (Wind River) - split into core, view and connector plugins
|
||||
# Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
-->
|
||||
<plugin>
|
||||
<extension-point id="terminalConnector" name="Terminal Connector" schema="schema/terminalConnector.exsd"/>
|
||||
<extension
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
<meta.schema plugin="org.eclipse.tm.terminal" id="terminalConnector" name="TerminalConnector"/>
|
||||
</appInfo>
|
||||
<documentation>
|
||||
[Enter description of this extension point.]
|
||||
|
||||
</documentation>
|
||||
</annotation>
|
||||
|
||||
|
@ -62,7 +62,7 @@
|
|||
<meta.section type="since"/>
|
||||
</appInfo>
|
||||
<documentation>
|
||||
[Enter the first release in which this extension point appears.]
|
||||
|
||||
</documentation>
|
||||
</annotation>
|
||||
|
||||
|
@ -71,7 +71,7 @@
|
|||
<meta.section type="examples"/>
|
||||
</appInfo>
|
||||
<documentation>
|
||||
[Enter extension point usage example here.]
|
||||
|
||||
</documentation>
|
||||
</annotation>
|
||||
|
||||
|
@ -80,7 +80,7 @@
|
|||
<meta.section type="apiInfo"/>
|
||||
</appInfo>
|
||||
<documentation>
|
||||
[Enter API information here.]
|
||||
|
||||
</documentation>
|
||||
</annotation>
|
||||
|
||||
|
@ -89,7 +89,7 @@
|
|||
<meta.section type="implementation"/>
|
||||
</appInfo>
|
||||
<documentation>
|
||||
[Enter information about supplied implementation of this extension point.]
|
||||
|
||||
</documentation>
|
||||
</annotation>
|
||||
|
||||
|
@ -98,6 +98,15 @@
|
|||
<meta.section type="copyright"/>
|
||||
</appInfo>
|
||||
<documentation>
|
||||
Copyright (c) 2006 Wind River Systems, Inc. and others.
|
||||
All rights reserved. This program and the accompanying materials
|
||||
are made available under the terms of the Eclipse Public License v1.0
|
||||
which accompanies this distribution, and is available at
|
||||
http://www.eclipse.org/legal/epl-v10.html
|
||||
|
||||
Contributors:
|
||||
Michael Scharf (Wind River) - initial API and implementation
|
||||
Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
|
||||
</documentation>
|
||||
</annotation>
|
||||
|
|
|
@ -6,8 +6,8 @@
|
|||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems, Inc. - initial implementation
|
||||
*
|
||||
* Michael Scharf (Wind River) - initial API and implementation
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
package org.eclipse.tm.terminal;
|
||||
|
||||
|
@ -26,18 +26,22 @@ public interface ISettingsPage {
|
|||
* @param parent
|
||||
*/
|
||||
void createControl(Composite parent);
|
||||
|
||||
/**
|
||||
* Called before the page is shown. Loads the state from the {@link ITerminalConnector}.
|
||||
*/
|
||||
void loadSettings();
|
||||
|
||||
/**
|
||||
* Called when the OK button is pressed.
|
||||
*/
|
||||
void saveSettings();
|
||||
|
||||
/**
|
||||
* @return true if the
|
||||
*/
|
||||
boolean validateSettings();
|
||||
|
||||
/**
|
||||
* @return a name of the connection type. Used in a tab page title or drop
|
||||
* down to select the connection.
|
||||
|
|
|
@ -6,18 +6,16 @@
|
|||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems, Inc. - initial implementation
|
||||
*
|
||||
* Michael Scharf (Wind River) - initial API and implementation
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
package org.eclipse.tm.terminal;
|
||||
|
||||
/**
|
||||
* A simple interface to a store to persist the state of a connection.
|
||||
*
|
||||
*
|
||||
* <p>Not to be implemented.
|
||||
* <p>TODO Not to be implemented.
|
||||
* @author Michael Scharf
|
||||
*
|
||||
*/
|
||||
public interface ISettingsStore {
|
||||
/**
|
||||
|
@ -25,12 +23,14 @@ public interface ISettingsStore {
|
|||
* @return value
|
||||
*/
|
||||
String get(String key);
|
||||
|
||||
/**
|
||||
* @param key
|
||||
* @param defaultValue
|
||||
* @return the value or the fecaault
|
||||
*/
|
||||
String get(String key, String defaultValue);
|
||||
|
||||
/**
|
||||
* Save a string value
|
||||
* @param key
|
||||
|
|
|
@ -6,8 +6,8 @@
|
|||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems, Inc. - initial implementation
|
||||
*
|
||||
* Michael Scharf (Wind River) - initial API and implementation
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
package org.eclipse.tm.terminal;
|
||||
|
||||
|
@ -20,24 +20,26 @@ import java.io.OutputStream;
|
|||
* via <code>org.eclipse.tm.terminal.terminalConnector</code> extension point.
|
||||
*
|
||||
* @author Michael Scharf
|
||||
*
|
||||
*/
|
||||
public interface ITerminalConnector {
|
||||
/**
|
||||
* @return an ID of this connector. Typically <code>getClass().getName()</code>
|
||||
*/
|
||||
String getId();
|
||||
|
||||
/**
|
||||
* @return true if the contribution is functioning (e.g. all external libraries are
|
||||
* installed). This was added for the serial support, because it requires the java comm
|
||||
* library, which is installed in the lib/ext directory of the
|
||||
*/
|
||||
boolean isInstalled();
|
||||
|
||||
/**
|
||||
* Connect using the current state of the settings.
|
||||
* @param control Used to inform the UI about state changes and messages from the connection.
|
||||
*/
|
||||
void connect(ITerminalControl control);
|
||||
|
||||
/**
|
||||
* Disconnect if connected. Else do nothing.
|
||||
*/
|
||||
|
@ -60,6 +62,7 @@ public interface ITerminalConnector {
|
|||
* @return a stream with data coming from the remote site.
|
||||
*/
|
||||
OutputStream getOutputStream();
|
||||
|
||||
/**
|
||||
* @return a stream to write to the remote site.
|
||||
*/
|
||||
|
|
|
@ -6,8 +6,8 @@
|
|||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems, Inc. - initial implementation
|
||||
*
|
||||
* Michael Scharf (Wind River) - initial API and implementation
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
package org.eclipse.tm.terminal;
|
||||
|
||||
|
@ -18,7 +18,6 @@ import org.eclipse.swt.widgets.Shell;
|
|||
*
|
||||
* <p> Not to be implemented by clients.
|
||||
* @author Michael Scharf
|
||||
*
|
||||
*/
|
||||
public interface ITerminalControl {
|
||||
|
||||
|
@ -26,6 +25,7 @@ public interface ITerminalControl {
|
|||
* @return the current state of the connection
|
||||
*/
|
||||
TerminalState getState();
|
||||
|
||||
/**
|
||||
* @param state
|
||||
*/
|
||||
|
@ -44,11 +44,13 @@ public interface ITerminalControl {
|
|||
* TODO: Michael Scharf: Is this really needed? (use {@link #displayTextInTerminal(String)}
|
||||
*/
|
||||
void displayTextInTerminal(String text);
|
||||
|
||||
/**
|
||||
* Write a string directly to the terminal.
|
||||
* @param txt
|
||||
*/
|
||||
void writeToTerminal(String txt);
|
||||
|
||||
/**
|
||||
* Set the title of the terminal view.
|
||||
* @param title
|
||||
|
|
|
@ -1,15 +1,16 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2006 Wind River Systems, Inc. and others.
|
||||
* Copyright (c) 2005, 2006 Wind River Systems, Inc. and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems, Inc. - initial implementation
|
||||
*
|
||||
* Fran Litterio (Wind River) - initial API and implementation
|
||||
* Ted Williams (Wind River) - refactored into org.eclipse namespace
|
||||
* Michael Scharf (Wind River) - split into core, view and connector plugins
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.tm.terminal;
|
||||
|
||||
import java.io.File;
|
||||
|
|
|
@ -6,8 +6,8 @@
|
|||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems, Inc. - initial implementation
|
||||
*
|
||||
* Michael Scharf (Wind River) - initial API and implementation
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
package org.eclipse.tm.terminal;
|
||||
|
||||
|
|
|
@ -6,8 +6,8 @@
|
|||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems, Inc. - initial implementation
|
||||
*
|
||||
* Michael Scharf (Wind River) - initial API and implementation
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
package org.eclipse.tm.terminal;
|
||||
|
||||
|
@ -22,23 +22,28 @@ public class TerminalState {
|
|||
* The terminal is not connected.
|
||||
*/
|
||||
public final static TerminalState CLOSED=new TerminalState("CLOSED"); //$NON-NLS-1$
|
||||
|
||||
/**
|
||||
* TODO: Michael Scharf: it's not clear to me what the meaning of the open state is
|
||||
*/
|
||||
public final static TerminalState OPENED=new TerminalState("OPENED"); //$NON-NLS-1$
|
||||
|
||||
/**
|
||||
* The terminal is about to connect.
|
||||
*/
|
||||
public final static TerminalState CONNECTING=new TerminalState("CONNECTING..."); //$NON-NLS-1$
|
||||
|
||||
/**
|
||||
* The terminal is connected.
|
||||
*/
|
||||
public final static TerminalState CONNECTED=new TerminalState("CONNECTED"); //$NON-NLS-1$
|
||||
|
||||
private final String fState;
|
||||
|
||||
public TerminalState(String state) {
|
||||
fState = state;
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
return fState;
|
||||
}
|
||||
|
|
|
@ -6,14 +6,13 @@
|
|||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems, Inc. - initial implementation
|
||||
*
|
||||
* Michael Scharf (Wind River) - initial API and implementation
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
package org.eclipse.tm.terminal.control;
|
||||
|
||||
import org.eclipse.tm.terminal.TerminalState;
|
||||
|
||||
|
||||
/**
|
||||
* Provided by a view implementation.
|
||||
* @author Michael Scharf
|
||||
|
@ -25,6 +24,7 @@ public interface ITerminalListener {
|
|||
* @param state
|
||||
*/
|
||||
void setState(TerminalState state);
|
||||
|
||||
/**
|
||||
* Set the title of the terminal.
|
||||
* @param title
|
||||
|
|
|
@ -6,8 +6,8 @@
|
|||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems, Inc. - initial implementation
|
||||
*
|
||||
* Michael Scharf (Wind River) - initial API and implementation
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
package org.eclipse.tm.terminal.control;
|
||||
|
||||
|
|
|
@ -6,8 +6,8 @@
|
|||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems, Inc. - initial implementation
|
||||
*
|
||||
* Michael Scharf (Wind River) - initial API and implementation
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
package org.eclipse.tm.terminal.control;
|
||||
|
||||
|
|
|
@ -6,8 +6,8 @@
|
|||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems, Inc. - initial implementation
|
||||
*
|
||||
* Michael Scharf (Wind River) - initial API and implementation
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
package org.eclipse.tm.terminal.internal.control;
|
||||
|
||||
|
|
|
@ -1,15 +1,19 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2006 Wind River Systems, Inc. and others.
|
||||
* Copyright (c) 2003, 2006 Wind River Systems, Inc. and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems, Inc. - initial implementation
|
||||
* Initial Contributors:
|
||||
* The following Wind River employees contributed to the Terminal component
|
||||
* that contains this file: Chris Thew, Fran Litterio, Stephen Lamb,
|
||||
* Helmut Haigermoser and Ted Williams.
|
||||
*
|
||||
* Contributors:
|
||||
* Michael Scharf (Wind River) - split into core, view and connector plugins
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.tm.terminal.internal.control;
|
||||
|
||||
import java.io.IOException;
|
||||
|
@ -102,6 +106,7 @@ public class TerminalControl implements ITerminalControlForText, ITerminalContro
|
|||
public ITerminalConnector[] getConnectors() {
|
||||
return fConnectors;
|
||||
}
|
||||
|
||||
/* (non-Javadoc)
|
||||
* @see org.eclipse.tm.terminal.ITerminalControl#copy()
|
||||
*/
|
||||
|
@ -241,6 +246,7 @@ public class TerminalControl implements ITerminalControlForText, ITerminalContro
|
|||
// fConnector=null;
|
||||
}
|
||||
}
|
||||
|
||||
// TODO
|
||||
private void waitForConnect() {
|
||||
Logger.log("entered."); //$NON-NLS-1$
|
||||
|
|
|
@ -6,12 +6,13 @@
|
|||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems, Inc. - initial implementation
|
||||
*
|
||||
* Michael Scharf (Wind River) - initial API and implementation
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
package org.eclipse.tm.terminal.internal.control;
|
||||
|
||||
import org.eclipse.osgi.util.NLS;
|
||||
|
||||
public class TerminalMessages extends NLS {
|
||||
static {
|
||||
NLS.initializeMessages(TerminalMessages.class.getName(), TerminalMessages.class);
|
||||
|
|
|
@ -1,13 +1,18 @@
|
|||
###############################################################################
|
||||
# Copyright (c) 2006 Wind River Systems, Inc. and others.
|
||||
# Copyright (c) 2003, 2006 Wind River Systems, Inc. and others.
|
||||
# All rights reserved. This program and the accompanying materials
|
||||
# are made available under the terms of the Eclipse Public License v1.0
|
||||
# which accompanies this distribution, and is available at
|
||||
# http://www.eclipse.org/legal/epl-v10.html
|
||||
#
|
||||
# Contributors:
|
||||
# Wind River Systems, Inc. - initial implementation
|
||||
# Initial Contributors:
|
||||
# The following Wind River employees contributed to the Terminal component
|
||||
# that contains this file: Chris Thew, Fran Litterio, Stephen Lamb,
|
||||
# Helmut Haigermoser and Ted Williams.
|
||||
#
|
||||
# Contributors:
|
||||
# Michael Scharf (Wind River) - split into core, view and connector plugins
|
||||
# Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
###############################################################################
|
||||
TerminalError = Terminal Error
|
||||
SocketError = Socket Error
|
||||
|
|
|
@ -1,15 +1,19 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2006 Wind River Systems, Inc. and others.
|
||||
* Copyright (c) 2003, 2006 Wind River Systems, Inc. and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems, Inc. - initial implementation
|
||||
* Initial Contributors:
|
||||
* The following Wind River employees contributed to the Terminal component
|
||||
* that contains this file: Chris Thew, Fran Litterio, Stephen Lamb,
|
||||
* Helmut Haigermoser and Ted Williams.
|
||||
*
|
||||
* Contributors:
|
||||
* Michael Scharf (Wind River) - split into core, view and connector plugins
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.tm.terminal.internal.control;
|
||||
|
||||
import org.eclipse.core.runtime.Platform;
|
||||
|
|
|
@ -1,15 +1,19 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2006 Wind River Systems, Inc. and others.
|
||||
* Copyright (c) 2003, 2006 Wind River Systems, Inc. and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems, Inc. - initial implementation
|
||||
* Initial Contributors:
|
||||
* The following Wind River employees contributed to the Terminal component
|
||||
* that contains this file: Chris Thew, Fran Litterio, Stephen Lamb,
|
||||
* Helmut Haigermoser and Ted Williams.
|
||||
*
|
||||
* Contributors:
|
||||
* Michael Scharf (Wind River) - split into core, view and connector plugins
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.tm.terminal.internal.control;
|
||||
|
||||
import java.io.IOException;
|
||||
|
|
|
@ -1,3 +1,14 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2006 Wind River Systems, Inc. and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Michael Scharf (Wind River) - initial API and implementation
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
package org.eclipse.tm.terminal.internal.telnet;
|
||||
|
||||
import org.eclipse.tm.terminal.ISettingsStore;
|
||||
|
|
|
@ -6,29 +6,31 @@
|
|||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems, Inc. - initial implementation
|
||||
*
|
||||
* Michael Scharf (Wind River) - initial API and implementation
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.tm.terminal.internal.telnet;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
public class NetworkPortMap {
|
||||
public static final String PROP_NAMETGTCONST = "tgtcons"; //$NON-NLS-1$
|
||||
public static final String PROP_NAMETGTCONS = "tgtcons"; //$NON-NLS-1$
|
||||
public static final String PROP_NAMETELNET = "telnet"; //$NON-NLS-1$
|
||||
public static final String PROP_VALUENET = "1233"; //$NON-NLS-1$
|
||||
public static final String PROP_VALUETGTCONST = "1232"; //$NON-NLS-1$
|
||||
public static final String PROP_VALUETGTCONS = "1232"; //$NON-NLS-1$
|
||||
public static final String PROP_VALUETELNET = "23"; //$NON-NLS-1$
|
||||
|
||||
String[][] fPortMap=new String[][] {
|
||||
// portName, port
|
||||
{PROP_NAMETGTCONST, PROP_VALUETGTCONST},
|
||||
{PROP_NAMETGTCONS, PROP_VALUETGTCONS},
|
||||
{PROP_NAMETELNET, PROP_VALUETELNET}
|
||||
};
|
||||
|
||||
public String getDefaultNetworkPort() {
|
||||
return PROP_VALUETELNET;
|
||||
}
|
||||
|
||||
public String findPortName(String strPort) {
|
||||
for (int i = 0; i < fPortMap.length; i++) {
|
||||
if(fPortMap[i][1].equals(strPort))
|
||||
|
@ -36,6 +38,7 @@ public class NetworkPortMap {
|
|||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
public String findPort(String strPortName) {
|
||||
for (int i = 0; i < fPortMap.length; i++) {
|
||||
if(fPortMap[i][0].equals(strPortName))
|
||||
|
@ -43,6 +46,7 @@ public class NetworkPortMap {
|
|||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
public List getNameTable() {
|
||||
List names=new ArrayList();
|
||||
for (int i = 0; i < fPortMap.length; i++) {
|
||||
|
|
|
@ -1,15 +1,17 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2006 Wind River Systems, Inc. and others.
|
||||
* Copyright (c) 2005, 2006 Wind River Systems, Inc. and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems, Inc. - initial implementation
|
||||
*
|
||||
* Fran Litterio (Wind River) - initial API and implementation
|
||||
* Helmut Haigermoser (Wind River) - repackaged
|
||||
* Ted Williams (Wind River) - repackaged into org.eclipse namespace
|
||||
* Michael Scharf (Wind River) - split into core, view and connector plugins
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.tm.terminal.internal.telnet;
|
||||
|
||||
/**
|
||||
|
|
|
@ -1,3 +1,19 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2005, 2006 Wind River Systems, Inc. and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Initial Contributors:
|
||||
* The following Wind River employees contributed to the Terminal component
|
||||
* that contains this file: Chris Thew, Fran Litterio, Stephen Lamb,
|
||||
* Helmut Haigermoser and Ted Williams.
|
||||
*
|
||||
* Contributors:
|
||||
* Michael Scharf (Wind River) - extracted from TerminalControl
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
package org.eclipse.tm.terminal.internal.telnet;
|
||||
|
||||
import java.net.ConnectException;
|
||||
|
|
|
@ -1,15 +1,17 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2006 Wind River Systems, Inc. and others.
|
||||
* Copyright (c) 2005, 2006 Wind River Systems, Inc. and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems, Inc. - initial implementation
|
||||
*
|
||||
* Fran Litterio (Wind River) - initial API and implementation
|
||||
* Helmut Haigermoser (Wind River) - repackaged
|
||||
* Ted Williams (Wind River) - repackaged into org.eclipse namespace
|
||||
* Michael Scharf (Wind River) - split into core, view and connector plugins
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.tm.terminal.internal.telnet;
|
||||
|
||||
import java.io.IOException;
|
||||
|
|
|
@ -1,6 +1,14 @@
|
|||
/**
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2006 Wind River Systems, Inc. and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
*/
|
||||
* Contributors:
|
||||
* Michael Scharf (Wind River) - initial API and implementation
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
package org.eclipse.tm.terminal.internal.telnet;
|
||||
|
||||
import java.io.IOException;
|
||||
|
|
|
@ -6,10 +6,9 @@
|
|||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems, Inc. - initial implementation
|
||||
*
|
||||
* Michael Scharf (Wind River) - initial API and implementation
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.tm.terminal.internal.telnet;
|
||||
|
||||
import org.eclipse.osgi.util.NLS;
|
||||
|
|
|
@ -1,13 +1,18 @@
|
|||
###############################################################################
|
||||
# Copyright (c) 2006 Wind River Systems, Inc. and others.
|
||||
# Copyright (c) 2005, 2006 Wind River Systems, Inc. and others.
|
||||
# All rights reserved. This program and the accompanying materials
|
||||
# are made available under the terms of the Eclipse Public License v1.0
|
||||
# which accompanies this distribution, and is available at
|
||||
# http://www.eclipse.org/legal/epl-v10.html
|
||||
#
|
||||
# Contributors:
|
||||
# Wind River Systems, Inc. - initial implementation
|
||||
# Initial Contributors:
|
||||
# The following Wind River employees contributed to the Terminal component
|
||||
# that contains this file: Chris Thew, Fran Litterio, Stephen Lamb,
|
||||
# Helmut Haigermoser and Ted Williams.
|
||||
#
|
||||
# Contributors:
|
||||
# Michael Scharf (Wind River) - split into core, view and connector plugins
|
||||
# Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
###############################################################################
|
||||
CONNTYPE_NETWORK = Network
|
||||
PORT = Port
|
||||
|
|
|
@ -1,16 +1,17 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2006 Wind River Systems, Inc. and others.
|
||||
* Copyright (c) 2005, 2006 Wind River Systems, Inc. and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems, Inc. - initial implementation
|
||||
*
|
||||
* Fran Litterio (Wind River) - initial API and implementation
|
||||
* Helmut Haigermoser (Wind River) - repackaged
|
||||
* Ted Williams (Wind River) - repackaged into org.eclipse namespace
|
||||
* Michael Scharf (Wind River) - split into core, view and connector plugins
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
|
||||
|
||||
package org.eclipse.tm.terminal.internal.telnet;
|
||||
|
||||
import java.io.IOException;
|
||||
|
|
|
@ -6,14 +6,11 @@
|
|||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems, Inc. - initial implementation
|
||||
*
|
||||
* Michael Scharf (Wind River) - initial API and implementation
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.tm.terminal.internal.telnet;
|
||||
|
||||
|
||||
|
||||
public class TelnetProperties {
|
||||
private final NetworkPortMap fNetworkPortMap;
|
||||
private final String fDefaultHost;
|
||||
|
@ -23,7 +20,6 @@ public class TelnetProperties {
|
|||
fNetworkPortMap = new NetworkPortMap();
|
||||
fDefaultNetworkPort = fNetworkPortMap.getDefaultNetworkPort();
|
||||
fDefaultHost = ""; //$NON-NLS-1$
|
||||
|
||||
}
|
||||
|
||||
public String getDefaultHost() {
|
||||
|
|
|
@ -6,10 +6,9 @@
|
|||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems, Inc. - initial implementation
|
||||
*
|
||||
* Michael Scharf (Wind River) - initial API and implementation
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.tm.terminal.internal.telnet;
|
||||
|
||||
import org.eclipse.tm.terminal.ISettingsStore;
|
||||
|
@ -56,14 +55,12 @@ public class TelnetSettings implements ITelnetSettings {
|
|||
fTimeout = store.get("Timeout","10");//$NON-NLS-1$ //$NON-NLS-2$
|
||||
}
|
||||
|
||||
|
||||
public void save(ISettingsStore store) {
|
||||
store.put("Host", fHost);//$NON-NLS-1$
|
||||
store.put("NetworkPort", fNetworkPort);//$NON-NLS-1$
|
||||
store.put("Timeout", fTimeout);//$NON-NLS-1$
|
||||
}
|
||||
|
||||
|
||||
public TelnetProperties getProperties() {
|
||||
return fProperties;
|
||||
}
|
||||
|
|
|
@ -1,15 +1,19 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2006 Wind River Systems, Inc. and others.
|
||||
* Copyright (c) 2005, 2006 Wind River Systems, Inc. and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems, Inc. - initial implementation
|
||||
* Initial Contributors:
|
||||
* The following Wind River employees contributed to the Terminal component
|
||||
* that contains this file: Chris Thew, Fran Litterio, Stephen Lamb,
|
||||
* Helmut Haigermoser and Ted Williams.
|
||||
*
|
||||
* Contributors:
|
||||
* Michael Scharf (Wind River) - refactored out of TerminalSettingsDlg
|
||||
* Martin Oberhuber (Wind River) - fixed copyright headers and beautified
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.tm.terminal.internal.telnet;
|
||||
|
||||
import java.util.Collections;
|
||||
|
|
Loading…
Add table
Reference in a new issue