Commit dac877c4 authored by Robert Smith's avatar Robert Smith
Browse files

Add test for PlotEditor

Adds a SWTBot test case for the plot editor.
parent ce132dd3
...@@ -1375,7 +1375,7 @@ public class MeshAppState extends ViewAppState implements ...@@ -1375,7 +1375,7 @@ public class MeshAppState extends ViewAppState implements
vSize = vertexSize; vSize = vertexSize;
vertexSize = (distance < 10f ? 0.0159f * distance + 0.0413f vertexSize = (distance < 10f ? 0.0159f * distance + 0.0413f
: 0.2f); : 0.2f);
if (vSize != vertexSize) { if (Math.abs(vSize - vertexSize) > 0.001f) {
updateVertices = true; updateVertices = true;
vSize = vertexSize; vSize = vertexSize;
} }
...@@ -1385,7 +1385,7 @@ public class MeshAppState extends ViewAppState implements ...@@ -1385,7 +1385,7 @@ public class MeshAppState extends ViewAppState implements
// changed. // changed.
eSize = edgeSize; eSize = edgeSize;
edgeSize = (distance < 10f ? 0.1f * distance + 4f : 5f); edgeSize = (distance < 10f ? 0.1f * distance + 4f : 5f);
if (eSize != edgeSize) { if (Math.abs(eSize - edgeSize) > 0.001f) {
updateEdges = true; updateEdges = true;
eSize = edgeSize; eSize = edgeSize;
} }
......
...@@ -66,7 +66,7 @@ public class ToolItemMenuListener implements Listener { ...@@ -66,7 +66,7 @@ public class ToolItemMenuListener implements Listener {
// event.detail == SWT.ARROW means the arrow has been clicked. // event.detail == SWT.ARROW means the arrow has been clicked.
// event.detail == SWT.NONE means the button has been clicked. // event.detail == SWT.NONE means the button has been clicked.
if (event.detail == SWT.ARROW | event.detail == SWT.NONE) { if (event.detail == SWT.ARROW || event.detail == SWT.NONE) {
Rectangle r = toolItem.getBounds(); Rectangle r = toolItem.getBounds();
Point p = new Point(r.x, r.y + r.height); Point p = new Point(r.x, r.y + r.height);
p = toolItem.getParent().toDisplay(p.x, p.y); p = toolItem.getParent().toDisplay(p.x, p.y);
......
...@@ -67,7 +67,7 @@ public class CoreConnectDialog extends Dialog { ...@@ -67,7 +67,7 @@ public class CoreConnectDialog extends Dialog {
portLabel.setText("Port: "); portLabel.setText("Port: ");
// Create a new text box to input port // Create a new text box to input port
portField = new Text(comp, SWT.SINGLE | SWT.SINGLE); portField = new Text(comp, SWT.SINGLE);
data = new GridData(GridData.FILL_HORIZONTAL); data = new GridData(GridData.FILL_HORIZONTAL);
portField.setLayoutData(data); portField.setLayoutData(data);
......
...@@ -111,7 +111,7 @@ public class NewItemWizard extends Wizard implements INewWizard { ...@@ -111,7 +111,7 @@ public class NewItemWizard extends Wizard implements INewWizard {
String selectedItem = page.getSelectedItem(); String selectedItem = page.getSelectedItem();
// Direct the client to create a new Item if a selection was made // Direct the client to create a new Item if a selection was made
if (selectedItem != null && selectedItem != null) { if (selectedItem != null) {
finished = client.createItem(selectedItem) > 0; finished = client.createItem(selectedItem) > 0;
} }
......
...@@ -169,10 +169,10 @@ public class NekWriter implements IComponentVisitor { ...@@ -169,10 +169,10 @@ public class NekWriter implements IComponentVisitor {
hostname = InetAddress.getLocalHost().getHostName(); hostname = InetAddress.getLocalHost().getHostName();
String iceHeader = String.format( String iceHeader = String.format(
"C *** Nek5000 reafile generated by ICE ***\n" "C *** Nek5000 reafile generated by ICE ***%n"
+ "C (Eclipse Integrated Computational Environment)\n" + "C (Eclipse Integrated Computational Environment)%n"
+ "C\n" + "C Created: %-30s\n" + "C%n" + "C Created: %-30s%n"
+ "C User: %-30s\n" + "C Hostname: %-30s", + "C User: %-30s%n" + "C Hostname: %-30s",
date, user, hostname); date, user, hostname);
// Write to the output stream // Write to the output stream
...@@ -204,10 +204,10 @@ public class NekWriter implements IComponentVisitor { ...@@ -204,10 +204,10 @@ public class NekWriter implements IComponentVisitor {
String currLine; String currLine;
// Construct the header // Construct the header
String paramHeader = String.format(" ****** PARAMETERS *****\n" String paramHeader = String.format(" ****** PARAMETERS *****%n"
+ " %9s NEKTON VERSION\n" + " %9s NEKTON VERSION%n"
+ " %d DIMENSIONAL RUN\n" + " %d DIMENSIONAL RUN%n"
+ " %3d PARAMETERS FOLLOW\n", + " %3d PARAMETERS FOLLOW%n",
properties.getNekVersion(), properties.getNumDimensions(), properties.getNekVersion(), properties.getNumDimensions(),
numEntries); numEntries);
...@@ -223,7 +223,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -223,7 +223,7 @@ public class NekWriter implements IComponentVisitor {
currName = currEntry.getName(); currName = currEntry.getName();
currDesc = currEntry.getDescription(); currDesc = currEntry.getDescription();
currValue = currEntry.getValue(); currValue = currEntry.getValue();
currLine = String.format(" %-14s %s %s\n", currValue, currLine = String.format(" %-14s %s %s%n", currValue,
currName, currDesc); currName, currDesc);
// Write to the output stream // Write to the output stream
...@@ -256,7 +256,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -256,7 +256,7 @@ public class NekWriter implements IComponentVisitor {
// Construct the header // Construct the header
String passiveScalarsHeader = String.format( String passiveScalarsHeader = String.format(
" %3s Lines of passive scalar data follows" " %3s Lines of passive scalar data follows"
+ "2 CONDUCT; 2RHOCP\n", numEntries); + "2 CONDUCT; 2RHOCP%n", numEntries);
// Write the passive scalars header // Write the passive scalars header
byte[] byteArray = passiveScalarsHeader.getBytes(); byte[] byteArray = passiveScalarsHeader.getBytes();
...@@ -268,7 +268,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -268,7 +268,7 @@ public class NekWriter implements IComponentVisitor {
// Define the current passive scalar line // Define the current passive scalar line
currEntry = passiveScalars.retrieveAllEntries().get(i); currEntry = passiveScalars.retrieveAllEntries().get(i);
currValue = currEntry.getValue(); currValue = currEntry.getValue();
currLine = String.format(" %-10s\n", currValue); currLine = String.format(" %-10s%n", currValue);
// Write to the output stream // Write to the output stream
byteArray = currLine.getBytes(); byteArray = currLine.getBytes();
...@@ -301,7 +301,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -301,7 +301,7 @@ public class NekWriter implements IComponentVisitor {
// Construct the header // Construct the header
String switchesHeader = String.format( String switchesHeader = String.format(
" %3s LOGICAL SWITCHES FOLLOW\n", numEntries); " %3s LOGICAL SWITCHES FOLLOW%n", numEntries);
// Write the logical switches header // Write the logical switches header
byte[] byteArray = switchesHeader.getBytes(); byte[] byteArray = switchesHeader.getBytes();
...@@ -318,7 +318,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -318,7 +318,7 @@ public class NekWriter implements IComponentVisitor {
// Construct the current line // Construct the current line
if (currName.contains("IFNAV") && currName.contains("IFADVC")) { if (currName.contains("IFNAV") && currName.contains("IFADVC")) {
currLine = String.format(" %s IFNAV & IFADVC %s\n", // This currLine = String.format(" %s IFNAV & IFADVC %s%n", // This
// entry's // entry's
// name // name
// has // has
...@@ -329,10 +329,10 @@ public class NekWriter implements IComponentVisitor { ...@@ -329,10 +329,10 @@ public class NekWriter implements IComponentVisitor {
// just write the // just write the
} // name out here } // name out here
else if (currName.contains("IFTMSH")) { else if (currName.contains("IFTMSH")) {
currLine = String.format(" %s %s %s\n", currValue, currName, currLine = String.format(" %s %s %s%n", currValue, currName,
currDesc); currDesc);
} else { } else {
currLine = String.format(" %s %s\n", currValue, currName); currLine = String.format(" %s %s%n", currValue, currName);
} }
// Write to the output stream // Write to the output stream
byteArray = currLine.getBytes(); byteArray = currLine.getBytes();
...@@ -368,7 +368,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -368,7 +368,7 @@ public class NekWriter implements IComponentVisitor {
currEntry = preNekAxes.retrieveAllEntries().get(i); currEntry = preNekAxes.retrieveAllEntries().get(i);
currValue = currEntry.getValue(); currValue = currEntry.getValue();
currName = currEntry.getName(); currName = currEntry.getName();
currLine = String.format(" %s %s\n", currValue, currName); currLine = String.format(" %s %s%n", currValue, currName);
// Write to the output stream // Write to the output stream
byteArray = currLine.getBytes(); byteArray = currLine.getBytes();
...@@ -423,7 +423,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -423,7 +423,7 @@ public class NekWriter implements IComponentVisitor {
currQuad = (Quad) mesh.getPolygons().get(i); currQuad = (Quad) mesh.getPolygons().get(i);
currValue = String.format(" ELEMENT%6s [ %4s]" // FORMAT: currValue = String.format(" ELEMENT%6s [ %4s]" // FORMAT:
// 18X,I6,4X,I3,A1,11x,i5 // 18X,I6,4X,I3,A1,11x,i5
+ " GROUP %5s\n", (i + 1), currQuad + " GROUP %5s%n", (i + 1), currQuad
.getPolygonProperties().getMaterialId(), currQuad .getPolygonProperties().getMaterialId(), currQuad
.getPolygonProperties().getGroupNum()); .getPolygonProperties().getGroupNum());
...@@ -467,7 +467,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -467,7 +467,7 @@ public class NekWriter implements IComponentVisitor {
// Construct the proper string format // Construct the proper string format
currValue = String.format( currValue = String.format(
" %-3s%3d%3d%14.7G%14.7G%14.7G%14.7G%14.7G\n", " %-3s%3d%3d%14.7G%14.7G%14.7G%14.7G%14.7G%n",
currBC.getType().id, (i + 1), (j + 1), currBC.getType().id, (i + 1), (j + 1),
currBCValues.get(0), currBCValues.get(1), currBCValues.get(0), currBCValues.get(1),
currBCValues.get(2), currBCValues.get(3), currBCValues.get(2), currBCValues.get(3),
...@@ -490,7 +490,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -490,7 +490,7 @@ public class NekWriter implements IComponentVisitor {
// Construct the proper string format // Construct the proper string format
currValue = String.format( currValue = String.format(
" %-3s%3d%3d%14.7G%14.7G%14.7G%14.7G%14.7G\n", " %-3s%3d%3d%14.7G%14.7G%14.7G%14.7G%14.7G%n",
currBC.getType().id, (i + 1), (j + 1), currBC.getType().id, (i + 1), (j + 1),
currBCValues.get(0), currBCValues.get(1), currBCValues.get(0), currBCValues.get(1),
currBCValues.get(2), currBCValues.get(3), currBCValues.get(2), currBCValues.get(3),
...@@ -524,7 +524,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -524,7 +524,7 @@ public class NekWriter implements IComponentVisitor {
// Construct the proper string format // Construct the proper string format
currValue = String currValue = String
.format(" %-3s%3d%3d%14.7G%14.7G%14.7G%14.7G%14.7G\n", .format(" %-3s%3d%3d%14.7G%14.7G%14.7G%14.7G%14.7G%n",
currBC.getType().id, (i + 1), currBC.getType().id, (i + 1),
(j + 1), currBCValues.get(0), (j + 1), currBCValues.get(0),
currBCValues.get(1), currBCValues.get(1),
...@@ -542,8 +542,8 @@ public class NekWriter implements IComponentVisitor { ...@@ -542,8 +542,8 @@ public class NekWriter implements IComponentVisitor {
} }
// Write the coordinates to the buffer // Write the coordinates to the buffer
currValue = String.format(" %9.6G %9.6G %9.6G %9.6G\n" currValue = String.format(" %9.6G %9.6G %9.6G %9.6G%n"
+ " %9.6G %9.6G %9.6G %9.6G\n", xCoords.get(0), + " %9.6G %9.6G %9.6G %9.6G%n", xCoords.get(0),
xCoords.get(1), xCoords.get(2), xCoords.get(3), xCoords.get(1), xCoords.get(2), xCoords.get(3),
yCoords.get(0), yCoords.get(1), yCoords.get(2), yCoords.get(0), yCoords.get(1), yCoords.get(2),
yCoords.get(3)); yCoords.get(3));
...@@ -565,8 +565,8 @@ public class NekWriter implements IComponentVisitor { ...@@ -565,8 +565,8 @@ public class NekWriter implements IComponentVisitor {
// Construct the header // Construct the header
String meshHeader = String String meshHeader = String
.format(" *** MESH DATA ***\n" .format(" *** MESH DATA ***%n"
+ " %3d %3d %3d NEL,NDIM,NELV\n", + " %3d %3d %3d NEL,NDIM,NELV%n",
properties.getNumThermalElements(), properties.getNumThermalElements(),
properties.getNumDimensions(), properties.getNumDimensions(),
properties.getNumFluidElements()); properties.getNumFluidElements());
...@@ -605,9 +605,9 @@ public class NekWriter implements IComponentVisitor { ...@@ -605,9 +605,9 @@ public class NekWriter implements IComponentVisitor {
// Construct the header // Construct the header
String curvedSidesHeader = String.format( String curvedSidesHeader = String.format(
" ***** CURVED SIDE DATA *****\n" " ***** CURVED SIDE DATA *****%n"
+ " %3s Curved sides follow " + " %3s Curved sides follow "
+ "IEDGE,IEL,CURVE(I),I=1,5, CCURVE\n", numEntries); + "IEDGE,IEL,CURVE(I),I=1,5, CCURVE%n", numEntries);
// Write the curved sides header // Write the curved sides header
byte[] byteArray = curvedSidesHeader.getBytes(); byte[] byteArray = curvedSidesHeader.getBytes();
...@@ -642,7 +642,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -642,7 +642,7 @@ public class NekWriter implements IComponentVisitor {
ArrayList<ArrayList<String>> passiveScalarBCs) throws IOException { ArrayList<ArrayList<String>> passiveScalarBCs) throws IOException {
// Construct the header // Construct the header
String boundaryConditionHeader = " ***** BOUNDARY CONDITIONS *****\n"; String boundaryConditionHeader = " ***** BOUNDARY CONDITIONS *****%n";
// Write the boundary conditions header // Write the boundary conditions header
byte[] byteArray = boundaryConditionHeader.getBytes(); byte[] byteArray = boundaryConditionHeader.getBytes();
...@@ -651,7 +651,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -651,7 +651,7 @@ public class NekWriter implements IComponentVisitor {
// Check that there are fluid boundary conditions // Check that there are fluid boundary conditions
if (!fluidBCs.isEmpty()) { if (!fluidBCs.isEmpty()) {
// Write the fluid boundary conditions header // Write the fluid boundary conditions header
String fluidHeader = " ***** FLUID BOUNDARY CONDITIONS *****\n"; String fluidHeader = " ***** FLUID BOUNDARY CONDITIONS *****%n";
byteArray = fluidHeader.getBytes(); byteArray = fluidHeader.getBytes();
stream.write(byteArray); stream.write(byteArray);
...@@ -661,7 +661,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -661,7 +661,7 @@ public class NekWriter implements IComponentVisitor {
stream.write(byteArray); stream.write(byteArray);
} }
} else { } else {
String noFluidHeader = " ***** NO FLUID BOUNDARY CONDITIONS *****\n"; String noFluidHeader = " ***** NO FLUID BOUNDARY CONDITIONS *****%n";
byteArray = noFluidHeader.getBytes(); byteArray = noFluidHeader.getBytes();
stream.write(byteArray); stream.write(byteArray);
} }
...@@ -669,7 +669,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -669,7 +669,7 @@ public class NekWriter implements IComponentVisitor {
// Check that there are thermal boundary conditions // Check that there are thermal boundary conditions
if (!thermalBCs.isEmpty()) { if (!thermalBCs.isEmpty()) {
// Write the thermal boundary conditions header // Write the thermal boundary conditions header
String thermalHeader = " ***** THERMAL BOUNDARY CONDITIONS *****\n"; String thermalHeader = " ***** THERMAL BOUNDARY CONDITIONS *****%n";
byteArray = thermalHeader.getBytes(); byteArray = thermalHeader.getBytes();
stream.write(byteArray); stream.write(byteArray);
...@@ -679,7 +679,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -679,7 +679,7 @@ public class NekWriter implements IComponentVisitor {
stream.write(byteArray); stream.write(byteArray);
} }
} else { } else {
String noThermalHeader = " ***** NO THERMAL BOUNDARY CONDITIONS *****\n"; String noThermalHeader = " ***** NO THERMAL BOUNDARY CONDITIONS *****%n";
byteArray = noThermalHeader.getBytes(); byteArray = noThermalHeader.getBytes();
stream.write(byteArray); stream.write(byteArray);
} }
...@@ -697,7 +697,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -697,7 +697,7 @@ public class NekWriter implements IComponentVisitor {
// Write the passive scalar boundary conditions header // Write the passive scalar boundary conditions header
String passiveScalarHeader = String String passiveScalarHeader = String
.format(" ***** PASSIVE SCALAR %3s BOUNDARY CONDITIONS *****\n", .format(" ***** PASSIVE SCALAR %3s BOUNDARY CONDITIONS *****%n",
(i + 1)); (i + 1));
byteArray = passiveScalarHeader.getBytes(); byteArray = passiveScalarHeader.getBytes();
stream.write(byteArray); stream.write(byteArray);
...@@ -736,7 +736,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -736,7 +736,7 @@ public class NekWriter implements IComponentVisitor {
// Construct the header // Construct the header
String presolveRestartOptsHeader = String.format( String presolveRestartOptsHeader = String.format(
"%3s PRESOLVE/RESTART OPTIONS *****\n", numEntries); "%3s PRESOLVE/RESTART OPTIONS *****%n", numEntries);
// Write the presolve/restart options header // Write the presolve/restart options header
byte[] byteArray = presolveRestartOptsHeader.getBytes(); byte[] byteArray = presolveRestartOptsHeader.getBytes();
...@@ -746,7 +746,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -746,7 +746,7 @@ public class NekWriter implements IComponentVisitor {
// Define the current pre-solve/restart option // Define the current pre-solve/restart option
currEntry = presolveRestartOpts.retrieveAllEntries().get(i); currEntry = presolveRestartOpts.retrieveAllEntries().get(i);
currValue = currEntry.getValue() + "\n"; currValue = currEntry.getValue() + "%n";
// Write to the output stream // Write to the output stream
byteArray = currValue.getBytes(); byteArray = currValue.getBytes();
...@@ -776,7 +776,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -776,7 +776,7 @@ public class NekWriter implements IComponentVisitor {
// Construct the header // Construct the header
String initialConditionsHeader = String.format( String initialConditionsHeader = String.format(
"%3s INITIAL CONDITIONS *****\n", numEntries); "%3s INITIAL CONDITIONS *****%n", numEntries);
// Write the initial conditions header // Write the initial conditions header
byte[] byteArray = initialConditionsHeader.getBytes(); byte[] byteArray = initialConditionsHeader.getBytes();
...@@ -786,7 +786,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -786,7 +786,7 @@ public class NekWriter implements IComponentVisitor {
// Define the current initial condition // Define the current initial condition
currEntry = initialConditions.retrieveAllEntries().get(i); currEntry = initialConditions.retrieveAllEntries().get(i);
currValue = currEntry.getValue() + "\n"; currValue = currEntry.getValue() + "%n";
// Write to the output stream // Write to the output stream
byteArray = currValue.getBytes(); byteArray = currValue.getBytes();
...@@ -817,8 +817,8 @@ public class NekWriter implements IComponentVisitor { ...@@ -817,8 +817,8 @@ public class NekWriter implements IComponentVisitor {
// Construct the header // Construct the header
String driveForceDataHeader = String String driveForceDataHeader = String
.format(" ***** DRIVE FORCE DATA ***** BODY FORCE, FLOW, Q\n" .format(" ***** DRIVE FORCE DATA ***** BODY FORCE, FLOW, Q%n"
+ " %3s Lines of Drive force data follow\n", + " %3s Lines of Drive force data follow%n",
numEntries); numEntries);
// Write the drive force data header // Write the drive force data header
...@@ -829,7 +829,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -829,7 +829,7 @@ public class NekWriter implements IComponentVisitor {
// Define the current drive force datum // Define the current drive force datum
currEntry = driveForceData.retrieveAllEntries().get(i); currEntry = driveForceData.retrieveAllEntries().get(i);
currValue = currEntry.getValue() + "\n"; currValue = currEntry.getValue() + "%n";
// Write to the output stream // Write to the output stream
byteArray = currValue.getBytes(); byteArray = currValue.getBytes();
...@@ -859,8 +859,8 @@ public class NekWriter implements IComponentVisitor { ...@@ -859,8 +859,8 @@ public class NekWriter implements IComponentVisitor {
// Construct the header // Construct the header
String varPropertyDataHeader = String.format( String varPropertyDataHeader = String.format(
" ***** Variable Property Data ***** Overrrides Parameter data.\n" " ***** Variable Property Data ***** Overrrides Parameter data.%n"
+ "%3s Lines follow.\n", numEntries); + "%3s Lines follow.%n", numEntries);
// Write the variable property data header // Write the variable property data header
byte[] byteArray = varPropertyDataHeader.getBytes(); byte[] byteArray = varPropertyDataHeader.getBytes();
...@@ -870,7 +870,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -870,7 +870,7 @@ public class NekWriter implements IComponentVisitor {
// Define the current variable property datum // Define the current variable property datum
currEntry = varPropertyData.retrieveAllEntries().get(i); currEntry = varPropertyData.retrieveAllEntries().get(i);
currValue = currEntry.getValue() + "\n"; currValue = currEntry.getValue() + "%n";
// Write to the output stream // Write to the output stream
byteArray = currValue.getBytes(); byteArray = currValue.getBytes();
...@@ -901,8 +901,8 @@ public class NekWriter implements IComponentVisitor { ...@@ -901,8 +901,8 @@ public class NekWriter implements IComponentVisitor {
// Construct the header // Construct the header
String historyIntegralDataHeader = String.format( String historyIntegralDataHeader = String.format(
" ***** HISTORY AND INTEGRAL DATA *****\n" " ***** HISTORY AND INTEGRAL DATA *****%n"
+ " %3s POINTS. Hcode, I,J,H,IEL\n", + " %3s POINTS. Hcode, I,J,H,IEL%n",
numEntries); numEntries);
// Write the history and integral data header // Write the history and integral data header
...@@ -913,7 +913,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -913,7 +913,7 @@ public class NekWriter implements IComponentVisitor {
// Define the current history and integral datum // Define the current history and integral datum
currEntry = historyIntegralData.retrieveAllEntries().get(i); currEntry = historyIntegralData.retrieveAllEntries().get(i);
currValue = currEntry.getValue() + "\n"; currValue = currEntry.getValue() + "%n";
// Write to the output stream // Write to the output stream
byteArray = currValue.getBytes(); byteArray = currValue.getBytes();
...@@ -946,8 +946,8 @@ public class NekWriter implements IComponentVisitor { ...@@ -946,8 +946,8 @@ public class NekWriter implements IComponentVisitor {
// Construct the header // Construct the header
String outputFieldSpecHeader = String.format( String outputFieldSpecHeader = String.format(
" ***** OUTPUT FIELD SPECIFICATION *****\n" " ***** OUTPUT FIELD SPECIFICATION *****%n"
+ " %3s SPECIFICATIONS FOLLOW\n", numEntries); + " %3s SPECIFICATIONS FOLLOW%n", numEntries);
// Write the output field specification header // Write the output field specification header
byte[] byteArray = outputFieldSpecHeader.getBytes(); byte[] byteArray = outputFieldSpecHeader.getBytes();
...@@ -960,7 +960,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -960,7 +960,7 @@ public class NekWriter implements IComponentVisitor {
currName = currEntry.getName(); currName = currEntry.getName();
currValue = ("YES".equals(currEntry.getValue()) ? "T" : ("NO" currValue = ("YES".equals(currEntry.getValue()) ? "T" : ("NO"
.equals(currEntry.getValue()) ? "F" : currEntry.getValue())); .equals(currEntry.getValue()) ? "F" : currEntry.getValue()));
currLine = String.format(" %s %s\n", currValue, currName); currLine = String.format(" %s %s%n", currValue, currName);
// Write to the output stream // Write to the output stream
byteArray = currLine.getBytes(); byteArray = currLine.getBytes();
...@@ -992,7 +992,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -992,7 +992,7 @@ public class NekWriter implements IComponentVisitor {
String currLine; String currLine;
// Construct the header // Construct the header
String objectSpecHeader = " ***** OBJECT SPECIFICATION *****\n"; String objectSpecHeader = " ***** OBJECT SPECIFICATION *****%n";
// Write the object specification header // Write the object specification header
byte[] byteArray = objectSpecHeader.getBytes(); byte[] byteArray = objectSpecHeader.getBytes();
...@@ -1004,7 +1004,7 @@ public class NekWriter implements IComponentVisitor { ...@@ -1004,7 +1004,7 @@ public class NekWriter implements IComponentVisitor {
currEntry = objectSpec.retrieveAllEntries().get(i); currEntry = objectSpec.retrieveAllEntries().get(i);
currValue = currEntry.getValue(); currValue = currEntry.getValue();
currName = currEntry.getName(); currName = currEntry.getName();