कोड में यह करने के लिए कैसे यहाँ समझाया गया है: Unity Register two interfaces as one singletonमैं एक सिंगलटन को एकता, एक्सएमएल कॉन्फ़िगरेशन में विभिन्न इंटरफेस में कैसे पंजीकृत कर सकता हूं?
_container.RegisterType<EventService>(new ContainerControlledLifetimeManager());
_container.RegisterType<IEventService, EventService>();
_container.RegisterType<IEventServiceInformation, EventService>();
bool singleton = ReferenceEquals(_container.Resolve<IEventService>(), _container.Resolve<IEventServiceInformation>());
कैसे एक्सएमएल config में यह करने के लिए?
याद किया और Event_Class वाला के दोनों मामलों में ही हो रहे हैं? – lukebuehler
हां। आपके संदर्भ एक्वाल्स काम करना चाहिए। – ErnieL