gov.nasa.pds.citool.registry.model.Slots Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of catalog-legacy Show documentation
Show all versions of catalog-legacy Show documentation
The Legacy Catalog Tool provides functionality for ingesting PDS3 catalog files into the PDS4 infrastructure including the Registry Service.
package gov.nasa.pds.citool.registry.model;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.Set;
public class Slots
{
private Map> map;
public Slots()
{
map = new HashMap>();
}
public void put(String key, String value)
{
List list = new ArrayList(1);
list.add(value);
map.put(key, list);
}
public void put(String key, List values)
{
map.put(key, values);
}
public Set>> entrySet()
{
return map.entrySet();
}
public List get(String key)
{
return map.get(key);
}
public String getFirst(String key)
{
List list = map.get(key);
return (list == null || list.isEmpty()) ? null : list.get(0);
}
public boolean containsKey(String key)
{
return map.containsKey(key);
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy