亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? attributefactory.java

?? stun的java實(shí)現(xiàn)
?? JAVA
字號(hào):
/** Stun4j, the OpenSource Java Solution for NAT and Firewall Traversal.
 *
 * Distributable under LGPL license.
 * See terms of license at gnu.org.
 */
package net.java.stun4j.attribute;

import net.java.stun4j.StunException;
import net.java.stun4j.StunAddress;

/**
 *
 * This class  provides factory methods to allow an application to create
 * STUN Attributes from a particular implementation.
 *
 * <p>Copyright: Copyright (c) 2003</p>
 * <p>Organisation: Louis Pasteur University, Strasbourg, France</p>
 * <p>Network Research Team (http://www-r2.u-strasbg.fr)</p></p>
 * @author Emil Ivov
 * @version 0.1
 */
public class AttributeFactory
{
    private AttributeFactory()
    {
    }

//------------------------------------ CHANGE REQUEST --------------------------

    /**
     * Creates a ChangeRequestAttribute with "false" values for the changeIP and
     * changePort flags.
     * @return the newly created ChangeRequestAttribute.
     */
    public static ChangeRequestAttribute
                    createChangeRequestAttribute()
    {
        return createChangeRequestAttribute(false, false);
    };

    /**
     * Creates a ChangeRequestAttribute with the specified flag values.
     * @param changeIP   the value of the changeIP flag.
     * @param changePort the value of the changePort flag.
     * @return the newly created ChangeRequestAttribute.
     */
    public static ChangeRequestAttribute
                    createChangeRequestAttribute(boolean changeIP,
                                                 boolean changePort)
    {
        ChangeRequestAttribute attribute = new ChangeRequestAttribute();

        attribute.setChangeIpFlag(changeIP);
        attribute.setChangePortFlag(changePort);

        return attribute;
    };

//------------------------------------ CHANGED ADDRESS -------------------------

    /**
     * Creates a changedAddressAttribute of the specified type and with the
     * specified address and port
     * @param address the address value of the address attribute
     * @return the newly created address attribute.
     */
    public static ChangedAddressAttribute
                                  createChangedAddressAttribute(StunAddress address)
    {
        ChangedAddressAttribute attribute= new ChangedAddressAttribute();

        attribute.setAddress(address);

        return attribute;

    };

//------------------------------------ ERROR CODE ------------------------------
    /**
     * Creates an ErrorCodeAttribute with the specified error class and number
     * and a default reason phrase.
     * @param errorClass a valid error class.
     * @param errorNumber a valid error number.
     * @return the newly created attribute.
     * @throws StunException if the error class or number have invalid values
     * according to rfc3489.
     */
    public static ErrorCodeAttribute createErrorCodeAttribute(
                        byte errorClass,
                        byte errorNumber
                        )
        throws StunException
    {
        return createErrorCodeAttribute(errorClass, errorNumber, null);
    };

    /**
     * Creates an ErrorCodeAttribute with the specified error class, number and
     * reason phrase.
     * @param errorClass a valid error class.
     * @param errorNumber a valid error number.
     * @param reasonPhrase a human readable reason phrase. A null reason phrase
     *                     would be replaced (if possible) by a default one
     *                     as defined byte the rfc3489.
     * @return the newly created attribute.
     * @throws StunException if the error class or number have invalid values
     * according to rfc3489.
     */
    public static ErrorCodeAttribute createErrorCodeAttribute(
                        byte errorClass,
                        byte errorNumber,
                        String reasonPhrase
                        )
        throws StunException
    {
        ErrorCodeAttribute attribute = new ErrorCodeAttribute();

        attribute.setErrorClass(errorClass);
        attribute.setErrorNumber(errorNumber);

        attribute.setReasonPhrase(reasonPhrase==null?
            ErrorCodeAttribute.getDefaultReasonPhrase(attribute.getErrorCode())
            :reasonPhrase);

        return attribute;
    };



    /**
     * Creates an ErrorCodeAttribute with the specified error code and a default
     * reason phrase.
     * @param errorCode a valid error code.
     * @return the newly created attribute.
     * @throws StunException if errorCode is not a valid error code as defined
     * by rfc3489
     */
    public static ErrorCodeAttribute createErrorCodeAttribute(char errorCode)
        throws StunException
    {
        return createErrorCodeAttribute(errorCode, null);
    };

