Skip to content
Permalink
Browse files

[WFCORE-4392] Documenting CapabilityServiceTarget methods

  • Loading branch information
ropalka committed Mar 28, 2019
1 parent d06db73 commit 6796bfd2a44344e540fec99b67c2478bbd363381
Showing with 15 additions and 1 deletion.
  1. +15 −1 controller/src/main/java/org/jboss/as/controller/CapabilityServiceTarget.java
@@ -22,7 +22,8 @@
import org.jboss.msc.service.Service;
import org.jboss.msc.service.ServiceTarget;

/**The target of ServiceBuilder for capabilities installations.
/**
* The target of ServiceBuilder for capability installations.
* CapabilityServiceBuilder to be installed on a target should be retrieved by calling one of the {@code addCapability} methods.
* Notice that installation will only take place after {@link CapabilityServiceBuilder#install()} is invoked.
* CapabilityServiceBuilder that are not installed are ignored.
@@ -33,11 +34,24 @@
public interface CapabilityServiceTarget extends ServiceTarget {

/**
* Gets a builder which can be used to add a capability service into this capability target.
*
* @param capability the capability to be installed
* @param service the service implementing this capability
* @return new capability builder instance
* @throws IllegalArgumentException if capability does not provide a service
* @deprecated use {@link #addCapability(RuntimeCapability)} method instead
*/
@Deprecated
<T> CapabilityServiceBuilder<T> addCapability(final RuntimeCapability<?> capability, final Service<T> service) throws IllegalArgumentException;

/**
* Gets a builder which can be used to add a capability service into this capability target.
*
* @param capability the capability to be installed
* @return new capability builder instance
* @throws IllegalArgumentException if capability does not provide a service
*/
CapabilityServiceBuilder<?> addCapability(final RuntimeCapability<?> capability) throws IllegalArgumentException;

}

0 comments on commit 6796bfd

Please sign in to comment.
You can’t perform that action at this time.