Back to project page ormada.
The source code is released under:
Copyright (c) 2012 Jesse Rosalia Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Sof...
If you think the Android project ormada listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package org.ormada.dialect; //w w w. j a v a 2 s. co m import java.util.Collection; import java.util.HashMap; import java.util.Map; /** * A simple default implementation of the ValueSet interface for standard SQL databases. * * @author thejenix * */ public class DefaultValueSet implements ValueSet { private Map<String, Object> valueMap = new HashMap<String, Object>(); public boolean containsField(String field) { return valueMap.containsKey(field); } public Collection<String> getFields() { return valueMap.keySet(); } public Object getAsObject(String field) { return valueMap.get(field); } @Override public void put(String key, byte[] value) { this.valueMap.put(key, value); } @Override public void put(String key, Integer value) { this.valueMap.put(key, value); } @Override public void put(String key, Short value) { this.valueMap.put(key, value); } @Override public void put(String key, Long value) { this.valueMap.put(key, value); } @Override public void put(String key, Float value) { this.valueMap.put(key, value); } @Override public void put(String key, Double value) { this.valueMap.put(key, value); } @Override public void put(String key, Boolean value) { this.valueMap.put(key, value); } @Override public void put(String key, Byte value) { this.valueMap.put(key, value); } @Override public void put(String key, String value) { this.valueMap.put(key, value); } }