Skip to content

Commit

Permalink
Merge pull request #4 from usgs/develop
Browse files Browse the repository at this point in the history
Update for Java 11
  • Loading branch information
mckelvym-usgs authored Oct 21, 2020
2 parents b6618df + bf0baad commit dd0dcfe
Show file tree
Hide file tree
Showing 16 changed files with 151 additions and 44 deletions.
2 changes: 1 addition & 1 deletion .classpath
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-11"/>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry kind="src" path="src"/>
<classpathentry kind="src" path="test"/>
Expand Down
108 changes: 98 additions & 10 deletions .settings/org.eclipse.jdt.core.prefs

Large diffs are not rendered by default.

26 changes: 21 additions & 5 deletions .settings/org.eclipse.jdt.ui.prefs
Original file line number Diff line number Diff line change
Expand Up @@ -11,59 +11,75 @@ cleanup.always_use_blocks=true
cleanup.always_use_parentheses_in_expressions=false
cleanup.always_use_this_for_non_static_field_access=false
cleanup.always_use_this_for_non_static_method_access=false
cleanup.convert_functional_interfaces=false
cleanup.convert_functional_interfaces=true
cleanup.convert_to_enhanced_for_loop=true
cleanup.correct_indentation=false
cleanup.convert_to_enhanced_for_loop_if_loop_var_used=false
cleanup.correct_indentation=true
cleanup.format_source_code=true
cleanup.format_source_code_changes_only=false
cleanup.insert_inferred_type_arguments=false
cleanup.lazy_logical_operator=true
cleanup.make_local_variable_final=true
cleanup.make_parameters_final=true
cleanup.make_private_fields_final=true
cleanup.make_type_abstract_if_missing_method=false
cleanup.make_variable_declarations_final=true
cleanup.merge_conditional_blocks=true
cleanup.never_use_blocks=false
cleanup.never_use_parentheses_in_expressions=true
cleanup.number_suffix=true
cleanup.objects_equals=true
cleanup.organize_imports=true
cleanup.precompile_regex=true
cleanup.push_down_negation=false
cleanup.qualify_static_field_accesses_with_declaring_class=false
cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
cleanup.qualify_static_member_accesses_with_declaring_class=true
cleanup.qualify_static_method_accesses_with_declaring_class=false
cleanup.remove_private_constructors=true
cleanup.remove_redundant_modifiers=true
cleanup.remove_redundant_semicolons=true
cleanup.remove_redundant_type_arguments=true
cleanup.remove_trailing_whitespaces=true
cleanup.remove_trailing_whitespaces_all=true
cleanup.remove_trailing_whitespaces_ignore_empty=false
cleanup.remove_unnecessary_array_creation=true
cleanup.remove_unnecessary_casts=true
cleanup.remove_unnecessary_nls_tags=true
cleanup.remove_unused_imports=true
cleanup.remove_unused_local_variables=true
cleanup.remove_unused_private_fields=true
cleanup.remove_unused_private_members=false
cleanup.remove_unused_private_members=true
cleanup.remove_unused_private_methods=true
cleanup.remove_unused_private_types=true
cleanup.simplify_lambda_expression_and_method_ref=true
cleanup.sort_members=true
cleanup.sort_members_all=true
cleanup.use_anonymous_class_creation=false
cleanup.use_autoboxing=false
cleanup.use_blocks=true
cleanup.use_blocks_only_for_return_and_throw=false
cleanup.use_directly_map_method=true
cleanup.use_lambda=true
cleanup.use_parentheses_in_expressions=true
cleanup.use_this_for_non_static_field_access=false
cleanup.use_this_for_non_static_field_access_only_if_necessary=true
cleanup.use_this_for_non_static_method_access=false
cleanup.use_this_for_non_static_method_access_only_if_necessary=true
cleanup.use_type_arguments=false
cleanup.use_unboxing=false
cleanup.use_var=false
cleanup_profile=_WARC Cleanup Profile
cleanup_settings_version=2
eclipse.preferences.version=1
formatter_profile=_WARC Formatting Profile
formatter_settings_version=12
formatter_settings_version=20
org.eclipse.jdt.ui.exception.name=e
org.eclipse.jdt.ui.gettersetter.use.is=true
org.eclipse.jdt.ui.keywordthis=false
org.eclipse.jdt.ui.overrideannotation=true
org.eclipse.jdt.ui.text.custom_code_templates=
sp_cleanup.add_default_serial_version_id=true
sp_cleanup.add_generated_serial_version_id=false
sp_cleanup.add_missing_annotations=true
Expand Down Expand Up @@ -120,4 +136,4 @@ sp_cleanup.use_parentheses_in_expressions=true
sp_cleanup.use_this_for_non_static_field_access=false
sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
sp_cleanup.use_this_for_non_static_method_access=false
sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
8 changes: 4 additions & 4 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@ language: java
sudo: false

jdk:
- openjdk8
- oraclejdk8
- openjdk11
- oraclejdk11

dist: trusty
dist: focal

script:
- mvn -P packaging-jar clean install
- mvn -P packaging-jar install verify

branches:
only:
Expand Down
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# JEM BMD Reader Library Change Log

## 2.0.0 - 2020-10-16
* Update for Java 11
* Update org.eclipse.jdt.core.prefs and org.eclipse.jdt.ui.prefs for Java 11 and warn on missing javadocs for private visibility

## 1.0.3 - 2020-08-14
* Add Automatic-Module-Name
* Minor changes to address compiler warnings
Expand Down
6 changes: 3 additions & 3 deletions META-INF/MANIFEST.MF
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: Binary Modeling Data (BMD) IO
Bundle-SymbolicName: gov.usgs.jem.binarymodelingdata
Bundle-Version: 1.0.3.qualifier
Bundle-Version: 2.0.0.qualifier
Bundle-Vendor: USGS/JEM
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
Bundle-RequiredExecutionEnvironment: JavaSE-11
Require-Bundle: guava;bundle-version="29.0.0",
org.apache.log4j;bundle-version="1.2.17",
org.junit;bundle-version="4.12.0"
org.junit;bundle-version="4.13.0"
Export-Package: gov.usgs.jem.binarymodelingdata,
gov.usgs.jem.binarymodelingdata.input
Automatic-Module-Name: gov.usgs.jem.binarymodelingdata
4 changes: 2 additions & 2 deletions code.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"name": "jem-bmd-library",
"organization": "U.S. Geological Survey",
"description": "JEM BMD Reader Java library to read and query from Binary Modeling Data (BMD) output from EPA WASP model.",
"version": "1.0.3",
"version": "2.0.0",
"status": "Beta",

"permissions": {
Expand Down Expand Up @@ -43,7 +43,7 @@
},

"date": {
"metadataLastUpdated": "2020-08-14"
"metadataLastUpdated": "2020-10-16"
}
}
]
19 changes: 10 additions & 9 deletions pom.xml
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>

<groupId>gov.usgs.jem.bmdconverter.group</groupId>
<artifactId>gov.usgs.jem.binarymodelingdata</artifactId>
<version>1.0.3-SNAPSHOT</version>
<version>2.0.0-SNAPSHOT</version>
<packaging>${packaging.type}</packaging>
<name>Binary Modeling Data Library Plug-in</name>
<profiles>
Expand All @@ -28,10 +29,9 @@

<com.google.guava.version>29.0-jre</com.google.guava.version>
<org.apache.log4j.version>1.2.17</org.apache.log4j.version>
<org.eclipse.core.version>3.12.0.v20160606-1342</org.eclipse.core.version>
<org.junit.version>4.12</org.junit.version>
<org.junit.plugin.version>4.12.0</org.junit.plugin.version>
<tycho.version>1.4.0</tycho.version>
<org.junit.version>4.13</org.junit.version>
<org.junit.plugin.version>4.13.0</org.junit.plugin.version>
<tycho.version>2.0.0</tycho.version>
</properties>
<build>
<sourceDirectory>src</sourceDirectory>
Expand All @@ -41,8 +41,9 @@
<artifactId>maven-compiler-plugin</artifactId>
<version>3.3</version>
<configuration>
<source>1.8</source>
<target>1.8</target>
<source>11</source>
<target>11</target>
<release>11</release>
</configuration>
</plugin>
<plugin>
Expand All @@ -64,7 +65,7 @@
<artifactId>target-platform-configuration</artifactId>
<version>${tycho.version}</version>
<configuration>

<environments>
<environment>
<os>win32</os>
Expand Down
1 change: 1 addition & 0 deletions src/gov/usgs/jem/binarymodelingdata/BMDHeader.java
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ public final class BMDHeader
* @since Apr 18, 2014
*
*/
@SuppressWarnings("javadoc")
public static class Builder
{
private double m_bEndTime;
Expand Down
1 change: 1 addition & 0 deletions test/gov/usgs/jem/binarymodelingdata/BMDHeaderTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
* @since Aug 18, 2016
*
*/
@SuppressWarnings("javadoc")
@FixMethodOrder(MethodSorters.NAME_ASCENDING)
public class BMDHeaderTest
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
* @since Aug 18, 2016
*
*/
@SuppressWarnings("javadoc")
@FixMethodOrder(MethodSorters.NAME_ASCENDING)
public class BMDReaderTest
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
* @since Aug 18, 2016
*
*/
@SuppressWarnings("javadoc")
@FixMethodOrder(MethodSorters.NAME_ASCENDING)
public class BMDSegmentImplTest
{
Expand Down Expand Up @@ -92,7 +93,6 @@ public final void testCompareTo()
m_Val.compareTo(new BMDSegmentImpl(m_Index - 1, m_Name)) > 0);
}

@SuppressWarnings("javadoc")
@Test
public final void testEquals() throws Exception
{
Expand Down Expand Up @@ -129,7 +129,6 @@ public final void testGetName()
Assert.assertEquals(m_Name, m_Val.getName());
}

@SuppressWarnings("javadoc")
@Test
public final void testHashCode() throws Exception
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
* @since Aug 18, 2016
*
*/
@SuppressWarnings("javadoc")
@FixMethodOrder(MethodSorters.NAME_ASCENDING)
public class BMDTimeStepImplTest
{
Expand Down Expand Up @@ -97,7 +98,6 @@ public final void testCompareTo()
new BMDTimeStepImpl(m_Index - 1, m_TimeMS, m_RawValue)) > 0);
}

@SuppressWarnings("javadoc")
@Test
public final void testEquals() throws Exception
{
Expand Down Expand Up @@ -144,7 +144,6 @@ public final void testGetValue()
Assert.assertEquals(m_RawValue, m_Val.getValue(), Double.MIN_NORMAL);
}

@SuppressWarnings("javadoc")
@Test
public final void testHashCode() throws Exception
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
* @since Aug 18, 2016
*
*/
@SuppressWarnings("javadoc")
@FixMethodOrder(MethodSorters.NAME_ASCENDING)
public class BMDVariableImplTest
{
Expand Down Expand Up @@ -99,7 +100,6 @@ public final void testCompareTo()
m_Name, m_Units, m_PCode)) > 0);
}

@SuppressWarnings("javadoc")
@Test
public final void testEquals() throws Exception
{
Expand Down Expand Up @@ -157,7 +157,6 @@ public final void testGetUnits()
Assert.assertEquals(m_Units, m_Val.getUnits());
}

@SuppressWarnings("javadoc")
@Test
public final void testHashCode() throws Exception
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
* @since Aug 19, 2016
*
*/
@SuppressWarnings("javadoc")
@FixMethodOrder(MethodSorters.NAME_ASCENDING)
public class ConcentrationImplTest
{
Expand Down Expand Up @@ -170,7 +171,6 @@ public final void testCompareTo()
}
}

@SuppressWarnings("javadoc")
@Test
public final void testEquals() throws Exception
{
Expand Down Expand Up @@ -228,7 +228,6 @@ public final void testGetVariable()
Assert.assertEquals(m_Variable, m_Concentration.getVariable());
}

@SuppressWarnings("javadoc")
@Test
public final void testHashCode() throws Exception
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
* @since Aug 19, 2016
*
*/
@SuppressWarnings("javadoc")
@FixMethodOrder(MethodSorters.NAME_ASCENDING)
public class SeekableDataFileInputStreamImplTest
{
Expand Down Expand Up @@ -180,7 +181,6 @@ public final void testClose()
}
}

@SuppressWarnings("javadoc")
@Test
public final void testEquals() throws Exception
{
Expand Down Expand Up @@ -217,7 +217,6 @@ public final void testGetFilePath()
Assert.assertEquals(m_FilePath, m_Input.getFilePath());
}

@SuppressWarnings("javadoc")
@Test
public final void testHashCode() throws Exception
{
Expand Down

0 comments on commit dd0dcfe

Please sign in to comment.