-
Notifications
You must be signed in to change notification settings - Fork 207
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
1681816
commit b167c08
Showing
3 changed files
with
130 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
package io.dapr.client.domain; | ||
|
||
import com.google.protobuf.Message; | ||
|
||
/** | ||
* A Job to schedule | ||
* | ||
* @param <T> The class type of Job data. | ||
*/ | ||
public final class Job<T extends Message> { | ||
|
||
private final String name; | ||
|
||
private String schedule; | ||
|
||
private Integer repeats; | ||
|
||
private String dueTime; | ||
|
||
private String ttl; | ||
|
||
private final T data; | ||
|
||
/** | ||
* Constructor for Job | ||
* | ||
* @param name name of the job to create | ||
*/ | ||
public Job(String name, T data) { | ||
super(); | ||
this.name = name; | ||
this.data = data; | ||
} | ||
|
||
public String getSchedule() { | ||
return schedule; | ||
} | ||
|
||
public void setSchedule(String schedule) { | ||
this.schedule = schedule; | ||
} | ||
|
||
public Integer getRepeats() { | ||
return repeats; | ||
} | ||
|
||
public void setRepeats(Integer repeats) { | ||
this.repeats = repeats; | ||
} | ||
|
||
public String getDueTime() { | ||
return dueTime; | ||
} | ||
|
||
public void setDueTime(String dueTime) { | ||
this.dueTime = dueTime; | ||
} | ||
|
||
public String getTtl() { | ||
return ttl; | ||
} | ||
|
||
public void setTtl(String ttl) { | ||
this.ttl = ttl; | ||
} | ||
|
||
public T getData() { | ||
return data; | ||
} | ||
|
||
public String getName() { | ||
return name; | ||
} | ||
} |