Skip to content

Commit 8930d81

Browse files
committed
Minor naming fix
1 parent 51f6851 commit 8930d81

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

src/main/java/com/fasterxml/jackson/core/util/SimpleStreamWriteContext.java

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ public final class SimpleStreamWriteContext extends TokenStreamContext
4949
* Marker used to indicate that we just wrote a property name (or possibly
5050
* property id for some backends) and now expect a value to write.
5151
*/
52-
protected boolean _gotFieldId;
52+
protected boolean _gotPropertyId;
5353

5454
/*
5555
/**********************************************************************
@@ -71,7 +71,7 @@ private SimpleStreamWriteContext reset(int type, Object currentValue) {
7171
_type = type;
7272
_index = -1;
7373
_currentName = null;
74-
_gotFieldId = false;
74+
_gotPropertyId = false;
7575
_currentValue = currentValue;
7676
if (_dups != null) { _dups.reset(); }
7777
return this;
@@ -132,11 +132,11 @@ public SimpleStreamWriteContext createChildObjectContext(Object currentValue) {
132132
@Override public final String currentName() {
133133
// 15-Aug-2019, tatu: Should NOT check this status because otherwise name
134134
// in parent context is not accessible after new structured scope started
135-
// if (_gotFieldId) { ... }
135+
// if (_gotPropertyId) { ... }
136136
return _currentName;
137137
}
138138

139-
@Override public boolean hasCurrentName() { return _gotFieldId; }
139+
@Override public boolean hasCurrentName() { return _gotPropertyId; }
140140

141141
/**
142142
* Method that can be used to both clear the accumulated references
@@ -174,10 +174,10 @@ public DupDetector getDupDetector() {
174174
* @throws StreamWriteException If write fails due to duplicate check
175175
*/
176176
public boolean writeName(String name) throws StreamWriteException {
177-
if ((_type != TYPE_OBJECT) || _gotFieldId) {
177+
if ((_type != TYPE_OBJECT) || _gotPropertyId) {
178178
return false;
179179
}
180-
_gotFieldId = true;
180+
_gotPropertyId = true;
181181
_currentName = name;
182182
if (_dups != null) { _checkDup(_dups, name); }
183183
return true;
@@ -194,10 +194,10 @@ private final void _checkDup(DupDetector dd, String name) throws StreamWriteExce
194194
public boolean writeValue() {
195195
// Only limitation is with OBJECTs:
196196
if (_type == TYPE_OBJECT) {
197-
if (!_gotFieldId) {
197+
if (!_gotPropertyId) {
198198
return false;
199199
}
200-
_gotFieldId = false;
200+
_gotPropertyId = false;
201201
}
202202
++_index;
203203
return true;

0 commit comments

Comments
 (0)