Skip to content
Permalink
Browse files
Make final variable. (#141)
  • Loading branch information
arturobernalg committed Mar 3, 2022
1 parent b85373d commit f2ca78fdc61db36354a7539b90ca58bb62bdbbfb
Showing 4 changed files with 5 additions and 5 deletions.
@@ -339,7 +339,7 @@ default Duration getDuration(final String key) {
* @since 2.8.0
*/
default Duration getDuration(final String key, final Duration defaultValue) {
Object value = getProperty(key);
final Object value = getProperty(key);
return value == null ? defaultValue : PropertyConverter.toDuration(value);
}

@@ -1057,7 +1057,7 @@ private Element getElement(final ImmutableNode node, final ReferenceNodeHandler

// special treatment for root node of the hierarchy
final Object reference = refHandler.getReference(node);
Node element;
final Node element;
if (reference instanceof XMLDocumentHelper) {
element = ((XMLDocumentHelper) reference).getDocument().getDocumentElement();
} else if (reference instanceof XMLListReference) {
@@ -304,7 +304,7 @@ public static Duration toDuration(final Object value) throws ConversionException
if (value instanceof CharSequence) {
try {
return Duration.parse((CharSequence) value);
} catch (DateTimeParseException e) {
} catch (final DateTimeParseException e) {
throw new ConversionException("Could not convert " + value + " to Duration", e);
}
}
@@ -131,7 +131,7 @@ private FileSystemOptions getOptions(final String scheme) {
return null;
}
final FileSystemOptions opts = new FileSystemOptions();
FileSystemConfigBuilder builder;
final FileSystemConfigBuilder builder;
try {
builder = getManager().getFileSystemConfigBuilder(scheme);
} catch (final Exception ex) {
@@ -244,7 +244,7 @@ public URL locateFromURL(final String basePath, final String fileName) {
return super.locateFromURL(basePath, fileName);
}
try {
FileObject file;
final FileObject file;
// Only use the base path if the file name doesn't have a scheme.
if (basePath != null && fileScheme == null) {
final String scheme = UriParser.extractScheme(basePath);

0 comments on commit f2ca78f

Please sign in to comment.