IndexGenerator.from constructor
IndexGenerator.from(
- ProjectSettings project,
- PackageSettings package,
- IndexSettings index
Implementation
factory IndexGenerator.from(
ProjectSettings project,
PackageSettings package,
IndexSettings index,
) {
final indexPath = path.join(index.path, '${_resolveIndexName(project, package, index)}.dart');
return IndexGenerator._(
project: project,
package: package,
index: index,
folders: index.folders.map((dir) {
return Directory(path.join(index.path, dir.replaceAll('/', path.separator)));
}).toList(),
indexFile: File(indexPath),
);
}