extractClassesToGenerateSerializersFor function
ClassesToGenerateSerializersFor
extractClassesToGenerateSerializersFor(
- LibraryElement externalSchemaLibrary
Implementation
ClassesToGenerateSerializersFor extractClassesToGenerateSerializersFor(
LibraryElement externalSchemaLibrary) {
final builtClasses = externalSchemaLibrary.units
.expand((cu) => cu.classes)
.where((c) => hasSerializer(c) && isBuiltValue(c))
.toSet();
final nonBuiltClasses = externalSchemaLibrary.units
.expand((cu) => cu.classes)
.where(
(c) => hasSerializer(c) && !isBuiltValue(c),
)
.toSet();
return (
builtClasses: builtClasses,
nonBuiltClasses: nonBuiltClasses,
);
}