Logo Search packages:      
Sourcecode: poco version File versions  Download package

bool Poco::XML::NamespaceSupport::undeclarePrefix ( const XMLString &  prefix  ) 

Declare a Namespace prefix. All prefixes must be declared before they are referenced. For example, a SAX driver (parser) would scan an element's attributes in two passes: first for namespace declarations, then a second pass using processName() to interpret prefixes against (potentially redefined) prefixes.

This method declares a prefix in the current Namespace context; the prefix will remain in force until this context is popped, unless it is shadowed in a descendant context.

To declare the default element Namespace, use the empty string as the prefix.

Note that you must not declare a prefix after you've pushed and popped another Namespace context, or treated the declarations phase as complete by processing a prefixed name.

Returns true if the prefix was legal, false otherwise.

Definition at line 77 of file NamespaceSupport.cpp.

Referenced by Poco::XML::XMLWriter::endPrefixMapping().

      for (ContextVec::reverse_iterator rit = _contexts.rbegin(); rit != _contexts.rend(); ++rit)
            Context::iterator it = rit->find(prefix);
            if (it != rit->end())
                  return true;
      return false;

Generated by  Doxygen 1.6.0   Back to index