GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing github.com — JavaGeneric/JavaGenMUB10.java at main · AvinandanBose/JavaGeneric Expand file tree/ Copy pathJavaGenMUB10.javaMore file actions 37 lines (28 loc) · 1004 Bytes / Copy pathJavaGenMUB10.javaFile metadata and controls37 lines (28 loc) · 1004 Bytes 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 import java.util.HashMap; import java.util.Map; public class JavaGenMUB10<T extends HashMap<String, String> & Map<String, String>> { T map; public JavaGenMUB10(T map) { this.map = map; } public void put(String string, String string2) { map.put(string, string2); } public String get(String string) { return map.get(string); } public static void main(String[] args) { HashMap<String, String> map = new HashMap<>(); map.put("key1", "value1"); map.put("key2", "value2"); map.put("key3", "value3"); map.put("key4", "value4"); map.put("key5", "value5"); map.put("key6", "value6"); JavaGenMUB10<HashMap<String, String>> javaMap = new JavaGenMUB10<>(map); System.out.println(javaMap.map); System.out.println(javaMap.get("key1")); javaMap.put("key7", "value7"); System.out.println(javaMap.map); } } |
| You are visitor 01402503 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |