提交 25e33078 编写于 作者: G Gian Merlino

Simplify AbstractTask constructor

上级 d8493f8e
......@@ -58,11 +58,7 @@ public abstract class AbstractTask implements Task
protected AbstractTask(String id, String groupId, String dataSource, Interval interval)
{
this.id = Preconditions.checkNotNull(id, "id");
this.groupId = Preconditions.checkNotNull(groupId, "groupId");
this.taskResource = new TaskResource(id, 1);
this.dataSource = Preconditions.checkNotNull(dataSource, "dataSource");
this.interval = Optional.fromNullable(interval);
this(id, groupId, new TaskResource(id, 1), dataSource, interval);
}
protected AbstractTask(String id, String groupId, TaskResource taskResource, String dataSource, Interval interval)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册