def has_feature(self,var):
if not var:<EOL><INDENT>raise ValueError("<STR_LIT>")<EOL><DEDENT>if '<STR_LIT:">' not in var:<EOL><INDENT>expr='<STR_LIT>' % (var,)<EOL><DEDENT>elif "<STR_LIT:'>" not in var:<EOL><INDENT>expr="<STR_LIT>" % (var,)<EOL><DEDENT>else:<EOL><INDENT>raise ValueError("<STR_LIT>")<EOL><DEDENT>l=self.xpath_ctxt.xpathEval(to_utf8(expr))<EOL>if l:<EOL><INDENT>return True<EOL><DEDENT>else:<EOL><INDENT>return False<EOL><DEDENT>
Check if `self` contains the named feature.

        :Parameters:
            - `var`: the feature name.
        :Types:
            - `var`: `unicode`

        :return: `True` if the feature is found in `self`.
        :returntype: `bool`