?? placeholder.java
字號:
// This is copyrighted source file, part of Rakiura JFern package. // See the file LICENSE for copyright information and the terms and conditions// for copying, distributing and modifications of Rakiura JFern package.// Copyright (C) 1999-2002 by Mariusz Nowostawski and others [http://www.rakiura.org]package org.rakiura.cpn;/**/import java.util.HashMap;import java.util.HashSet;import java.util.Set;/** * Utility class for storing and referencing Place objects. * *<br><br> * PlaceHolder.java<br> * Created: Fri Sep 29 12:31:14 2000<br> * *@author <a href="mariusz@rakiura.org">Mariusz Nowostawski</a> *@version 2.1.0 $Revision: 1.3 $ *@since 1.0 */final class PlaceHolder implements java.io.Serializable { private HashMap map_forName; private HashMap map_forID; public PlaceHolder() { this.map_forName = new HashMap(); this.map_forID = new HashMap(); } public final PlaceHolder add(Place place){ this.map_forName.put(place.getName(), place); this.map_forID.put(place.getID(), place); return this; } public final Place forName(String name){ return (Place)this.map_forName.get(name); } public final Place forID(String id){ return (Place)this.map_forID.get(id); } public final Set places(){ return new HashSet(this.map_forID.values()); } } // PlaceHolder//////////////////// end of file ////////////////////
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -