コード例 #1
0
        public CustomEditGroupMemberOf(XmlDocument pagedata, List <ModuleParams> moduleparams, XmlNamespaceManager pagenamespaces)
            : base(pagedata, moduleparams, pagenamespaces)
        {
            this.XMLData = pagedata;

            data     = new Edit.Utilities.DataIO();
            propdata = new Profiles.Profile.Utilities.DataIO();

            string predicateuri = Request.QueryString["predicateuri"].Replace("!", "#");

            this.PropertyListXML = propdata.GetPropertyList(this.BaseData, base.PresentationXML, predicateuri, false, true, false);
            if (Request.QueryString["subject"] != null)
            {
                this.SubjectID = Convert.ToInt64(Request.QueryString["subject"]);
            }
            else
            {
                Response.Redirect(Root.Domain + "/search");
            }

            securityOptions.Subject        = this.SubjectID;
            securityOptions.PredicateURI   = predicateuri;
            securityOptions.PrivacyCode    = Convert.ToInt32(this.PropertyListXML.SelectSingleNode("PropertyList/PropertyGroup/Property/@ViewSecurityGroup").Value);
            securityOptions.SecurityGroups = new XmlDocument();
            securityOptions.SecurityGroups.LoadXml(base.PresentationXML.DocumentElement.LastChild.OuterXml);
        }
コード例 #2
0
        public void GetSubjectProfile()
        {
            Profile.Utilities.DataIO dataio = new Profile.Utilities.DataIO();

            Namespace rdfnamespaces = new Namespace();

            try
            {
                this.RDFTriple = new RDFTriple(Convert.ToInt64(HttpContext.Current.Request.QueryString["subject"]));

                this.RDFTriple.ShowDetails = true;
                this.RDFTriple.Expand      = true;
                //This method is used during the edit process.
                this.RDFTriple.Edit = true;

                this.BaseData   = dataio.GetRDFData(this.RDFTriple);
                this.Namespaces = rdfnamespaces.LoadNamespaces(this.BaseData);
            }
            catch (Exception ex) { Framework.Utilities.DebugLogging.Log(ex.Message + " ++ " + ex.StackTrace); }
        }
コード例 #3
0
        public void GetNetworkProfile(Int64 subject, Int64 predicate)
        {
            Profile.Utilities.DataIO dataio = new Profile.Utilities.DataIO();

            Namespace rdfnamespaces = new Namespace();

            try
            {
                this.RDFTriple = new RDFTriple(subject, predicate);

                this.RDFTriple.ShowDetails = true;
                this.RDFTriple.Expand      = true;
                //This method is used during the edit process.
                this.RDFTriple.Edit = true;

                this.BaseData   = dataio.GetRDFData(this.RDFTriple);
                this.Namespaces = rdfnamespaces.LoadNamespaces(this.BaseData);
            }
            catch (Exception ex) { Framework.Utilities.DebugLogging.Log(ex.Message + " ++ " + ex.StackTrace); }
        }
コード例 #4
0
        public EditVisibilityOnly(XmlDocument pagedata, List<ModuleParams> moduleparams, XmlNamespaceManager pagenamespaces)
            : base(pagedata, moduleparams, pagenamespaces)
        {
            this.XMLData = pagedata;

            data = new Edit.Utilities.DataIO();
            propdata = new Profiles.Profile.Utilities.DataIO();

            string predicateuri = Request.QueryString["predicateuri"].Replace("!", "#");
            this.PropertyListXML = propdata.GetPropertyList(this.BaseData, base.PresentationXML, predicateuri, false, true, false);
            if (Request.QueryString["subject"] != null)
                this.SubjectID = Convert.ToInt64(Request.QueryString["subject"]);
            else
                Response.Redirect(Root.Domain + "/search");

            securityOptions.Subject = this.SubjectID;
            securityOptions.PredicateURI = predicateuri;
            securityOptions.PrivacyCode = Convert.ToInt32(this.PropertyListXML.SelectSingleNode("PropertyList/PropertyGroup/Property/@ViewSecurityGroup").Value);
            securityOptions.SecurityGroups = new XmlDataDocument();
            securityOptions.SecurityGroups.LoadXml(base.PresentationXML.DocumentElement.LastChild.OuterXml);
        }
