pub fn collection_aliases(&self, collection_name: &str) -> Result<Vec<String>, StorageError> {
        let mut result = vec![];
        for pair in self.alias_persistence.iter() {
            let (alias_bt, target_collection_bt) = pair?;
            let alias = from_utf8(&alias_bt).unwrap().to_string();
            let target_collection = from_utf8(&target_collection_bt).unwrap();
            if collection_name == target_collection {
                result.push(alias);
            }
        }
        Ok(result)
    }
/// List of all aliases for a given collection
List of all aliases for a given collection
List of all aliases for a given collection
pub fn collection_aliases(&self, collection_name: &str) -> Result<Vec<String>, StorageError> {
        let mut result = vec![];
        for pair in self.alias_persistence.iter() {
            let (alias_bt, target_collection_bt) = pair?;
            let alias = from_utf8(&alias_bt).unwrap().to_string();
            let target_collection = from_utf8(&target_collection_bt).unwrap();
            if collection_name == target_collection {
                result.push(alias);
            }
        }
        Ok(result)
    }
pub fn collection_aliases ( & self , collection_name : & str ) -> Result < Vec < String > , StorageError > { let mut result = vec ! [ ] ; for pair in self . alias_persistence . iter ( ) { let ( alias_bt , target_collection_bt ) = pair ? ; let alias = from_utf8 ( & alias_bt ) . unwrap ( ) . to_string ( ) ; let target_collection = from_utf8 ( & target_collection_bt ) . unwrap ( ) ; if collection_name == target_collection { result . push ( alias ) ; } } Ok ( result ) }
List of all aliases for a given collection
List of all aliases for a given collection
&self
collection_name
&str
&self
collection_name
&str