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

beforeKey() — spring-boot Function Reference

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

Function java GradlePlugin AotProcessing calls 3 called by 1

Entity Profile

Dependency Diagram

graph TD
  f7850c98_ffd7_9766_27a1_8b42d7687b07["beforeKey()"]
  65076e4d_26f9_55c7_e58b_d2e3df1292a7["key()"]
  65076e4d_26f9_55c7_e58b_d2e3df1292a7 -->|calls| f7850c98_ffd7_9766_27a1_8b42d7687b07
  e532399d_15ce_1aa0_3023_65e4c0f2706a["peek()"]
  f7850c98_ffd7_9766_27a1_8b42d7687b07 -->|calls| e532399d_15ce_1aa0_3023_65e4c0f2706a
  fde32a20_30b1_e5ec_2935_875f5d28ca41["newline()"]
  f7850c98_ffd7_9766_27a1_8b42d7687b07 -->|calls| fde32a20_30b1_e5ec_2935_875f5d28ca41
  a884604b_2d69_5510_5230_05bfd672dfd9["replaceTop()"]
  f7850c98_ffd7_9766_27a1_8b42d7687b07 -->|calls| a884604b_2d69_5510_5230_05bfd672dfd9
  style f7850c98_ffd7_9766_27a1_8b42d7687b07 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

cli/spring-boot-cli/src/json-shade/java/org/springframework/boot/cli/json/JSONStringer.java lines 373–383

	private void beforeKey() throws JSONException {
		Scope context = peek();
		if (context == Scope.NONEMPTY_OBJECT) { // first in object
			this.out.append(',');
		}
		else if (context != Scope.EMPTY_OBJECT) { // not in an object!
			throw new JSONException("Nesting problem");
		}
		newline();
		replaceTop(Scope.DANGLING_KEY);
	}

Domain

Subdomains

Called By

Frequently Asked Questions

What does beforeKey() do?
beforeKey() is a function in the spring-boot codebase.
What does beforeKey() call?
beforeKey() calls 3 function(s): newline, peek, replaceTop.
What calls beforeKey()?
beforeKey() is called by 1 function(s): key.

Analyze Your Own Codebase

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

Try Supermodel Free