Esempio n. 1
0
        /// <summary>
        /// Decompile the WixHttpUrlAce table.
        /// </summary>
        /// <param name="table">The table to decompile.</param>
        private void DecompileWixHttpUrlAceTable(Table table)
        {
            foreach (Row row in table.Rows)
            {
                Http.UrlAce urlace = new Http.UrlAce();
                urlace.Id = (string)row[0];
                urlace.SecurityPrincipal = (string)row[2];
                switch (Convert.ToInt32(row[3]))
                {
                case HttpConstants.GENERIC_ALL:
                default:
                    urlace.Rights = Http.UrlAce.RightsType.all;
                    break;

                case HttpConstants.GENERIC_EXECUTE:
                    urlace.Rights = Http.UrlAce.RightsType.register;
                    break;

                case HttpConstants.GENERIC_WRITE:
                    urlace.Rights = Http.UrlAce.RightsType.@delegate;
                    break;
                }

                string reservationId = (string)row[1];
                Http.UrlReservation urlReservation = (Http.UrlReservation) this.Core.GetIndexedElement("WixHttpUrlReservation", reservationId);
                if (null != urlReservation)
                {
                    urlReservation.AddChild(urlace);
                }
                else
                {
                    this.Core.OnMessage(WixWarnings.ExpectedForeignRow(row.SourceLineNumbers, table.Name, urlace.Id, "WixHttpUrlReservation_", reservationId, "WixHttpUrlReservation"));
                }
            }
        }
Esempio n. 2
0
        /// <summary>
        /// Decompile the WixHttpUrlAce table.
        /// </summary>
        /// <param name="table">The table to decompile.</param>
        private void DecompileWixHttpUrlAceTable(Table table)
        {
            foreach (Row row in table.Rows)
            {
                Http.UrlAce urlace = new Http.UrlAce();
                urlace.Id = (string)row[0];
                urlace.SecurityPrincipal = (string)row[2];
                switch (Convert.ToInt32(row[3]))
                {
                    case HttpConstants.GENERIC_ALL:
                    default:
                        urlace.Rights = Http.UrlAce.RightsType.all;
                        break;
                    case HttpConstants.GENERIC_EXECUTE:
                        urlace.Rights = Http.UrlAce.RightsType.register;
                        break;
                    case HttpConstants.GENERIC_WRITE:
                        urlace.Rights = Http.UrlAce.RightsType.@delegate;
                        break;
                }

                string reservationId = (string)row[1];
                Http.UrlReservation urlReservation = (Http.UrlReservation)this.Core.GetIndexedElement("WixHttpUrlReservation", reservationId);
                if (null != urlReservation)
                {
                    urlReservation.AddChild(urlace);
                }
                else
                {
                    this.Core.OnMessage(WixWarnings.ExpectedForeignRow(row.SourceLineNumbers, table.Name, urlace.Id, "WixHttpUrlReservation_", reservationId, "WixHttpUrlReservation"));
                }
            }
        }