NSURL.odin 881 B

123456789101112131415161718192021222324252627282930
  1. package objc_Foundation
  2. @(objc_class="NSURL")
  3. URL :: struct{using _: Copying(URL)}
  4. @(objc_type=URL, objc_name="alloc", objc_is_class_method=true)
  5. URL_alloc :: proc "c" () -> ^URL {
  6. return msgSend(^URL, URL, "alloc")
  7. }
  8. @(objc_type=URL, objc_name="init")
  9. URL_init :: proc "c" (self: ^URL) -> ^URL {
  10. return msgSend(^URL, self, "init")
  11. }
  12. @(objc_type=URL, objc_name="initWithString")
  13. URL_initWithString :: proc "c" (self: ^URL, value: ^String) -> ^URL {
  14. return msgSend(^URL, self, "initWithString:", value)
  15. }
  16. @(objc_type=URL, objc_name="initFileURLWithPath")
  17. URL_initFileURLWithPath :: proc "c" (self: ^URL, path: ^String) -> ^URL {
  18. return msgSend(^URL, self, "initFileURLWithPath:", path)
  19. }
  20. @(objc_type=URL, objc_name="fileSystemRepresentation")
  21. URL_fileSystemRepresentation :: proc "c" (self: ^URL) -> cstring {
  22. return msgSend(cstring, self, "fileSystemRepresentation")
  23. }