byte[] GetPermissions(Dictionary <string, object> request)
        {
            UUID agent_id;

            if (!UUID.TryParse(request["agent_id"].ToString(), out agent_id))
            {
                return(FailureResult());
            }

            Dictionary <UUID, bool> reply_data = m_service.FetchExperiencePermissions(agent_id);

            XmlDocument doc = new XmlDocument();

            XmlNode xmlnode = doc.CreateNode(XmlNodeType.XmlDeclaration, "", "");

            doc.AppendChild(xmlnode);

            XmlElement rootElement = doc.CreateElement("", "ServerResponse", "");

            doc.AppendChild(rootElement);

            int i = 0;

            foreach (var pair in reply_data)
            {
                XmlElement key = doc.CreateElement("", string.Format("uuid_{0}", i), "");
                key.AppendChild(doc.CreateTextNode(pair.Key.ToString()));
                rootElement.AppendChild(key);

                XmlElement perm = doc.CreateElement("", string.Format("perm_{0}", i), "");
                perm.AppendChild(doc.CreateTextNode(pair.Value.ToString()));
                rootElement.AppendChild(perm);

                i++;
            }

            return(Util.DocToBytes(doc));
        }
 public Dictionary <UUID, bool> FetchExperiencePermissions(UUID agent_id)
 {
     return(m_service.FetchExperiencePermissions(agent_id));
 }
 public Dictionary <UUID, bool> FetchExperiencePermissions(UUID agent_id)
 {
     return(m_remoteConnector.FetchExperiencePermissions(agent_id));
 }