GetIsForeign() публичный статический Метод

public static GetIsForeign ( UUID AgentID, string server, IRegistryCore registry, string &serverURL ) : bool
AgentID UUID
server string
registry IRegistryCore
serverURL string
Результат bool
Пример #1
0
        public override InventoryItemBase GetItem(InventoryItemBase item)
        {
            string invServerURL = "", assetServerURL = "";

            if (GetHandlers.GetIsForeign(item.Owner, "InventoryServerURI", m_registry, out invServerURL))
            {
                XInventoryServicesConnector xinv = new XInventoryServicesConnector(invServerURL + "xinventory");
                InventoryItemBase           it   = xinv.GetItem(item);
                if (GetHandlers.GetIsForeign(item.Owner, "AssetServerURI", m_registry, out assetServerURL))
                {
                    GetAssets(it, assetServerURL + "assets");
                }
                return(it);
            }
            else
            {
                InventoryItemBase it = base.GetItem(item);
                if (it != null)
                {
                    UserAccount user = m_UserAccountService.GetUserAccount(null, UUID.Parse(it.CreatorId));

                    // Adjust the creator data
                    if (user != null && it != null && (it.CreatorData == null || it.CreatorData == string.Empty))
                    {
                        it.CreatorData = GetHandlers.PROFILE_URL + "/" + it.CreatorId + ";" + user.FirstName + " " + user.LastName;
                    }
                }
                return(it);
            }
        }
Пример #2
0
        public override bool AddFolder(InventoryFolderBase folder)
        {
            string invserverURL = "";

            if (GetHandlers.GetIsForeign(folder.Owner, "InventoryServerURI", m_registry, out invserverURL))
            {
                XInventoryServicesConnector xinv = new XInventoryServicesConnector(invserverURL + "xinventory");
                return(xinv.AddFolder(folder));
            }
            return(base.AddFolder(folder));
        }
Пример #3
0
        public override InventoryFolderBase GetRootFolder(UUID principalID)
        {
            string invserverURL = "";

            if (GetHandlers.GetIsForeign(principalID, "InventoryServerURI", m_registry, out invserverURL))
            {
                XInventoryServicesConnector xinv = new XInventoryServicesConnector(invserverURL + "xinventory");
                return(xinv.GetRootFolder(principalID));
            }
            return(base.GetRootFolder(principalID));
        }
Пример #4
0
        public override InventoryFolderBase GetFolderForType(UUID principalID, InventoryType invType, AssetType type)
        {
            string invserverURL = "";

            if (GetHandlers.GetIsForeign(principalID, "InventoryServerURI", m_registry, out invserverURL))
            {
                XInventoryServicesConnector xinv = new XInventoryServicesConnector(invserverURL + "xinventory");
                return(xinv.GetFolderForType(principalID, invType, type));
            }
            return(base.GetFolderForType(principalID, invType, type));
        }
Пример #5
0
        public override bool AddItem(InventoryItemBase item)
        {
            string invserverURL = "";

            if (GetHandlers.GetIsForeign(item.Owner, "InventoryServerURI", m_registry, out invserverURL))
            {
                XInventoryServicesConnector xinv = new XInventoryServicesConnector(invserverURL + "xinventory");
                bool success = xinv.AddItem(item);
                return(success);
            }
            return(base.AddItem(item));
        }