⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 swarm.collections.keyedcollection.protocol.html

📁 set for Swarm2.1是圣菲研究院的开发人员对Swarm的特性及其使用描述的最为完备的指南性文档。从这里可以获得最细致的平台说明。
💻 HTML
字号:
<HTML><HEAD><TITLE>KeyedCollection</TITLE><METANAME="GENERATOR"CONTENT="Modular DocBook HTML Stylesheet Version 1.53"><LINKREL="HOME"TITLE="Documentation Set for Swarm 2.1.1"HREF="set.html"><LINKREL="UP"TITLE="Collections Library"HREF="swarm.collections.sgml.reference.html"><LINKREL="PREVIOUS"TITLE="InputStream"HREF="swarm.collections.inputstream.protocol.html"><LINKREL="NEXT"TITLE="KeyedCollectionIndex"HREF="swarm.collections.keyedcollectionindex.protocol.html"></HEAD><BODYCLASS="REFENTRY"BGCOLOR="#FFFFFF"TEXT="#000000"LINK="#0000FF"VLINK="#840084"ALINK="#0000FF"><DIVCLASS="NAVHEADER"><TABLEWIDTH="100%"BORDER="0"CELLPADDING="0"CELLSPACING="0"><TR><THCOLSPAN="3"ALIGN="center">Documentation Set for Swarm 2.1.1</TH></TR><TR><TDWIDTH="10%"ALIGN="left"VALIGN="bottom"><AHREF="swarm.collections.inputstream.protocol.html">Prev</A></TD><TDWIDTH="80%"ALIGN="center"VALIGN="bottom">Reference II. Collections Library</TD><TDWIDTH="10%"ALIGN="right"VALIGN="bottom"><AHREF="swarm.collections.keyedcollectionindex.protocol.html">Next</A></TD></TR></TABLE><HRALIGN="LEFT"WIDTH="100%"></DIV><H1><ANAME="SWARM.COLLECTIONS.KEYEDCOLLECTION.PROTOCOL">KeyedCollection</A></H1><DIVCLASS="REFNAMEDIV"><ANAME="AEN7103"></A><H2>Name</H2>KeyedCollection&nbsp;--&nbsp; Member identity definition shared by Set and Map types.</DIV><DIVCLASS="REFSECT1"><ANAME="AEN7106"></A><H2>Description</H2><P> A keyed collection is a collection in which each member can be compared with some other value that identifies the member.  This value is referred to as the member key.  The key value may be determined either by the member value itself, which defines a Set, or by external association with the member when the member is first added, which defines a Map.</P><P> The KeyedCollection type inherits all standard behavior of Collection. The KeyedCollection type is not itself creatable; it only serves as a common supertype for Set and Map collection types.</P><P> The keyed collection type establishes the common behavior shared by both Set and Map.  Standard options are provided to declare ordering of members in the collection. </P></DIV><DIVCLASS="REFSECT1"><ANAME="AEN7111"></A><H2>Protocols adopted by KeyedCollection</H2><P> <AHREF="swarm.collections.collection.protocol.html">Collection</A> <AHREF="swarm.collections.foreachkey.protocol.html">ForEachKey</A></P></DIV><DIVCLASS="REFSECT1"><ANAME="AEN7116"></A><H2>Methods</H2><DIVCLASS="REFSECT2"><ANAME="AEN7118"></A><H3>Phase: Using</H3><P></P><UL><LI><DIVCLASS="FUNCSYNOPSIS"><ANAME="SWARM.COLLECTIONS.KEYEDCOLLECTION.METHOD.PU.M232"></A><P></P>- <BCLASS="FUNCPROTOTYPE">createIndex:</B> (id &lt;Zone&gt;)<VARCLASS="PDPARAM">aZone</VAR> <BCLASS="FUNCPROTOTYPE">fromMember:</B> <VARCLASS="PDPARAM">anObject</VAR> <BR><P></P></DIV></LI><LI><DIVCLASS="FUNCSYNOPSIS"><ANAME="SWARM.COLLECTIONS.KEYEDCOLLECTION.METHOD.PU.M123"></A><P></P>- <BCLASS="FUNCPROTOTYPE">at:</B> <VARCLASS="PDPARAM">aKey</VAR> <BR> The at: message returns the existing member of the collection which matches the key value passed as its argument, or nil if there is no key value in the collection which matches.  If duplicate entries for this key exist, the entire collection of duplicate members created for the key value is returned instead.<P></P></DIV></LI><LI><DIVCLASS="FUNCSYNOPSIS"><ANAME="SWARM.COLLECTIONS.KEYEDCOLLECTION.METHOD.PU.M639"></A><P></P>- <BCLASS="FUNCPROTOTYPE">removeKey:</B> <VARCLASS="PDPARAM">aKey</VAR> <BR> The removeKey: message removes a member matching a key value from the collection, and returns the member just removed.  It returns nil if there is no key value in the collection which matches.  If more than one entry was present for the key value, it removes and returns the first member in the internal collection created for duplicate members.<P></P></DIV></LI><LI><DIVCLASS="FUNCSYNOPSIS"><ANAME="SWARM.COLLECTIONS.KEYEDCOLLECTION.METHOD.PU.M200"></A><P></P>- (BOOL)<BCLASS="FUNCPROTOTYPE">containsKey:</B> <VARCLASS="PDPARAM">aKey</VAR> <BR> The containsKey: message returns true if the key value passed as its argument is contained in the collection, and false otherwise. <P></P></DIV></LI></UL></DIV></DIV><DIVCLASS="NAVFOOTER"><HRALIGN="LEFT"WIDTH="100%"><TABLEWIDTH="100%"BORDER="0"CELLPADDING="0"CELLSPACING="0"><TR><TDWIDTH="33%"ALIGN="left"VALIGN="top"><AHREF="swarm.collections.inputstream.protocol.html">Prev</A></TD><TDWIDTH="34%"ALIGN="center"VALIGN="top"><AHREF="set.html">Home</A></TD><TDWIDTH="33%"ALIGN="right"VALIGN="top"><AHREF="swarm.collections.keyedcollectionindex.protocol.html">Next</A></TD></TR><TR><TDWIDTH="33%"ALIGN="left"VALIGN="top">InputStream</TD><TDWIDTH="34%"ALIGN="center"VALIGN="top"><AHREF="swarm.collections.sgml.reference.html">Up</A></TD><TDWIDTH="33%"ALIGN="right"VALIGN="top">KeyedCollectionIndex</TD></TR></TABLE></DIV></BODY></HTML>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -