Always use 'this.' when accessing fields

Ensure that `this.` is used consistently when accessing class
fields.

Issue: SPR-16968
This commit is contained in:
Phillip Webb
2018-06-25 11:37:17 -07:00
committed by Juergen Hoeller
parent eeebd51f57
commit 0b53c1096a
154 changed files with 374 additions and 373 deletions

View File

@@ -550,7 +550,7 @@ public class CastorMarshaller extends AbstractMarshaller implements Initializing
@Override
protected void marshalOutputStream(Object graph, OutputStream outputStream) throws XmlMappingException, IOException {
marshalWriter(graph, new OutputStreamWriter(outputStream, encoding));
marshalWriter(graph, new OutputStreamWriter(outputStream, this.encoding));
}
@Override

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2002-2017 the original author or authors.
* Copyright 2002-2018 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -230,8 +230,8 @@ public class JibxMarshaller extends AbstractMarshaller implements InitializingBe
}
}
else if (this.targetPackage != null) {
if (!StringUtils.hasLength(bindingName)) {
bindingName = DEFAULT_BINDING_NAME;
if (!StringUtils.hasLength(this.bindingName)) {
this.bindingName = DEFAULT_BINDING_NAME;
}
if (logger.isInfoEnabled()) {
logger.info("Configured for target package [" + this.targetPackage + "] using binding [" + this.bindingName + "]");
@@ -290,9 +290,9 @@ public class JibxMarshaller extends AbstractMarshaller implements InitializingBe
}
private void marshalDocument(IMarshallingContext marshallingContext, Object graph) throws IOException, JiBXException {
if (StringUtils.hasLength(docTypeRootElementName)) {
if (StringUtils.hasLength(this.docTypeRootElementName)) {
IXMLWriter xmlWriter = marshallingContext.getXmlWriter();
xmlWriter.writeDocType(docTypeRootElementName, docTypeSystemId, docTypePublicId, docTypeInternalSubset);
xmlWriter.writeDocType(this.docTypeRootElementName, this.docTypeSystemId, this.docTypePublicId, this.docTypeInternalSubset);
}
marshallingContext.marshalDocument(graph);
}
@@ -391,7 +391,7 @@ public class JibxMarshaller extends AbstractMarshaller implements InitializingBe
protected Object unmarshalInputStream(InputStream inputStream) throws XmlMappingException, IOException {
try {
IUnmarshallingContext unmarshallingContext = createUnmarshallingContext();
return unmarshallingContext.unmarshalDocument(inputStream, encoding);
return unmarshallingContext.unmarshalDocument(inputStream, this.encoding);
}
catch (JiBXException ex) {
throw convertJibxException(ex, false);

View File

@@ -193,7 +193,7 @@ public class MarshallingSource extends SAXSource {
@Nullable
public Object getProperty(String name) throws SAXNotRecognizedException {
if ("http://xml.org/sax/properties/lexical-handler".equals(name)) {
return lexicalHandler;
return this.lexicalHandler;
}
else {
throw new SAXNotRecognizedException(name);