美文网首页Java源代码阅读
RandomAccess interface 源码阅读

RandomAccess interface 源码阅读

作者: 张骁骁啊 | 来源:发表于2017-06-05 22:50 被阅读0次

Marker interface used by List implementations to indicate that they support fast (generally constant time) random access. The primary purpose of this interface is to allow generic algorithms to alter their behavior to provide good performance when applied to either random or sequential access lists.

这个接口用来标记实现该接口的类支持快速随机访问。以便在算法中实现更好的性能。

notes:空接口只是一个标识接口,标识某各类只要实现此接口就会具备某种特性,才能做某种事情。

相关文章

网友评论

    本文标题:RandomAccess interface 源码阅读

    本文链接:https://www.haomeiwen.com/subject/akpwfxtx.html