pub fn is_sub_state_the_same(&self, state: &SPState, path: &SPPath) -> bool {
        self.index
            .iter()
            .filter(|(key, _)| key.is_child_of(path))
            .all(|(key, i)| {
                state
                    .sp_value_from_path(key)
                    .map(|x| x == self.values[*i].value())
                    .unwrap_or(false)
            })
    }
/// Checks if a sub state is the same as another states sub state given the same path
/// This is used to check this so we do not need to create a clone with sub_state.
Checks if a sub state is the same as another states sub state given the same path
This is used to check this so we do not need to create a clone with sub_state.
Checks if a sub state is the same as another states sub state given the same path This is used to check this so we do not need to create a clone with sub_state .
pub fn is_sub_state_the_same(&self, state: &SPState, path: &SPPath) -> bool {
        self.index
            .iter()
            .filter(|(key, _)| key.is_child_of(path))
            .all(|(key, i)| {
                state
                    .sp_value_from_path(key)
                    .map(|x| x == self.values[*i].value())
                    .unwrap_or(false)
            })
    }
pub fn is_sub_state_the_same ( & self , state : & SPState , path : & SPPath ) -> bool { self . index . iter ( ) . filter ( | ( key , _ ) | key . is_child_of ( path ) ) . all ( | ( key , i ) | { state . sp_value_from_path ( key ) . map ( | x | x == self . values [ * i ] . value ( ) ) . unwrap_or ( false ) } ) }
Checks if a sub state is the same as another states sub state given the same path
This is used to check this so we do not need to create a clone with sub_state.
Checks if a sub state is the same as another states sub state given the same path This is used to check this so we do not need to create a clone with sub_state .
&self
state
&SPState
path
&SPPath