Class OmsPortMapper
- java.lang.Object
-
- org.onosproject.net.optical.device.port.AbstractPortMapper<OmsPort>
-
- org.onosproject.net.optical.device.port.OmsPortMapper
-
- All Implemented Interfaces:
PortMapper<OmsPort>
@Beta public class OmsPortMapper extends AbstractPortMapper<OmsPort>
PortMapperto handlerOmsPorttranslation.
-
-
Constructor Summary
Constructors Constructor Description OmsPortMapper()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.Optional<OmsPort>as(org.onosproject.net.Port port)Returnsportmapped to<P>.booleanis(org.onosproject.net.Port port)Returns true if this port is capable of being projected as<P>.protected java.util.Optional<OmsPort>mapPort(org.onosproject.net.Port port)Returnsportmapped to<P>.
-
-
-
Method Detail
-
is
public boolean is(org.onosproject.net.Port port)
Description copied from class:AbstractPortMapperReturns true if this port is capable of being projected as<P>.Note: Subclasses should override and implement short-cut conditions and call
super.is(port).- Specified by:
isin interfacePortMapper<OmsPort>- Overrides:
isin classAbstractPortMapper<OmsPort>- Parameters:
port- port- Returns:
- true if this port can be projected as the given type
-
as
public java.util.Optional<OmsPort> as(org.onosproject.net.Port port)
Description copied from class:AbstractPortMapperReturnsportmapped to<P>.Note: Subclasses should override and check if
portis already of typePand directly returnOptional.of((P) port), if not callsuper.as(port).- Specified by:
asin interfacePortMapper<OmsPort>- Overrides:
asin classAbstractPortMapper<OmsPort>- Parameters:
port- Port to map- Returns:
portmapped to<P>
-
mapPort
protected java.util.Optional<OmsPort> mapPort(org.onosproject.net.Port port)
Description copied from class:AbstractPortMapperReturnsportmapped to<P>.- Specified by:
mapPortin classAbstractPortMapper<OmsPort>- Parameters:
port- Port to map- Returns:
portmapped to<P>
-
-