/* * Copyright (c) 2014, Inversoft Inc., All Rights Reserved * * 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.example.domain; import java.util.Collection; import java.util.HashMap; import java.util.Map; import java.util.Set; /** * Sub-class of generic map. */ public class MapImplements implements Map<String, String> { public Map<String, String> map = new HashMap<>(); @Override public int size() { return map.size(); } @Override public boolean isEmpty() { return map.isEmpty(); } @Override public boolean containsKey(Object key) { return map.containsKey(key); } @Override public boolean containsValue(Object value) { return map.containsValue(value); } @Override public String get(Object key) { return map.get(key); } @Override public String put(String key, String value) { return map.put(key, value); } @Override public String remove(Object key) { return map.remove(key); } @Override public void putAll(Map<? extends String, ? extends String> m) { map.putAll(m); } @Override public void clear() { map.clear(); } @Override public Set<String> keySet() { return map.keySet(); } @Override public Collection<String> values() { return map.values(); } @Override public Set<Entry<String, String>> entrySet() { return map.entrySet(); } }