Package org.osgi.resource
Interface Wire
-
- All Known Subinterfaces:
BundleWire
- All Known Implementing Classes:
BundleWireImpl
@ConsumerType public interface Wire
A wire connecting aCapability
to aRequirement
.Instances of this type must be effectively immutable. That is, for a given instance of this interface, the methods defined by this interface must always return the same result.
- Author:
- $Id: 6c248ea2b9b24f3610a14e5e8deec9cd0b7aa1c9 $
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description boolean
equals(java.lang.Object obj)
Compares thisWire
to anotherWire
.Capability
getCapability()
Returns theCapability
for this wire.Resource
getProvider()
Returns the resource providing thecapability
.Requirement
getRequirement()
Returns theRequirement
for this wire.Resource
getRequirer()
Returns the resource whorequires
thecapability
.int
hashCode()
Returns the hashCode of thisWire
.
-
-
-
Method Detail
-
getCapability
Capability getCapability()
Returns theCapability
for this wire.- Returns:
- The
Capability
for this wire.
-
getRequirement
Requirement getRequirement()
Returns theRequirement
for this wire.- Returns:
- The
Requirement
for this wire.
-
getProvider
Resource getProvider()
Returns the resource providing thecapability
.The returned resource may differ from the resource referenced by the
capability
.- Returns:
- The resource providing the capability.
-
getRequirer
Resource getRequirer()
Returns the resource whorequires
thecapability
.The returned resource may differ from the resource referenced by the
requirement
.- Returns:
- The resource who requires the capability.
-
equals
boolean equals(java.lang.Object obj)
Compares thisWire
to anotherWire
.This
Wire
is equal to anotherWire
if they have the same capability, requirement, provider and requirer.- Overrides:
equals
in classjava.lang.Object
- Parameters:
obj
- The object to compare against thisWire
.- Returns:
true
if thisWire
is equal to the other object;false
otherwise.
-
hashCode
int hashCode()
Returns the hashCode of thisWire
.- Overrides:
hashCode
in classjava.lang.Object
- Returns:
- The hashCode of this
Wire
.
-
-