SingleColumnLayoutPresenter class
Produces SingleColumnLayoutViewModels to be displayed by a SingleColumnDocumentLayout.
A SingleColumnLayoutComponentViewModel is created for every DocumentNode
in the given document
, using the ComponentBuilders. These component
view models are assembled into a SingleColumnLayoutViewModel.
The view model is styled by passing it through a series of "style phases",
known as a pipeline
. The final, styled, SingleColumnLayoutViewModel is
available via the viewModel property.
When the document
changes, the entire pipeline is re-run to produce
a new SingleColumnLayoutViewModel.
The output from each phase of the pipeline is cached so that when
something other than the document changes, like the user's selection,
only some of the pipeline phases are re-run. For this reason, the most
volatile phases should be placed at the end of the pipeline
.
Constructors
-
SingleColumnLayoutPresenter({required Document document, required List<
ComponentBuilder> componentBuilders, required List<SingleColumnLayoutStylePhase> pipeline})
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- isDirty → bool
-
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- viewModel → SingleColumnLayoutViewModel
-
no setter
Methods
-
addChangeListener(
SingleColumnLayoutPresenterChangeListener listener) → void -
dispose(
) → void -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
removeChangeListener(
SingleColumnLayoutPresenterChangeListener listener) → void -
toString(
) → String -
A string representation of this object.
inherited
-
updateViewModel(
) → void
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited