Lines Matching refs:state

140         final StringifyState state = new StringifyState();
144 state.replacerFunction = replacer;
150 state.propertyList = new ArrayList<>();
169 state.propertyList.add(item);
205 state.gap = gap;
210 return str("", wrapper, state);
227 private static Object str(final Object key, final Object holder, final StringifyState state) {
247 if (state.replacerFunction != null) {
248 value = getREPLACER_INVOKER().invokeExact(state.replacerFunction, holder, key, value);
287 return JA(value, state);
289 return JO(value, state);
297 private static String JO(final Object value, final StringifyState state) {
300 if (state.stack.containsKey(value)) {
304 state.stack.put(value, value);
305 final StringBuilder stepback = new StringBuilder(state.indent.toString());
306 state.indent.append(state.gap);
310 final List<String> k = state.propertyList == null ?
311 Arrays.asList(getOwnKeys(value)) : state.propertyList;
314 final Object strP = str(p, value, state);
320 if (!state.gap.isEmpty()) {
332 if (state.gap.isEmpty()) {
352 finalStr.append(state.indent);
358 finalStr.append(state.indent);
369 state.stack.remove(value);
370 state.indent = stepback;
376 private static Object JA(final Object value, final StringifyState state) {
379 if (state.stack.containsKey(value)) {
383 state.stack.put(value, value);
384 final StringBuilder stepback = new StringBuilder(state.indent.toString());
385 state.indent.append(state.gap);
392 Object strP = str(index, value, state);
404 if (state.gap.isEmpty()) {
421 finalStr.append(state.indent);
426 finalStr.append(state.indent);
437 state.stack.remove(value);
438 state.indent = stepback;