我有这样的功能:
def get_entity(entity_class, entity_id):
"get an entity by given entity id
@type entity_class: type
@type entity_id: long
@rtype: entity_class
"
return entity_class.get(entity_id)
我写了 pypredef 文件:
def get_entity(entity_class, entity_id):
"
@type entity_class: type
@type entity_id: long
"
return entity_class
并将其添加到预定义的完成中。但它不起作用。