Skip to content

Commit 0a0f2fe

Browse files
committed
Source formatting
1 parent 8aa6a7a commit 0a0f2fe

File tree

8 files changed

+13
-12
lines changed

8 files changed

+13
-12
lines changed

src/main/java/net/sf/mpxj/DefaultBaselineStrategy.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ public class DefaultBaselineStrategy implements BaselineStrategy
4949
Map<Object, Task> map = baseline.getTasks().stream().filter(t -> getKeyForTask(t) != null).collect(Collectors.toMap(this::getKeyForTask, t -> t, (u, v) -> null));
5050

5151
// Create a map from the current project tasks to the baseline projects tasks
52-
Map<Task, Task> baselineTaskMap = project.getTasks().stream().filter(t-> map.get(getKeyForTask(t)) != null).collect(Collectors.toMap(t -> t, t-> map.get(getKeyForTask(t))));
52+
Map<Task, Task> baselineTaskMap = project.getTasks().stream().filter(t -> map.get(getKeyForTask(t)) != null).collect(Collectors.toMap(t -> t, t -> map.get(getKeyForTask(t))));
5353

5454
// Cache this map to support the Task.getBaselineTask() method
5555
project.setBaselineTaskMap(index, baselineTaskMap);

src/main/java/net/sf/mpxj/ProjectFile.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1038,7 +1038,7 @@ ProjectFile readExternalProject(String fileName)
10381038
private final DataLinkContainer m_dataLinks = new DataLinkContainer();
10391039
private final ExternalProjectContainer m_externalProjects = new ExternalProjectContainer(this);
10401040
private final ProjectFile[] m_baselines = new ProjectFile[11];
1041-
private final Map<Integer, Map<Task,Task>> m_baselineTaskMap = new HashMap<>();
1041+
private final Map<Integer, Map<Task, Task>> m_baselineTaskMap = new HashMap<>();
10421042
private final List<Exception> m_ignoredErrors = new ArrayList<>();
10431043
private final Map<String, ObjectSequence> m_uniqueIdObjectSequences = new HashMap<>();
10441044
private final ProjectFileSharedData m_shared;

src/main/java/net/sf/mpxj/Task.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5912,7 +5912,7 @@ private Number calculateActivityPercentComplete()
59125912
return getPercentageComplete();
59135913
}
59145914

5915-
switch(type)
5915+
switch (type)
59165916
{
59175917
case UNITS:
59185918
{

src/main/java/net/sf/mpxj/explorer/ProjectExplorer.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -475,12 +475,12 @@ private void configureReader(UniversalProjectReader.ProjectReaderProxy proxy)
475475
ProjectReader reader = proxy.getProjectReader();
476476
if (reader instanceof PrimaveraXERFileReader)
477477
{
478-
((PrimaveraXERFileReader)reader).setLinkCrossProjectRelations(m_linkCrossProjectRelations);
478+
((PrimaveraXERFileReader) reader).setLinkCrossProjectRelations(m_linkCrossProjectRelations);
479479
}
480480

481481
if (reader instanceof PrimaveraPMFileReader)
482482
{
483-
((PrimaveraPMFileReader)reader).setLinkCrossProjectRelations(m_linkCrossProjectRelations);
483+
((PrimaveraPMFileReader) reader).setLinkCrossProjectRelations(m_linkCrossProjectRelations);
484484
}
485485
}
486486

src/main/java/net/sf/mpxj/json/JsonWriter.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1440,7 +1440,7 @@ private void writeRateField(String fieldName, Object value) throws IOException
14401440
return;
14411441
}
14421442

1443-
Rate val = (Rate)value;
1443+
Rate val = (Rate) value;
14441444
if (val.getAmount() != 0.0)
14451445
{
14461446
m_writer.writeNameValuePair(fieldName, val.getAmount() + "/" + val.getUnits());

src/main/java/net/sf/mpxj/mpp/CustomFieldValueReader.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ public CustomFieldValueReader(ProjectFile file, Map<UUID, FieldType> lookupTable
6767
*/
6868
public void process()
6969
{
70-
for (int loop=0; loop < m_outlineCodeFixedData.getItemCount(); loop++)
70+
for (int loop = 0; loop < m_outlineCodeFixedData.getItemCount(); loop++)
7171
{
7272
byte[] fixedData = m_outlineCodeFixedData.getByteArrayValue(loop);
7373
if (fixedData == null)
@@ -118,7 +118,7 @@ public void process()
118118
// Replace the original instance in the table.
119119
// This ensures that the same instance is in the container and the lookup table.
120120
// TODO: is there a better way to do this? Should we generate the lookup table contents dynamically from the container?
121-
for (int index=0; index< table.size(); index++)
121+
for (int index = 0; index < table.size(); index++)
122122
{
123123
if (table.get(index).getUniqueID().equals(item.getUniqueID()))
124124
{

src/main/java/net/sf/mpxj/utility/ProjectCleanUtility.java

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -280,6 +280,7 @@ private void processMPP(String input, String output) throws IOException
280280
* @param items items to extract field values from
281281
* @param unicode true if replacing unicode text
282282
* @param nulTerminated true if a nul terminator should be included with the string
283+
* @param xml true if we're replacing test in an xml file
283284
* @param fields list of fields to extract
284285
*/
285286
private void processReplacements(byte[] data, List<? extends FieldContainer> items, boolean unicode, boolean nulTerminated, boolean xml, FieldType... fields)
@@ -465,10 +466,10 @@ private String escapeXml(String text)
465466
}
466467

467468
StringBuilder sb = new StringBuilder();
468-
for (int loop=0; loop < text.length(); loop++)
469+
for (int loop = 0; loop < text.length(); loop++)
469470
{
470471
char c = text.charAt(loop);
471-
switch(c)
472+
switch (c)
472473
{
473474
case '&':
474475
{

src/test/java/net/sf/mpxj/junit/CustomerDataTest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -521,12 +521,12 @@ private List<ProjectFile> testReader(String name, File file) throws Exception
521521
ProjectReader reader = proxy.getProjectReader();
522522
if (reader instanceof PrimaveraXERFileReader)
523523
{
524-
((PrimaveraXERFileReader)reader).setLinkCrossProjectRelations(true);
524+
((PrimaveraXERFileReader) reader).setLinkCrossProjectRelations(true);
525525
}
526526

527527
if (reader instanceof PrimaveraPMFileReader)
528528
{
529-
((PrimaveraPMFileReader)reader).setLinkCrossProjectRelations(true);
529+
((PrimaveraPMFileReader) reader).setLinkCrossProjectRelations(true);
530530
}
531531

532532
projects = proxy.readAll();

0 commit comments

Comments
 (0)