Package apple.foundation
Class NSCalendar
- java.lang.Object
-
- org.moe.natj.general.NativeObject
-
- org.moe.natj.objc.ObjCObject
-
- apple.NSObject
-
- apple.foundation.NSCalendar
-
- All Implemented Interfaces:
NSCoding,NSCopying,NSSecureCoding,NSObject
public class NSCalendar extends NSObject implements NSCopying, NSSecureCoding
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interfaceNSCalendar.Block_enumerateDatesStartingAfterDateMatchingComponentsOptionsUsingBlock-
Nested classes/interfaces inherited from class apple.NSObject
NSObject.Block_accessibilityActivateBlock_ret, NSObject.Block_accessibilityActivationPointBlock_ret, NSObject.Block_accessibilityAttributedHintBlock_ret, NSObject.Block_accessibilityAttributedLabelBlock_ret, NSObject.Block_accessibilityAttributedUserInputLabelsBlock_ret, NSObject.Block_accessibilityAttributedValueBlock_ret, NSObject.Block_accessibilityContainerTypeBlock_ret, NSObject.Block_accessibilityCustomActionsBlock_ret, NSObject.Block_accessibilityCustomRotorsBlock_ret, NSObject.Block_accessibilityDecrementBlock_ret, NSObject.Block_accessibilityElementsBlock_ret, NSObject.Block_accessibilityElementsHiddenBlock_ret, NSObject.Block_accessibilityFrameBlock_ret, NSObject.Block_accessibilityHeaderElementsBlock_ret, NSObject.Block_accessibilityHintBlock_ret, NSObject.Block_accessibilityIdentifierBlock_ret, NSObject.Block_accessibilityIncrementBlock_ret, NSObject.Block_accessibilityLabelBlock_ret, NSObject.Block_accessibilityLanguageBlock_ret, NSObject.Block_accessibilityMagicTapBlock_ret, NSObject.Block_accessibilityNavigationStyleBlock_ret, NSObject.Block_accessibilityPathBlock_ret, NSObject.Block_accessibilityPerformEscapeBlock_ret, NSObject.Block_accessibilityRespondsToUserInteractionBlock_ret, NSObject.Block_accessibilityShouldGroupAccessibilityChildrenBlock_ret, NSObject.Block_accessibilityTextualContextBlock_ret, NSObject.Block_accessibilityTraitsBlock_ret, NSObject.Block_accessibilityUserInputLabelsBlock_ret, NSObject.Block_accessibilityValueBlock_ret, NSObject.Block_accessibilityViewIsModalBlock_ret, NSObject.Block_automationElementsBlock_ret, NSObject.Block_isAccessibilityElementBlock_ret, NSObject.Block_setAccessibilityActivateBlock, NSObject.Block_setAccessibilityActivationPointBlock, NSObject.Block_setAccessibilityAttributedHintBlock, NSObject.Block_setAccessibilityAttributedLabelBlock, NSObject.Block_setAccessibilityAttributedUserInputLabelsBlock, NSObject.Block_setAccessibilityAttributedValueBlock, NSObject.Block_setAccessibilityContainerTypeBlock, NSObject.Block_setAccessibilityCustomActionsBlock, NSObject.Block_setAccessibilityCustomRotorsBlock, NSObject.Block_setAccessibilityDecrementBlock, NSObject.Block_setAccessibilityElementsBlock, NSObject.Block_setAccessibilityElementsHiddenBlock, NSObject.Block_setAccessibilityFrameBlock, NSObject.Block_setAccessibilityHeaderElementsBlock, NSObject.Block_setAccessibilityHintBlock, NSObject.Block_setAccessibilityIdentifierBlock, NSObject.Block_setAccessibilityIncrementBlock, NSObject.Block_setAccessibilityLabelBlock, NSObject.Block_setAccessibilityLanguageBlock, NSObject.Block_setAccessibilityMagicTapBlock, NSObject.Block_setAccessibilityNavigationStyleBlock, NSObject.Block_setAccessibilityPathBlock, NSObject.Block_setAccessibilityPerformEscapeBlock, NSObject.Block_setAccessibilityRespondsToUserInteractionBlock, NSObject.Block_setAccessibilityShouldGroupAccessibilityChildrenBlock, NSObject.Block_setAccessibilityTextualContextBlock, NSObject.Block_setAccessibilityTraitsBlock, NSObject.Block_setAccessibilityUserInputLabelsBlock, NSObject.Block_setAccessibilityValueBlock, NSObject.Block_setAccessibilityViewIsModalBlock, NSObject.Block_setAutomationElementsBlock, NSObject.Block_setIsAccessibilityElementBlock, NSObject.Function_instanceMethodForSelector_ret, NSObject.Function_methodForSelector_ret
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedNSCalendar(org.moe.natj.general.Pointer peer)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description boolean_supportsSecureCoding()This property must return YES on all classes that allow secure coding.static booleanaccessInstanceVariablesDirectly()static NSCalendaralloc()static NSCalendarallocWithZone(org.moe.natj.general.ptr.VoidPtr zone)@NotNull java.lang.StringAMSymbol()API-Since: 5.0static booleanautomaticallyNotifiesObserversForKey(@NotNull java.lang.String key)static @NotNull NSCalendarautoupdatingCurrentCalendar()tracks changes to user's preferred calendar identifier API-Since: 2.0@NotNull java.lang.StringcalendarIdentifier()static @Nullable NSCalendarcalendarWithIdentifier(@NotNull java.lang.String calendarIdentifierConstant)This method returns a new autoreleased calendar object of the given type, specified by a calendar identifier constant.static voidcancelPreviousPerformRequestsWithTarget(@NotNull java.lang.Object aTarget)static voidcancelPreviousPerformRequestsWithTargetSelectorObject(@NotNull java.lang.Object aTarget, @NotNull org.moe.natj.objc.SEL aSelector, @Nullable java.lang.Object anArgument)static @NotNull NSArray<java.lang.String>classFallbacksForKeyedArchiver()static @NotNull org.moe.natj.objc.ClassclassForKeyedUnarchiver()longcompareDateToDateToUnitGranularity(@NotNull NSDate date1, @NotNull NSDate date2, long unit)This API compares the given dates down to the given unit, reporting them equal if they are the same in the given unit and all larger units, otherwise either less than or greater than.longcomponentFromDate(long unit, @NotNull NSDate date)Get just one component's value.@NotNull NSDateComponentscomponentsFromDate(long unitFlags, @NotNull NSDate date)@NotNull NSDateComponentscomponentsFromDateComponentsToDateComponentsOptions(long unitFlags, @NotNull NSDateComponents startingDateComp, @NotNull NSDateComponents resultDateComp, long options)This API returns the difference between two dates specified as date components.@NotNull NSDateComponentscomponentsFromDateToDateOptions(long unitFlags, @NotNull NSDate startingDate, @NotNull NSDate resultDate, long opts)@NotNull NSDateComponentscomponentsInTimeZoneFromDate(@NotNull NSTimeZone timezone, @NotNull NSDate date)This API returns all the date components of a date, as if in a given time zone (instead of the receiving calendar's time zone).@NotNull java.lang.ObjectcopyWithZone(@Nullable org.moe.natj.general.ptr.VoidPtr zone)static @NotNull NSCalendarcurrentCalendar()user's preferred calendar@Nullable NSDatedateByAddingComponentsToDateOptions(@NotNull NSDateComponents comps, @NotNull NSDate date, long opts)@Nullable NSDatedateByAddingUnitValueToDateOptions(long unit, long value, @NotNull NSDate date, long options)This API returns a new NSDate object representing the date calculated by adding an amount of a specific component to a given date.@Nullable NSDatedateBySettingHourMinuteSecondOfDateOptions(long h, long m, long s, @NotNull NSDate date, long opts)This API returns a new NSDate object representing the date calculated by setting hour, minute, and second to a given time.@Nullable NSDatedateBySettingUnitValueOfDateOptions(long unit, long v, @NotNull NSDate date, long opts)This API returns a new NSDate object representing the date calculated by setting a specific component to a given time, and trying to keep lower components the same.@Nullable NSDatedateFromComponents(@NotNull NSDateComponents comps)booleandateMatchesComponents(@NotNull NSDate date, @NotNull NSDateComponents components)This API returns YES if the date has all the matched components.@Nullable NSDatedateWithEraYearForWeekOfYearWeekOfYearWeekdayHourMinuteSecondNanosecond(long eraValue, long yearValue, long weekValue, long weekdayValue, long hourValue, long minuteValue, long secondValue, long nanosecondValue)Create a date with given components.@Nullable NSDatedateWithEraYearMonthDayHourMinuteSecondNanosecond(long eraValue, long yearValue, long monthValue, long dayValue, long hourValue, long minuteValue, long secondValue, long nanosecondValue)Create a date with given components.static java.lang.StringdebugDescription_static()static java.lang.Stringdescription_static()voidencodeWithCoder(@NotNull NSCoder coder)voidenumerateDatesStartingAfterDateMatchingComponentsOptionsUsingBlock(@NotNull NSDate start, @NotNull NSDateComponents comps, long opts, @NotNull NSCalendar.Block_enumerateDatesStartingAfterDateMatchingComponentsOptionsUsingBlock block)This method computes the dates which match (or most closely match) a given set of components, and calls the block once for each of them, until the enumeration is stopped.@NotNull NSArray<java.lang.String>eraSymbols()Methods to return component name strings localized to the calendar's locale API-Since: 5.0longfirstWeekday()voidgetEraYearForWeekOfYearWeekOfYearWeekdayFromDate(@Nullable org.moe.natj.general.ptr.NIntPtr eraValuePointer, @Nullable org.moe.natj.general.ptr.NIntPtr yearValuePointer, @Nullable org.moe.natj.general.ptr.NIntPtr weekValuePointer, @Nullable org.moe.natj.general.ptr.NIntPtr weekdayValuePointer, @NotNull NSDate date)This API is a convenience for getting era, year for week-of-year calculations, week of year, and weekday of a given date.voidgetEraYearMonthDayFromDate(@Nullable org.moe.natj.general.ptr.NIntPtr eraValuePointer, @Nullable org.moe.natj.general.ptr.NIntPtr yearValuePointer, @Nullable org.moe.natj.general.ptr.NIntPtr monthValuePointer, @Nullable org.moe.natj.general.ptr.NIntPtr dayValuePointer, @NotNull NSDate date)This API is a convenience for getting era, year, month, and day of a given date.voidgetHourMinuteSecondNanosecondFromDate(@Nullable org.moe.natj.general.ptr.NIntPtr hourValuePointer, @Nullable org.moe.natj.general.ptr.NIntPtr minuteValuePointer, @Nullable org.moe.natj.general.ptr.NIntPtr secondValuePointer, @Nullable org.moe.natj.general.ptr.NIntPtr nanosecondValuePointer, @NotNull NSDate date)This API is a convenience for getting hour, minute, second, and nanoseconds of a given date.static longhash_static()NSCalendarinit()NSCalendarinitWithCalendarIdentifier(@NotNull java.lang.String ident)NSCalendarinitWithCoder(@NotNull NSCoder coder)NS_DESIGNATED_INITIALIZERstatic NSObject.Function_instanceMethodForSelector_retinstanceMethodForSelector(org.moe.natj.objc.SEL aSelector)static NSMethodSignatureinstanceMethodSignatureForSelector(org.moe.natj.objc.SEL aSelector)static booleaninstancesRespondToSelector(org.moe.natj.objc.SEL aSelector)booleanisDateEqualToDateToUnitGranularity(@NotNull NSDate date1, @NotNull NSDate date2, long unit)This API compares the given dates down to the given unit, reporting them equal if they are the same in the given unit and all larger units.booleanisDateInSameDayAsDate(@NotNull NSDate date1, @NotNull NSDate date2)This API compares the Days of the given dates, reporting them equal if they are in the same Day.booleanisDateInToday(@NotNull NSDate date)This API reports if the date is within "today".booleanisDateInTomorrow(@NotNull NSDate date)This API reports if the date is within "tomorrow".booleanisDateInWeekend(@NotNull NSDate date)This API reports if the date is within a weekend period, as defined by the calendar and calendar's locale.booleanisDateInYesterday(@NotNull NSDate date)This API reports if the date is within "yesterday".static booleanisSubclassOfClass(org.moe.natj.objc.Class aClass)static @NotNull NSSet<java.lang.String>keyPathsForValuesAffectingValueForKey(@NotNull java.lang.String key)@Nullable NSLocalelocale()@NotNull NSArray<java.lang.String>longEraSymbols()API-Since: 5.0NSRangemaximumRangeOfUnit(long unit)longminimumDaysInFirstWeek()NSRangeminimumRangeOfUnit(long unit)Calendrical calculations@NotNull NSArray<java.lang.String>monthSymbols()API-Since: 5.0static NSCalendarnew_objc()@Nullable NSDatenextDateAfterDateMatchingComponentsOptions(@NotNull NSDate date, @NotNull NSDateComponents comps, long options)This method computes the next date which matches (or most closely matches) a given set of components.@Nullable NSDatenextDateAfterDateMatchingHourMinuteSecondOptions(@NotNull NSDate date, long hourValue, long minuteValue, long secondValue, long options)This API returns a new NSDate object representing the date found which matches the given hour, minute, and second values.@Nullable NSDatenextDateAfterDateMatchingUnitValueOptions(@NotNull NSDate date, long unit, long value, long options)This API returns a new NSDate object representing the date found which matches a specific component value.booleannextWeekendStartDateIntervalOptionsAfterDate(@Nullable org.moe.natj.general.ptr.Ptr<NSDate> datep, @Nullable org.moe.natj.general.ptr.DoublePtr tip, long options, @NotNull NSDate date)Returns the range of the next weekend, via two by-reference parameters, which starts strictly after the given date.longordinalityOfUnitInUnitForDate(long smaller, long larger, @NotNull NSDate date)@NotNull java.lang.StringPMSymbol()API-Since: 5.0@NotNull NSArray<java.lang.String>quarterSymbols()API-Since: 5.0NSRangerangeOfUnitInUnitForDate(long smaller, long larger, @NotNull NSDate date)booleanrangeOfUnitStartDateIntervalForDate(long unit, @Nullable org.moe.natj.general.ptr.Ptr<NSDate> datep, @Nullable org.moe.natj.general.ptr.DoublePtr tip, @NotNull NSDate date)API-Since: 2.0booleanrangeOfWeekendStartDateIntervalContainingDate(@Nullable org.moe.natj.general.ptr.Ptr<NSDate> datep, @Nullable org.moe.natj.general.ptr.DoublePtr tip, @NotNull NSDate date)Find the range of the weekend around the given date, returned via two by-reference parameters.static booleanresolveClassMethod(org.moe.natj.objc.SEL sel)static booleanresolveInstanceMethod(org.moe.natj.objc.SEL sel)voidsetFirstWeekday(long value)voidsetLocale(@Nullable NSLocale value)voidsetMinimumDaysInFirstWeek(long value)voidsetTimeZone(@NotNull NSTimeZone value)static voidsetVersion_static(long aVersion)@NotNull NSArray<java.lang.String>shortMonthSymbols()API-Since: 5.0@NotNull NSArray<java.lang.String>shortQuarterSymbols()API-Since: 5.0@NotNull NSArray<java.lang.String>shortStandaloneMonthSymbols()API-Since: 5.0@NotNull NSArray<java.lang.String>shortStandaloneQuarterSymbols()API-Since: 5.0@NotNull NSArray<java.lang.String>shortStandaloneWeekdaySymbols()API-Since: 5.0@NotNull NSArray<java.lang.String>shortWeekdaySymbols()API-Since: 5.0@NotNull NSArray<java.lang.String>standaloneMonthSymbols()API-Since: 5.0@NotNull NSArray<java.lang.String>standaloneQuarterSymbols()API-Since: 5.0@NotNull NSArray<java.lang.String>standaloneWeekdaySymbols()API-Since: 5.0@NotNull NSDatestartOfDayForDate(@NotNull NSDate date)This API returns the first moment date of a given date.static org.moe.natj.objc.Classsuperclass_static()static booleansupportsSecureCoding()@NotNull NSTimeZonetimeZone()static booleanuseStoredAccessor()Deprecated.static longversion_static()@NotNull NSArray<java.lang.String>veryShortMonthSymbols()API-Since: 5.0@NotNull NSArray<java.lang.String>veryShortStandaloneMonthSymbols()API-Since: 5.0@NotNull NSArray<java.lang.String>veryShortStandaloneWeekdaySymbols()API-Since: 5.0@NotNull NSArray<java.lang.String>veryShortWeekdaySymbols()API-Since: 5.0@NotNull NSArray<java.lang.String>weekdaySymbols()API-Since: 5.0-
Methods inherited from class apple.NSObject
accessibilityActivate, accessibilityActivateBlock, accessibilityActivationPoint, accessibilityActivationPointBlock, accessibilityAssistiveTechnologyFocusedIdentifiers, accessibilityAttributedHint, accessibilityAttributedHintBlock, accessibilityAttributedLabel, accessibilityAttributedLabelBlock, accessibilityAttributedUserInputLabels, accessibilityAttributedUserInputLabelsBlock, accessibilityAttributedValue, accessibilityAttributedValueBlock, accessibilityContainerType, accessibilityContainerTypeBlock, accessibilityCustomActions, accessibilityCustomActionsBlock, accessibilityCustomRotors, accessibilityCustomRotorsBlock, accessibilityDecrement, accessibilityDecrementBlock, accessibilityDirectTouchOptions, accessibilityDragSourceDescriptors, accessibilityDropPointDescriptors, accessibilityElementAtIndex, accessibilityElementCount, accessibilityElementDidBecomeFocused, accessibilityElementDidLoseFocus, accessibilityElementIsFocused, accessibilityElements, accessibilityElementsBlock, accessibilityElementsHidden, accessibilityElementsHiddenBlock, accessibilityFrame, accessibilityFrameBlock, accessibilityHeaderElementsBlock, accessibilityHint, accessibilityHintBlock, accessibilityIdentifierBlock, accessibilityIncrement, accessibilityIncrementBlock, accessibilityLabel, accessibilityLabelBlock, accessibilityLanguage, accessibilityLanguageBlock, accessibilityMagicTapBlock, accessibilityNavigationStyle, accessibilityNavigationStyleBlock, accessibilityPath, accessibilityPathBlock, accessibilityPerformEscape, accessibilityPerformEscapeBlock, accessibilityPerformMagicTap, accessibilityRespondsToUserInteraction, accessibilityRespondsToUserInteractionBlock, accessibilityScroll, accessibilityShouldGroupAccessibilityChildrenBlock, accessibilityTextualContext, accessibilityTextualContextBlock, accessibilityTraits, accessibilityTraitsBlock, accessibilityUserInputLabels, accessibilityUserInputLabelsBlock, accessibilityValue, accessibilityValueBlock, accessibilityViewIsModal, accessibilityViewIsModalBlock, accessibilityZoomInAtPoint, accessibilityZoomOutAtPoint, addObserverForKeyPathOptionsContext, attemptRecoveryFromErrorOptionIndex, attemptRecoveryFromErrorOptionIndexDelegateDidRecoverSelectorContextInfo, autoContentAccessingProxy, automationElements, automationElementsBlock, awakeAfterUsingCoder, awakeFromNib, class_objc, classForCoder, classForKeyedArchiver, copy, dealloc, debugDescription, description, dictionaryWithValuesForKeys, didChangeValueForKey, didChangeValueForKeyWithSetMutationUsingObjects, didChangeValuesAtIndexesForKey, doesNotRecognizeSelector, fileManagerShouldProceedAfterError, fileManagerWillProcessPath, finalize_objc, forwardingTargetForSelector, forwardInvocation, handleQueryWithUnboundKey, handleTakeValueForUnboundKey, hash, indexOfAccessibilityElement, isAccessibilityElement, isAccessibilityElementBlock, isEqual, isKindOfClass, isMemberOfClass, isProxy, methodForSelector, methodSignatureForSelector, mutableArrayValueForKey, mutableArrayValueForKeyPath, mutableCopy, mutableOrderedSetValueForKey, mutableOrderedSetValueForKeyPath, mutableSetValueForKey, mutableSetValueForKeyPath, observationInfo, observeValueForKeyPathOfObjectChangeContext, performSelector, performSelectorInBackgroundWithObject, performSelectorOnMainThreadWithObjectWaitUntilDone, performSelectorOnMainThreadWithObjectWaitUntilDoneModes, performSelectorOnThreadWithObjectWaitUntilDone, performSelectorOnThreadWithObjectWaitUntilDoneModes, performSelectorWithObject, performSelectorWithObjectAfterDelay, performSelectorWithObjectAfterDelayInModes, performSelectorWithObjectWithObject, prepareForInterfaceBuilder, provideImageDataBytesPerRowOrigin_Size_UserInfo, removeObserverForKeyPath, removeObserverForKeyPathContext, replacementObjectForCoder, replacementObjectForKeyedArchiver, respondsToSelector, self, setAccessibilityActivateBlock, setAccessibilityActivationPoint, setAccessibilityActivationPointBlock, setAccessibilityAttributedHint, setAccessibilityAttributedHintBlock, setAccessibilityAttributedLabel, setAccessibilityAttributedLabelBlock, setAccessibilityAttributedUserInputLabels, setAccessibilityAttributedUserInputLabelsBlock, setAccessibilityAttributedValue, setAccessibilityAttributedValueBlock, setAccessibilityContainerType, setAccessibilityContainerTypeBlock, setAccessibilityCustomActions, setAccessibilityCustomActionsBlock, setAccessibilityCustomRotors, setAccessibilityCustomRotorsBlock, setAccessibilityDecrementBlock, setAccessibilityDirectTouchOptions, setAccessibilityDragSourceDescriptors, setAccessibilityDropPointDescriptors, setAccessibilityElements, setAccessibilityElementsBlock, setAccessibilityElementsHidden, setAccessibilityElementsHiddenBlock, setAccessibilityFrame, setAccessibilityFrameBlock, setAccessibilityHeaderElementsBlock, setAccessibilityHint, setAccessibilityHintBlock, setAccessibilityIdentifierBlock, setAccessibilityIncrementBlock, setAccessibilityLabel, setAccessibilityLabelBlock, setAccessibilityLanguage, setAccessibilityLanguageBlock, setAccessibilityMagicTapBlock, setAccessibilityNavigationStyle, setAccessibilityNavigationStyleBlock, setAccessibilityPath, setAccessibilityPathBlock, setAccessibilityPerformEscapeBlock, setAccessibilityRespondsToUserInteraction, setAccessibilityRespondsToUserInteractionBlock, setAccessibilityShouldGroupAccessibilityChildrenBlock, setAccessibilityTextualContext, setAccessibilityTextualContextBlock, setAccessibilityTraits, setAccessibilityTraitsBlock, setAccessibilityUserInputLabels, setAccessibilityUserInputLabelsBlock, setAccessibilityValue, setAccessibilityValueBlock, setAccessibilityViewIsModal, setAccessibilityViewIsModalBlock, setAutomationElements, setAutomationElementsBlock, setIsAccessibilityElement, setIsAccessibilityElementBlock, setNilValueForKey, setObservationInfo, setShouldGroupAccessibilityChildren, setValueForKey, setValueForKeyPath, setValueForUndefinedKey, setValuesForKeysWithDictionary, shouldGroupAccessibilityChildren, storedValueForKey, superclass, takeStoredValueForKey, takeValueForKey, takeValueForKeyPath, takeValuesFromDictionary, unableToSetNilForKey, validateValueForKeyError, validateValueForKeyPathError, valueForKey, valueForKeyPath, valueForUndefinedKey, valuesForKeys, willChangeValueForKey, willChangeValueForKeyWithSetMutationUsingObjects, willChangeValuesAtIndexesForKey
-
-
-
-
Method Detail
-
accessInstanceVariablesDirectly
public static boolean accessInstanceVariablesDirectly()
-
alloc
public static NSCalendar alloc()
-
allocWithZone
public static NSCalendar allocWithZone(org.moe.natj.general.ptr.VoidPtr zone)
-
automaticallyNotifiesObserversForKey
public static boolean automaticallyNotifiesObserversForKey(@NotNull @NotNull java.lang.String key)
-
autoupdatingCurrentCalendar
@NotNull public static @NotNull NSCalendar autoupdatingCurrentCalendar()
tracks changes to user's preferred calendar identifier API-Since: 2.0
-
calendarWithIdentifier
@Nullable public static @Nullable NSCalendar calendarWithIdentifier(@NotNull @NotNull java.lang.String calendarIdentifierConstant)
This method returns a new autoreleased calendar object of the given type, specified by a calendar identifier constant. The calendar defaults to having the current locale and default time zone, for those properties. API-Since: 8.0
-
cancelPreviousPerformRequestsWithTarget
public static void cancelPreviousPerformRequestsWithTarget(@NotNull @NotNull java.lang.Object aTarget)
-
cancelPreviousPerformRequestsWithTargetSelectorObject
public static void cancelPreviousPerformRequestsWithTargetSelectorObject(@NotNull @NotNull java.lang.Object aTarget, @NotNull @NotNull org.moe.natj.objc.SEL aSelector, @Nullable @Nullable java.lang.Object anArgument)
-
classFallbacksForKeyedArchiver
@NotNull public static @NotNull NSArray<java.lang.String> classFallbacksForKeyedArchiver()
-
classForKeyedUnarchiver
@NotNull public static @NotNull org.moe.natj.objc.Class classForKeyedUnarchiver()
-
currentCalendar
@NotNull public static @NotNull NSCalendar currentCalendar()
user's preferred calendar
-
debugDescription_static
public static java.lang.String debugDescription_static()
-
description_static
public static java.lang.String description_static()
-
hash_static
public static long hash_static()
-
instanceMethodForSelector
public static NSObject.Function_instanceMethodForSelector_ret instanceMethodForSelector(org.moe.natj.objc.SEL aSelector)
-
instanceMethodSignatureForSelector
public static NSMethodSignature instanceMethodSignatureForSelector(org.moe.natj.objc.SEL aSelector)
-
instancesRespondToSelector
public static boolean instancesRespondToSelector(org.moe.natj.objc.SEL aSelector)
-
isSubclassOfClass
public static boolean isSubclassOfClass(org.moe.natj.objc.Class aClass)
-
keyPathsForValuesAffectingValueForKey
@NotNull public static @NotNull NSSet<java.lang.String> keyPathsForValuesAffectingValueForKey(@NotNull @NotNull java.lang.String key)
-
new_objc
public static NSCalendar new_objc()
-
resolveClassMethod
public static boolean resolveClassMethod(org.moe.natj.objc.SEL sel)
-
resolveInstanceMethod
public static boolean resolveInstanceMethod(org.moe.natj.objc.SEL sel)
-
setVersion_static
public static void setVersion_static(long aVersion)
-
superclass_static
public static org.moe.natj.objc.Class superclass_static()
-
supportsSecureCoding
public static boolean supportsSecureCoding()
-
version_static
public static long version_static()
-
AMSymbol
@NotNull public @NotNull java.lang.String AMSymbol()
API-Since: 5.0
-
PMSymbol
@NotNull public @NotNull java.lang.String PMSymbol()
API-Since: 5.0
-
calendarIdentifier
@NotNull public @NotNull java.lang.String calendarIdentifier()
-
compareDateToDateToUnitGranularity
public long compareDateToDateToUnitGranularity(@NotNull @NotNull NSDate date1, @NotNull @NotNull NSDate date2, long unit)This API compares the given dates down to the given unit, reporting them equal if they are the same in the given unit and all larger units, otherwise either less than or greater than. API-Since: 8.0
-
componentFromDate
public long componentFromDate(long unit, @NotNull @NotNull NSDate date)Get just one component's value. API-Since: 8.0
-
componentsFromDate
@NotNull public @NotNull NSDateComponents componentsFromDate(long unitFlags, @NotNull @NotNull NSDate date)
-
componentsFromDateToDateOptions
@NotNull public @NotNull NSDateComponents componentsFromDateToDateOptions(long unitFlags, @NotNull @NotNull NSDate startingDate, @NotNull @NotNull NSDate resultDate, long opts)
-
componentsFromDateComponentsToDateComponentsOptions
@NotNull public @NotNull NSDateComponents componentsFromDateComponentsToDateComponentsOptions(long unitFlags, @NotNull @NotNull NSDateComponents startingDateComp, @NotNull @NotNull NSDateComponents resultDateComp, long options)
This API returns the difference between two dates specified as date components. For units which are not specified in each NSDateComponents, but required to specify an absolute date, the base value of the unit is assumed. For example, for an NSDateComponents with just a Year and a Month specified, a Day of 1, and an Hour, Minute, Second, and Nanosecond of 0 are assumed. Calendrical calculations with unspecified Year or Year value prior to the start of a calendar are not advised. For each date components object, if its time zone property is set, that time zone is used for it; if the calendar property is set, that is used rather than the receiving calendar, and if both the calendar and time zone are set, the time zone property value overrides the time zone of the calendar property. No options are currently defined; pass 0. API-Since: 8.0
-
componentsInTimeZoneFromDate
@NotNull public @NotNull NSDateComponents componentsInTimeZoneFromDate(@NotNull @NotNull NSTimeZone timezone, @NotNull @NotNull NSDate date)
This API returns all the date components of a date, as if in a given time zone (instead of the receiving calendar's time zone). The time zone overrides the time zone of the NSCalendar for the purposes of this calculation. Note: if you want "date information in a given time zone" in order to display it, you should use NSDateFormatter to format the date. API-Since: 8.0
-
copyWithZone
@NotNull public @NotNull java.lang.Object copyWithZone(@Nullable @Nullable org.moe.natj.general.ptr.VoidPtr zone)- Specified by:
copyWithZonein interfaceNSCopying
-
dateMatchesComponents
public boolean dateMatchesComponents(@NotNull @NotNull NSDate date, @NotNull @NotNull NSDateComponents components)This API returns YES if the date has all the matched components. Otherwise, it returns NO. It is useful to test the return value of the -nextDateAfterDate:matchingUnit:value:options:, to find out if the components were obeyed or if the method had to fudge the result value due to missing time. API-Since: 8.0
-
dateByAddingComponentsToDateOptions
@Nullable public @Nullable NSDate dateByAddingComponentsToDateOptions(@NotNull @NotNull NSDateComponents comps, @NotNull @NotNull NSDate date, long opts)
-
dateByAddingUnitValueToDateOptions
@Nullable public @Nullable NSDate dateByAddingUnitValueToDateOptions(long unit, long value, @NotNull @NotNull NSDate date, long options)
This API returns a new NSDate object representing the date calculated by adding an amount of a specific component to a given date. The NSCalendarWrapComponents option specifies if the component should be incremented and wrap around to zero/one on overflow, and should not cause higher units to be incremented. API-Since: 8.0
-
dateBySettingHourMinuteSecondOfDateOptions
@Nullable public @Nullable NSDate dateBySettingHourMinuteSecondOfDateOptions(long h, long m, long s, @NotNull @NotNull NSDate date, long opts)
This API returns a new NSDate object representing the date calculated by setting hour, minute, and second to a given time. If no such time exists, the next available time is returned (which could, for example, be in a different day than the nominal target date). The intent is to return a date on the same day as the original date argument. This may result in a date which is earlier than the given date, of course. API-Since: 8.0
-
dateBySettingUnitValueOfDateOptions
@Nullable public @Nullable NSDate dateBySettingUnitValueOfDateOptions(long unit, long v, @NotNull @NotNull NSDate date, long opts)
This API returns a new NSDate object representing the date calculated by setting a specific component to a given time, and trying to keep lower components the same. If the unit already has that value, this may result in a date which is the same as the given date. Changing a component's value often will require higher or coupled components to change as well. For example, setting the Weekday to Thursday usually will require the Day component to change its value, and possibly the Month and Year as well. If no such time exists, the next available time is returned (which could, for example, be in a different day, week, month, ... than the nominal target date). Setting a component to something which would be inconsistent forces other units to change; for example, setting the Weekday to Thursday probably shifts the Day and possibly Month and Year. The specific behaviors here are as yet unspecified; for example, if I change the weekday to Thursday, does that move forward to the next, backward to the previous, or to the nearest Thursday? A likely rule is that the algorithm will try to produce a result which is in the next-larger unit to the one given (there's a table of this mapping at the top of this document). So for the "set to Thursday" example, find the Thursday in the Week in which the given date resides (which could be a forwards or backwards move, and not necessarily the nearest Thursday). For forwards or backwards behavior, one can use the -nextDateAfterDate:matchingUnit:value:options: method above. API-Since: 8.0
-
dateFromComponents
@Nullable public @Nullable NSDate dateFromComponents(@NotNull @NotNull NSDateComponents comps)
-
dateWithEraYearMonthDayHourMinuteSecondNanosecond
@Nullable public @Nullable NSDate dateWithEraYearMonthDayHourMinuteSecondNanosecond(long eraValue, long yearValue, long monthValue, long dayValue, long hourValue, long minuteValue, long secondValue, long nanosecondValue)
Create a date with given components. Current era is assumed. API-Since: 8.0
-
dateWithEraYearForWeekOfYearWeekOfYearWeekdayHourMinuteSecondNanosecond
@Nullable public @Nullable NSDate dateWithEraYearForWeekOfYearWeekOfYearWeekdayHourMinuteSecondNanosecond(long eraValue, long yearValue, long weekValue, long weekdayValue, long hourValue, long minuteValue, long secondValue, long nanosecondValue)
Create a date with given components. Current era is assumed. API-Since: 8.0
-
encodeWithCoder
public void encodeWithCoder(@NotNull @NotNull NSCoder coder)- Specified by:
encodeWithCoderin interfaceNSCoding
-
enumerateDatesStartingAfterDateMatchingComponentsOptionsUsingBlock
public void enumerateDatesStartingAfterDateMatchingComponentsOptionsUsingBlock(@NotNull @NotNull NSDate start, @NotNull @NotNull NSDateComponents comps, long opts, @NotNull @NotNull NSCalendar.Block_enumerateDatesStartingAfterDateMatchingComponentsOptionsUsingBlock block)This method computes the dates which match (or most closely match) a given set of components, and calls the block once for each of them, until the enumeration is stopped. There will be at least one intervening date which does not match all the components (or the given date itself must not match) between the given date and any result. If the NSCalendarSearchBackwards option is used, this method finds the previous match before the given date. The intent is that the same matches as for a forwards search will be found (that is, if you are enumerating forwards or backwards for each hour with minute "27", the seconds in the date you will get in forwards search would obviously be 00, and the same will be true in a backwards search in order to implement this rule. Similarly for DST backwards jumps which repeats times, you'll get the first match by default, where "first" is defined from the point of view of searching forwards. So, when searching backwards looking for a particular hour, with no minute and second specified, you don't get a minute and second of 59:59 for the matching hour (which would be the nominal first match within a given hour, given the other rules here, when searching backwards). If the NSCalendarMatchStrictly option is used, the algorithm travels as far forward or backward as necessary looking for a match, but there are ultimately implementation-defined limits in how far distant the search will go. If the NSCalendarMatchStrictly option is not specified, the algorithm searches up to the end of the next instance of the next higher unit to the highest specified unit in the NSDateComponents argument. If you want to find the next Feb 29 in the Gregorian calendar, for example, you have to specify the NSCalendarMatchStrictly option to guarantee finding it. If an exact match is not possible, and requested with the NSCalendarMatchStrictly option, nil is passed to the block and the enumeration ends. (Logically, since an exact match searches indefinitely into the future, if no match is found there's no point in continuing the enumeration.) If the NSCalendarMatchStrictly option is NOT used, exactly one option from the set {NSCalendarMatchPreviousTimePreservingSmallerUnits, NSCalendarMatchNextTimePreservingSmallerUnits, NSCalendarMatchNextTime} must be specified, or an illegal argument exception will be thrown. If the NSCalendarMatchPreviousTimePreservingSmallerUnits option is specified, and there is no matching time before the end of the next instance of the next higher unit to the highest specified unit in the NSDateComponents argument, the method will return the previous existing value of the missing unit and preserves the lower units' values (e.g., no 2:37am results in 1:37am, if that exists). If the NSCalendarMatchNextTimePreservingSmallerUnits option is specified, and there is no matching time before the end of the next instance of the next higher unit to the highest specified unit in the NSDateComponents argument, the method will return the next existing value of the missing unit and preserves the lower units' values (e.g., no 2:37am results in 3:37am, if that exists). If the NSCalendarMatchNextTime option is specified, and there is no matching time before the end of the next instance of the next higher unit to the highest specified unit in the NSDateComponents argument, the method will return the next existing time which exists (e.g., no 2:37am results in 3:00am, if that exists). If the NSCalendarMatchFirst option is specified, and there are two or more matching times (all the components are the same, including isLeapMonth) before the end of the next instance of the next higher unit to the highest specified unit in the NSDateComponents argument, the method will return the first occurrence. If the NSCalendarMatchLast option is specified, and there are two or more matching times (all the components are the same, including isLeapMonth) before the end of the next instance of the next higher unit to the highest specified unit in the NSDateComponents argument, the method will return the last occurrence. If neither the NSCalendarMatchFirst or NSCalendarMatchLast option is specified, the default behavior is to act as if NSCalendarMatchFirst was specified. There is no option to return middle occurrences of more than two occurrences of a matching time, if such exist. Result dates have an integer number of seconds (as if 0 was specified for the nanoseconds property of the NSDateComponents matching parameter), unless a value was set in the nanoseconds property, in which case the result date will have that number of nanoseconds (or as close as possible with floating point numbers). The enumeration is stopped by setting *stop = YES in the block and return. It is not necessary to set *stop to NO to keep the enumeration going. API-Since: 8.0
-
eraSymbols
@NotNull public @NotNull NSArray<java.lang.String> eraSymbols()
Methods to return component name strings localized to the calendar's locale API-Since: 5.0
-
firstWeekday
public long firstWeekday()
-
getEraYearMonthDayFromDate
public void getEraYearMonthDayFromDate(@Nullable @Nullable org.moe.natj.general.ptr.NIntPtr eraValuePointer, @Nullable @Nullable org.moe.natj.general.ptr.NIntPtr yearValuePointer, @Nullable @Nullable org.moe.natj.general.ptr.NIntPtr monthValuePointer, @Nullable @Nullable org.moe.natj.general.ptr.NIntPtr dayValuePointer, @NotNull @NotNull NSDate date)This API is a convenience for getting era, year, month, and day of a given date. Pass NULL for a NSInteger pointer parameter if you don't care about that value. API-Since: 8.0
-
getEraYearForWeekOfYearWeekOfYearWeekdayFromDate
public void getEraYearForWeekOfYearWeekOfYearWeekdayFromDate(@Nullable @Nullable org.moe.natj.general.ptr.NIntPtr eraValuePointer, @Nullable @Nullable org.moe.natj.general.ptr.NIntPtr yearValuePointer, @Nullable @Nullable org.moe.natj.general.ptr.NIntPtr weekValuePointer, @Nullable @Nullable org.moe.natj.general.ptr.NIntPtr weekdayValuePointer, @NotNull @NotNull NSDate date)This API is a convenience for getting era, year for week-of-year calculations, week of year, and weekday of a given date. Pass NULL for a NSInteger pointer parameter if you don't care about that value. API-Since: 8.0
-
getHourMinuteSecondNanosecondFromDate
public void getHourMinuteSecondNanosecondFromDate(@Nullable @Nullable org.moe.natj.general.ptr.NIntPtr hourValuePointer, @Nullable @Nullable org.moe.natj.general.ptr.NIntPtr minuteValuePointer, @Nullable @Nullable org.moe.natj.general.ptr.NIntPtr secondValuePointer, @Nullable @Nullable org.moe.natj.general.ptr.NIntPtr nanosecondValuePointer, @NotNull @NotNull NSDate date)This API is a convenience for getting hour, minute, second, and nanoseconds of a given date. Pass NULL for a NSInteger pointer parameter if you don't care about that value. API-Since: 8.0
-
init
public NSCalendar init()
-
initWithCalendarIdentifier
public NSCalendar initWithCalendarIdentifier(@NotNull @NotNull java.lang.String ident)
-
initWithCoder
public NSCalendar initWithCoder(@NotNull @NotNull NSCoder coder)
Description copied from interface:NSCodingNS_DESIGNATED_INITIALIZER- Specified by:
initWithCoderin interfaceNSCoding
-
isDateEqualToDateToUnitGranularity
public boolean isDateEqualToDateToUnitGranularity(@NotNull @NotNull NSDate date1, @NotNull @NotNull NSDate date2, long unit)This API compares the given dates down to the given unit, reporting them equal if they are the same in the given unit and all larger units. API-Since: 8.0
-
isDateInSameDayAsDate
public boolean isDateInSameDayAsDate(@NotNull @NotNull NSDate date1, @NotNull @NotNull NSDate date2)This API compares the Days of the given dates, reporting them equal if they are in the same Day. API-Since: 8.0
-
isDateInToday
public boolean isDateInToday(@NotNull @NotNull NSDate date)This API reports if the date is within "today". API-Since: 8.0
-
isDateInTomorrow
public boolean isDateInTomorrow(@NotNull @NotNull NSDate date)This API reports if the date is within "tomorrow". API-Since: 8.0
-
isDateInWeekend
public boolean isDateInWeekend(@NotNull @NotNull NSDate date)This API reports if the date is within a weekend period, as defined by the calendar and calendar's locale. API-Since: 8.0
-
isDateInYesterday
public boolean isDateInYesterday(@NotNull @NotNull NSDate date)This API reports if the date is within "yesterday". API-Since: 8.0
-
locale
@Nullable public @Nullable NSLocale locale()
-
longEraSymbols
@NotNull public @NotNull NSArray<java.lang.String> longEraSymbols()
API-Since: 5.0
-
maximumRangeOfUnit
public NSRange maximumRangeOfUnit(long unit)
-
minimumDaysInFirstWeek
public long minimumDaysInFirstWeek()
-
minimumRangeOfUnit
public NSRange minimumRangeOfUnit(long unit)
Calendrical calculations
-
monthSymbols
@NotNull public @NotNull NSArray<java.lang.String> monthSymbols()
API-Since: 5.0
-
nextDateAfterDateMatchingComponentsOptions
@Nullable public @Nullable NSDate nextDateAfterDateMatchingComponentsOptions(@NotNull @NotNull NSDate date, @NotNull @NotNull NSDateComponents comps, long options)
This method computes the next date which matches (or most closely matches) a given set of components. The general semantics follow those of the -enumerateDatesStartingAfterDate:... method above. To compute a sequence of results, use the -enumerateDatesStartingAfterDate:... method above, rather than looping and calling this method with the previous loop iteration's result. API-Since: 8.0
-
nextDateAfterDateMatchingHourMinuteSecondOptions
@Nullable public @Nullable NSDate nextDateAfterDateMatchingHourMinuteSecondOptions(@NotNull @NotNull NSDate date, long hourValue, long minuteValue, long secondValue, long options)
This API returns a new NSDate object representing the date found which matches the given hour, minute, and second values. The general semantics follow those of the -enumerateDatesStartingAfterDate:... method above. To compute a sequence of results, use the -enumerateDatesStartingAfterDate:... method above, rather than looping and calling this method with the previous loop iteration's result. API-Since: 8.0
-
nextDateAfterDateMatchingUnitValueOptions
@Nullable public @Nullable NSDate nextDateAfterDateMatchingUnitValueOptions(@NotNull @NotNull NSDate date, long unit, long value, long options)
This API returns a new NSDate object representing the date found which matches a specific component value. The general semantics follow those of the -enumerateDatesStartingAfterDate:... method above. To compute a sequence of results, use the -enumerateDatesStartingAfterDate:... method above, rather than looping and calling this method with the previous loop iteration's result. API-Since: 8.0
-
nextWeekendStartDateIntervalOptionsAfterDate
public boolean nextWeekendStartDateIntervalOptionsAfterDate(@Nullable @Nullable org.moe.natj.general.ptr.Ptr<NSDate> datep, @Nullable @Nullable org.moe.natj.general.ptr.DoublePtr tip, long options, @NotNull @NotNull NSDate date)Returns the range of the next weekend, via two by-reference parameters, which starts strictly after the given date. The NSCalendarSearchBackwards option can be used to find the previous weekend range strictly before the date. Returns NO if there are no such things as weekend in the calendar and its locale. Note that a given entire Day within a calendar is not necessarily all in a weekend or not; weekends can start in the middle of a Day in some calendars and locales. API-Since: 8.0
-
ordinalityOfUnitInUnitForDate
public long ordinalityOfUnitInUnitForDate(long smaller, long larger, @NotNull @NotNull NSDate date)
-
quarterSymbols
@NotNull public @NotNull NSArray<java.lang.String> quarterSymbols()
API-Since: 5.0
-
rangeOfUnitInUnitForDate
public NSRange rangeOfUnitInUnitForDate(long smaller, long larger, @NotNull @NotNull NSDate date)
-
rangeOfUnitStartDateIntervalForDate
public boolean rangeOfUnitStartDateIntervalForDate(long unit, @Nullable @Nullable org.moe.natj.general.ptr.Ptr<NSDate> datep, @Nullable @Nullable org.moe.natj.general.ptr.DoublePtr tip, @NotNull @NotNull NSDate date)API-Since: 2.0
-
rangeOfWeekendStartDateIntervalContainingDate
public boolean rangeOfWeekendStartDateIntervalContainingDate(@Nullable @Nullable org.moe.natj.general.ptr.Ptr<NSDate> datep, @Nullable @Nullable org.moe.natj.general.ptr.DoublePtr tip, @NotNull @NotNull NSDate date)Find the range of the weekend around the given date, returned via two by-reference parameters. Returns NO if the given date is not in a weekend. Note that a given entire Day within a calendar is not necessarily all in a weekend or not; weekends can start in the middle of a Day in some calendars and locales. API-Since: 8.0
-
setFirstWeekday
public void setFirstWeekday(long value)
-
setLocale
public void setLocale(@Nullable @Nullable NSLocale value)
-
setMinimumDaysInFirstWeek
public void setMinimumDaysInFirstWeek(long value)
-
setTimeZone
public void setTimeZone(@NotNull @NotNull NSTimeZone value)
-
shortMonthSymbols
@NotNull public @NotNull NSArray<java.lang.String> shortMonthSymbols()
API-Since: 5.0
-
shortQuarterSymbols
@NotNull public @NotNull NSArray<java.lang.String> shortQuarterSymbols()
API-Since: 5.0
-
shortStandaloneMonthSymbols
@NotNull public @NotNull NSArray<java.lang.String> shortStandaloneMonthSymbols()
API-Since: 5.0
-
shortStandaloneQuarterSymbols
@NotNull public @NotNull NSArray<java.lang.String> shortStandaloneQuarterSymbols()
API-Since: 5.0
-
shortStandaloneWeekdaySymbols
@NotNull public @NotNull NSArray<java.lang.String> shortStandaloneWeekdaySymbols()
API-Since: 5.0
-
shortWeekdaySymbols
@NotNull public @NotNull NSArray<java.lang.String> shortWeekdaySymbols()
API-Since: 5.0
-
standaloneMonthSymbols
@NotNull public @NotNull NSArray<java.lang.String> standaloneMonthSymbols()
API-Since: 5.0
-
standaloneQuarterSymbols
@NotNull public @NotNull NSArray<java.lang.String> standaloneQuarterSymbols()
API-Since: 5.0
-
standaloneWeekdaySymbols
@NotNull public @NotNull NSArray<java.lang.String> standaloneWeekdaySymbols()
API-Since: 5.0
-
startOfDayForDate
@NotNull public @NotNull NSDate startOfDayForDate(@NotNull @NotNull NSDate date)
This API returns the first moment date of a given date. Pass in [NSDate date], for example, if you want the start of "today". If there were two midnights, it returns the first. If there was none, it returns the first moment that did exist. API-Since: 8.0
-
_supportsSecureCoding
public boolean _supportsSecureCoding()
Description copied from interface:NSSecureCodingThis property must return YES on all classes that allow secure coding. Subclasses of classes that adopt NSSecureCoding and override initWithCoder: must also override this method and return YES. The Secure Coding Guide should be consulted when writing methods that decode data.- Specified by:
_supportsSecureCodingin interfaceNSSecureCoding
-
timeZone
@NotNull public @NotNull NSTimeZone timeZone()
-
veryShortMonthSymbols
@NotNull public @NotNull NSArray<java.lang.String> veryShortMonthSymbols()
API-Since: 5.0
-
veryShortStandaloneMonthSymbols
@NotNull public @NotNull NSArray<java.lang.String> veryShortStandaloneMonthSymbols()
API-Since: 5.0
-
veryShortStandaloneWeekdaySymbols
@NotNull public @NotNull NSArray<java.lang.String> veryShortStandaloneWeekdaySymbols()
API-Since: 5.0
-
veryShortWeekdaySymbols
@NotNull public @NotNull NSArray<java.lang.String> veryShortWeekdaySymbols()
API-Since: 5.0
-
weekdaySymbols
@NotNull public @NotNull NSArray<java.lang.String> weekdaySymbols()
API-Since: 5.0
-
useStoredAccessor
@Deprecated public static boolean useStoredAccessor()
Deprecated.
-
-