-
-
Save maurer/5369c9e7c313ecbefc25007212f3053e to your computer and use it in GitHub Desktop.
Rust code shared from the playground
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/// Retrieve a list of new files to be copied to the DMS. | |
pub fn added_files<'a>(local: &'a BTreeSet<LibraryFile>, dms: &'a BTreeSet<LibraryFile>) -> | |
Vec<&'a LibraryFile> { | |
local.difference(dms).collect() | |
} | |
/// Retrieve a list of new files to be copied to the DMS. | |
pub fn added_files<'a>(local: &'a BTreeSet<LibraryFile>, dms: &'a BTreeSet<LibraryFile>) -> | |
Box<Iterator<Item=&'a LibraryFile>> { | |
Box::new(local.difference(dms)) as Box<Iterator<Item=&'a LibraryFile>> | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment