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

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? discoveryservice.java

?? jxta平臺的開發包
?? JAVA
?? 第 1 頁 / 共 2 頁
字號:
/* *  Copyright (c) 2001-2006 Sun Microsystems, Inc.  All rights reserved. * *  Redistribution and use in source and binary forms, with or without *  modification, are permitted provided that the following conditions *  are met: * *  1. Redistributions of source code must retain the above copyright *  notice, this list of conditions and the following disclaimer. * *  2. Redistributions in binary form must reproduce the above copyright *  notice, this list of conditions and the following disclaimer in *  the documentation and/or other materials provided with the *  distribution. * *  3. The end-user documentation included with the redistribution, *  if any, must include the following acknowledgment: *  "This product includes software developed by the *  Sun Microsystems, Inc. for Project JXTA." *  Alternately, this acknowledgment may appear in the software itself, *  if and wherever such third-party acknowledgments normally appear. * *  4. The names "Sun", "Sun Microsystems, Inc.", "JXTA" and "Project JXTA" must *  not be used to endorse or promote products derived from this *  software without prior written permission. For written *  permission, please contact Project JXTA at http://www.jxta.org. * *  5. Products derived from this software may not be called "JXTA", *  nor may "JXTA" appear in their name, without prior written *  permission of Sun. * *  THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED *  WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES *  OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE *  DISCLAIMED.  IN NO EVENT SHALL SUN MICROSYSTEMS OR *  ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, *  SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT *  LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF *  USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND *  ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, *  OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT *  OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF *  SUCH DAMAGE. *  ==================================================================== * *  This software consists of voluntary contributions made by many *  individuals on behalf of Project JXTA.  For more *  information on Project JXTA, please see *  <http://www.jxta.org/>. * *  This license is based on the BSD license adopted by the Apache Foundation. * *  $Id: DiscoveryService.java,v 1.40 2006/06/19 18:27:34 bondolo Exp $ */package net.jxta.discovery;import java.io.IOException;import java.util.Enumeration;import net.jxta.document.Advertisement;import net.jxta.id.ID;import net.jxta.service.Service;/** * Provides an asynchronous mechanism for discovering Advertisement (Peers, * Groups, Pipes, Modules, etc.). The scope of discovery queries can be  * controlled by specifying a name and attribute pair, and/or a threshold.  * The threshold is an upper limit the requesting peer specifies for  * responding peers not to exceed. Each JXTA Peer Group has an instance of  * a DiscoveryService. The scope of discovery is limited to the group. For  * example : * * <p/>A peer in the soccer group invokes the soccer group's DiscoveryService * to discover pipe advertisements for the Score tracker service in the group, * and is interested in a maximum of 10 Advertisements from each peer: * <pre> *  discovery.getRemoteAdvertisements(null, discovery.ADV, *                                    "Name", "Score tracker*", 10, null); * * </pre> * * <p/>In the above example, peers that are part of the soccer group would * respond. After a getRemoteAdvertisements call is made and the peers respond, * a call to getLocalAdvertisements can be made to retrieve results that have * been found and added to the local group cache. Alternately, a call to * addDiscoveryListener() will provide asynchronous notification of discovered * advertisements. * * <p/>When an Advertisement is published, it is stored, and indexed in the  * peer's local cache. The Advertisement indexes are also shared with  * Rendezvous peers. Advertisement indexes may not be shared with other * peers immediately, but may be updated as part of a periodic process. The * Discovery Service currently updates remote indexes every 30 seconds. * * <p/>It is important to note that what is shared with the rendezvous peer is   * the index and expiration of the advertisement, not the advertisement. The * indexes are republished whenever the peer establishes a new connection with  * a different rendezvous peer. * * <p/>Distributed index garbage collection. A rendezvous peer will GC indexes for * a specific peer when it receive a disconnect message, or it has determined * that a peer is no longer reachable, the latter action is a lazy GC and is * triggered by messenger creation failures which results in a mark and sweep at * a future point in time. * * <p/>DiscoveryService also provides a mechanism for publishing advertisements, * so that they may be discovered. The rules to follow when publishing are: * *  <ul> *    <li> *    Use the current discovery service to publish advertisements private to the *    group. * <pre>discovery.publish(adv); * </pre></li> * *    <li>Use the parent's discovery to publish advertisements that public outside *    of the group. Example : a peer would like publish the "soccer" group in the *    NetPeerGroup * <pre> *        parent=soccerGroup.getParent(); *        discovery= parent.getDiscoveryService() *        discovery.publish(adv); * </pre></li> *  </ul> * * <p/>The threshold can be utilized in peer discovery in situations where a peer * is only interested in other peers, and not about additional peers they may * know about. To achieve this effect for peer discovery set the Threshold to * <code>0</code> (zero). * * <p/>Advertisements are often stored in a persistent local cache. This cache  * can improve performance and responsiveness by retaining advertisements  * between restarts. * *@see        net.jxta.service.Service *@see        net.jxta.resolver.ResolverService *@see        net.jxta.protocol.DiscoveryQueryMsg *@see        net.jxta.protocol.DiscoveryResponseMsg *@see        net.jxta.protocol.ResolverQueryMsg *@see        net.jxta.protocol.ResolverResponseMsg */public interface DiscoveryService extends Service {        /**     * Discovery type Peer     */    public final static int PEER = 0;        /**     * Discovery type Group     */    public final static int GROUP = 1;        /**     *  Discovery type Advertisement     */    public final static int ADV = 2;        /**     * Default lifetime time for advertisements. This is the maximum     * amount of time which the advertisement will remain valid. If the     * advertisement remains valid after this time, then the creator will     * need to republish the advertisement.     */    public final static long DEFAULT_LIFETIME = 1000L * 60L * 60L * 24L * 365L;        /**     *  Default expiration time for advertisements. This is the amount of     *  time which advertisements will live in caches. After this time, the     *  advertisement should be refreshed from the source.     */    public final static long DEFAULT_EXPIRATION = 1000L * 60L * 60L * 2L;        /**     *  Infinite lifetime for advertisements. The advertisement is valid     *  forever. (well maybe it will expire when the sun burns out, but not     *  before then).     */    public final static long INFINITE_LIFETIME = Long.MAX_VALUE;        /**     *  Specifies that the advertisement will have no expiration and will be     *  kept indefinitely.     */    public final static long NO_EXPIRATION = Long.MAX_VALUE;        /**     *  Discover advertisements from remote peers. This does not normally      *  provide an exhaustive search. Instead it provides a "best efforts"      *  search which will provide a selection of advertisements of matching the      *  search criteria. The selection of advertisements returned may be random      *  or predictable depending upon the network configuration and no      *  particular behaviour should be assumed. In general the narrower the     *  query specified the more exhaustive the responses will be.      *      *  <p/>Discovery can be performed in two ways : <ul>     *      <li>With a <tt>null</tt> peerid - The discovery query is     *      propagated on via the Rendezvous Service and via local sub-net     *      utilizing IP multicast.</li>     *      <li>With a provided peerid - The discovery query is forwarded to the     *      specified peer.</li>     *  </ul>     *     *  <p/>The scope of advertisements returned can be narrowed by specifying     *  an {@code attribute} and {@code value} pair. The {@code attribute} is     *  a case-sensitive string matching the name of an Advertisement XML tag     *  who's values will be matched by the {@code value}.  Only a limited number     *  of Advertisement XML fields are indexed. {@link     *  net.jxta.document.Advertisement#getIndexFields()} will return the      *  fields on which you may query for a particular Advertisement type.      *      *  <p/>The {@code value} is a case-insensitive string who's value is     *  matched against the values of {@code attribute} fields of Advertisements.     *  The {@code} value may be of several forms :     *  <ul>     *      <li>{@code null} - Don't care. All advertisements with the matching     *      {@code attribute} will be returned.</li>     *      <li>exact value - Only advertisements with an {@code attribute}     *      field who's value exactly matches the string {@code value} will be     *      returned.</li>     *      <li>wild card - Only advertisements with an {@code attribute}     *      field who's value matches the wild card expression {@code value}      *      will be returned. eg. The following expressions all match against     *      "FooBar":     *      <ul>     *          <li>{@code foO*}</li>     *          <li>{@code *Bar}</li>     *          <li>{@code *oBA*}</li>     *      </ul></li>     *  </ul>     *      * @param peerid If provided the query will be forwarded to the specified     *      peer. If {@code null} then the query will be propagated through the     *      network to peers with matching Advertisements.     * @param type Discovery type; <tt>PEER</tt>, <tt>GROUP</tt> or <tt>ADV</tt>.     * @param  attribute indexed element name (see advertisement(s) for a     *       list of indexed fields. A null attribute indicates any advertisement     *       of specified type     * @param  value      value of attribute to narrow discovery to. Valid values for     *      this parameter are null (don't care), Exact value, or use of wild     *      card(s) (e.g. if a Advertisement defines <Name>FooBar</name> , a value     *      of "*bar", "foo*", or "*ooB*", will return the Advertisement     * @param  threshold  The maximum number of matching advertisements which     *      be returned by each responding peer. A {@code threshold} of 0, and      *      {@code type} of {@code PEER} has a special behaviour.     * @return query ID for this discovery query.     */    public int getRemoteAdvertisements(String peerid,            int type,            String attribute,            String value,            int threshold);        /**     *  Discover advertisements from remote peers. This does not normally      *  provide an exhaustive search. Instead it provides a "best efforts"      *  search which will provide a selection of advertisements of matching the 

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
欧美日韩一区二区在线观看视频| 一区二区三区中文在线观看| 丰满亚洲少妇av| 亚洲福利视频导航| 欧美一区二区黄色| 国产91精品欧美| 亚洲高清一区二区三区| 久久精品免视看| 一本色道久久加勒比精品| 免费成人在线观看| 国产精品污网站| 久久天堂av综合合色蜜桃网| 成人黄色小视频| 日本人妖一区二区| 欧美mv日韩mv| 91精品国产综合久久国产大片| 成人一区二区三区| 蜜臀精品久久久久久蜜臀| 国产精品每日更新| 久久精品一区二区三区不卡牛牛 | 91在线视频免费91| 久久精品国产在热久久| 亚洲欧美激情在线| 国产精品国产自产拍高清av | 国产性色一区二区| 欧美电视剧免费全集观看| 色综合中文字幕| 国产精品一区免费在线观看| 日韩经典中文字幕一区| 亚洲一区二区精品久久av| 国产精品国产三级国产三级人妇| 欧美va日韩va| 91麻豆精品国产91久久久使用方法| 91色porny蝌蚪| 国产一区二区三区不卡在线观看| 亚洲成人动漫一区| 亚洲综合一区二区三区| 国产亚洲制服色| 日韩欧美国产系列| 在线视频中文字幕一区二区| 成人va在线观看| 精品无码三级在线观看视频| 久久精品国产精品亚洲综合| 日韩中文字幕不卡| 亚洲国产毛片aaaaa无费看| 久久女同性恋中文字幕| 国产午夜亚洲精品理论片色戒 | 日韩一区二区免费高清| 91精品国产入口| 欧美在线视频不卡| 欧美日韩在线免费视频| 欧美性猛交xxxxxx富婆| 日本二三区不卡| 色综合天天综合| 在线看日本不卡| 欧美性高清videossexo| 欧美午夜精品一区二区三区| 欧美中文字幕亚洲一区二区va在线 | 欧美一级精品大片| 欧美一区二区三区男人的天堂| 日韩一区二区中文字幕| 日韩午夜在线影院| 91麻豆精品国产91久久久| 欧美日韩精品电影| 99re热这里只有精品视频| 欧美日韩一区国产| 555www色欧美视频| 欧美日韩一区 二区 三区 久久精品| 91在线播放网址| 欧美专区日韩专区| 91麻豆精品国产91久久久久久久久 | 处破女av一区二区| 成人国产在线观看| 91女人视频在线观看| 91国在线观看| 日韩一级免费观看| 26uuu精品一区二区| 中文字幕欧美激情| 亚洲欧美精品午睡沙发| 日本特黄久久久高潮| 国产乱子轮精品视频| 丁香一区二区三区| 在线观看日韩高清av| 精品欧美一区二区久久| 亚洲国产精品久久久久秋霞影院 | 精品无人码麻豆乱码1区2区 | 国产在线播放一区二区三区| 91网站最新网址| 欧美一区二区高清| 亚洲图片另类小说| 麻豆成人免费电影| 99久久精品国产导航| 日韩一区二区三区电影在线观看| 国产精品成人一区二区三区夜夜夜| 无码av免费一区二区三区试看| 风间由美一区二区三区在线观看| 欧美日韩精品福利| 中文字幕免费不卡在线| 日韩av不卡一区二区| 成人av资源在线观看| 日韩你懂的在线观看| 亚洲欧美日韩小说| 国产成人免费网站| 欧美福利一区二区| 一色桃子久久精品亚洲| 国产一区福利在线| 7777精品伊人久久久大香线蕉的 | 一区二区三区免费观看| 国产福利一区二区三区| 91精品国产麻豆国产自产在线| 中日韩av电影| 国产精品亚洲专一区二区三区| 欧美美女喷水视频| 亚洲欧美日韩国产手机在线| 国产.精品.日韩.另类.中文.在线.播放| 欧美日韩国产美女| 亚洲精品一二三| www.亚洲人| 国产精品三级av在线播放| 韩国三级在线一区| 日韩欧美亚洲另类制服综合在线 | 成人性生交大片免费看视频在线 | 不卡一二三区首页| 欧美成人欧美edvon| 一区二区三区日韩在线观看| 成人国产精品视频| 久久色在线视频| 久久精品国产秦先生| 欧美一卡2卡3卡4卡| 天天亚洲美女在线视频| 欧美日韩夫妻久久| 亚洲一区二区三区小说| 日本黄色一区二区| 亚洲色图第一区| 91视频国产观看| 一区2区3区在线看| 在线亚洲欧美专区二区| 亚洲一区在线观看网站| 一本大道久久a久久精品综合| 综合欧美亚洲日本| 一本色道亚洲精品aⅴ| 亚洲另类一区二区| 欧美网站大全在线观看| 天天色天天操综合| 欧美一级理论性理论a| 麻豆高清免费国产一区| 精品国一区二区三区| 狠狠色丁香久久婷婷综| 久久久久高清精品| 成人精品免费网站| 国产精品麻豆视频| 91免费视频网址| 亚洲一区在线视频观看| 欧美日韩国产小视频| 老司机精品视频线观看86| 久久色视频免费观看| 国产激情偷乱视频一区二区三区| 国产精品毛片大码女人| 色综合一个色综合| 日本美女一区二区| 久久久久久久综合| 97久久超碰国产精品电影| 亚洲三级电影网站| 欧美日韩国产美女| 国产九色精品成人porny| 亚洲国产激情av| 91国产视频在线观看| 青青国产91久久久久久| 国产日产亚洲精品系列| 一道本成人在线| 麻豆精品在线观看| 国产精品女人毛片| 欧美精品日韩精品| 韩国成人福利片在线播放| 日韩理论在线观看| 日韩欧美中文字幕精品| 风间由美一区二区三区在线观看| 一区二区三区高清| 久久久综合精品| 在线观看免费视频综合| 久久不见久久见免费视频7 | 亚洲一区二区欧美日韩| 日韩免费高清视频| 一本到三区不卡视频| 美国一区二区三区在线播放| 国产精品久久久久久福利一牛影视 | 久久嫩草精品久久久久| 一本大道久久精品懂色aⅴ| 久草在线在线精品观看| 亚洲美女视频在线| 精品噜噜噜噜久久久久久久久试看| 91蜜桃传媒精品久久久一区二区| 天天色综合天天| 亚洲女同一区二区| 久久影院午夜论| 欧美日韩视频一区二区| 成人app网站| 久久精品国产999大香线蕉| 一区二区久久久久| 国产欧美日韩综合|