| 154 | } |
| 155 | |
| 156 | std::vector<Bundle> |
| 157 | BundleContext::GetBundles(std::string const& location) const |
| 158 | { |
| 159 | if (!d) |
| 160 | { |
| 161 | throw cppmicroservices::IllegalStateException("The bundle context is no longer valid"); |
| 162 | } |
| 163 | |
| 164 | d->CheckValid(); |
| 165 | auto b = GetAndCheckBundlePrivate(d); |
| 166 | |
| 167 | std::vector<Bundle> res; |
| 168 | for (auto bu : b->coreCtx->bundleRegistry.GetBundles(location)) |
| 169 | { |
| 170 | res.emplace_back(MakeBundle(bu)); |
| 171 | } |
| 172 | return res; |
| 173 | } |
| 174 | |
| 175 | std::vector<Bundle> |
| 176 | BundleContext::GetBundles() const |