public final class UpdateVterminalTask extends UpdateVirtualNodeTask<Vterminal,VterminalConfig,VTerminalIdentifier> implements RpcOutputGenerator<VtnUpdateType,UpdateVterminalOutput>
UpdateVterminalTask
describes the MD-SAL datastore transaction task
that creates or updates the specified vTerminal.
a * @see #create(UpdateVterminalInput)Modifier and Type | Method and Description |
---|---|
protected void |
checkParent(TxContext ctx)
Ensure that the parent VTN is present.
|
protected void |
create(TxContext ctx,
VTerminalIdentifier ident,
VterminalConfig cfg)
Create a new vTerminal.
|
static UpdateVterminalTask |
create(UpdateVterminalInput input)
Construct a new task that creates or updates the specified vTerminal.
|
protected VterminalConfig |
createConfig()
Create a new vTerminal configuration as specified by the RPC.
|
UpdateVterminalOutput |
createOutput(VtnUpdateType result)
Generate the output of the RPC request.
|
protected boolean |
equalsConfig(VterminalConfig cur,
VterminalConfig cfg)
Determine whether the given two vTerminal configurations are identical
or not.
|
protected VterminalConfig |
getConfig(Vterminal vnode)
Return the vTerminal configuration in the given vTerminal.
|
protected org.opendaylight.yangtools.yang.binding.InstanceIdentifier<VterminalConfig> |
getConfigPath(VTerminalIdentifier ident)
Return the instance identifier for the configuration container in the
target vTerminal.
|
Class<UpdateVterminalOutput> |
getOutputType()
Return a class which indicates the type of the RPC output.
|
protected VterminalConfig |
mergeConfig(VterminalConfig cur)
Merge the vTerminal configuration specified by the RPC with the current
configuration.
|
execute, getIdentifier, onUpdated
needErrorLog
addBackgroundTask, execute, getBackgroundTasks, getMaxRetry, onFailure, onSuccess
public static UpdateVterminalTask create(UpdateVterminalInput input) throws RpcException
input
- A UpdateVterminalInput
instance.UpdateVterminalTask
instance associated with the task
that creates or updates the specified vTerminal.RpcException
- The given input contains invalid value.protected void checkParent(TxContext ctx) throws VTNException
checkParent
in class UpdateVirtualNodeTask<Vterminal,VterminalConfig,VTerminalIdentifier>
ctx
- A runtime context for transaction task.VTNException
- An error occurred.protected VterminalConfig createConfig() throws RpcException
createConfig
in class UpdateVirtualNodeTask<Vterminal,VterminalConfig,VTerminalIdentifier>
VterminalConfig
instance.RpcException
- The configuration specified by the RPC is invalid.protected VterminalConfig mergeConfig(VterminalConfig cur)
mergeConfig
in class UpdateVirtualNodeTask<Vterminal,VterminalConfig,VTerminalIdentifier>
cur
- The current configuration of the target vTerminal.VterminalConfig
instance.protected VterminalConfig getConfig(Vterminal vnode)
getConfig
in class UpdateVirtualNodeTask<Vterminal,VterminalConfig,VTerminalIdentifier>
vnode
- The vTerminal container.protected org.opendaylight.yangtools.yang.binding.InstanceIdentifier<VterminalConfig> getConfigPath(VTerminalIdentifier ident)
getConfigPath
in class UpdateVirtualNodeTask<Vterminal,VterminalConfig,VTerminalIdentifier>
ident
- The identifier for the target vTerminal.protected boolean equalsConfig(VterminalConfig cur, VterminalConfig cfg)
equalsConfig
in class UpdateVirtualNodeTask<Vterminal,VterminalConfig,VTerminalIdentifier>
cur
- The current configuration.cfg
- The configuration that is going to be applied.true
only if the given two configurations are
identical.protected void create(TxContext ctx, VTerminalIdentifier ident, VterminalConfig cfg) throws VTNException
create
in class UpdateVirtualNodeTask<Vterminal,VterminalConfig,VTerminalIdentifier>
ctx
- A runtime context for transaction task.ident
- The identifier for the new vTerminal.cfg
- The configuration for the new vTerminal.VTNException
- An error occurred.public Class<UpdateVterminalOutput> getOutputType()
getOutputType
in interface RpcOutputGenerator<VtnUpdateType,UpdateVterminalOutput>
public UpdateVterminalOutput createOutput(VtnUpdateType result)
createOutput
in interface RpcOutputGenerator<VtnUpdateType,UpdateVterminalOutput>
result
- The result of the RPC main procedure.Copyright © 2018 OpenDaylight. All rights reserved.