All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.jpattern.gwt.client.property.Property Maven / Gradle / Ivy

There is a newer version: 2.45.7
Show newest version
package com.jpattern.gwt.client.property;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 * 
 * @author Francesco Cina'
 *
 * 08/mag/2011
 */
public class Property implements IProperty {

	private Map properties = new HashMap();
	
	public Property(Map properties) {
		if (properties!=null) {
			this.properties = properties;
		}
	}
	
	@Override
	public List getKeys() {
		List result = new ArrayList(properties.keySet());
		return result;
	}

	@Override
	public boolean containsKey(String key) {
		return (key!=null && properties.containsKey(key));
	}
	
	@Override
	public String getProperty(String key) {
		if (containsKey(key)) {
			return properties.get(key);
		}
		return "";
	}

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy