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

Method constructor

src/Language/CPlusPlus.ts:246–261  ·  view source on GitHub ↗
(
        graph: TypeGraph,
        private readonly _namespaceName: string,
        _typeNamingStyle: NamingStyle,
        _memberNamingStyle: NamingStyle,
        _enumeratorNamingStyle: NamingStyle,
        private readonly _uniquePtr: boolean
    )

Source from the content-addressed store, hash-verified

244 private readonly _optionalType: string;
245
246 constructor(
247 graph: TypeGraph,
248 private readonly _namespaceName: string,
249 _typeNamingStyle: NamingStyle,
250 _memberNamingStyle: NamingStyle,
251 _enumeratorNamingStyle: NamingStyle,
252 private readonly _uniquePtr: boolean
253 ) {
254 super(graph);
255
256 this._typeNameStyle = cppNameStyle(_typeNamingStyle);
257 this._typeNamingFunction = funPrefixNamer(this._typeNameStyle);
258 this._memberNamingFunction = funPrefixNamer(cppNameStyle(_memberNamingStyle));
259 this._caseNamingFunction = funPrefixNamer(cppNameStyle(_enumeratorNamingStyle));
260 this._optionalType = _uniquePtr ? "std::unique_ptr" : "boost::optional";
261 }
262
263 protected get forbiddenNamesForGlobalNamespace(): string[] {
264 return keywords;

Callers

nothing calls this directly

Calls 2

funPrefixNamerFunction · 0.90
cppNameStyleFunction · 0.85

Tested by

no test coverage detected