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

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

?? baseregistry.java

?? jetspeed源代碼
?? JAVA
字號:
/*
 * Copyright 2000-2001,2004 The Apache Software Foundation.
 * 
 * Licensed 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 org.apache.jetspeed.om.registry.base;

import org.apache.jetspeed.om.registry.RegistryEntry;
import org.apache.jetspeed.om.registry.InvalidEntryException;
import java.util.Map;
import java.util.TreeMap;
import java.util.Iterator;
import java.util.Enumeration;
import java.util.Vector;

/**
 * Provides base functionality within a Registry.
 *
 * @author <a href="mailto:burton@apache.org">Kevin A. Burton</a>
 * @author <a href="mailto:raphael@apache.org">Rapha雔 Luta</a>
 * @version $Id: BaseRegistry.java,v 1.7 2004/02/23 03:08:26 jford Exp $
 */
public class BaseRegistry implements LocalRegistry
{
    protected static final boolean DEBUG = false;

    protected Map entries = new TreeMap();

    /** @see Registry#getEntryCount */
    public int getEntryCount()
    {
        return this.entries.size();
    }

    /** @see Registry#getEntry */
    public RegistryEntry getEntry( String name ) throws InvalidEntryException
    {

        RegistryEntry entry = null;

        if (name != null)
        {
            entry = (RegistryEntry)this.entries.get( name ) ;
        }

        if (entry == null)
        {
            throw new InvalidEntryException( InvalidEntryException.ENTRY_DOES_NOT_EXIST+" "+name );
        }

        return entry;
    }

    /**
    @see Registry#setEntry
    */
    public void setEntry( RegistryEntry entry ) throws InvalidEntryException
    {
        synchronized (this)
        {

            if ( this.hasEntry( entry.getName() ) == false )
            {
                throw new InvalidEntryException( InvalidEntryException.ENTRY_DOES_NOT_EXIST+" "+entry.getName());
            }

            this.entries.put( entry.getName(), entry );
        }
    }

    /**
    @see Registry#addEntry
    */
    public void addEntry( RegistryEntry entry ) throws InvalidEntryException
    {

        synchronized (this)
        {
            if ( this.hasEntry( entry.getName() ) )
            {
                throw new InvalidEntryException( InvalidEntryException.ENTRY_ALREADY_PRESENT );
            }

            this.entries.put( entry.getName(), entry );
        }
    }

    /**
       @see Registry#hasEntry
    */
    public boolean hasEntry( String name )
    {
        return this.entries.containsKey( name );
    }

    /**
    @see Registry#removeEntry
    */
    public void removeEntry( String name )
    {
        synchronized(this)
        {
            this.entries.remove( name );
        }
    }

    /**
    @see Registry#removeEntry
    */

    public void removeEntry( RegistryEntry entry )
    {
        synchronized(this)
        {
            this.entries.remove( entry.getName() );
        }
    }

    /**
       @see Registry#getEntries
     */
    public Enumeration getEntries()
    {
        Vector v = null;

        synchronized (this)
        {
            // this is ne
            v = new Vector(this.entries.values());
        }

        return v.elements();
    }

    /**
       @see Registry#listEntryNames
     */
    public Iterator listEntryNames()
    {
        return entries.keySet().iterator();
    }

    /**
       @see Registry#toArray
     */
    public RegistryEntry[] toArray()
    {

        Enumeration enum = getEntries();
        Vector v = new Vector();

        while( enum.hasMoreElements() )
        {
            v.addElement( enum.nextElement() );
        }

        RegistryEntry[] entries = new RegistryEntry[ v.size() ];
        v.copyInto( entries );
        return entries;

    }

    /**
     * Creates a new RegistryEntry instance compatible with the current
     * Registry instance implementation
     *
     * @return the newly created RegistryEntry
     */
    public RegistryEntry createEntry()
    {
        return new BaseRegistryEntry();
    }


    // RegistryService specific methods

    /**
     * This method is used  to only set the entry in the local
     * memory cache of the registry without any coherency check with
     * persistent storage
     *
     * @param entry the RegistryEntry to store
     */
    public void setLocalEntry( RegistryEntry entry ) throws InvalidEntryException
    {
        synchronized (this)
        {

            if ( this.hasEntry( entry.getName() ) == false )
            {
                throw new InvalidEntryException( InvalidEntryException.ENTRY_DOES_NOT_EXIST+" "+entry.getName());
            }

            this.entries.put( entry.getName(), entry );
        }
    }

    /**
     * This method is used to only add the entry in the local
     * memory cache of the registry without any coherency check with
     * persistent storage
     *
     * @param entry the RegistryEntry to store
     */
    public void addLocalEntry( RegistryEntry entry ) throws InvalidEntryException
    {

        synchronized (this)
        {
            if ( this.hasEntry( entry.getName() ) )
            {
                throw new InvalidEntryException( InvalidEntryException.ENTRY_ALREADY_PRESENT );
            }

            this.entries.put( entry.getName(), entry );
        }
    }

    /**
     * This method is used to only remove the entry from the local
     * memory cache of the registry without any coherency check with
     * persistent storage
     *
     * @param name the name of the RegistryEntry to remove
     */
    public void removeLocalEntry( String name )
    {
        synchronized(this)
        {
            this.entries.remove( name );
        }
    }

