it.netgrid.bauer.helpers.NOPTopicFactory Maven / Gradle / Ivy
package it.netgrid.bauer.helpers;
import java.util.HashMap;
import java.util.Map;
import it.netgrid.bauer.ITopicFactory;
import it.netgrid.bauer.Topic;
public class NOPTopicFactory implements ITopicFactory {
final Map> topics = new HashMap>();
@Override
public Topic getTopic(String name) {
@SuppressWarnings("unchecked")
NOPTopic topic = (NOPTopic)topics.get(name);
if(topic == null) {
topic = new NOPTopic();
topics.put(name, topic);
}
return (Topic) topic;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy