[Merge] lp:~mardy/location-service/providers-dir into lp:location-service
Thomas Voß
thomas.voss at canonical.com
Fri Dec 18 15:48:59 UTC 2015
> Thanks Thomas for the review.
>
> I just want to clarify a couple of things about the FilesystemProviderLoader:
> why I have the base_dir parameter on the load_providers() method and why it's
> stateful (the instantiated providers set).
>
> The point is that it needs to load provider manifests from several directories
> (/usr/share/location/providers and ~/.local/share/location/providers, at
> least) and at the same time there's an override mechanism so that the
> manifests defined by the user can override the system ones (as per the
> description).
@stateful: I get why you maintain the set, but that could just be scoped to the function itself iiuc.
> So, I think we have three possibilities:
> 1) keep it as is
> 2) do as you suggested, but then the constructor needs to take a
> std::vector<fs::path>, not just a single path
I think this one is the best way forward, I originally made that proposal in an inline comment:
"This should take const std::set<boost::filesystem::path>& base_dir at construction time."
The joys of the laucnhpad review UI then :)
> 3) no paths visible in the FilesystemProviderLoader API, handle everything
> internally
--
https://code.launchpad.net/~mardy/location-service/providers-dir/+merge/280724
Your team Ubuntu Phablet Team is subscribed to branch lp:location-service.
More information about the Ubuntu-reviews
mailing list