Class ComponentContextBuilder
java.lang.Object
org.apache.sling.testing.mock.osgi.ComponentContextBuilder
Builds a mocked
ComponentContext.-
Method Summary
Modifier and TypeMethodDescription@NotNull org.osgi.service.component.ComponentContextbuild()@NotNull ComponentContextBuilderbundleContext(@NotNull org.osgi.framework.BundleContext bundleContext) @NotNull ComponentContextBuilderproperties(@NotNull Object @NotNull ... properties) @NotNull ComponentContextBuilderproperties(@Nullable Dictionary<String, Object> properties) @NotNull ComponentContextBuilderproperties(@Nullable Map<String, Object> properties) @NotNull ComponentContextBuilderusingBundle(@NotNull org.osgi.framework.Bundle usingBundle)
-
Method Details
-
bundleContext
@NotNull public @NotNull ComponentContextBuilder bundleContext(@NotNull @NotNull org.osgi.framework.BundleContext bundleContext) -
properties
@NotNull public @NotNull ComponentContextBuilder properties(@Nullable @Nullable Dictionary<String, Object> properties) -
properties
@NotNull public @NotNull ComponentContextBuilder properties(@Nullable @Nullable Map<String, Object> properties) -
properties
@NotNull public @NotNull ComponentContextBuilder properties(@NotNull @NotNull Object @NotNull ... properties) -
usingBundle
@NotNull public @NotNull ComponentContextBuilder usingBundle(@NotNull @NotNull org.osgi.framework.Bundle usingBundle) -
build
@NotNull public @NotNull org.osgi.service.component.ComponentContext build()
-