From 68c6b6ece3f1f20a81806b08ffd5c73296324d6c Mon Sep 17 00:00:00 2001 From: Justin Clarke Casey Date: Tue, 22 Apr 2008 18:58:09 +0000 Subject: * Replace previous specific inventory callback code with generic alternative --- .../Communications/Cache/CachedUserInfo.cs | 23 ++++++++++++++++++++++ 1 file changed, 23 insertions(+) (limited to 'OpenSim/Framework/Communications/Cache/CachedUserInfo.cs') diff --git a/OpenSim/Framework/Communications/Cache/CachedUserInfo.cs b/OpenSim/Framework/Communications/Cache/CachedUserInfo.cs index 3d7ada3..9a7ce42 100644 --- a/OpenSim/Framework/Communications/Cache/CachedUserInfo.cs +++ b/OpenSim/Framework/Communications/Cache/CachedUserInfo.cs @@ -332,6 +332,29 @@ namespace OpenSim.Framework.Communications.Cache /// public interface IInventoryRequest { + /// + /// This is the method executed once we have received the user's inventory by which the request can be fulfilled. + /// void Execute(); } + + /// + /// Generic inventory request + /// + public class InventoryRequest : IInventoryRequest + { + private Delegate m_delegat; + private Object[] m_args; + + internal InventoryRequest(Delegate delegat, Object[] args) + { + m_delegat = delegat; + m_args = args; + } + + public void Execute() + { + m_delegat.DynamicInvoke(m_args); + } + } } -- cgit v1.1