add setTaskID interface to framework

@xiaoyunwu We need to add this to make `HasChildren` and `HasParent` work.