config library

The Dart form of the dartvel: section of pubspec.yaml.

A project can write dartvel: dartvel_config.dart and declare its configuration as a class instead:

import 'package:dartvel_core/config.dart';

class const AppConfig() extends DartvelConfig {

  @override
  List<DVFileAssociation> get fileAssociations => const <DVFileAssociation>[
        DVFileAssociation(mimeType: 'application/x-shop-order', extensions: <String>['order']),
      ];
}

The build turns the class into the same object the YAML would have been with DartvelConfig.toPubspec, so the two are one configuration: every field has the same name, default and validation in both.

A separate library rather than part of dartvel.dart, because the generated client barrel already has a DartvelConfig (its constants), and a page importing both would not compile.

Classes

DartvelConfig
A project's configuration, written in Dart.
DartvelPubspecConfig
The configuration a dartvel: object describes, as a DartvelConfig.
DVFileAssociation
One file type the application opens.
DVFileAssociationsParse
What reading fileAssociations found.

Enums

DVFileAssociationRole
What the application does with a file of this type.

Constants

dvAndroidOpenActivityClass → const String
The Activity dartvel build android writes to receive the files the application is opened with or shared, in JNI's slash-separated form. The intent filters are on it rather than on MainActivity, which is the developer's; it copies each file into the cache, queues it, brings the application forward and finishes.
dvIosOpenedFilesKey → const String
Where the iOS app delegate leaves the files it was opened with, as a JSON list of {path, name} copied out of their security scope, until the Flutter runtime takes them.