System::Xml::XmlDocument::CreateAttribute método
Contenido
[
Ocultar
]XmlDocument::CreateAttribute(const String&) method
Crea un XmlAttribute con el nombre especificado.
SharedPtr<XmlAttribute> System::Xml::XmlDocument::CreateAttribute(const String &name)
| Parámetro | Tipo | Descripción |
|---|---|---|
| name | const String& | El nombre calificado del atributo. Si el nombre contiene dos puntos, el valor de XmlNode::get_Prefix refleja la parte del nombre que precede al primer dos puntos y el valor de XmlDocument::get_LocalName refleja la parte del nombre que sigue al primer dos puntos. El XmlNode::get_NamespaceURI permanece vacío a menos que el prefijo sea un prefijo incorporado reconocido como xmlns. En este caso, get_NamespaceURI tiene un valor de http://www.w3.org/2000/xmlns/. |
ReturnValue
El nuevo XmlAttribute.
Ver también
- Typedef SharedPtr
- Class XmlAttribute
- Class String
- Class XmlDocument
- Namespace System::Xml
- Library Aspose.Page for C++
XmlDocument::CreateAttribute(const String&, const String&, const String&) method
Crea un XmlAttribute con el XmlNode::get_Prefix, el XmlDocument::get_LocalName y el XmlNode::get_NamespaceURI especificados.
virtual SharedPtr<XmlAttribute> System::Xml::XmlDocument::CreateAttribute(const String &prefix, const String &localName, const String &namespaceURI)
| Parámetro | Tipo | Descripción |
|---|---|---|
| prefix | const String& | El prefijo del atributo (si lo hay). String::Empty y nullptr son equivalentes. |
| localName | const String& | El nombre local del atributo. |
| namespaceURI | const String& | El URI del espacio de nombres del atributo (si lo hay). String::Empty y nullptr son equivalentes. Si prefix es xmlns, entonces este parámetro debe ser http://www.w3.org/2000/xmlns/; de lo contrario se lanza una excepción. |
ReturnValue
El nuevo XmlAttribute.
Ver también
- Typedef SharedPtr
- Class XmlAttribute
- Class String
- Class XmlDocument
- Namespace System::Xml
- Library Aspose.Page for C++
XmlDocument::CreateAttribute(const String&, const String&) method
Crea un XmlAttribute con el nombre calificado especificado y XmlNode::get_NamespaceURI.
SharedPtr<XmlAttribute> System::Xml::XmlDocument::CreateAttribute(const String &qualifiedName, const String &namespaceURI)
| Parámetro | Tipo | Descripción |
|---|---|---|
| qualifiedName | const String& | El nombre calificado del atributo. Si el nombre contiene dos puntos, el valor de XmlNode::get_Prefix reflejará la parte del nombre que precede al dos puntos y el valor de XmlDocument::get_LocalName reflejará la parte del nombre que sigue al dos puntos. |
| namespaceURI | const String& | El namespaceURI del atributo. Si el nombre calificado incluye un prefijo xmlns, entonces este parámetro debe ser http://www.w3.org/2000/xmlns/. |
ReturnValue
El nuevo XmlAttribute.
Ver también
- Typedef SharedPtr
- Class XmlAttribute
- Class String
- Class XmlDocument
- Namespace System::Xml
- Library Aspose.Page for C++