Warning: file_get_contents(/data/phpspider/zhask/data//catemap/5/objective-c/26.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Objective c Apple文档未显示方法返回类型_Objective C_Nsdate - Fatal编程技术网

Objective c Apple文档未显示方法返回类型

Objective c Apple文档未显示方法返回类型,objective-c,nsdate,Objective C,Nsdate,我是一个开始学习iOS开发的新手 如何从Apple文档中了解基础框架中返回的属性或方法的类型。 我阅读了苹果的文档,但它没有提到返回类型 比如说 timeIntervalSince1970 Instance Property timeIntervalSince1970 Language SwiftObjective-C SDKs iOS 2.0+ macOS 10.0+ tvOS 9.0+ watchOS 2.0+

我是一个开始学习iOS开发的新手

如何从Apple文档中了解基础框架中返回的属性或方法的类型。 我阅读了苹果的文档,但它没有提到返回类型

比如说

timeIntervalSince1970

    Instance Property
    timeIntervalSince1970
    Language
    SwiftObjective-C
    SDKs
    iOS 2.0+
    macOS 10.0+
    tvOS 9.0+
    watchOS 2.0+
    The interval between the date object and 00:00:00 UTC on 1 January 1970.

    Declaration

         @property(readonly) NSTimeInterval timeIntervalSince1970;

    Discussion

    # This property’s value is negative if the date object is earlier than 00:00:00 UTC on 1 January 1970.

timeIntervalSince1970
返回float,为什么苹果的文档没有提到它?如何知道其他类方法、实例方法、属性的返回类型?

您发布的声明中提到了返回类型。它不是
float
,它是
NSTimeInterval
…而
NSTimeInterval
是一个双精度。。。。。。精确地(可通过查找
NSTimeInterval
)访问@I'L'LThankyou@Malik感谢您您发布的声明中提到了退货类型。它不是
float
,它是
NSTimeInterval
…而
NSTimeInterval
是一个双精度。。。。。。精确地(可通过查找
NSTimeInterval
)访问@I'L'LThankyou@Malik谢谢你