Package com.taskadapter.redmineapi.bean
Class TimeEntry
- java.lang.Object
-
- com.taskadapter.redmineapi.bean.TimeEntry
-
- All Implemented Interfaces:
FluentStyle,Identifiable
public class TimeEntry extends java.lang.Object implements Identifiable, FluentStyle
-
-
Field Summary
Fields Modifier and Type Field Description static Property<java.lang.Integer>ACTIVITY_IDstatic Property<java.lang.String>ACTIVITY_NAMEstatic Property<java.lang.String>COMMENTstatic Property<java.util.Date>CREATED_ONstatic Property<java.util.Set<CustomField>>CUSTOM_FIELDSstatic Property<java.lang.Integer>DATABASE_IDdatabase numeric Idstatic Property<java.lang.Float>HOURSstatic Property<java.lang.Integer>ISSUE_IDdatabase Id of the Issuestatic Property<java.lang.Integer>PROJECT_IDdatabase Id of the projectstatic Property<java.lang.String>PROJECT_NAMEstatic Property<java.util.Date>SPENT_ONstatic Property<java.util.Date>UPDATED_ONstatic Property<java.lang.Integer>USER_IDstatic Property<java.lang.String>USER_NAME
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddCustomFields(java.util.Collection<CustomField> customFields)voidclearCustomFields()TimeEntrycreate()voiddelete()booleanequals(java.lang.Object o)java.lang.IntegergetActivityId()java.lang.StringgetActivityName()java.lang.StringgetComment()java.util.DategetCreatedOn()CustomFieldgetCustomField(java.lang.String name)java.util.Set<CustomField>getCustomFields()java.lang.FloatgetHours()java.lang.IntegergetId()java.lang.IntegergetIssueId()java.lang.IntegergetProjectId()java.lang.StringgetProjectName()java.util.DategetSpentOn()PropertyStoragegetStorage()java.util.DategetUpdatedOn()java.lang.IntegergetUserId()java.lang.StringgetUserName()inthashCode()booleanisValid()TimeEntrysetActivityId(java.lang.Integer activityId)voidsetActivityName(java.lang.String activityName)TimeEntrysetComment(java.lang.String comment)voidsetCreatedOn(java.util.Date createdOn)TimeEntrysetHours(java.lang.Float hours)TimeEntrysetId(java.lang.Integer id)TimeEntrysetIssueId(java.lang.Integer issueId)TimeEntrysetProjectId(java.lang.Integer projectId)voidsetProjectName(java.lang.String projectName)TimeEntrysetSpentOn(java.util.Date spentOn)voidsetTransport(Transport transport)voidsetUpdatedOn(java.util.Date updatedOn)TimeEntrysetUserId(java.lang.Integer userId)voidsetUserName(java.lang.String userName)java.lang.StringtoString()voidupdate()
-
-
-
Field Detail
-
DATABASE_ID
public static final Property<java.lang.Integer> DATABASE_ID
database numeric Id
-
ISSUE_ID
public static final Property<java.lang.Integer> ISSUE_ID
database Id of the Issue
-
PROJECT_ID
public static final Property<java.lang.Integer> PROJECT_ID
database Id of the project
-
PROJECT_NAME
public static final Property<java.lang.String> PROJECT_NAME
-
USER_NAME
public static final Property<java.lang.String> USER_NAME
-
USER_ID
public static final Property<java.lang.Integer> USER_ID
-
ACTIVITY_NAME
public static final Property<java.lang.String> ACTIVITY_NAME
-
ACTIVITY_ID
public static final Property<java.lang.Integer> ACTIVITY_ID
-
HOURS
public static final Property<java.lang.Float> HOURS
-
COMMENT
public static final Property<java.lang.String> COMMENT
-
SPENT_ON
public static final Property<java.util.Date> SPENT_ON
-
CREATED_ON
public static final Property<java.util.Date> CREATED_ON
-
UPDATED_ON
public static final Property<java.util.Date> UPDATED_ON
-
CUSTOM_FIELDS
public static final Property<java.util.Set<CustomField>> CUSTOM_FIELDS
-
-
Constructor Detail
-
TimeEntry
public TimeEntry(Transport transport)
-
-
Method Detail
-
setId
public TimeEntry setId(java.lang.Integer id)
- Parameters:
id- database Id
-
getId
public java.lang.Integer getId()
- Specified by:
getIdin interfaceIdentifiable
-
getUserId
public java.lang.Integer getUserId()
-
setUserId
public TimeEntry setUserId(java.lang.Integer userId)
-
getIssueId
public java.lang.Integer getIssueId()
-
setIssueId
public TimeEntry setIssueId(java.lang.Integer issueId)
-
getProjectId
public java.lang.Integer getProjectId()
-
setProjectId
public TimeEntry setProjectId(java.lang.Integer projectId)
-
getProjectName
public java.lang.String getProjectName()
-
setProjectName
public void setProjectName(java.lang.String projectName)
-
getActivityName
public java.lang.String getActivityName()
-
setActivityName
public void setActivityName(java.lang.String activityName)
-
getActivityId
public java.lang.Integer getActivityId()
-
setActivityId
public TimeEntry setActivityId(java.lang.Integer activityId)
-
getHours
public java.lang.Float getHours()
-
setHours
public TimeEntry setHours(java.lang.Float hours)
-
getComment
public java.lang.String getComment()
-
setComment
public TimeEntry setComment(java.lang.String comment)
-
getSpentOn
public java.util.Date getSpentOn()
-
setSpentOn
public TimeEntry setSpentOn(java.util.Date spentOn)
-
getCreatedOn
public java.util.Date getCreatedOn()
-
setCreatedOn
public void setCreatedOn(java.util.Date createdOn)
-
getUpdatedOn
public java.util.Date getUpdatedOn()
-
setUpdatedOn
public void setUpdatedOn(java.util.Date updatedOn)
-
getUserName
public java.lang.String getUserName()
-
setUserName
public void setUserName(java.lang.String userName)
-
getCustomField
public CustomField getCustomField(java.lang.String name)
- Returns:
- the custom field with given name or NULL if the field is not found
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
getCustomFields
public java.util.Set<CustomField> getCustomFields()
-
clearCustomFields
public void clearCustomFields()
-
addCustomFields
public void addCustomFields(java.util.Collection<CustomField> customFields)
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
isValid
public boolean isValid()
-
getStorage
public PropertyStorage getStorage()
-
setTransport
public void setTransport(Transport transport)
- Specified by:
setTransportin interfaceFluentStyle
-
create
public TimeEntry create() throws RedmineException
- Throws:
RedmineException
-
update
public void update() throws RedmineException- Throws:
RedmineException
-
delete
public void delete() throws RedmineException- Throws:
RedmineException
-
-