Platforms to show: All Mac Windows Linux Cross-Platform

Back to NSDateIntervalMBS class.

NSDateIntervalMBS.compare(DateInterval as NSDateIntervalMBS) as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa MBS MacFrameworks Plugin 20.2 ✅ Yes ❌ No ❌ No ✅ Yes All
Compares the receiver with the specified date interval.

dateInterval: The date interval with which to compare the receiver.

Returns an NSComparisonResult value that indicates the temporal ordering of the receiver and a given date interval:
NSOrderedAscending (-1) if the receiver’s startDate occurs earlier than that of dateInterval, or both startDate values are equal and the duration of the receiver is less than that of dateInterval.
NSOrderedDescending (1) if the receiver’s startDate occurs later than that of dateInterval, or both startDate values are equal and the duration of the receiver is greater than that of dateInterval.
NSOrderedSame (0) if the receiver’s startDate and duration values are equal to those of dateInterval.

NSDateIntervalMBS.Constructor

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa MBS MacFrameworks Plugin 20.2 ✅ Yes ❌ No ❌ No ✅ Yes All
Initializes a date interval by setting the start and end date to the current date.

See also:

NSDateIntervalMBS.Constructor(startDate as date, duration as double)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa MBS MacFrameworks Plugin 20.2 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Initializes a date interval with a given start date and duration.

startDate: The start date of the date interval.
duration: The duration from the start date for the date interval.

This method raises an NSExceptionMBS if duration is less than 0.

See also:

NSDateIntervalMBS.Constructor(startDate as date, endDate as date)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa MBS MacFrameworks Plugin 20.2 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Initializes a date interval from a given start date and end date.

startDate: The start date of the date interval.
endDate: The end date of the date interval.

This method raises an NSExceptionMBS if endDate occurs earlier than startDate.

See also:

NSDateIntervalMBS.Constructor(startDate as dateTime, endDate as dateTime)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa MBS MacFrameworks Plugin 20.5 ✅ Yes ❌ No ❌ No ✅ Yes All
Initializes a date interval from a given start date and end date.

startDate: The start date of the date interval.
endDate: The end date of the date interval.

This method raises an NSExceptionMBS if endDate occurs earlier than startDate.

See also:

NSDateIntervalMBS.containsDate(date as date) as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa MBS MacFrameworks Plugin 20.2 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Indicates whether the receiver contains the specified date.

date: The date for which to test membership of the date interval.

Returns true if the receiver contains date. Otherwise, false.

NSDateIntervalMBS.containsDateTime(date as dateTime) as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa MBS MacFrameworks Plugin 20.5 ✅ Yes ❌ No ❌ No ✅ Yes All
Indicates whether the receiver contains the specified date.

date: The date for which to test membership of the date interval.

Returns true if the receiver contains date. Otherwise, false.

NSDateIntervalMBS.copy as NSDateIntervalMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa MBS MacFrameworks Plugin 20.2 ✅ Yes ❌ No ❌ No ✅ Yes All
Creates a copy of the object.

NSDateIntervalMBS.intersectionWithDateInterval(DateInterval as NSDateIntervalMBS) as NSDateIntervalMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa MBS MacFrameworks Plugin 20.2 ✅ Yes ❌ No ❌ No ✅ Yes All
Returns the intersection between the receiver and the specified date interval.

dateInterval: The date interval with which to calculate the intersection of the receiver.

Returns a date interval for the intersection of the receiver and dateInterval, or nil if no intersection occurs.

Calculating the intersection of date intervals is a commutative and associative operation. The intersection of a date interval with itself is equal to itself.

NSDateIntervalMBS.intersectsDateInterval(DateInterval as NSDateIntervalMBS) as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa MBS MacFrameworks Plugin 20.2 ✅ Yes ❌ No ❌ No ✅ Yes All
Indicates whether the receiver intersects with the specified date interval.

dateInterval: The date interval with which to check the receiver for intersection.

See intersectionWithDateInterval for more information about determining whether two date intervals intersect.

NSDateIntervalMBS.isEqualToDateInterval(DateInterval as NSDateIntervalMBS) as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa MBS MacFrameworks Plugin 20.2 ✅ Yes ❌ No ❌ No ✅ Yes All
Indicates whether the receiver is equal to the specified date interval.

dateInterval: The date interval with which to check the receiver for equality.

Returns true if the startDate and duration of dateInterval and the receiver are equal. Otherwise, false.

NSDateIntervalMBS.Operator_Compare(DateInterval as NSDateIntervalMBS) as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa MBS MacFrameworks Plugin 20.2 ✅ Yes ❌ No ❌ No ✅ Yes All
The compare operator to use in Xojo.

The items on this page are in the following plugins: MBS MacFrameworks Plugin.


The biggest plugin in space...