28 references to Invalid
Microsoft.NET.ProjectData.Generators (28)
DataModelSchemaGenerator.cs (28)
156
throw
Invalid
("Field 'properties' must define at least one property.");
186
throw
Invalid
($"Field '{propertyPath}.name' cannot be '{name}' because that name is reserved by the generated ProjectProperties or TypedProperties type.");
188
throw
Invalid
($"Property name '{name}' is duplicated across 'properties.required' and 'properties.optional'.");
207
throw
Invalid
($"Item name '{item.Name}' is reserved by the generated ProjectItems type.");
209
throw
Invalid
($"Item name '{item.Name}' is duplicated.");
220
throw
Invalid
("Field 'items' must define at least one item.");
240
throw
Invalid
($"Metadata name '{name}' is duplicated in field '{itemPath}.metadata'.");
245
throw
Invalid
($"Field '{path}' produces duplicate generated member name '{generatedName}'.");
258
throw
Invalid
("Field 'cacheFormat.versionHeader' must have the form 'version=<major>[.<minor>]' using non-negative integers.");
266
throw
Invalid
("Field 'cacheFormat.commentChar' must contain exactly one character.");
274
throw
Invalid
("Fields 'cacheFormat.sectionOpen' and 'cacheFormat.sectionClose' must be different.");
276
throw
Invalid
("Fields 'cacheFormat.projectHeaderPrefix' and 'cacheFormat.languagePrefix' must be different.");
278
throw
Invalid
("Fields 'cacheFormat.primaryMarker' and 'cacheFormat.lastDtbSucceededMarker' must be different.");
294
throw
Invalid
($"Section name '{name}' is duplicated in field 'cacheFormat.sections'.");
298
throw
Invalid
($"Field '{sectionPath}.name' produces duplicate generated member name '{generatedName}'.");
302
throw
Invalid
($"Field '{sectionPath}.itemType' references unknown item type '{itemType}'.");
309
throw
Invalid
("Field 'cacheFormat.sections' must define at least one section.");
338
throw
Invalid
($"Path sentinel name '{entry.Name}' produces duplicate generated member name '{generatedName}'.");
343
throw
Invalid
($"Path sentinel value '{value}' is duplicated.");
349
throw
Invalid
("Field 'pathSentinels' must define at least one sentinel.");
358
throw
Invalid
($"Required field '{path}' is missing.");
366
throw
Invalid
($"{char.ToUpperInvariant(subject[0]) + subject.Substring(1)} must be a JSON {GetJsonKindName(kind)}, but found {GetJsonKindName(value.ValueKind)}.");
392
throw
Invalid
($"Field '{path}' must be a non-empty string.");
416
throw
Invalid
($"Field '{path}' cannot contain line breaks.");
434
throw
Invalid
($"{char.ToUpperInvariant(subject[0]) + subject.Substring(1)} must be a JSON boolean, but found {GetJsonKindName(value.ValueKind)}.");
444
throw
Invalid
($"{char.ToUpperInvariant(subject[0]) + subject.Substring(1)} contains duplicate field '{property.Name}'.");
454
throw
Invalid
($"{subject} must be a valid, non-keyword C# identifier, but found '{value}'.");
493
throw
Invalid
($"{subject} cannot contain control characters or Unicode line separators.");