Ok, let me exlplain my use case.
I have two task, task1->task2
task1 is a manual task, the form properties of this task has 1 form property named count of type long.
Now task 2 is also a manual task, the form properties of task2 uses an external form, like UserFormType. Added a renderer for this form Type. this custom form type shows a custom field which can contain n textFields, n is passed in the constructor.
The way i thought i can do this is get the count variable using
ProcessEngines.getDefaultProcessEngine().getTaskService().getVariable(taskId, "count")
but i dont know the way to get the current task id.
If there is a better way to do this then suggest. I am working over the activity-explorer.