'Get the value of an attribute by name.
@param name: The name of the attribute.
@type name: basestring
@param ns: The optional attribute\'s namespace.
@type ns: (I{prefix}, I{name})
@param default: An optional value to be returned when either
the attribute does not exist of has not value.
@type default: basestring
@return: The attribute\'s value or I{default}
@rtype: basestring
@see: __getitem__()'

def get(self, name, ns=None, default=None):

    attr = self.getAttribute(name, ns)
    if ((attr is None) or (attr.value is None)):
        return default
    else:
        return attr.getValue()
