public GetFieldTypeAndNameFromXmlAttribute ( String xmlAttribute, String xmlNamespace, |
||
xmlAttribute | String | |
xmlNamespace | String | |
type | ||
name | String | |
return | void |
/// <summary>Retrieves field type from XML attribute name, namespace, and the <see cref="T:System.Type" /> of the containing object.</summary> /// <param name="containingType">The <see cref="T:System.Type" /> of the object that contains the field. </param> /// <param name="xmlAttribute">The XML attribute name of the field type. </param> /// <param name="xmlNamespace">The XML namespace of the field type. </param> /// <param name="type">When this method returns, contains a <see cref="T:System.Type" /> of the field. This parameter is passed uninitialized. </param> /// <param name="name">When this method returns, contains a <see cref="T:System.String" /> that holds the name of the field. This parameter is passed uninitialized. </param> /// <exception cref="T:System.Security.SecurityException">The immediate caller does not have infrastructure permission. </exception> // Token: 0x0600558F RID: 21903 RVA: 0x0012EDF0 File Offset: 0x0012CFF0 public static void GetInteropFieldTypeAndNameFromXmlAttribute(Type containingType, string xmlAttribute, string xmlNamespace, out Type type, out string name) { if (containingType == null) { type = null; name = null; return; } SoapServices.XmlToFieldTypeMap xmlToFieldTypeMap = (SoapServices.XmlToFieldTypeMap)SoapServices._xmlToFieldTypeMap[containingType]; if (xmlToFieldTypeMap != null) { xmlToFieldTypeMap.GetFieldTypeAndNameFromXmlAttribute(xmlAttribute, xmlNamespace, out type, out name); return; } type = null; name = null; }
/// <summary>从 XML 特性名、命名空间和包含对象的 <see cref="T:System.Type" /> 中检索字段类型。</summary> /// <param name="containingType">包含该字段的对象的 <see cref="T:System.Type" />。</param> /// <param name="xmlAttribute">该字段类型的 XML 特性名。</param> /// <param name="xmlNamespace">该字段类型的 XML 命名空间。</param> /// <param name="type">此方法返回时,包含该字段的 <see cref="T:System.Type" />。该参数未经初始化即被传递。</param> /// <param name="name">此方法返回时,包含保存该字段名的 <see cref="T:System.String" />。该参数未经初始化即被传递。</param> /// <exception cref="T:System.Security.SecurityException">直接调用方没有基础结构权限。</exception> /// <PermissionSet> /// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" /> /// </PermissionSet> public static void GetInteropFieldTypeAndNameFromXmlAttribute(Type containingType, string xmlAttribute, string xmlNamespace, out Type type, out string name) { if (containingType == (Type)null) { type = (Type)null; name = (string)null; } else { SoapServices.XmlToFieldTypeMap xmlToFieldTypeMap = (SoapServices.XmlToFieldTypeMap)SoapServices._xmlToFieldTypeMap[(object)containingType]; if (xmlToFieldTypeMap != null) { xmlToFieldTypeMap.GetFieldTypeAndNameFromXmlAttribute(xmlAttribute, xmlNamespace, out type, out name); } else { type = (Type)null; name = (string)null; } } }