public Ice.ValueFactory find(string id) { lock (this) { Ice.ValueFactory factory = null; _factoryMap.TryGetValue(id, out factory); return(factory); } }
public void add(Ice.ValueFactory factory, string id) { lock (this) { if (_factoryMap.ContainsKey(id)) { Ice.AlreadyRegisteredException ex = new Ice.AlreadyRegisteredException(); ex.id = id; ex.kindOfObject = "value factory"; throw ex; } _factoryMap[id] = factory; } }
public void add(Ice.ObjectFactory factory, string id) { lock (this) { if (_factoryMap.ContainsKey(id)) { Ice.AlreadyRegisteredException ex = new Ice.AlreadyRegisteredException(); ex.id = id; ex.kindOfObject = "value factory"; throw ex; } Ice.ValueFactory valueFactory = s => { return(factory.create(s)); }; _factoryMap[id] = valueFactory; _objectFactoryMap[id] = factory; } }
public void setFactory(Ice.ValueFactory factory) { _factory = factory; }
public MyClassFactoryWrapper() { _factory = null; }