コード例 #1
0
 /// <summary>
 /// Get the standard tag name for an <see cref="InjectionMemberElement"/>
 /// taking into account currently loaded section extensions.
 /// </summary>
 /// <param name="memberElement">Element to get the name for.</param>
 /// <returns>The element name.</returns>
 /// <exception cref="ArgumentException">If the member element is not currently registered
 /// with the section.</exception>
 public static string GetMemberElementName(InjectionMemberElement memberElement)
 {
     Guard.ArgumentNotNull(memberElement, "memberElement");
     return(memberElement.ElementName);
 }
コード例 #2
0
 /// <summary>
 /// Get the standard tag name for an <see cref="InjectionMemberElement"/>
 /// taking into account currently loaded section extensions.
 /// </summary>
 /// <param name="memberElement">Element to get the name for.</param>
 /// <returns>The element name.</returns>
 /// <exception cref="ArgumentException">If the member element is not currently registered
 /// with the section.</exception>
 public static string GetMemberElementName(InjectionMemberElement memberElement)
 {
     Guard.ArgumentNotNull(memberElement, "memberElement");
     return memberElement.ElementName;
 }
コード例 #3
0
        ///<summary>
        ///Gets the element key for a specified configuration element when overridden in a derived class.
        ///</summary>
        ///
        ///<returns>
        ///An <see cref="T:System.Object"></see> that acts as the key for the specified <see cref="T:System.Configuration.ConfigurationElement"></see>.
        ///</returns>
        ///
        ///<param name="element">The <see cref="T:System.Configuration.ConfigurationElement"></see> to return the key for. </param>
        protected override object GetElementKey(ConfigurationElement element)
        {
            InjectionMemberElement e = (InjectionMemberElement)element;

            return(e.GetElementKey());
        }
コード例 #4
0
 private bool DeserializeAndAdd(InjectionMemberElement element, XmlReader reader)
 {
     element.DeserializeElement(reader);
     BaseAdd(element);
     return(true);
 }
コード例 #5
0
        ///<summary>
        ///Gets the element key for a specified configuration element when overridden in a derived class.
        ///</summary>
        ///
        ///<returns>
        ///An <see cref="T:System.Object"></see> that acts as the key for the specified <see cref="T:System.Configuration.ConfigurationElement"></see>.
        ///</returns>
        ///
        ///<param name="element">The <see cref="T:System.Configuration.ConfigurationElement"></see> to return the key for. </param>
        protected override object GetElementKey(ConfigurationElement element)
        {
            InjectionMemberElement e = (InjectionMemberElement)element;

            return(e.ElementName + ":" + e.Name);
        }