PackageApi constructor
const
PackageApi({
- required String packageName,
- required String? packageVersion,
- required String packagePath,
- required List<
InterfaceDeclaration> interfaceDeclarations, - required List<
ExecutableDeclaration> executableDeclarations, - required List<
FieldDeclaration> fieldDeclarations, - required List<
TypeAliasDeclaration> typeAliasDeclarations, - @Default(<PackageApiSemantics>{}) Set<
PackageApiSemantics> semantics, - AndroidPlatformConstraints? androidPlatformConstraints,
- IOSPlatformConstraints? iosPlatformConstraints,
- required SdkType sdkType,
- required List<
PackageDependency> packageDependencies, - required Version minSdkVersion,
- required TypeHierarchy typeHierarchy,
Implementation
const factory PackageApi({
/// name of the package
required String packageName,
/// version of the package
required String? packageVersion,
/// path to the package
required String packagePath,
/// interface declarations this package has
required List<InterfaceDeclaration> interfaceDeclarations,
/// root level executable declarations this package has
required List<ExecutableDeclaration> executableDeclarations,
/// root level field declarations this package has
required List<FieldDeclaration> fieldDeclarations,
/// type alias declarations this package has
required List<TypeAliasDeclaration> typeAliasDeclarations,
/// the semantics of this model. This indicates if this model is compatible (e.g. for diffing) with another model
@Default(<PackageApiSemantics>{}) Set<PackageApiSemantics> semantics,
/// used Android platform constraints
AndroidPlatformConstraints? androidPlatformConstraints,
/// used iOS platform constraints
IOSPlatformConstraints? iosPlatformConstraints,
/// type of sdk needed
required SdkType sdkType,
/// package dependencies
required List<PackageDependency> packageDependencies,
/// minimum sdk version
required Version minSdkVersion,
/// the type hierarchy of the public API
required TypeHierarchy typeHierarchy,
}) = _PackageApi;