コード例 #5
0
        public void GetSubjectProfile()
        {
            Profile.Utilities.DataIO dataio = new Profile.Utilities.DataIO();

            Namespace rdfnamespaces = new Namespace();
            try
            {
                this.RDFTriple = new RDFTriple(Convert.ToInt64(HttpContext.Current.Request.QueryString["subject"]));

                this.RDFTriple.ShowDetails = true;
                this.RDFTriple.Expand = true;
                //This method is used during the edit process.
                this.RDFTriple.Edit = true;

                this.BaseData = dataio.GetRDFData(this.RDFTriple);
                this.Namespaces = rdfnamespaces.LoadNamespaces(this.BaseData);

            }
            catch (Exception ex) { Framework.Utilities.DebugLogging.Log(ex.Message + " ++ " + ex.StackTrace); }
        }
コード例 #6
0
        public void GetNetworkProfile(Int64 subject, Int64 predicate)
        {
            Profile.Utilities.DataIO dataio = new Profile.Utilities.DataIO();

            Namespace rdfnamespaces = new Namespace();
            try
            {
                this.RDFTriple = new RDFTriple(subject, predicate);

                this.RDFTriple.ShowDetails = true;
                this.RDFTriple.Expand = true;
                //This method is used during the edit process.
                this.RDFTriple.Edit = true;

                this.BaseData = dataio.GetRDFData(this.RDFTriple);
                this.Namespaces = rdfnamespaces.LoadNamespaces(this.BaseData);

            }
            catch (Exception ex) { Framework.Utilities.DebugLogging.Log(ex.Message + " ++ " + ex.StackTrace); }
        }
コード例 #7
0
        public void GetDataByURI()
        {
            Profile.Utilities.DataIO dataio = new Profile.Utilities.DataIO();

            Namespace rdfnamespaces = new Namespace();
            try
            {
                if (this.RDFTriple == null)
                {
                    if (this.BaseData.SelectSingleNode(this.GetModuleParamString("DataURI"), this.Namespaces).InnerText.Contains(Root.Domain))
                    {
                        string[] vars = this.BaseData.SelectSingleNode(this.GetModuleParamString("DataURI"), this.Namespaces).InnerText.Split('/');

                        //SPO
                        Int64 subject = 0;
                        Int64 predicate = 0;
                        Int64 _object = 0;
                        Int64 result;

                        for (int i = 0; i < vars.Length; i++)
                        {
                            if (Int64.TryParse(vars[i], out result))
                            {

                                if (subject != 0 && predicate != 0 && _object == 0)
                                    _object = Convert.ToInt64(vars[i]);

                                if (subject != 0 && predicate == 0)
                                    predicate = Convert.ToInt64(vars[i]);

                                if (subject == 0)
                                    subject = Convert.ToInt64(vars[i]);

                            }

                        }

                        this.RDFTriple = new RDFTriple(subject, predicate, _object);
                    }
                    else
                    {
                        this.RDFTriple = new RDFTriple(this.BaseData.SelectSingleNode(this.GetModuleParamString("DataURI"), this.Namespaces).InnerText);
                    }

                }
                if (this.GetModuleParamString("Offset") != string.Empty)
                    this.RDFTriple.Offset = this.GetModuleParamString("Offset");
                else
                    this.RDFTriple.Offset = string.Empty;

                if (this.GetModuleParamString("Limit") != string.Empty)
                    this.RDFTriple.Limit = this.GetModuleParamString("Limit");
                else
                    this.RDFTriple.Limit = string.Empty;

                if (this.GetModuleParamString("Edit") == "true")
                    this.RDFTriple.Edit = true;

                if (this.GetModuleParamXml("ExpandRDFList") != null)
                {
                    XmlNode x = this.GetModuleParamXml("ExpandRDFList");

                    if (x != null)
                        this.RDFTriple.ExpandRDFList = x.InnerXml;
                }

                this.RDFTriple.ShowDetails = true;
                this.RDFTriple.Expand = true;
                this.BaseData = dataio.GetRDFData(this.RDFTriple);
                this.Namespaces = rdfnamespaces.LoadNamespaces(this.BaseData);

            }
            catch (Exception ex) { Framework.Utilities.DebugLogging.Log(ex.Message + " ++ " + ex.StackTrace); }
        }
コード例 #8
0
        public void GetDataByURI()
        {
            Profile.Utilities.DataIO dataio = new Profile.Utilities.DataIO();

            Namespace rdfnamespaces = new Namespace();

            try
            {
                if (this.RDFTriple == null)
                {
                    if (this.BaseData.SelectSingleNode(this.GetModuleParamString("DataURI"), this.Namespaces).InnerText.Contains(Root.Domain))
                    {
                        string[] vars = this.BaseData.SelectSingleNode(this.GetModuleParamString("DataURI"), this.Namespaces).InnerText.Split('/');

                        //SPO
                        Int64 subject   = 0;
                        Int64 predicate = 0;
                        Int64 _object   = 0;
                        Int64 result;

                        for (int i = 0; i < vars.Length; i++)
                        {
                            if (Int64.TryParse(vars[i], out result))
                            {
                                if (subject != 0 && predicate != 0 && _object == 0)
                                {
                                    _object = Convert.ToInt64(vars[i]);
                                }

                                if (subject != 0 && predicate == 0)
                                {
                                    predicate = Convert.ToInt64(vars[i]);
                                }

                                if (subject == 0)
                                {
                                    subject = Convert.ToInt64(vars[i]);
                                }
                            }
                        }

                        this.RDFTriple = new RDFTriple(subject, predicate, _object);
                    }
                    else
                    {
                        this.RDFTriple = new RDFTriple(this.BaseData.SelectSingleNode(this.GetModuleParamString("DataURI"), this.Namespaces).InnerText);
                    }
                }
                if (this.GetModuleParamString("Offset") != string.Empty)
                {
                    this.RDFTriple.Offset = this.GetModuleParamString("Offset");
                }
                else
                {
                    this.RDFTriple.Offset = string.Empty;
                }


                if (this.GetModuleParamString("Limit") != string.Empty)
                {
                    this.RDFTriple.Limit = this.GetModuleParamString("Limit");
                }
                else
                {
                    this.RDFTriple.Limit = string.Empty;
                }


                if (this.GetModuleParamString("Edit") == "true")
                {
                    this.RDFTriple.Edit = true;
                }

                if (this.GetModuleParamXml("ExpandRDFList") != null)
                {
                    XmlNode x = this.GetModuleParamXml("ExpandRDFList");

                    if (x != null)
                    {
                        this.RDFTriple.ExpandRDFList = x.InnerXml;
                    }
                }

                this.RDFTriple.ShowDetails = true;
                this.RDFTriple.Expand      = true;
                this.BaseData   = dataio.GetRDFData(this.RDFTriple);
                this.Namespaces = rdfnamespaces.LoadNamespaces(this.BaseData);
            }
            catch (Exception ex) { Framework.Utilities.DebugLogging.Log(ex.Message + " ++ " + ex.StackTrace); }
        }
コード例 #9
0
        public void GetDataByURI()
        {
            Profile.Utilities.DataIO dataio = new Profile.Utilities.DataIO();

            Namespace rdfnamespaces = new Namespace();
            try
            {
                if (this.RDFTriple == null)
                    this.RDFTriple = new RDFTriple(this.BaseData.SelectSingleNode(this.GetModuleParamString("DataURI"), this.Namespaces).InnerText);

                if (this.GetModuleParamString("Offset") != string.Empty)
                    this.RDFTriple.Offset = this.GetModuleParamString("Offset");
                else
                    this.RDFTriple.Offset = string.Empty;

                if (this.GetModuleParamString("Limit") != string.Empty)
                    this.RDFTriple.Limit = this.GetModuleParamString("Limit");
                else
                    this.RDFTriple.Limit = string.Empty;

                if (this.GetModuleParamString("Edit") == "true")
                    this.RDFTriple.Edit = true;

                this.RDFTriple.ShowDetails = true;
                this.RDFTriple.Expand = true;
                this.BaseData = dataio.GetRDFData(this.RDFTriple);
                this.Namespaces = rdfnamespaces.LoadNamespaces(this.BaseData);

            }
            catch (Exception ex) { Framework.Utilities.DebugLogging.Log(ex.Message + " ++ " + ex.StackTrace); }
        }