    /**
     * This method is used to only remove the entry from the local
     * memory cache of the registry without any coherency check with
     * persistent storage
     *
     * @param entry the RegistryEntry to remove
     */
    public void removeLocalEntry( RegistryEntry entry )
    {
        synchronized(this)
        {
            this.entries.remove( entry.getName() );
        }
    }

}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
欧美aⅴ一区二区三区视频| 亚洲国产视频一区| 国产成人av自拍| 久久精品男人天堂av| 国产大片一区二区| 国产精品久久一级| 欧美午夜一区二区三区 | 国产xxx精品视频大全| 国产欧美日韩亚州综合| 91在线国产观看| 一区二区三区色| 日韩一卡二卡三卡国产欧美| 国内精品写真在线观看| 中文字幕在线一区二区三区| 色88888久久久久久影院按摩| 日韩精品免费视频人成| 久久久99精品久久| 91麻豆免费在线观看| 亚洲国产va精品久久久不卡综合| 91精品国产综合久久精品性色| 精品一区二区三区免费播放| 国产精品国产成人国产三级| 亚洲h在线观看| 石原莉奈一区二区三区在线观看 | 丁香六月久久综合狠狠色| 水蜜桃久久夜色精品一区的特点| 国产精品嫩草影院com| 51精品久久久久久久蜜臀| 久久久久久久久岛国免费| 亚瑟在线精品视频| av在线不卡免费看| 国产欧美一区二区精品仙草咪| 亚洲在线成人精品| 91丨九色丨蝌蚪富婆spa| 久久婷婷成人综合色| 极品瑜伽女神91| 欧美日韩电影一区| 亚洲综合免费观看高清完整版在线 | 亚洲国产综合91精品麻豆| 色激情天天射综合网| 国产精品入口麻豆原神| 国产成人精品免费在线| 欧美经典一区二区三区| 国产在线观看免费一区| 国产婷婷色一区二区三区四区| 韩国三级在线一区| 亚洲品质自拍视频| 91行情网站电视在线观看高清版| 亚洲精品国产a| 日韩三级中文字幕| 国产不卡视频在线观看| 亚洲精品成人在线| 欧美一区三区四区| 不卡的av中国片| 午夜免费久久看| 国产精品乱码人人做人人爱| 在线观看视频一区二区| 国模套图日韩精品一区二区| ...xxx性欧美| 久久尤物电影视频在线观看| 福利电影一区二区| 日本不卡视频一二三区| 国产专区欧美精品| 精品视频一区二区三区免费| 亚洲第一会所有码转帖| 久久精品免费在线观看| 欧美电影在线免费观看| 成人美女视频在线观看| 九九视频精品免费| 亚洲观看高清完整版在线观看| 国产日韩v精品一区二区| 欧美精品电影在线播放| 色哟哟日韩精品| 不卡大黄网站免费看| 成人午夜碰碰视频| 国产精一区二区三区| 久久国产人妖系列| 极品销魂美女一区二区三区| 日韩高清在线一区| 五月婷婷色综合| 一区二区三区毛片| 国产精品少妇自拍| 国产精品久线观看视频| 亚洲欧美精品午睡沙发| 1024国产精品| 亚洲一区二区偷拍精品| 亚洲1区2区3区视频| 日韩精品一卡二卡三卡四卡无卡| 免费欧美日韩国产三级电影| 久久精品国产秦先生| 国产麻豆精品一区二区| 成人av中文字幕| 欧美在线免费视屏| 91精品综合久久久久久| 欧美精品一级二级三级| 精品久久久久99| 不卡一卡二卡三乱码免费网站| 国产成人精品午夜视频免费| 成人高清在线视频| 欧美理论片在线| 欧美国产精品一区| 午夜视频一区二区| www.亚洲精品| 亚洲精品亚洲人成人网| 不卡一二三区首页| 亚洲一区在线电影| 中文文精品字幕一区二区| 色综合中文字幕国产 | 国产在线精品一区在线观看麻豆| 国产精品嫩草影院av蜜臀| 欧美一区二区三区视频免费播放| 日本大胆欧美人术艺术动态| 国产在线国偷精品免费看| 成人综合在线观看| 色欧美片视频在线观看在线视频| 欧美日韩第一区日日骚| 日韩久久久精品| 国产精品色在线| 亚洲国产欧美日韩另类综合| 久久不见久久见免费视频7| 国产成人av电影在线观看| 在线观看一区日韩| 2024国产精品视频| 一区二区三区av电影| 激情偷乱视频一区二区三区| 大美女一区二区三区| 337p亚洲精品色噜噜噜| 国产日产欧美一区| 欧美日韩一区二区三区免费看| 中文欧美字幕免费| 91精品国产乱码| ...av二区三区久久精品| 日韩—二三区免费观看av| 99久久综合国产精品| 欧美一区二区三区视频在线观看| ㊣最新国产の精品bt伙计久久| 麻豆91精品91久久久的内涵| 色哟哟国产精品免费观看| 久久久久久久久久久黄色| 亚洲成va人在线观看| 成人丝袜18视频在线观看| 欧美不卡一区二区三区四区| 亚洲国产成人av网| 91一区二区在线| 国产亚洲欧美色| 久久精品国产免费看久久精品| 欧美亚洲动漫精品| 国产精品每日更新| 国产一区高清在线| 制服丝袜亚洲色图| 亚洲国产日韩精品| 99这里都是精品| 久久久久九九视频| 免费久久99精品国产| 欧洲国内综合视频| 亚洲欧美区自拍先锋| 成人综合在线网站| 国产偷国产偷亚洲高清人白洁| 图片区小说区国产精品视频| 在线观看视频一区二区欧美日韩| 亚洲欧洲日韩在线| 成人av动漫在线| 久久精品视频一区二区| 国产一区久久久| 久久久久久久精| 国产精品69久久久久水密桃| 日韩午夜在线播放| 蜜桃91丨九色丨蝌蚪91桃色| 日韩一区二区三区免费看| 亚洲成人av电影在线| 欧美另类高清zo欧美| 香蕉久久一区二区不卡无毒影院| 欧美伦理视频网站| 青青草97国产精品免费观看| 在线综合亚洲欧美在线视频| 日韩精品一二区| 欧美一区二区三区性视频| 免费观看成人av| 久久久久久黄色| 成人午夜私人影院| 国产精品高潮久久久久无| 成年人国产精品| 夜夜嗨av一区二区三区网页| 欧美日韩一区二区三区在线| 午夜精品视频一区| 日韩精品资源二区在线| 国产精品一区二区在线观看网站 | 欧美人与性动xxxx| 美女在线一区二区| 久久精品这里都是精品| 成人福利电影精品一区二区在线观看| 国产精品乱子久久久久| 欧美亚洲国产bt| 精品一区二区综合| 国产精品美女一区二区| 色综合久久久久| 日韩成人午夜精品| 国产亚洲欧美日韩在线一区| 97久久精品人人爽人人爽蜜臀| 亚洲图片一区二区|