def METHOD_NAME(self):
    ExpatParser.METHOD_NAME(self)
    if self.forbid_dtd:
        self._parser.StartDoctypeDeclHandler = self.start_doctype_decl
    if self.forbid_entities:
        self._parser.EntityDeclHandler = self.entity_decl
        self._parser.UnparsedEntityDeclHandler = self.unparsed_entity_decl