Class DefaultForwardingObjective
- java.lang.Object
-
- org.onosproject.net.AbstractAnnotated
-
- org.onosproject.net.flowobjective.DefaultForwardingObjective
-
- All Implemented Interfaces:
Annotated,ForwardingObjective,Objective
@Beta public final class DefaultForwardingObjective extends AbstractAnnotated implements ForwardingObjective
Default implementation of a forwarding objective.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classDefaultForwardingObjective.Builder-
Nested classes/interfaces inherited from interface org.onosproject.net.flowobjective.ForwardingObjective
ForwardingObjective.Flag
-
Nested classes/interfaces inherited from interface org.onosproject.net.flowobjective.Objective
Objective.Operation
-
-
Field Summary
-
Fields inherited from interface org.onosproject.net.flowobjective.Objective
DEFAULT_PERMANENT, DEFAULT_PRIORITY, DEFAULT_TIMEOUT, MAX_PRIORITY, MIN_PRIORITY
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description ApplicationIdappId()The application which applied this objective.static DefaultForwardingObjective.Builderbuilder()Returns a new builder.static DefaultForwardingObjective.Builderbuilder(ForwardingObjective fwd)Returns a new builder primed to produce entities patterned after the supplied forwarding objective.Optional<ObjectiveContext>context()Obtains an optional context.DefaultForwardingObjective.Buildercopy()Returns a new builder set to create a copy of this objective.booleanequals(Object obj)ForwardingObjective.Flagflag()Obtain the type of this objective.inthashCode()intid()An identifier for this objective.TrafficSelectormeta()Auxiliary optional information provided to the device driver.IntegernextId()Obtain the traffic treatment for this objective.Objective.Operationop()The type of operation for this objective.booleanpermanent()Whether this objective is permanent.intpriority()The priority for this objective.TrafficSelectorselector()Obtain the selector for this objective.inttimeout()The timeout for this objective.StringtoString()TrafficTreatmenttreatment()A traffic treatment for this forwarding objective.-
Methods inherited from class org.onosproject.net.AbstractAnnotated
annotations
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.onosproject.net.Annotated
annotations
-
-
-
-
Method Detail
-
selector
public TrafficSelector selector()
Description copied from interface:ForwardingObjectiveObtain the selector for this objective.- Specified by:
selectorin interfaceForwardingObjective- Returns:
- a traffic selector
-
nextId
public Integer nextId()
Description copied from interface:ForwardingObjectiveObtain the traffic treatment for this objective. Mutually exclusive with 'treatment'.- Specified by:
nextIdin interfaceForwardingObjective- Returns:
- an integer
-
treatment
public TrafficTreatment treatment()
Description copied from interface:ForwardingObjectiveA traffic treatment for this forwarding objective. Mutually exclusive with a nextId.- Specified by:
treatmentin interfaceForwardingObjective- Returns:
- a traffic treatment
-
flag
public ForwardingObjective.Flag flag()
Description copied from interface:ForwardingObjectiveObtain the type of this objective.- Specified by:
flagin interfaceForwardingObjective- Returns:
- a flag type
-
id
public int id()
Description copied from interface:ObjectiveAn identifier for this objective.
-
priority
public int priority()
Description copied from interface:ObjectiveThe priority for this objective.
-
appId
public ApplicationId appId()
Description copied from interface:ObjectiveThe application which applied this objective.
-
timeout
public int timeout()
Description copied from interface:ObjectiveThe timeout for this objective.
-
permanent
public boolean permanent()
Description copied from interface:ObjectiveWhether this objective is permanent.
-
op
public Objective.Operation op()
Description copied from interface:ObjectiveThe type of operation for this objective.
-
context
public Optional<ObjectiveContext> context()
Description copied from interface:ObjectiveObtains an optional context.
-
meta
public TrafficSelector meta()
Description copied from interface:ForwardingObjectiveAuxiliary optional information provided to the device driver. Typically conveys information about selectors (matches) that are intended to use this Forwarding Objective.- Specified by:
metain interfaceForwardingObjective- Returns:
- a selector intended to pass meta information to the device driver. Value may be null if no meta information is provided.
-
builder
public static DefaultForwardingObjective.Builder builder()
Returns a new builder.- Returns:
- new builder
-
builder
public static DefaultForwardingObjective.Builder builder(ForwardingObjective fwd)
Returns a new builder primed to produce entities patterned after the supplied forwarding objective.- Parameters:
fwd- base fwd- Returns:
- forwarding objective builder
-
copy
public DefaultForwardingObjective.Builder copy()
Description copied from interface:ForwardingObjectiveReturns a new builder set to create a copy of this objective.- Specified by:
copyin interfaceForwardingObjective- Specified by:
copyin interfaceObjective- Returns:
- new builder
-
-