Home / Function/ beforeValue() — spring-boot Function Reference

beforeValue() — spring-boot Function Reference

Architecture documentation for the beforeValue() function in JSONStringer.java from the spring-boot codebase.

Function java GradlePlugin RunTasks calls 3 called by 2

Entity Profile

Dependency Diagram

graph TD
  250890e2_bc7d_48c3_5fce_7d652e3be2b4["beforeValue()"]
  72c07c64_b550_5f12_73c9_c77b5ce919c2["open()"]
  72c07c64_b550_5f12_73c9_c77b5ce919c2 -->|calls| 250890e2_bc7d_48c3_5fce_7d652e3be2b4
  92191868_5757_b438_a428_8a7b39e68bad["value()"]
  92191868_5757_b438_a428_8a7b39e68bad -->|calls| 250890e2_bc7d_48c3_5fce_7d652e3be2b4
  9596cab2_d5a6_0f2b_a448_634ebb188df4["peek()"]
  250890e2_bc7d_48c3_5fce_7d652e3be2b4 -->|calls| 9596cab2_d5a6_0f2b_a448_634ebb188df4
  6a51dcc6_e82a_1a05_431d_9fee7c63dcab["replaceTop()"]
  250890e2_bc7d_48c3_5fce_7d652e3be2b4 -->|calls| 6a51dcc6_e82a_1a05_431d_9fee7c63dcab
  4bc521aa_77f0_104c_fbaa_5ff8efa00155["newline()"]
  250890e2_bc7d_48c3_5fce_7d652e3be2b4 -->|calls| 4bc521aa_77f0_104c_fbaa_5ff8efa00155
  style 250890e2_bc7d_48c3_5fce_7d652e3be2b4 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

configuration-metadata/spring-boot-configuration-metadata/src/json-shade/java/org/springframework/boot/configurationmetadata/json/JSONStringer.java lines 391–412

	private void beforeValue() throws JSONException {
		if (this.stack.isEmpty()) {
			return;
		}

		Scope context = peek();
		if (context == Scope.EMPTY_ARRAY) { // first in array
			replaceTop(Scope.NONEMPTY_ARRAY);
			newline();
		}
		else if (context == Scope.NONEMPTY_ARRAY) { // another in array
			this.out.append(',');
			newline();
		}
		else if (context == Scope.DANGLING_KEY) { // value for key
			this.out.append(this.indent == null ? ":" : ": ");
			replaceTop(Scope.NONEMPTY_OBJECT);
		}
		else if (context != Scope.NULL) {
			throw new JSONException("Nesting problem");
		}
	}

Domain

Subdomains

Called By

Frequently Asked Questions

What does beforeValue() do?
beforeValue() is a function in the spring-boot codebase.
What does beforeValue() call?
beforeValue() calls 3 function(s): newline, peek, replaceTop.
What calls beforeValue()?
beforeValue() is called by 2 function(s): open, value.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free