def to_vobject(self, project=None, uid=None):
self._update()<EOL>vtodos = iCalendar()<EOL>if uid:<EOL><INDENT>uid = uid.split('<STR_LIT:@>')[<NUM_LIT:0>]<EOL>if not project:<EOL><INDENT>for p in self._tasks:<EOL><INDENT>if uid in self._tasks[p]:<EOL><INDENT>project = p<EOL>break<EOL><DEDENT><DEDENT><DEDENT>self._gen_vtodo(self._tasks[basename(project)][uid], vtodos.add('<STR_LIT>'))<EOL><DEDENT>elif project:<EOL><INDENT>for task in self._tasks[basename(project)].values():<EOL><INDENT>self._gen_vtodo(task, vtodos.add('<STR_LIT>'))<EOL><DEDENT><DEDENT>else:<EOL><INDENT>for project in self._tasks:<EOL><INDENT>for task in self._tasks[project].values():<EOL><INDENT>self._gen_vtodo(task, vtodos.add('<STR_LIT>'))<EOL><DEDENT><DEDENT><DEDENT>return vtodos<EOL>
Return vObject object of Taskwarrior tasks
        If filename and UID are specified, the vObject only contains that task.
        If only a filename is specified, the vObject contains all events in the project.
        Otherwise the vObject contains all all objects of all files associated with the IcsTask object.

        project -- the Taskwarrior project
        uid -- the UID of the task