MasonBundle class
A bundled version of a mason template.
- Annotations
-
- @JsonSerializable(fieldRename: FieldRename.snake)
Constructors
-
MasonBundle({required String name, required String description, required String version, BrickEnvironment environment = const BrickEnvironment(), Map<
String, BrickVariableProperties> vars = const <String, BrickVariableProperties>{}, List<MasonBundledFile> files = const [], List<MasonBundledFile> hooks = const [], String? repository, String? publishTo, MasonBundledFile? readme, MasonBundledFile? changelog, MasonBundledFile? license}) -
A bundled version of a mason template.
const
-
MasonBundle.fromJson(Map<
String, dynamic> json) -
Converts a Map<String, dynamic> into a MasonBundle instance.
factory
Properties
- changelog → MasonBundledFile?
-
The brick's CHANGELOG.md file.
final
- description → String
-
Description of the brick (from the
brick.yaml
).final - environment → BrickEnvironment
-
The brick environment (from the
brick.yaml
).final -
files
→ List<
MasonBundledFile> -
List of all MasonBundledFile instances within the
__brick__
directory.final - hashCode → int
-
The hash code for this object.
no setterinherited
-
hooks
→ List<
MasonBundledFile> -
List of all MasonBundledFile instances within the
hooks
directory.final - license → MasonBundledFile?
-
The brick's LICENSE file.
final
- name → String
-
Name of the brick (from the
brick.yaml
).final - publishTo → String?
-
Optional url used to specify a custom brick registry
as the publish target.
final
- readme → MasonBundledFile?
-
The brick's README.md file.
final
- repository → String?
-
Optional url pointing to the brick's source code repository.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
vars
→ Map<
String, BrickVariableProperties> -
All required variables for the brick (from the
brick.yaml
).final - version → String
-
The brick version (from the
brick.yaml
).final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> - Converts a MasonBundle into a Map<String, dynamic>.
-
toString(
) → String -
A string representation of this object.
inherited
-
toUniversalBundle(
) → Future< List< int> > - Converts a MasonBundle into universal bundle bytes.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
fromDartBundle(
String content) → Future< MasonBundle> - Converts a dart bundle into a MasonBundle instance.
-
fromUniversalBundle(
List< int> bytes) → Future<MasonBundle> - Converts a universal bundle into a MasonBundle instance.