import type { NobjcObject } from "objc-js";
import type { _NSData } from "../Foundation/NSData.js";
import type { _NSDate } from "../Foundation/NSDate.js";
import type { _NSDictionary } from "../Foundation/NSDictionary.js";
import type { _NSError } from "../Foundation/NSError.js";
import type { _NSObject } from "../Foundation/NSObject.js";
import type { _NSSecureCoding } from "../Foundation/NSSecureCoding.js";
import type { _HKHealthStore } from "./HKHealthStore.js";
import type { _HKLiveWorkoutBuilder } from "./HKLiveWorkoutBuilder.js";
import type { _HKWorkoutActivity } from "./HKWorkoutActivity.js";
import type { _HKWorkoutConfiguration } from "./HKWorkoutConfiguration.js";
import type { _HKWorkoutSessionDelegate } from "./HKWorkoutSessionDelegate.js";
import type { HKWorkoutActivityType } from "./HKWorkoutActivityType.js";
import type { HKWorkoutSessionLocationType } from "./HKWorkoutSessionLocationType.js";
import type { HKWorkoutSessionState } from "./HKWorkoutSessionState.js";
import type { HKWorkoutSessionType } from "./HKWorkoutSessionType.js";
export declare class _HKWorkoutSession extends _NSObject {
    static alloc(): _HKWorkoutSession;
    static new(): _HKWorkoutSession;
    init(): _HKWorkoutSession;
    /**
     * @method initWithActivityType:locationType: @param activityType The activity type of the workout session. @param locationType The type of location where the workout will be performed.
     * @deprecated initWithHealthStore:configuration:error:
     */
    initWithActivityType$locationType$(activityType: HKWorkoutActivityType, locationType: HKWorkoutSessionLocationType): _HKWorkoutSession;
    /**
     * @method initWithConfiguration:error: @param workoutConfiguration Configuration object describing the various properties of a workout. @param error If the configuration does not specify valid configuration properties, an an NSError describing the error is set and nil is returned.
     * @deprecated initWithHealthStore:configuration:error:
     */
    initWithConfiguration$error$(workoutConfiguration: _HKWorkoutConfiguration, error: NobjcObject | null): _HKWorkoutSession | null;
    /**
     * @method initWithHealthStore:configuration:error: @param healthStore Specifies the HKHealthStore object to use. @param workoutConfiguration Configuration object describing the various properties of a workout. @param error If the configuration does not specify valid configuration properties, an an NSError describing the error is set and nil is returned.
     */
    initWithHealthStore$configuration$error$(healthStore: _HKHealthStore, workoutConfiguration: _HKWorkoutConfiguration, error: NobjcObject | null): _HKWorkoutSession | null;
    /**
     * @method prepare @abstract Prepares the workout session for starting. @discussion This method will asynchronously prepare the workout session for starting. The state of the workout session will transition to HKWorkoutSessionStatePrepared. A prepared session will put the system in session mode, but will not start the session activity. You might call this methods, for example, prior to displaying a countdown on your application while waiting for the activity to start.
     */
    prepare(): void;
    /**
     * @method startActivityWithDate: @param date Start date for the workout session activity @abstract Starts the workout session activity. @discussion This method will asynchronously begin the workout session activity. The state of the workout session will transition to HKWorkoutSessionStateRunning. Once a session activity is started the system will be in session mode and sensor algorithms will be applied to generate data for the workout activity.
     */
    startActivityWithDate$(date: _NSDate | null): void;
    /**
     * @method stopActivityWithDate: @param date Stop date for the workout session activity @abstract Stops the workout session activity. @discussion This method will asynchronously stop the session activity if it is currently running. The state of the workout session will transition to HKWorkoutSessionStateStopped. Once a workout session is stopped, it cannot be reused to start a new workout session. Sensor algorithms will be stopped and no new data will be generated for this session. However, the system will remain in session mode.
     */
    stopActivityWithDate$(date: _NSDate | null): void;
    /**
     * @method end @abstract Ends the workout session. @discussion This method will end the session if it is currently running or stopped. The state of the workout session will transition to HKWorkoutSessionStateEnded. Once a workout session is ended, it cannot be reused to start a new workout session. Sensor algorithms will be stopped, no new data will be generated for this session, and the system will exit session mode.
     */
    end(): void;
    /**
     * @method pause @abstract Pauses the workout session. @discussion This method will pause the session if it is currently running. The state of the workout session will transition to HKWorkoutSessionStatePaused. An HKWorkoutEventTypePause will be generated and delivered to the workout session's delegate.
     */
    pause(): void;
    /**
     * @method resume @abstract Resumes the workout session. @discussion This method will resume the session if it is currently paused. The state of the workout session will transition to HKWorkoutSessionStateRunning. An HKWorkoutEventTypeResume will be generated and delivered to the workout session's delegate.
     */
    resume(): void;
    /**
     * @method associatedWorkoutBuilder @abstract Retrieves (and creates if necessary) an HKLiveWorkoutBuilder associated with this session. @discussion A session may have associated with it an HKLiveWorkoutBuilder that will be used to record the workout for this session. This method will return the session's associated builder, creating it if needed. Calling this method more than once will return the previously-created builder. If this session was not initialized with initWithHealthStore:configuration:error:, an exception will be thrown.
     */
    associatedWorkoutBuilder(): _HKLiveWorkoutBuilder;
    /**
     * @method beginNewActivityWithConfiguration:date:metadata: @abstract Begins a new workout activity for this session. @discussion This method will asynchronously begin the workout activity. The delegate for this session would be informed once the activity effectively begins. Sensor algorithms to generate data would be updated to match the new activity.
     */
    beginNewActivityWithConfiguration$date$metadata$(workoutConfiguration: _HKWorkoutConfiguration, date: _NSDate, metadata: _NSDictionary | null): void;
    /**
     * @method endCurrentActivityOnDate: @abstract Ends the current workout activity. @discussion This method will end the current activity, reverting to the main session activity. The delegate for this session would be informed once the activity effectively ends. Sensor algorithms to generate data would be updated to match the main session activity.
     */
    endCurrentActivityOnDate$(date: _NSDate): void;
    /**
     * @method startMirroringToCompanionDeviceWithCompletion: @abstract Starts mirroring the session to the companion device. @discussion Calling this method will result in your app on the companion device being launched in the background. When your app is launched set the `HKHealthStore` `workoutSessionMirroringStartHandler` property to retrieve the mirrored session. This method will fail if called for a session that is ended. The completion handler will be executed on an arbitrary background queue.
     */
    startMirroringToCompanionDeviceWithCompletion$(completion: ((success: boolean, error: _NSError) => void) | null): void;
    /**
     * @method stopMirroringToCompanionDeviceWithCompletion: @abstract Stops mirroring the session to the companion device. @discussion Calling this method will stop sending data to the companion device. The mirrored session's delegate method `didDisconnectFromRemoteDeviceWithError:` will be called to indicate that. When a workout session is ended, mirroring is automatically stopped. The completion handler will be executed on an arbitrary background queue.
     */
    stopMirroringToCompanionDeviceWithCompletion$(completion: ((success: boolean, error: _NSError) => void) | null): void;
    /**
     * @method sendDataToRemoteWorkoutSession:completion: @abstract Sends an NSData object to the connected remote workout session. @discussion This method can be called to send data from a primary session to its mirrored counterpart and vice-versa. It's only intended to be used for data that describes the current state of the workout, such as accumulated metrics, and any data needed to keep your app on both devices in sync. The maximum amount of data that can be sent is 100 KB in any given 10-second time window. If this limit is exceeded, an error will be returned in the completion handler. An error will also be returned if the session is not mirroring. The completion handler will be executed on an arbitrary background queue.
     */
    sendDataToRemoteWorkoutSession$completion$(data: _NSData, completion: ((success: boolean, error: _NSError) => void) | null): void;
    /**
     * @property activityType @abstract Indicates the type of workout that will be performed during the session.
     * @deprecated workoutConfiguration
     */
    activityType(): HKWorkoutActivityType;
    /**
     * @property locationType @abstract Indicates the type of location (indoors vs. outdoors) where the workout will take place. @discussion Knowing the location type allows for more accurate measurements and better performance.
     * @deprecated workoutConfiguration
     */
    locationType(): HKWorkoutSessionLocationType;
    /**
     * @property workoutConfiguration @abstract The configuration object describing the workout. @discussion This returns a copy of the configuration passed when creating the HKWorkoutSession. Changes made to the returned object have no impact on the HKWorkoutSession.
     */
    workoutConfiguration(): _HKWorkoutConfiguration;
    /**
     * @property delegate @abstract The session delegate, which receives @discussion The session delegate object is the one implementing the methods that get called when the session state changes or a failure occurs in the session.
     */
    delegate(): _HKWorkoutSessionDelegate | null;
    setDelegate$(value: _HKWorkoutSessionDelegate | null): void;
    /**
     * @property state @abstract Indicates the current state of the workout session. @discussion Each time this value is updated, the delegate method workoutSession:didChangeToState:fromState:date: will be called.
     */
    state(): HKWorkoutSessionState;
    /**
     * @property type @abstract Indicates the type of the workout session. @discussion A workout session created using an initializer will be primary, while a session retrieved with the `HKHealthStore` `workoutSessionMirroringStartHandler` property will be mirrored.
     */
    type(): HKWorkoutSessionType;
    /**
     * @property startDate @abstract Indicates the date when the workout session started running. @discussion This value is nil when a workout session is initialized. It is set when the workout session state changes to HKWorkoutSessionStateRunning.
     */
    startDate(): _NSDate | null;
    /**
     * @property endDate @abstract Indicates the date when the workout session stopped. @discussion This value is nil when a workout session is initialized. It is set when the workout session state changes to HKWorkoutSessionStateStopped.
     */
    endDate(): _NSDate | null;
    /**
     * @property currentActivity @abstract The current workout activity. @discussion This returns a copy of the session's current workout activity. It will return a copy of the main workout activity if no new activity has begun. Changes made to the returned object have no impact on the HKWorkoutSession.
     */
    currentActivity(): _HKWorkoutActivity;
}
export interface _HKWorkoutSession extends _NSSecureCoding {
}
