Class DefaultNextObjective.Builder
- java.lang.Object
-
- org.onosproject.net.flowobjective.DefaultNextObjective.Builder
-
- All Implemented Interfaces:
NextObjective.Builder,Objective.Builder
- Enclosing class:
- DefaultNextObjective
public static final class DefaultNextObjective.Builder extends Object implements NextObjective.Builder
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description NextObjectiveadd()Builds the next objective that will be added.NextObjectiveadd(ObjectiveContext context)Builds the next objective that will be added.NextObjectiveaddToExisting()Build the next objective that will be added, withObjective.OperationADD_TO_EXISTING.NextObjectiveaddToExisting(ObjectiveContext context)Builds the next objective that will be added, withObjective.OperationADD_TO_EXISTING.DefaultNextObjective.BuilderaddTreatment(TrafficTreatment treatment)Adds a treatment to this next step.DefaultNextObjective.BuilderaddTreatment(NextTreatment nextTreatment)Adds a next treatment to this next step.DefaultNextObjective.BuilderfromApp(ApplicationId appId)Specifies the application which applied the filter.DefaultNextObjective.BuildermakePermanent()Noop.DefaultNextObjective.BuildermakeTemporary(int timeout)Noop.NextObjectivemodify()Build the next objective that will be modified withObjective.OperationMODIFY.NextObjectivemodify(ObjectiveContext context)Build the next objective that will be modified, withObjective.OperationMODIFY.NextObjectiveremove()Builds the next objective that will be removed.NextObjectiveremove(ObjectiveContext context)Builds the next objective that will be removed.NextObjectiveremoveFromExisting()Build the next objective that will be removed, withObjective.OperationREMOVE_FROM_EXISTING.NextObjectiveremoveFromExisting(ObjectiveContext context)Builds the next objective that will be removed, withObjective.OperationREMOVE_FROM_EXISTING.NextObjectiveverify()Builds the next objective that needs to be verified.NextObjectiveverify(ObjectiveContext context)Builds the next objective that needs to be verified.DefaultNextObjective.BuilderwithId(int nextId)Specifies the id for this next objective.DefaultNextObjective.BuilderwithMeta(TrafficSelector meta)Set meta information related to this next objective.DefaultNextObjective.BuilderwithPriority(int priority)Noop.DefaultNextObjective.BuilderwithType(NextObjective.Type type)Sets the type of next step.
-
-
-
Method Detail
-
withId
public DefaultNextObjective.Builder withId(int nextId)
Description copied from interface:NextObjective.BuilderSpecifies the id for this next objective.- Specified by:
withIdin interfaceNextObjective.Builder- Parameters:
nextId- an integer- Returns:
- a next objective builder
-
withType
public DefaultNextObjective.Builder withType(NextObjective.Type type)
Description copied from interface:NextObjective.BuilderSets the type of next step.- Specified by:
withTypein interfaceNextObjective.Builder- Parameters:
type- a type- Returns:
- a next step builder
-
addTreatment
public DefaultNextObjective.Builder addTreatment(TrafficTreatment treatment)
Description copied from interface:NextObjective.BuilderAdds a treatment to this next step.- Specified by:
addTreatmentin interfaceNextObjective.Builder- Parameters:
treatment- a traffic treatment- Returns:
- a next step builder
-
addTreatment
public DefaultNextObjective.Builder addTreatment(NextTreatment nextTreatment)
Description copied from interface:NextObjective.BuilderAdds a next treatment to this next step.- Specified by:
addTreatmentin interfaceNextObjective.Builder- Parameters:
nextTreatment- a next treatment- Returns:
- a next step builder
-
makeTemporary
public DefaultNextObjective.Builder makeTemporary(int timeout)
Noop. This method has no effect.- Specified by:
makeTemporaryin interfaceObjective.Builder- Parameters:
timeout- a timeout- Returns:
- a next objective builder
-
makePermanent
public DefaultNextObjective.Builder makePermanent()
Noop. This method has no effect.- Specified by:
makePermanentin interfaceObjective.Builder- Returns:
- a next objective builder
-
fromApp
public DefaultNextObjective.Builder fromApp(ApplicationId appId)
Description copied from interface:NextObjective.BuilderSpecifies the application which applied the filter.- Specified by:
fromAppin interfaceNextObjective.Builder- Specified by:
fromAppin interfaceObjective.Builder- Parameters:
appId- an application id- Returns:
- an objective builder
-
withPriority
public DefaultNextObjective.Builder withPriority(int priority)
Noop. This method has no effect.- Specified by:
withPriorityin interfaceNextObjective.Builder- Specified by:
withPriorityin interfaceObjective.Builder- Parameters:
priority- an integer- Returns:
- a next objective builder
-
withMeta
public DefaultNextObjective.Builder withMeta(TrafficSelector meta)
Description copied from interface:NextObjective.BuilderSet meta information related to this next objective.- Specified by:
withMetain interfaceNextObjective.Builder- Parameters:
meta- match conditions- Returns:
- an objective builder
-
add
public NextObjective add()
Description copied from interface:NextObjective.BuilderBuilds the next objective that will be added.- Specified by:
addin interfaceNextObjective.Builder- Specified by:
addin interfaceObjective.Builder- Returns:
- a next objective
-
remove
public NextObjective remove()
Description copied from interface:NextObjective.BuilderBuilds the next objective that will be removed.- Specified by:
removein interfaceNextObjective.Builder- Specified by:
removein interfaceObjective.Builder- Returns:
- a next objective.
-
add
public NextObjective add(ObjectiveContext context)
Description copied from interface:NextObjective.BuilderBuilds the next objective that will be added. The context will be used to notify the calling application.- Specified by:
addin interfaceNextObjective.Builder- Specified by:
addin interfaceObjective.Builder- Parameters:
context- an objective context- Returns:
- a next objective
-
remove
public NextObjective remove(ObjectiveContext context)
Description copied from interface:NextObjective.BuilderBuilds the next objective that will be removed. The context will be used to notify the calling application.- Specified by:
removein interfaceNextObjective.Builder- Specified by:
removein interfaceObjective.Builder- Parameters:
context- an objective context- Returns:
- a next objective
-
addToExisting
public NextObjective addToExisting()
Description copied from interface:NextObjective.BuilderBuild the next objective that will be added, withObjective.OperationADD_TO_EXISTING.- Specified by:
addToExistingin interfaceNextObjective.Builder- Returns:
- a next objective
-
removeFromExisting
public NextObjective removeFromExisting()
Description copied from interface:NextObjective.BuilderBuild the next objective that will be removed, withObjective.OperationREMOVE_FROM_EXISTING.- Specified by:
removeFromExistingin interfaceNextObjective.Builder- Returns:
- a next objective
-
addToExisting
public NextObjective addToExisting(ObjectiveContext context)
Description copied from interface:NextObjective.BuilderBuilds the next objective that will be added, withObjective.OperationADD_TO_EXISTING. The context will be used to notify the calling application.- Specified by:
addToExistingin interfaceNextObjective.Builder- Parameters:
context- an objective context- Returns:
- a next objective
-
removeFromExisting
public NextObjective removeFromExisting(ObjectiveContext context)
Description copied from interface:NextObjective.BuilderBuilds the next objective that will be removed, withObjective.OperationREMOVE_FROM_EXISTING. The context will be used to notify the calling application.- Specified by:
removeFromExistingin interfaceNextObjective.Builder- Parameters:
context- an objective context- Returns:
- a next objective
-
modify
public NextObjective modify()
Description copied from interface:NextObjective.BuilderBuild the next objective that will be modified withObjective.OperationMODIFY.- Specified by:
modifyin interfaceNextObjective.Builder- Returns:
- a next objective
-
modify
public NextObjective modify(ObjectiveContext context)
Description copied from interface:NextObjective.BuilderBuild the next objective that will be modified, withObjective.OperationMODIFY. The context will be used to notify the calling application.- Specified by:
modifyin interfaceNextObjective.Builder- Parameters:
context- an objective context- Returns:
- a next objective
-
verify
public NextObjective verify()
Description copied from interface:NextObjective.BuilderBuilds the next objective that needs to be verified.- Specified by:
verifyin interfaceNextObjective.Builder- Returns:
- a next objective with
Objective.OperationVERIFY
-
verify
public NextObjective verify(ObjectiveContext context)
Description copied from interface:NextObjective.BuilderBuilds the next objective that needs to be verified. The context will be used to notify the calling application.- Specified by:
verifyin interfaceNextObjective.Builder- Parameters:
context- an objective context- Returns:
- a next objective with
Objective.OperationVERIFY
-
-