コード例 #1
0
 /// <summary>
 /// On property
 /// </summary>
 /// <param name="pProperty">Property</param>
 protected void OnProperty(ConfigurationFileProperty pProperty)
 {
     if (this.Property != null)
     {
         this.Property(this, new ConfigurationFilePropertyEventArgs(pProperty));
     }
 }
コード例 #2
0
        /// <summary>
        /// Setting property
        /// </summary>
        /// <param name="pPropertyName">Property name</param>
        /// <param name="pPropertyValue">Property value</param>
        public void SetProperty(string pPropertyName, string pPropertyValue)
        {
            ConfigurationFileProperty lProperty = this.FindProperty(pPropertyName);

            if (lProperty != null)
            {
                lProperty.Value = pPropertyValue;
            }
            else
            {
                this.Properties.Add(new ConfigurationFileProperty(pPropertyName, pPropertyValue));
            }
        }
コード例 #3
0
        /// <summary>
        /// Getting property
        /// </summary>
        /// <param name="pPropertyName">Property name</param>
        /// <returns>Property value</returns>
        public string GetProperty(string pPropertyName)
        {
            ConfigurationFileProperty lProperty = this.FindProperty(pPropertyName);

            if (lProperty != null)
            {
                return(lProperty.Value);
            }
            else
            {
                return(string.Empty);
            }
        }
コード例 #4
0
 /// <summary>
 /// Standard constructor
 /// </summary>
 /// <param name="pProperty">Property</param>
 public ConfigurationFilePropertyEventArgs(ConfigurationFileProperty pProperty)
 {
     this.Property = pProperty;
 }