NSDate.odin 888 B

1234567891011121314151617181920212223242526272829
  1. package objc_Foundation
  2. @(objc_class="NSDate")
  3. Date :: struct {using _: Copying(Date)}
  4. @(objc_type=Date, objc_name="alloc", objc_is_class_method=true)
  5. Date_alloc :: proc "c" () -> ^Date {
  6. return msgSend(^Date, Date, "alloc")
  7. }
  8. @(objc_type=Date, objc_name="init")
  9. Date_init :: proc "c" (self: ^Date) -> ^Date {
  10. return msgSend(^Date, self, "init")
  11. }
  12. @(objc_type=Date, objc_name="dateWithTimeIntervalSinceNow")
  13. Date_dateWithTimeIntervalSinceNow :: proc "c" (secs: TimeInterval) -> ^Date {
  14. return msgSend(^Date, Date, "dateWithTimeIntervalSinceNow:", secs)
  15. }
  16. @(objc_type=Date, objc_name="distantFuture", objc_is_class_method=true)
  17. Date_distantFuture :: proc "c" () -> ^Date {
  18. return msgSend(^Date, Date, "distantFuture")
  19. }
  20. @(objc_type=Date, objc_name="distantPast", objc_is_class_method=true)
  21. Date_distantPast :: proc "c" () -> ^Date {
  22. return msgSend(^Date, Date, "distantPast")
  23. }