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

io.baltoro.remote.ResponseMap Maven / Gradle / Ivy

There is a newer version: 4.0.12
Show newest version
package io.baltoro.remote;

import java.util.HashMap;
import java.util.Map;

import io.baltoro.to.WSTO;

public class ResponseMap
{
	private static ResponseMap _instance;
	private Map map;

	private ResponseMap()
	{
		map = new HashMap(1000);
	}
	
	
	
	public static ResponseMap getInstance()
	{
		if(_instance == null)
		{
			_instance = new ResponseMap();
		}
		
		return _instance;
	}
	
	public void add(String uuid, WSTO obj)
	{
		map.put(uuid, obj);
	}
	
	public WSTO get(String uuid)
	{
		WSTO obj = map.get(uuid);
		map.remove(uuid);
		return obj;
		
	}
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy