Click or drag to resize

DurationFormatter Class

Converts a data value which represents a duration in seconds to a formatted string.

Input: Single (Duration in seconds).

Output: String (Formated duration).

Inheritance Hierarchy
SystemObject
  UnityEngineObject
    UnityEngineComponent
      UnityEngineBehaviour
        UnityEngineMonoBehaviour
          Slash.Unity.DataBind.Core.PresentationDataBindingOperator
            Slash.Unity.DataBind.Core.PresentationDataProvider
              Slash.Unity.DataBind.Foundation.Providers.FormattersDurationFormatter

Namespace:  Slash.Unity.DataBind.Foundation.Providers.Formatters
Assembly:  Assembly-CSharp (in Assembly-CSharp.dll) Version: 0.0.0.0
Syntax
public class DurationFormatter : DataProvider

The DurationFormatter type exposes the following members.

Constructors
  NameDescription
Public methodDurationFormatter
Initializes a new instance of the DurationFormatter class
Top
Properties
Methods
Fields
  NameDescription
Public fieldArgument
Data value which contains the duration in seconds.
Public fieldDaysSymbol
Text to show after the days value, if shown.
Public fieldHoursSymbol
Text to show after the hours value, if shown.
Public fieldMinutesSymbol
Text to show after the minutes value, if shown.
Public fieldSecondsSymbol
Text to show after the seconds value, if shown.
Public fieldTimeUnits

How many time units to show.

Example: If set to two, will show hours and minutes if specified time is shorter than a day, or minutes and seconds if specified time is shorter than an hour.

Top
See Also