MCPcopy Create free account
hub / github.com/glideapps/quicktype / javaNameStyle

Function javaNameStyle

src/Language/Java.ts:153–165  ·  view source on GitHub ↗
(startWithUpper: boolean, upperUnderscore: boolean, original: string)

Source from the content-addressed store, hash-verified

151// just capitalize and concatenate.
152// https://stackoverflow.com/questions/8277355/naming-convention-for-upper-case-abbreviations
153function javaNameStyle(startWithUpper: boolean, upperUnderscore: boolean, original: string): string {
154 const words = splitIntoWords(original);
155 return combineWords(
156 words,
157 legalizeName,
158 upperUnderscore ? allUpperWordStyle : startWithUpper ? firstUpperWordStyle : allLowerWordStyle,
159 upperUnderscore ? allUpperWordStyle : firstUpperWordStyle,
160 upperUnderscore || startWithUpper ? allUpperWordStyle : allLowerWordStyle,
161 allUpperWordStyle,
162 upperUnderscore ? "_" : "",
163 isStartCharacter
164 );
165}
166
167class JavaRenderer extends ConvenienceRenderer {
168 constructor(graph: TypeGraph, private readonly _packageName: string, private readonly _justTypes: boolean) {

Callers 2

Java.tsFile · 0.85
topLevelNameStyleMethod · 0.85

Calls 2

splitIntoWordsFunction · 0.90
combineWordsFunction · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…