pub trait FollowableItem: Item {
type FollowableEvent: FollowableEvents;
// Required methods
fn remote_id(&self) -> Option<ViewId>;
fn to_state_proto(&self, cx: &AppContext) -> Option<Variant>;
fn from_state_proto(
pane: View<Pane>,
project: View<Workspace>,
id: ViewId,
state: &mut Option<Variant>,
cx: &mut AppContext
) -> Option<Task<Result<View<Self>>>>;
fn add_event_to_update_proto(
&self,
event: &Self::FollowableEvent,
update: &mut Option<Variant>,
cx: &AppContext
) -> bool;
fn apply_update_proto(
&mut self,
project: &Model<Project>,
message: Variant,
cx: &mut ViewContext<'_, Self>
) -> Task<Result<()>>;
fn is_project_item(&self, cx: &AppContext) -> bool;
fn set_leader_peer_id(
&mut self,
leader_peer_id: Option<PeerId>,
cx: &mut ViewContext<'_, Self>
);
}