什么描述了“文件的所有者”最好在objective-c /可可豆? [英] What describes the "File's Owner" best in objective-c / cocoa Nib?

查看:87
本文介绍了什么描述了“文件的所有者”最好在objective-c /可可豆?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

不幸的是,文件的所有者的解释在苹果文档很短。我知道它是一个代理对象。但是真正关于文件所有者对象的是什么?它有什么好处?

Unfortunately, the explanation of File's Owner is pretty short at the Apple docs. I know it is an proxy object. But what's really the point about that "File's Owner" object? What is it good for?

推荐答案

Nib文件通常被称为冻干,准备运行,一个伟大的方式使您的应用程序更模块化,可以减少内存使用。 Nib文件可以解冻,或者当应用程序需要其中的对象时,将其加载到内存中。

Nib files are often referred to as "freeze dried" and ready to run, and they are a great way of making your apps more modular which can reduce memory usage. Nib files can be defrosted, or loaded into memory anytime when the app needs the objects inside it.

每当nib文件解冻时,它需要一个指向解冻它的对象的指针。而该对象通常是文件的所有者。文件的所有者允许nib文件中的对象访问在nib文件被解冻之前存在的对象。在某种程度上,文件的所有者充当新加载的对象和旧对象之间的桥梁。

Whenever a nib file is defrosted, it needs a pointer to the object that defrosted it. And that object is usually, the File's owner. The File's owner allows objects inside the nib file to access objects that existed before the nib file was defrosted. In a way, the File's owner acts as a bridge between newly loaded objects and old objects.

这篇关于什么描述了“文件的所有者”最好在objective-c /可可豆?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