示例#1
0
        public InventoryFolderBase GetRootFolder(UUID userID)
        {
            //m_log.DebugFormat("[HG INVENTORY CONNECTOR]: GetRootFolder for {0}", userID);
            InventoryFolderBase root = m_Cache.GetRootFolder(userID);

            if (root != null)
            {
                return(root);
            }

            string invURL = GetInventoryServiceURL(userID);

            if (invURL == null) // not there, forward to local inventory connector to resolve
            {
                lock (m_Lock)
                    return(m_LocalGridInventoryService.GetRootFolder(userID));
            }

            IInventoryService connector = GetConnector(invURL);

            root = connector.GetRootFolder(userID);

            m_Cache.Cache(userID, root);

            return(root);
        }