alvinalexander.com | career | drupal | java | mac | mysql | perl | scala | uml | unix  
* </tr> * <td>{@link ChannelOption#SO_BROADCAST} * </tr> * <td>{@link ChannelOption#IP_MULTICAST_ADDR} * </tr> * <td>{@link ChannelOption#IP_MULTICAST_LOOP_DISABLED} * <td>{@link #setLoopbackModeDisabled(boolean)} * </tr> * <td>{@link ChannelOption#IP_MULTICAST_IF} * <td>{@link #setNetworkInterface(NetworkInterface)} * </tr> * <td>{@link ChannelOption#SO_REUSEADDR} * </tr> * <td>{@link ChannelOption#SO_RCVBUF} * </tr> * <td>{@link ChannelOption#SO_SNDBUF} * </tr> * <td>{@link ChannelOption#IP_MULTICAST_TTL} * </tr> * <td>{@link ChannelOption#IP_TOS} * </tr> * </table> */ public interface DatagramChannelConfig extends ChannelConfig { /** * Gets the {@link StandardSocketOptions#SO_SNDBUF} option. */ int getSendBufferSize(); /** * Sets the {@link StandardSocketOptions#SO_SNDBUF} option. */ DatagramChannelConfig setSendBufferSize(int sendBufferSize); /** * Gets the {@link StandardSocketOptions#SO_RCVBUF} option. */ int getReceiveBufferSize(); /** * Sets the {@link StandardSocketOptions#SO_RCVBUF} option. */ DatagramChannelConfig setReceiveBufferSize(int receiveBufferSize); /** * Gets the {@link StandardSocketOptions#IP_TOS} option. */ int getTrafficClass(); /** * Sets the {@link StandardSocketOptions#IP_TOS} option. */ DatagramChannelConfig setTrafficClass(int trafficClass); /** * Gets the {@link StandardSocketOptions#SO_REUSEADDR} option. */ boolean isReuseAddress(); /** * Gets the {@link StandardSocketOptions#SO_REUSEADDR} option. */ DatagramChannelConfig setReuseAddress(boolean reuseAddress); /** * Gets the {@link StandardSocketOptions#SO_BROADCAST} option. */ boolean isBroadcast(); /** * Sets the {@link StandardSocketOptions#SO_BROADCAST} option. */ DatagramChannelConfig setBroadcast(boolean broadcast); /** * Gets the {@link StandardSocketOptions#IP_MULTICAST_LOOP} option. * * @return {@code true} if and only if the loopback mode has been disabled */ boolean isLoopbackModeDisabled(); /** * Sets the {@link StandardSocketOptions#IP_MULTICAST_LOOP} option. * * @param loopbackModeDisabled * {@code true} if and only if the loopback mode has been disabled */ DatagramChannelConfig setLoopbackModeDisabled(boolean loopbackModeDisabled); /** * Gets the {@link StandardSocketOptions#IP_MULTICAST_TTL} option. */ int getTimeToLive(); /** * Sets the {@link StandardSocketOptions#IP_MULTICAST_TTL} option. */ DatagramChannelConfig setTimeToLive(int ttl); /** * Gets the address of the network interface used for multicast packets. */ InetAddress getInterface(); /** * Sets the address of the network interface used for multicast packets. */ DatagramChannelConfig setInterface(InetAddress interfaceAddress); /** * Gets the {@link StandardSocketOptions#IP_MULTICAST_IF} option. */ NetworkInterface getNetworkInterface(); /** * Sets the {@link StandardSocketOptions#IP_MULTICAST_IF} option. */ DatagramChannelConfig setNetworkInterface(NetworkInterface networkInterface); @Override @Deprecated DatagramChannelConfig setMaxMessagesPerRead(int maxMessagesPerRead); @Override DatagramChannelConfig setWriteSpinCount(int writeSpinCount); @Override DatagramChannelConfig setConnectTimeoutMillis(int connectTimeoutMillis); @Override DatagramChannelConfig setAllocator(ByteBufAllocator allocator); @Override DatagramChannelConfig setRecvByteBufAllocator(RecvByteBufAllocator allocator); @Override DatagramChannelConfig setAutoRead(boolean autoRead); @Override DatagramChannelConfig setAutoClose(boolean autoClose); @Override DatagramChannelConfig setMessageSizeEstimator(MessageSizeEstimator estimator); @Override DatagramChannelConfig setWriteBufferWaterMark(WriteBufferWaterMark writeBufferWaterMark); }

Other Java examples (source code examples)

Here is a short list of links related to this Java DatagramChannelConfig.java source code file:

Java example source code file (DatagramChannelConfig.java)

This example Java source code file (DatagramChannelConfig.java) is included in the alvinalexander.com "Java Source Code Warehouse" project. The intent of this project is to help you "Learn Java by Example" TM.

Learn more about this Java project at its project page.

Java - Java tags/keywords

datagramchannelconfig, deprecated, inetaddress, net, network, networkinterface, override

The DatagramChannelConfig.java Java example source code

/*
 * Copyright 2012 The Netty Project
 *
 * The Netty Project licenses this file to you under the Apache License,
 * version 2.0 (the "License"); you may not use this file except in compliance
 * with the License. You may obtain a copy of the License at:
 *
 *   http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
 * License for the specific language governing permissions and limitations
 * under the License.
 */
package io.netty.channel.socket;

import io.netty.buffer.ByteBufAllocator;
import io.netty.channel.ChannelConfig;
import io.netty.channel.ChannelOption;
import io.netty.channel.MessageSizeEstimator;
import io.netty.channel.RecvByteBufAllocator;
import io.netty.channel.WriteBufferWaterMark;

import java.net.InetAddress;
import java.net.NetworkInterface;
import java.net.StandardSocketOptions;

/**
 * A {@link ChannelConfig} for a {@link DatagramChannel}.
 *
 * <h3>Available options
 *
 * In addition to the options provided by {@link ChannelConfig},
 * {@link DatagramChannelConfig} allows the following options in the option map:
 *
 * <table border="1" cellspacing="0" cellpadding="6">
 * <tr>
 * <th>Name
Associated setter method
{@link #setBroadcast(boolean)}
{@link #setInterface(InetAddress)}
{@link #setReuseAddress(boolean)}
{@link #setReceiveBufferSize(int)}
{@link #setSendBufferSize(int)}
{@link #setTimeToLive(int)}
{@link #setTrafficClass(int)}
... this post is sponsored by my books ...

#1 New Release!

FP Best Seller

 

new blog posts

 

Copyright 1998-2021 Alvin Alexander, alvinalexander.com
All Rights Reserved.

A percentage of advertising revenue from
pages under the /java/jwarehouse URI on this website is
paid back to open source projects.