    /**
     * Creates an ErrorCodeAttribute with the specified error code and reason
     * phrase.
     * @param errorCode a valid error code.
     * @param reasonPhrase a human readable reason phrase. A null reason phrase
     *                     would be replaced (if possible) by a default one
     *                     as defined byte the rfc3489.

     * @return the newly created attribute.
     * @throws StunException if errorCode is not a valid error code as defined
     * by rfc3489
     */
    public static ErrorCodeAttribute createErrorCodeAttribute(
                                        char errorCode,
                                        String reasonPhrase)
        throws StunException
    {
        ErrorCodeAttribute attribute = new ErrorCodeAttribute();

        attribute.setErrorCode(errorCode);
        attribute.setReasonPhrase(reasonPhrase==null?
            ErrorCodeAttribute.getDefaultReasonPhrase(attribute.getErrorCode())
            :reasonPhrase);


        return attribute;
    };

//------------------------------------ MAPPED ADDRESS --------------------------

    /**
     * Creates a MappedAddressAttribute of the specified type and with the
     * specified address and port
     * @param address the address value of the address attribute
     * @return the newly created address attribute.
     */
    public static MappedAddressAttribute createMappedAddressAttribute(
                                                StunAddress address)
    {
        MappedAddressAttribute attribute = new MappedAddressAttribute();

        attribute.setAddress(address);

        return attribute;

    };

//------------------------------------ REFLECTED FROM --------------------------

    /**
     * Creates a ReflectedFromAddressAttribute of the specified type and with
     * the specified address and port
     * @param address the address value of the address attribute
     * @return the newly created address attribute.
     */
    public static ReflectedFromAttribute createReflectedFromAttribute(
                                                StunAddress address)
    {
        ReflectedFromAttribute attribute = new ReflectedFromAttribute();

        attribute.setAddress(address);

        return attribute;

    };

//------------------------------------ RESPONSE ADRESS -------------------------
    /**
     * Creates a ResponseFromAddressAttribute of the specified type and with
     * the specified address and port
     * @param address the address value of the address attribute
     * @return the newly created address attribute.
     */
    public static ResponseAddressAttribute createResponseAddressAttribute(
                                                    StunAddress address)
    {
        ResponseAddressAttribute attribute = new ResponseAddressAttribute();

        attribute.setAddress(address);

        return attribute;

    };

//------------------------------------ SOURCE ADDRESS --------------------------
    /**
     * Creates a SourceFromAddressAttribute of the specified type and with
     * the specified address and port
     * @param address the address value of the address attribute
     * @return the newly created address attribute.
     */
    public static SourceAddressAttribute createSourceAddressAttribute(
                                               StunAddress address)
    {
        SourceAddressAttribute attribute = new SourceAddressAttribute();

        attribute.setAddress(address);

        return attribute;

    };

//------------------------------------ UNKNOWN ATTRIBUTES ----------------------
    /**
     * Creates an empty UnknownAttributesAttribute.
     * @return the newly created UnknownAttributesAttribute
     */
    public static UnknownAttributesAttribute createUnknownAttributesAttribute()
    {
        UnknownAttributesAttribute attribute = new UnknownAttributesAttribute();

        return attribute;
    };

}

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
欧美无砖砖区免费| 色综合久久综合中文综合网| 成人白浆超碰人人人人| 欧美午夜精品理论片a级按摩| 91麻豆精品久久久久蜜臀| 国产区在线观看成人精品| 亚洲chinese男男1069| thepron国产精品| 精品国产99国产精品| 亚洲香肠在线观看| www.欧美亚洲| 国产日韩欧美精品综合| 免费观看一级欧美片| 在线观看日韩电影| 国产精品久久毛片a| 国产综合色精品一区二区三区| 欧美午夜精品久久久| ●精品国产综合乱码久久久久| 精品一区二区三区不卡| 7777精品伊人久久久大香线蕉最新版| 最新热久久免费视频| 成人高清视频在线观看| 亚洲精品一区二区三区精华液 | 精品日本一线二线三线不卡| 亚洲男同性视频| 大胆亚洲人体视频| 欧美精品一区二区三区蜜桃| 日本欧美肥老太交大片| 欧美一区二区精品| 日本欧美一区二区三区| 欧美日韩一级黄| 亚洲成人免费视| 欧美午夜精品久久久久久孕妇| 亚洲欧美国产77777| 99久久er热在这里只有精品66| 中文字幕欧美激情一区| 国产成人精品网址| 国产精品无圣光一区二区| 成人高清视频在线| 亚洲乱码国产乱码精品精的特点 | 国产精品久久久一本精品| 国产69精品久久久久777| 久久精品视频免费| 精油按摩中文字幕久久| 国产东北露脸精品视频| 国产女人18毛片水真多成人如厕| 成人丝袜18视频在线观看| 亚洲欧洲av另类| 欧美三级中文字| 免费人成黄页网站在线一区二区| 欧美一区二区三区白人| 国产在线视频一区二区三区| 国产亚洲精品资源在线26u| 成人免费视频网站在线观看| 亚洲国产成人在线| 欧美三级中文字幕| 黑人巨大精品欧美一区| 欧美激情中文字幕| 精品视频资源站| 韩日欧美一区二区三区| 亚洲欧美日韩电影| 亚洲一本大道在线| 日韩欧美在线不卡| 成人午夜碰碰视频| 亚洲高清一区二区三区| 精品久久久久久无| 色综合色狠狠综合色| 日韩黄色小视频| 国产精品每日更新在线播放网址| 精品视频在线免费看| 国内精品伊人久久久久av影院 | 欧美一区二区黄色| 国产iv一区二区三区| 亚洲国产精品久久人人爱| 精品国产一区二区三区久久影院| 99精品欧美一区| 国产综合久久久久久鬼色| 亚洲黄色尤物视频| 国产亚洲一区字幕| 制服丝袜成人动漫| 99国产麻豆精品| 国产在线精品一区二区不卡了| 亚洲欧洲精品一区二区三区不卡| 91精品久久久久久久99蜜桃| 99久久国产综合色|国产精品| 裸体健美xxxx欧美裸体表演| 自拍偷拍国产亚洲| 国产午夜亚洲精品午夜鲁丝片| 欧美日本不卡视频| 91美女在线视频| 大白屁股一区二区视频| 精品制服美女丁香| 日本中文一区二区三区| 亚洲老妇xxxxxx| 国产精品欧美一区喷水| wwwwxxxxx欧美| 欧美一区午夜精品| 欧美精品久久久久久久久老牛影院| 国产成人99久久亚洲综合精品| 蜜臀久久久久久久| 亚洲444eee在线观看| 亚洲人成精品久久久久久| 久久新电视剧免费观看| 日韩你懂的电影在线观看| 欧美性视频一区二区三区| 色婷婷激情一区二区三区| va亚洲va日韩不卡在线观看| 成人免费福利片| 成人免费va视频| 成人av电影在线网| 成人福利视频网站| av中文字幕亚洲| www.亚洲色图.com| 色综合天天性综合| 色婷婷久久一区二区三区麻豆| 成人高清视频免费观看| 99久免费精品视频在线观看| 不卡欧美aaaaa| 91丝袜美女网| 在线观看欧美黄色| 欧美日韩美女一区二区| 欧美高清视频在线高清观看mv色露露十八 | 亚洲精品免费一二三区| 亚洲天堂av一区| 亚洲综合另类小说| 日韩电影免费一区| 久久国产免费看| 粉嫩一区二区三区在线看| 丁香桃色午夜亚洲一区二区三区| 成人综合婷婷国产精品久久免费| 成人精品国产福利| 欧美影院一区二区| 91精品国产高清一区二区三区蜜臀 | www.爱久久.com| 欧洲视频一区二区| 日韩天堂在线观看| 久久嫩草精品久久久久| 国产精品高清亚洲| 亚洲va欧美va国产va天堂影院| 免费在线欧美视频| 国产99久久久国产精品| 色婷婷香蕉在线一区二区| 制服.丝袜.亚洲.中文.综合| 久久久噜噜噜久噜久久综合| 成人欧美一区二区三区白人 | 国产不卡视频一区二区三区| 色哟哟日韩精品| 日韩午夜小视频| 国产精品国产三级国产aⅴ原创 | 国产精品一品二品| 欧美在线观看18| www成人在线观看| 亚洲一区二区在线免费看| 久久精品99国产国产精| 99久久99久久综合| 精品国产三级电影在线观看| 亚洲天堂2014| 久久草av在线| 欧美在线观看一二区| 久久亚洲春色中文字幕久久久| 亚洲女人的天堂| 国产精品一二三区在线| 欧美日韩国产123区| 欧美韩国日本综合| 日韩精品一区第一页| 91在线观看视频| 精品电影一区二区三区 | 久久国产精品99久久人人澡| 91麻豆.com| 日本一区二区视频在线| 石原莉奈在线亚洲三区| 99re视频精品| 国产三区在线成人av| 偷拍一区二区三区四区| 国产剧情av麻豆香蕉精品| 欧美日韩一二三| 亚洲三级电影全部在线观看高清| 久久99国产精品久久99果冻传媒| 精品成人在线观看| 亚洲精品一线二线三线| 午夜视频久久久久久| 91视频在线观看| 中文字幕成人av| 国产91色综合久久免费分享| 欧美一区二区三区婷婷月色| 亚洲一卡二卡三卡四卡五卡| 亚洲另类春色校园小说| 99re6这里只有精品视频在线观看 99re8在线精品视频免费播放 | 欧美吻胸吃奶大尺度电影| 国产精品美女一区二区在线观看| 精品无码三级在线观看视频| 欧美日韩五月天| 亚洲电影欧美电影有声小说| 欧美中文字幕一区| 亚洲一区二区三区中文字幕| 99国产麻豆精品| 亚洲黄色片在线观看| 欧美亚洲一区二区在线观看| 一区二区成人在线| 欧美性做爰猛烈叫床潮|