Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Convert from List to Set to speed up contains() logic. #2354

Merged
merged 2 commits into from
Aug 22, 2018

Commits on Aug 8, 2018

  1. Convert from List to Set to speed up contains() logic.

    Using a List here results in extremely long runtimes when the source
    folder is large because the contains() call is O(n). The logic
    ends up placing this List into a Set anyway so just use a Set here
    and make contains() checks cheap.
    Christopher Stokes committed Aug 8, 2018
    Configuration menu
    Copy the full SHA
    501b8c2 View commit details
    Browse the repository at this point in the history

Commits on Aug 9, 2018

  1. Just return a List.

    Folders are never added to VirtualFolder's file field (just files)
    so we can just return the file contents as a List. files is a Set
    so deduplication has already been done.
    Christopher Stokes committed Aug 9, 2018
    Configuration menu
    Copy the full SHA
    0b0b37a View commit details
    Browse the repository at this point in the history