1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-07-13 03:55:22 +02:00

[cleanup] Avoid Javadoc param tag on separate line

This commit is contained in:
Martin Oberhuber 2008-03-16 20:18:30 +00:00
parent 3ea93ca975
commit dd3b95b989
3 changed files with 265 additions and 275 deletions

View file

@ -66,7 +66,7 @@
<documentation>
Allows specifying semicolon separated multicast addresses to be used with specific transports in the format &lt;transport&gt;:&lt;address&gt;
An example would be:
&lt;code&gt;&quot;transportName1:address1;transportName2:address2;UDP:224.0.0.251&quot;&lt;code/&gt;
&lt;code&gt;&quot;transportName1:address1;transportName2:address2;UDP:224.0.0.251&quot;&lt;/code&gt;
</documentation>
</annotation>
</attribute>

View file

@ -29,19 +29,19 @@ public interface IProtocol {
/**
* Instantiates a Job to populate a model given an initial query, a resource containing the model to be populated and an ITranport implementation.
* Instantiates a Job to populate a model given an initial query, a resource
* containing the model to be populated and an ITranport implementation.
*
* @param query
* Initial query to be sent to the target. This initial query can be obtained from the getQueries() method.
* @param query Initial query to be sent to the target. This initial query
* can be obtained from the getQueries() method.
*
* @param resource
* Resource containing the model to be populated with the results of the service discovery action.
* @param resource Resource containing the model to be populated with the
* results of the service discovery action.
*
* @param transport
* ITransport implementation of the transport to be used for the discovery action.
* @param transport ITransport implementation of the transport to be used
* for the discovery action.
*
* @return
* Job containing the service discovery action.
* @return Job containing the service discovery action.
*
* @see Job
* @see Resource

View file

@ -124,18 +124,14 @@ public class ServiceDiscoveryWizardDisplayPage extends WizardPage {
private Hashtable supportedServicesType = new Hashtable();
/**
* Constructor for the wizard page performing and displayin the results of the service discovery
* Constructor for the wizard page performing and displayin the results of
* the service discovery
*
* @param query
* Query for the service discovery action
* @param address
* Address of the target device
* @param transportName
* Name of the transport implementation to be used
* @param protocolName
* Name of the protocol implementation to be used
* @param timeOut
* Timeout to be used in the transport
* @param query Query for the service discovery action
* @param address Address of the target device
* @param transportName Name of the transport implementation to be used
* @param protocolName Name of the protocol implementation to be used
* @param timeOut Timeout to be used in the transport
*/
public ServiceDiscoveryWizardDisplayPage(String query, String address, String transportName, String protocolName, int timeOut) {
@ -189,16 +185,11 @@ public class ServiceDiscoveryWizardDisplayPage extends WizardPage {
/**
* Refresh the contents of the service discovery model
*
* @param query
* Query for the service discovery action
* @param address
* Address of the target device
* @param transportName
* Name of the transport implementation to be used
* @param protocolName
* Name of the protocol implementation to be used
* @param timeOut
* Timeout to be used in the transport
* @param query Query for the service discovery action
* @param address Address of the target device
* @param transportName Name of the transport implementation to be used
* @param protocolName Name of the protocol implementation to be used
* @param timeOut Timeout to be used in the transport
*/
public void update(String query, String address, String transportName, String protocolName, int timeOut)
{
@ -253,12 +244,12 @@ public class ServiceDiscoveryWizardDisplayPage extends WizardPage {
Composite comp = new Composite(parent, SWT.NULL);
GridLayout gridLayout = new GridLayout();
gridLayout.numColumns = 1;
comp.setLayout(gridLayout);
gridLayout.numColumns = 1;
comp.setLayout(gridLayout);
//TOOLBAR
//TOOLBAR
createToolBar(comp);
createToolBar(comp);
GridData data = new GridData();
data.horizontalAlignment = GridData.FILL;
@ -382,15 +373,15 @@ public class ServiceDiscoveryWizardDisplayPage extends WizardPage {
((ContainerCheckedTreeViewer) viewerPaneTree.getViewer()).addCheckStateListener(new ICheckStateListener() {
public void checkStateChanged(CheckStateChangedEvent event) {
ContainerCheckedTreeViewer treeViewer = (ContainerCheckedTreeViewer) event.getSource();
ContainerCheckedTreeViewer treeViewer = (ContainerCheckedTreeViewer) event.getSource();
if(treeViewer.getCheckedElements().length > 0)
setPageComplete(true);
else
setPageComplete(false);
if(treeViewer.getCheckedElements().length > 0)
setPageComplete(true);
else
setPageComplete(false);
}
});
}
});
filter = new ViewerFilter(){
@ -422,27 +413,27 @@ public class ServiceDiscoveryWizardDisplayPage extends WizardPage {
Pair pair = (Pair)it.next();
if(pair.getKey().equalsIgnoreCase("transport")) //$NON-NLS-1$
{
String transport = pair.getValue();
String transport = pair.getValue();
for (int i = 0; i < transports.size(); i++) {
if(((String)transports.elementAt(i)).equalsIgnoreCase(transport))
{
//found a supported transport
supported = true;
}
for (int i = 0; i < transports.size(); i++) {
if(((String)transports.elementAt(i)).equalsIgnoreCase(transport))
{
//found a supported transport
supported = true;
}
}
}
}
}
}
return supported;
}};
((ContainerCheckedTreeViewer) viewerPaneTree.getViewer()).addFilter(filter);
((ContainerCheckedTreeViewer) viewerPaneTree.getViewer()).addFilter(filter);
}
@ -454,102 +445,102 @@ public class ServiceDiscoveryWizardDisplayPage extends WizardPage {
viewerPaneTable =
new ViewerPane(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage(),
PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage().getActivePart()) {
public Viewer createViewer(Composite composite) {
return new TableViewer(composite);
}
};
public Viewer createViewer(Composite composite) {
return new TableViewer(composite);
}
};
viewerPaneTable.createControl(comp);
tableViewer = (TableViewer)viewerPaneTable.getViewer();
viewerPaneTable.createControl(comp);
tableViewer = (TableViewer)viewerPaneTable.getViewer();
viewerPaneTable.setTitle(Messages.getString("ServiceDiscoveryWizardDisplayPage.PropertiesTableTitle"), null); //$NON-NLS-1$
viewerPaneTable.setTitle(Messages.getString("ServiceDiscoveryWizardDisplayPage.PropertiesTableTitle"), null); //$NON-NLS-1$
table = tableViewer.getTable();
table = tableViewer.getTable();
TableLayout layout = new TableLayout();
table.setLayout(layout);
TableLayout layout = new TableLayout();
table.setLayout(layout);
table.setHeaderVisible(true);
table.setLinesVisible(true);
table.setHeaderVisible(true);
table.setLinesVisible(true);
TableColumn objectColumn = new TableColumn(table, SWT.NONE);
layout.addColumnData(new ColumnWeightData(3, 100, true));
objectColumn.setText(Messages.getString("ServiceDiscoveryWizardDisplayPage.KeyColumnLabel")); //$NON-NLS-1$
objectColumn.setResizable(true);
TableColumn objectColumn = new TableColumn(table, SWT.NONE);
layout.addColumnData(new ColumnWeightData(3, 100, true));
objectColumn.setText(Messages.getString("ServiceDiscoveryWizardDisplayPage.KeyColumnLabel")); //$NON-NLS-1$
objectColumn.setResizable(true);
TableColumn selfColumn = new TableColumn(table, SWT.NONE);
layout.addColumnData(new ColumnWeightData(2, 100, true));
selfColumn.setText(Messages.getString("ServiceDiscoveryWizardDisplayPage.ValueColumnLabel")); //$NON-NLS-1$
selfColumn.setResizable(true);
TableColumn selfColumn = new TableColumn(table, SWT.NONE);
layout.addColumnData(new ColumnWeightData(2, 100, true));
selfColumn.setText(Messages.getString("ServiceDiscoveryWizardDisplayPage.ValueColumnLabel")); //$NON-NLS-1$
selfColumn.setResizable(true);
tableViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory));
tableViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory));
tableViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
tableViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
editor = new TableEditor(table);
editor.horizontalAlignment = SWT.LEFT;
editor.grabHorizontal = true;
table.addListener (SWT.MouseDown, new Listener () {
public void handleEvent (Event event) {
Rectangle clientArea = table.getClientArea ();
Point pt = new Point (event.x, event.y);
int index = table.getTopIndex ();
while (index < table.getItemCount ()) {
boolean visible = false;
final TableItem item = table.getItem (index);
for (int i=table.getColumnCount()-1; i<table.getColumnCount(); i++) {
Rectangle rect = item.getBounds (i);
if (rect.contains (pt)) {
final int column = i;
final Text text = new Text (table, SWT.NONE);
Listener textListener = new Listener () {
public void handleEvent (final Event e) {
switch (e.type) {
case SWT.FocusOut:
item.setText (column, text.getText ());
text.dispose ();
editor = new TableEditor(table);
editor.horizontalAlignment = SWT.LEFT;
editor.grabHorizontal = true;
table.addListener (SWT.MouseDown, new Listener () {
public void handleEvent (Event event) {
Rectangle clientArea = table.getClientArea ();
Point pt = new Point (event.x, event.y);
int index = table.getTopIndex ();
while (index < table.getItemCount ()) {
boolean visible = false;
final TableItem item = table.getItem (index);
for (int i=table.getColumnCount()-1; i<table.getColumnCount(); i++) {
Rectangle rect = item.getBounds (i);
if (rect.contains (pt)) {
final int column = i;
final Text text = new Text (table, SWT.NONE);
Listener textListener = new Listener () {
public void handleEvent (final Event e) {
switch (e.type) {
case SWT.FocusOut:
item.setText (column, text.getText ());
text.dispose ();
//update model when focus out
updatePairs(item.getText(0),item.getText(1));
break;
//update model when focus out
updatePairs(item.getText(0),item.getText(1));
break;
case SWT.Traverse:
switch (e.detail) {
case SWT.TRAVERSE_RETURN:
item.setText (column, text.getText ());
case SWT.Traverse:
switch (e.detail) {
case SWT.TRAVERSE_RETURN:
item.setText (column, text.getText ());
//update model when pressing return
updatePairs(item.getText(0),item.getText(1));
text.dispose ();
e.doit = false;
break;
case SWT.TRAVERSE_ESCAPE:
text.dispose ();
e.doit = false;
}
break;
}
//update model when pressing return
updatePairs(item.getText(0),item.getText(1));
text.dispose ();
e.doit = false;
break;
case SWT.TRAVERSE_ESCAPE:
text.dispose ();
e.doit = false;
}
};
text.addListener (SWT.FocusOut, textListener);
text.addListener (SWT.Traverse, textListener);
editor.setEditor (text, item, i);
text.setText (item.getText (i));
text.selectAll ();
text.setFocus ();
return;
break;
}
}
if (!visible && rect.intersects (clientArea)) {
visible = true;
}
}
if (!visible) return;
index++;
};
text.addListener (SWT.FocusOut, textListener);
text.addListener (SWT.Traverse, textListener);
editor.setEditor (text, item, i);
text.setText (item.getText (i));
text.selectAll ();
text.setFocus ();
return;
}
if (!visible && rect.intersects (clientArea)) {
visible = true;
}
}
});
if (!visible) return;
index++;
}
}
});
}
@ -567,15 +558,15 @@ public class ServiceDiscoveryWizardDisplayPage extends WizardPage {
public void widgetSelected(SelectionEvent e) {
Object src = e.getSource();
if(((Button)src).getSelection())
{
((ContainerCheckedTreeViewer) viewerPaneTree.getViewer()).removeFilter(filter);
}
else
{
((ContainerCheckedTreeViewer) viewerPaneTree.getViewer()).addFilter(filter);
}
Object src = e.getSource();
if(((Button)src).getSelection())
{
((ContainerCheckedTreeViewer) viewerPaneTree.getViewer()).removeFilter(filter);
}
else
{
((ContainerCheckedTreeViewer) viewerPaneTree.getViewer()).addFilter(filter);
}
}
});
}
@ -597,12 +588,11 @@ public class ServiceDiscoveryWizardDisplayPage extends WizardPage {
}
/**
* Get the <code>Service<code> objects selected in the tree view from the specified host
* Get the
* <code>Service<code> objects selected in the tree view from the specified host
*
* @param address
* Address of the host which services are queried
* @return
* Vector containing the <code>Service<code> selected
* @param address Address of the host which services are queried
* @return Vector containing the <code>Service<code> selected
*
* @see Service
*/
@ -651,11 +641,11 @@ public class ServiceDiscoveryWizardDisplayPage extends WizardPage {
return addresses;
}
/* (non-Javadoc)
/* (non-Javadoc)
* @see org.eclipse.jface.wizard.WizardPage#canFlipToNextPage()
*/
public boolean canFlipToNextPage() {
return false;
}
return false;
}
}