Package com._1c.g5.wiring
Interface IServiceRegistrationBuilder<T>
-
- Type Parameters:
T
- the registering service type
- All Known Subinterfaces:
IInjectorAwareManagedServiceRegistrationBuilder<T>
,IInjectorAwareServiceRegistrationBuilder<T>
,IManagedServiceRegistrationBuilder<T>
public interface IServiceRegistrationBuilder<T>
OSGi service registration builder. Provides fluent API to configure and register OSGi service.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
registerInstance(T instance)
Register the given instance to the builder service interface.IServiceRegistrationBuilder<T>
withProperties(Map<String,?> properties)
Associate the given properties map with registering service.IServiceRegistrationBuilder<T>
withProperty(String key, Object value)
Associate the given property with registering service.
-
-
-
Method Detail
-
withProperty
IServiceRegistrationBuilder<T> withProperty(String key, Object value)
Associate the given property with registering service. All builded properties will be combined.- Parameters:
key
- the propertyString
key, cannot benull
value
- the property value, cannot benull
- Returns:
- a reference to this builder, never
null
-
withProperties
IServiceRegistrationBuilder<T> withProperties(Map<String,?> properties)
Associate the given properties map with registering service. All builded properties will be combined.- Parameters:
properties
- the properties map, cannot benull
- Returns:
- a reference to this builder, never
null
-
registerInstance
void registerInstance(T instance)
Register the given instance to the builder service interface.- Parameters:
instance
- the instance of service to register, cannot benull
-
-