public final class MoveChannelCommand extends ArchiveConfigurationCommand
ArchiveConfigurationService
, but it might also be
sent over the network before actually being processed.ArchiveConfigurationCommand.Type
Constructor and Description |
---|
MoveChannelCommand(String channelName,
UUID expectedOldServerId,
UUID newServerId)
Creates a "move channel" command.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object obj) |
String |
getChannelName()
Returns the name of the channel that shall be moved.
|
ArchiveConfigurationCommand.Type |
getCommandType()
Returns the type of the actual command type.
|
UUID |
getExpectedOldServerId()
Returns the ID of the server which is expected to currently own the
channel.
|
UUID |
getNewServerId()
Returns the ID of the server to which the channel shall be moved.
|
int |
hashCode() |
String |
toString() |
public MoveChannelCommand(String channelName, UUID expectedOldServerId, UUID newServerId)
expectedOldServerId
does not match the actual ID of the
server that currently owns the channel, the operation will fail.channelName
- name of the channel to be moved.expectedOldServerId
- if not null
, the channel is only moved if it is
currently registered with the specified server.newServerId
- ID of the server to which the channel shall be moved.IllegalArgumentException
- if channelName
is empty.NullPointerException
- if channelName
or newServerId
is
null
.public ArchiveConfigurationCommand.Type getCommandType()
ArchiveConfigurationCommand
ArchiveConfigurationCommand
class or the ArchiveConfigurationCommand.Type
enum
for a list of types. The return value is never null
.getCommandType
in class ArchiveConfigurationCommand
public String getChannelName()
null
or the empty string.public UUID getNewServerId()
null
.public UUID getExpectedOldServerId()
null
the channel will be moved to the new server
regardless of which server currently owns the channel. If not
null
, the move operation will fail if the channel is
currently registered with a different server than the specified one.null
if the channel should be moved regardless of
the server that currently owns the channel.Copyright © 2011–2017 aquenos GmbH. All rights reserved.