Skip to main content

policy

Function policy 

Source
pub fn policy(
    layout: impl Layout<EndpointId> + Clone,
) -> impl Policy<EndpointId> + Clone
Expand description

Returns a policy that admits every peer with its grant under layout.

A pair of layouts is their union. For example, policy((LiveLayout::default(), RoomsLayout)) lets every peer publish its own broadcasts and its room broadcasts.