Back to index

plone3  3.1.7
Functions
Marshall.utils Namespace Reference

Functions

def fixtag

Function Documentation

def Marshall.utils.fixtag (   tag,
  namespaces 
)
returns the tag name seperated from the namespace uri
as givein in {some.namespace}tag in elementtree

Definition at line 3 of file utils.py.

00003 
00004 def fixtag(tag, namespaces):
00005     """ returns the tag name seperated from the namespace uri
00006     as givein in {some.namespace}tag in elementtree"""
00007     
00008     # given a decorated tag (of the form {uri}tag), return prefixed
00009     # tag and namespace declaration, if any
00010 
00011     namespace_uri, tag = tag[1:].split( "}", 1)
00012     ns = namespaces.get(namespace_uri)
00013     return tag, ns

Here is the call graph for this function: