TAILIEUCHUNG - iOS App Programming Guide phần 3

Đừng lo lắng nếu bạn không nhận được tất cả những điều này, bạn sẽ hiểu được nó thông qua các ví dụ tiếp theo trong phần cải thiện trải nghiệm của người dùng với các ứng dụng đang chạy. Các hệ điều hành thông báo ứng dụng của bạn bất cứ khi nào nó di chuyển giữa các nền trước và nền. | CHAPTER 2 Core App Objects For information about the specific behaviors of a given class see the corresponding class reference. For more information about how events flow in your app and information about your app s responsibilities at various points during that flow see App States and Multitasking page 35 . The Data Model Your app s data model comprises your data structures and the business logic needed to keep that data in a consistent state. You never want to design your data model in total isolation from your app s user interface however the implementation of your data model objects should be separate and not rely on the presence of specific views or view controllers. Keeping your data separate from your user interface makes it easier to implement a universal app one that can run on both iPad and iPhone and also makes it easier to reuse portions of your code later. If you have not yet defined your data model the iOS frameworks provide help for doing so. The following sections highlight some of the technologies you can use when defining specific types of data models. Defining a Custom Data Model When defining a custom data model create custom objects to represent any high-level constructs but take advantage of the system-supplied objects for simpler data types. The Foundation framework provides many objects most of which are listed in Table 2-2 for managing strings numbers and other types of simple data in an object-oriented way. Using these objects is preferable to defining new objects both because it saves time and because many other system routines expect you to use the built-in objects anyway. Table 2-2 Data classes in the Foundation framework Data Classes Description Strings and text NSString NSMutableString NSAttributedString NSMutableAttributed-String Strings in iOS are Unicode based. The string classes provide support for creating and manipulating strings in a variety of ways. The attributed string classes support stylized text and are used only in .

TAILIEUCHUNG - Chia sẻ tài liệu không giới hạn
Địa chỉ : 444 Hoang Hoa Tham, Hanoi, Viet Nam
Website : tailieuchung.com
Email : tailieuchung20@gmail.com
Tailieuchung.com là thư viện tài liệu trực tuyến, nơi chia sẽ trao đổi hàng triệu tài liệu như luận văn đồ án, sách, giáo trình, đề thi.
Chúng tôi không chịu trách nhiệm liên quan đến các vấn đề bản quyền nội dung tài liệu được thành viên tự nguyện đăng tải lên, nếu phát hiện thấy tài liệu xấu hoặc tài liệu có bản quyền xin hãy email cho chúng tôi.
Đã phát hiện trình chặn quảng cáo AdBlock
Trang web này phụ thuộc vào doanh thu từ số lần hiển thị quảng cáo để tồn tại. Vui lòng tắt trình chặn quảng cáo của bạn hoặc tạm dừng tính năng chặn quảng cáo cho trang web này.