Skip to content
This repository was archived by the owner on Feb 4, 2022. It is now read-only.

Commit 3786d3d

Browse files
committed
Refactor + organize import of the whole project using Eclipse + IJ Eclipse preferences
1 parent 32180b3 commit 3786d3d

71 files changed

Lines changed: 2472 additions & 2513 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

src/main/java/ij/notebook/converter/ImagePlusToPNGNotebookConverter.java

Lines changed: 17 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -36,26 +36,24 @@
3636
* @author Alison Walter
3737
*/
3838
@Plugin(type = Converter.class)
39-
public class ImagePlusToPNGNotebookConverter extends
40-
NotebookOutputConverter<ImagePlus, PNGImageNotebookOutput>
41-
{
42-
@Parameter
43-
private LogService log;
39+
public class ImagePlusToPNGNotebookConverter extends NotebookOutputConverter<ImagePlus, PNGImageNotebookOutput> {
40+
@Parameter
41+
private LogService log;
4442

45-
@Override
46-
public Class<ImagePlus> getInputType() {
47-
return ImagePlus.class;
48-
}
43+
@Override
44+
public Class<ImagePlus> getInputType() {
45+
return ImagePlus.class;
46+
}
4947

50-
@Override
51-
public Class<PNGImageNotebookOutput> getOutputType() {
52-
return PNGImageNotebookOutput.class;
53-
}
48+
@Override
49+
public Class<PNGImageNotebookOutput> getOutputType() {
50+
return PNGImageNotebookOutput.class;
51+
}
5452

55-
@Override
56-
public PNGImageNotebookOutput convert(final Object object) {
57-
final ImagePlus imgPlus = (ImagePlus) object;
58-
final String base64Image = NotebookConverters.toPNG(imgPlus.getBufferedImage());
59-
return new PNGImageNotebookOutput(base64Image);
60-
}
53+
@Override
54+
public PNGImageNotebookOutput convert(final Object object) {
55+
final ImagePlus imgPlus = (ImagePlus) object;
56+
final String base64Image = NotebookConverters.toPNG(imgPlus.getBufferedImage());
57+
return new PNGImageNotebookOutput(base64Image);
58+
}
6159
}

src/main/java/ij/notebook/converter/ResultsTableToHTMLTableNotebookConverter.java

Lines changed: 21 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -37,27 +37,26 @@
3737
* @author Alison Walter
3838
*/
3939
@Plugin(type = Converter.class)
40-
public class ResultsTableToHTMLTableNotebookConverter extends
41-
HTMLNotebookOutputConverter<ResultsTable, HTMLTableNotebookOutput>
42-
{
43-
44-
@Parameter
45-
private ConvertService convertService;
46-
47-
@Override
48-
public Class<HTMLTableNotebookOutput> getOutputType() {
49-
return HTMLTableNotebookOutput.class;
50-
}
51-
52-
@Override
53-
public Class<ResultsTable> getInputType() {
54-
return ResultsTable.class;
55-
}
56-
57-
@Override
58-
public HTMLTableNotebookOutput convert(final Object object) {
59-
GenericTable t = convertService.convert((ResultsTable)object, GenericTable.class);
60-
return convertService.convert(t, HTMLTableNotebookOutput.class);
61-
}
40+
public class ResultsTableToHTMLTableNotebookConverter
41+
extends HTMLNotebookOutputConverter<ResultsTable, HTMLTableNotebookOutput> {
42+
43+
@Parameter
44+
private ConvertService convertService;
45+
46+
@Override
47+
public Class<HTMLTableNotebookOutput> getOutputType() {
48+
return HTMLTableNotebookOutput.class;
49+
}
50+
51+
@Override
52+
public Class<ResultsTable> getInputType() {
53+
return ResultsTable.class;
54+
}
55+
56+
@Override
57+
public HTMLTableNotebookOutput convert(final Object object) {
58+
GenericTable t = convertService.convert((ResultsTable) object, GenericTable.class);
59+
return convertService.convert(t, HTMLTableNotebookOutput.class);
60+
}
6261

6362
}

0 commit comments

Comments
 (0)