ComponentPortal<T> class
A component, when attached, instantiates a new component of type T
.
Constructors
-
ComponentPortal(ComponentFactory<
Object> componentFactory, {ViewContainerRef? origin})
Properties
- component → Type
-
The type of component that will be created.
no setter
-
componentFactory
→ ComponentFactory<
Object> -
The factory to create the component.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- isAttached → bool
-
Returns true if this portal is in the process of being attached but the
host has not loaded it yet or if the host has already loaded it.
no setterinherited
- origin → ViewContainerRef?
-
Optionally define an origin.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
attach(
PortalHost? host) → Future -
Attaches the portal within
host
.inherited -
clone(
) → ComponentPortal< T> -
Creates a copy of this portal that can also be attached.
override
-
detach(
) → Future< void> -
Detaches the portal if attached to a host.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
setAttachedHost(
PortalHost? host) → void -
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited