Package io.atomix.cluster
Class MulticastConfig
java.lang.Object
io.atomix.cluster.MulticastConfig
- All Implemented Interfaces:
io.atomix.utils.config.Config
public class MulticastConfig extends Object implements io.atomix.utils.config.Config
Multicast configuration.
-
Constructor Summary
Constructors Constructor Description MulticastConfig() -
Method Summary
Modifier and Type Method Description InetAddressgetGroup()Returns the multicast group.intgetPort()Returns the multicast port.booleanisEnabled()Returns whether multicast is enabled.MulticastConfigsetEnabled(boolean enabled)Sets whether multicast is enabled.MulticastConfigsetGroup(String group)Sets the multicast group.MulticastConfigsetGroup(InetAddress group)Sets the multicast group.MulticastConfigsetPort(int port)Sets the multicast port.
-
Constructor Details
-
MulticastConfig
public MulticastConfig()
-
-
Method Details
-
isEnabled
public boolean isEnabled()Returns whether multicast is enabled.- Returns:
- whether multicast is enabled
-
setEnabled
Sets whether multicast is enabled.- Parameters:
enabled- whether multicast is enabled- Returns:
- the multicast configuration
-
getGroup
Returns the multicast group.- Returns:
- the multicast group
-
setGroup
Sets the multicast group.- Parameters:
group- the multicast group- Returns:
- the multicast configuration
- Throws:
io.atomix.utils.config.ConfigurationException- if the group is invalid
-
setGroup
Sets the multicast group.- Parameters:
group- the multicast group- Returns:
- the multicast configuration
-
getPort
public int getPort()Returns the multicast port.- Returns:
- the multicast port
-
setPort
Sets the multicast port.- Parameters:
port- the multicast port- Returns:
- the multicast configuration
-