PartialImpl class

The base class for a partial file

Inheritance
Mixed-in types

Constructors

PartialImpl(PartialConfig? config, {required String sourceFile, required String outputDir})
The base class for a partial file

Properties

combine → List<Iterable<(String, String)>>
no setterinherited
fileName → String
returns the file name and extension of the partial
no setteroverride
hashCode → int
The hash code for this object.
no setterinherited
name → String
the name of the partial
no setteroverride
outputDir → String
The path to where the partial will be written
final
props → List<Object?>
The list of properties that will be used to determine whether two instances are equal.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
sectionSetupPattern → RegExp
the pattern to find sections (sections) within the content
no setterinherited
sourceFile → String
The path to where the partial is located
final
stringify → bool?
If set to true, the toString method will be overridden to output this instance's props.
no setterinherited
variableConfig → Map<String, String?>?
finalinherited
variables → Iterable<Variable>
retrieves all variables from the VarsMixin.varsMap
no setterinherited
variablesToProcess → List
no setterinherited
vars → Iterable<String>
no setterinherited
varsMap → Set<(String, String)>
no setterinherited

Methods

checkForPartials({required String content, required Iterable<Partial> partials}) → ContentReplacement
writes the partials to the content
inherited
checkForSections(String content, Variable variable) → ContentReplacement
checks the content for sections (sections) and replaces them with the variable's value
inherited
checkForVariables(String content, Variable variable) → ContentReplacement
replaces the variable in the content
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
sectionPattern(Variable variable) → RegExp
the pattern to find sections within the content
inherited
toJson() → Map<String, dynamic>
inherited
toPartialFile() → String
returns the fileName wrapped with {{> and }}
inherited
toPartialInput() → String
returns the fileName wrapped with {{~ and }}
inherited
toString() → String
A string representation of this object.
inherited
variablePattern(Variable variable) → RegExp
the pattern to find variables within the content
inherited
write({required Iterable<Partial> partials, required Set<Variable> outOfFileVariables}) → FileWriteResult
writes the partial to the target file
override
writeFile({required String targetPath, required String sourcePath, required Iterable<Variable> variables, required Iterable<Variable> outOfFileVariables, required Iterable<Partial> partials}) → FileWriteResult
writes the targetPath content using the sourcePath's content and replacing the variables and partials with their configured values
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited