Show / Hide Table of Contents

    Class ScheduledCallback

    Represents a action that should be scheduled with the operating system for execution at a future time.

    Inheritance
    System.Object
    ScheduledCallback
    Namespace: Sensus.Callbacks
    Assembly: SensusAndroid.dll
    Syntax
    public class ScheduledCallback : Object

    Constructors

    ScheduledCallback(ScheduledCallback.ActionAsyncDelegate, TimeSpan, String, String, Protocol, Nullable<TimeSpan>, TimeSpan, TimeSpan)

    Initializes a new instance of the ScheduledCallback class.

    Declaration
    public ScheduledCallback(ScheduledCallback.ActionAsyncDelegate actionAsync, TimeSpan delay, string id, string domain, Protocol protocol, Nullable<TimeSpan> timeout, TimeSpan delayToleranceBefore, TimeSpan delayToleranceAfter)
    Parameters
    Type Name Description
    ScheduledCallback.ActionAsyncDelegate actionAsync

    Action to execute when callback time arrives.

    System.TimeSpan delay

    How long to delay callback execution.

    System.String id

    Identifier for callback. Must be unique within the callback domain.

    System.String domain

    Domain of callback identifier. All callback IDs within a domain must be unique. If an ID duplicates another within the same domain, then it will not be scheduled.

    Protocol protocol

    Protocol associated with scheduled callback

    System.Nullable<System.TimeSpan> timeout

    How long to allow callback to execute before cancelling it.

    System.TimeSpan delayToleranceBefore

    Delay tolerance before.

    System.TimeSpan delayToleranceAfter

    Delay tolerance after.

    ScheduledCallback(ScheduledCallback.ActionAsyncDelegate, TimeSpan, TimeSpan, String, String, Protocol, Nullable<TimeSpan>, TimeSpan, TimeSpan)

    Initializes a new instance of the ScheduledCallback class.

    Declaration
    public ScheduledCallback(ScheduledCallback.ActionAsyncDelegate actionAsync, TimeSpan initialDelay, TimeSpan repeatDelay, string id, string domain, Protocol protocol, Nullable<TimeSpan> timeout, TimeSpan delayToleranceBefore, TimeSpan delayToleranceAfter)
    Parameters
    Type Name Description
    ScheduledCallback.ActionAsyncDelegate actionAsync

    Action to execute when callback time arrives.

    System.TimeSpan initialDelay

    How long to delay callback execution.

    System.TimeSpan repeatDelay

    How long to delay repeating callback executions following the first callback.

    System.String id

    Identifier for callback. Must be unique within the callback domain.

    System.String domain

    Domain of callback identifier. All callback IDs within a domain must be unique. If an ID duplicates another in the same domain, then it will not be scheduled.

    Protocol protocol

    Protocol associated with scheduled callback

    System.Nullable<System.TimeSpan> timeout

    How long to allow callback to execute before cancelling it.

    System.TimeSpan delayToleranceBefore

    Delay tolerance before.

    System.TimeSpan delayToleranceAfter

    Delay tolerance after.

    Properties

    ActionAsync

    Action to execute.

    Declaration
    public ScheduledCallback.ActionAsyncDelegate ActionAsync { get; set; }
    Property Value
    Type Description
    ScheduledCallback.ActionAsyncDelegate

    The action.

    Batched

    Gets or sets a value indicating whether this ScheduledCallback has been batched with another ScheduledCallback.

    Declaration
    public bool Batched { get; set; }
    Property Value
    Type Description
    System.Boolean

    true if batched; otherwise, false.

    Canceller

    Source of cancellation tokens to be cancelled when the action times out.

    Declaration
    public CancellationTokenSource Canceller { get; set; }
    Property Value
    Type Description
    System.Threading.CancellationTokenSource

    The canceller.

    Delay

    Gets or sets the delay of the action.

    Declaration
    public TimeSpan Delay { get; set; }
    Property Value
    Type Description
    System.TimeSpan

    The delay.

    DelayToleranceAfter

    Gets or sets the delay tolerance after NextExecution.

    Declaration
    public TimeSpan DelayToleranceAfter { get; set; }
    Property Value
    Type Description
    System.TimeSpan

    The delay tolerance.

    DelayToleranceBefore

    Gets or sets the delay tolerance before NextExecution.

    Declaration
    public TimeSpan DelayToleranceBefore { get; set; }
    Property Value
    Type Description
    System.TimeSpan

    The delay tolerance.

    DelayToleranceTotal

    Gets the delay tolerance total.

    Declaration
    public TimeSpan DelayToleranceTotal { get; }
    Property Value
    Type Description
    System.TimeSpan

    The delay tolerance total.

    Id

    Gets or sets the identifier.

    Declaration
    public string Id { get; set; }
    Property Value
    Type Description
    System.String

    The identifier.

    InvocationId

    Gets or sets the invocation identifier.

    Declaration
    public string InvocationId { get; set; }
    Property Value
    Type Description
    System.String

    The invocation identifier.

    NextExecution

    Gets or sets the next execution time for this callback.

    Declaration
    public Nullable<DateTime> NextExecution { get; set; }
    Property Value
    Type Description
    System.Nullable<System.DateTime>

    The next execution time.

    NotificationUserResponseAction

    Action to take after the user responds to (e.g., by tapping) the notification defined by UserNotificationMessage. If UserNotificationMessage is null, then this has no effect.

    Declaration
    public NotificationUserResponseAction NotificationUserResponseAction { get; set; }
    Property Value
    Type Description
    NotificationUserResponseAction

    The display page.

    NotificationUserResponseMessage

    Message to display after the user responds to (e.g., by tapping) the notification defined by UserNotificationMessage. If UserNotificationMessage is null, then this has no effect.

    Declaration
    public string NotificationUserResponseMessage { get; set; }
    Property Value
    Type Description
    System.String

    The notification user response message.

    Protocol

    Gets or sets the callback's protocol.

    Declaration
    public Protocol Protocol { get; set; }
    Property Value
    Type Description
    Protocol

    The protocol identifier.

    RepeatDelay

    For actions that are repeatedly executed, this is the delay between executions.

    Declaration
    public Nullable<TimeSpan> RepeatDelay { get; set; }
    Property Value
    Type Description
    System.Nullable<System.TimeSpan>

    The repeat delay.

    State

    Gets or sets the state.

    Declaration
    public ScheduledCallbackState State { get; set; }
    Property Value
    Type Description
    ScheduledCallbackState

    The state.

    Timeout

    Gets or sets the callback timeout. After this time has elapsed, the callback's cancellation token will be cancelled.

    Declaration
    public Nullable<TimeSpan> Timeout { get; set; }
    Property Value
    Type Description
    System.Nullable<System.TimeSpan>

    The callback timeout.

    UserNotificationMessage

    Notification message that should be displayed to the user at the time when the ScheduledCallback is scheduled to run. On iOS, this message will not be displayed when the app is in the foreground. On Android, this message will be displayed regardless of the foreground/background state of the app.

    Declaration
    public string UserNotificationMessage { get; set; }
    Property Value
    Type Description
    System.String

    The user notification message.

    Back to top Copyright © 2014-2018 University of Virginia
    Generated by DocFX