240 发简信
IP属地:山西
  • 120
    初探Core Text 架构:paragraphs, lines, glyph runs and glyph

    原文 https://blog.changyy.org/2014/06/ios-core-text-paragraphs-lines-glyph.html[https://b...

  • iOS 启动优化

    启动优化思考 在面试时遇到这个问题,很多人信手拈来,上来就说:+load、减少离屏渲染、二进制重排等。不得不说,针对这个问题,这确实很重要的一环,对于工作 3 年左右的工程师...

  • iOS:self.xx vs self->_xx vs _xx

    基本理解 self.xx 是对类的属性访问,会调用getter、setter方法; _xx 是直接对实例变量的操作; _xx 类似于 self->_xx(类外肯定没法用 _x...

  • iOS 对self和super的理解

    答案:都输出 Son self 是类的隐藏参数,指向当前调用方法的这个类的实例。而 super 是一个 Magic Keyword, 它本质是一个编译器标示符,和 self ...

  • iOS 查看设备列表(包括模拟器)

    How to list devices available to Xcode 原文[http://mokagio.github.io/tech-journal/2015/03...

  • 120
    iOS转场动画入门

    概述 本文内容是直接从github上找了一个demo,分析了下其源码实现,仅供入门参考,原始链接:https://github.com/YanLYM/YMTransition...

  • 拖拽生成flutter代码工具

    新手对flutter布局不熟悉,可以上这个地址:https://ui.flutterdart.cn/ 通过拖拽代码可以更好的学习flutter布局,写一些比较简单的页面也可以...

  • 广告相关术语

    OTV OTV即Online TV,所以OTV广告是线上视频的广告,具体可以是贴片广告、插播广告、创可贴广告等这是区别于TVC的,TVC就是TV Commercials,电视...

  • Using Custom Keys

    In most cases, Cocoa-provided objects such as NSString objects should be sufficient for use as keys. In some cases, however, it may be necessary to use custom objects as keys in a dictionary. When using custom objects as keys, there are some important points to keep in mind.

    Keys must conform to the NSCopying protocol. Methods that add entries to dictionaries—whether as part of initialization (for all dictionaries) or during modification (for mutable dictionaries)— don’t add each key object to the dictionary directly. Instead, they copy each key argument and add the copy to the dictionary. After being copied into the dictionary, the dictionary-owned copies of the keys should not be modified.

    Keys must implement the hash and isEqual: methods because a dictionary uses a hash table to organize its storage and to quickly access contained objects. In addition, performance in a dictionary is heavily dependent on the hash function used. With a bad hash function, the decrease in performance can be severe. For more information on the hash and isEqual: methods see NSObject.

    Important: Because the dictionary copies each key, keys must conform to the NSCopying protocol. Bear this in mind when choosing what objects to use as keys. Although you can use any object that adopts the NSCopying protocol and implements the hash and isEqual: methods, it is typically bad design to use large objects, such as instances of NSImage, because doing so may incur performance penalties.
    感觉这里解释得更清楚啊。

  • 目录篇

    未分类 SQL基础[https://www.jianshu.com/p/3cc6a1740d1b] 向前兼容和向后兼容[https://www.jianshu.com/p/7...