目录

ActivityRecord.Builder

CLASS info

public static class Builder

Constructs a builder for ActivityRecord.

Public Method Summary

Return

Method

Builder

setName(String sessionName)

Sets the name of the activity record. The input parameter can be null or a string of 1 to 980 characters.

Builder

setId(String identifier)

Sets the identifier of the activity record. The input parameter can be a string of 1 to 1000 characters.

Builder

setStartTime(long startTimeMillis, TimeUnit timeUnit)

Sets the start time of the activity record based on the passed time unit.

Builder

setEndTime(long endTimeMillis, TimeUnit timeUnit)

Sets the end time of the activity record based on the passed time unit.

Builder

setDurationTime(long time, TimeUnit timeUnit)

Sets the duration of the activity record based on the passed time unit.

Builder

setActivityTypeId(String activityType)

Sets the activity type associated with the activity record.

Builder

setDesc(String describer)

Sets the description of the activity record. The input parameter can be null, an empty string, or a string of 1 to 1000 characters.

ActivityRecord

build()

Builds and returns the activity record instance.

Public Methods

[h2]setName(String sessionName)

Method

public ActivityRecord.Builder setName(String sessionName)

Sets the name of the activity record.

Parameters

Parameter name

Parameter desc

sessionName

Name of the activity record.

Return

Type

Return desc

ActivityRecord.Builder

Builder.

[h2]setId(String identifier)

Method

public ActivityRecord.Builder setId(String identifier)

Sets the identifier of the activity record.

Parameters

Parameter name

Parameter desc

identifier

Identifier of the activity record.

Return

Type

Return desc

ActivityRecord.Builder

Builder.

[h2]setStartTime(long startTimeMillis, TimeUnit timeUnit)

Method

public ActivityRecord.Builder setStartTime(long startTimeMillis, TimeUnit timeUnit)

Sets the start time of the activity record based on the passed time unit.

Parameters

Parameter name

Parameter desc

startTimeMillis

Start time.

timeUnit

Time unit.

Return

Type

Return desc

ActivityRecord.Builder

Builder.

[h2]setEndTime(long endTimeMillis, TimeUnit timeUnit)

Method

public ActivityRecord.Builder setEndTime(long endTimeMillis, TimeUnit timeUnit)

Sets the end time of the activity record based on the passed time unit. If the end time is not specified, the activity record is considered as still being in progress.

Parameters

Parameter name

Parameter desc

endTimeMillis

End time.

timeUnit

Time unit.

Return

Type

Return desc

Builder

Builder.

[h2]setDurationTime(long time, TimeUnit timeUnit)

Method

public ActivityRecord.Builder setDurationTime(long time, TimeUnit timeUnit)

Sets the duration of the activity record based on the passed time unit.

Parameters

Parameter name

Parameter desc

time

Time.

timeUnit

Time unit.

Return

Type

Return desc

Builder

Builder.

[h2]setActivityTypeId(String activityType)

Method

public ActivityRecord.Builder setActivityTypeId(String activityType)

Sets the activity type associated with the activity record.

Parameters

Parameter name

Parameter desc

activityType

Activity type.

Return

Type

Return desc

Builder

Builder.

[h2]setDesc(String describer)

Method

public ActivityRecord.Builder setDesc(String describer)

Sets the description of the activity record.

Parameters

Parameter name

Parameter desc

describer

Description.

Return

Type

Return desc

Builder

Builder.

[h2]build()

Method

public ActivityRecord build()

Builds and returns the activity record.

Return

Type

Return desc

ActivityRecord

Activity record.