pub trait ChunkType:
ValueToString
+ Send
+ Sync
+ NonLocalValue
+ ValueDebug {
// Required methods
fn is_style(self: Vc<Self>) -> Vc<bool>
where Self: Sized;
fn chunk(
self: Vc<Self>,
chunking_context: Vc<Box<dyn ChunkingContext>>,
chunk_items: Vec<ChunkItemOrBatchWithAsyncModuleInfo>,
batch_groups: Vec<Vc<ChunkItemBatchGroup>>,
component_chunks: Vec<Vc<Box<dyn Chunk>>>,
) -> Vc<Box<dyn Chunk>>
where Self: Sized;
fn chunk_item_size(
self: Vc<Self>,
chunking_context: Vc<Box<dyn ChunkingContext>>,
chunk_item: Vc<Box<dyn ChunkItem>>,
async_module_info: Option<Vc<AsyncModuleInfo>>,
) -> Vc<usize>
where Self: Sized;
}Required Methods§
Sourcefn is_style(self: Vc<Self>) -> Vc<bool>where
Self: Sized,
fn is_style(self: Vc<Self>) -> Vc<bool>where
Self: Sized,
Whether the source (reference) order of items needs to be retained during chunking.
Sourcefn chunk(
self: Vc<Self>,
chunking_context: Vc<Box<dyn ChunkingContext>>,
chunk_items: Vec<ChunkItemOrBatchWithAsyncModuleInfo>,
batch_groups: Vec<Vc<ChunkItemBatchGroup>>,
component_chunks: Vec<Vc<Box<dyn Chunk>>>,
) -> Vc<Box<dyn Chunk>>where
Self: Sized,
fn chunk(
self: Vc<Self>,
chunking_context: Vc<Box<dyn ChunkingContext>>,
chunk_items: Vec<ChunkItemOrBatchWithAsyncModuleInfo>,
batch_groups: Vec<Vc<ChunkItemBatchGroup>>,
component_chunks: Vec<Vc<Box<dyn Chunk>>>,
) -> Vc<Box<dyn Chunk>>where
Self: Sized,
Create a new chunk for the given chunk items
fn chunk_item_size(
self: Vc<Self>,
chunking_context: Vc<Box<dyn ChunkingContext>>,
chunk_item: Vc<Box<dyn ChunkItem>>,
async_module_info: Option<Vc<AsyncModuleInfo>>,
) -> Vc<usize>where
Self: Sized,
Trait Implementations§
impl Dynamic<Box<dyn ChunkType>> for Box<dyn ChunkType>
impl Dynamic<Box<dyn ValueDebug>> for Box<dyn ChunkType>
Available on debug-assertions enabled only.
impl Dynamic<Box<dyn ValueToString>> for Box<dyn ChunkType>
impl Upcast<Box<dyn ChunkType>> for Box<dyn ChunkType>
impl Upcast<Box<dyn ValueDebug>> for Box<dyn ChunkType>
Available on debug-assertions enabled only.
impl Upcast<Box<dyn ValueToString>> for Box<dyn ChunkType>
impl UpcastStrict<Box<dyn ValueDebug>> for Box<dyn ChunkType>
Available on debug-assertions enabled only.
impl UpcastStrict<Box<dyn ValueToString>> for Box<dyn ChunkType>
Source§impl VcValueTrait for Box<dyn ChunkType>
impl VcValueTrait for Box<dyn ChunkType>
Source§const IMPL_VTABLES: &'static VTableRegistry<Self::ValueTrait>
const IMPL_VTABLES: &'static VTableRegistry<Self::ValueTrait>
The per-trait vtable registry, populated by [crate::value_type::register_all_trait_methods] Read more
type ValueTrait = dyn ChunkType
Source§fn get_trait_type_id() -> TraitTypeId
fn get_trait_type_id() -> TraitTypeId
Returns the type id of the trait object.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".