<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<?xml-stylesheet href="./_c74_ref.xsl" type="text/xsl"?>
<!--This is an automatically generated file. DO NOT EDIT THIS FILE DIRECTLY.-->
<c74object module="rnbo" kind="rnboobject" name="bag" category="Control">
<!--METADATA-->
<metadatalist>
<metadata name="author">Cycling '74</metadata>
<metadata name="tag">RNBO</metadata>
<metadata name="tag">RNBO Data</metadata>
<metadata name="tag">RNBO Control</metadata>
</metadatalist>
<digest>Store a collection of numbers.</digest>
<description><p>
Store and manage a collection of numbers. Contents are reported first-in-last-out (FILO).
</p></description>
<!--ARGUMENTS-->
<!--NONE-->
<!--OPTIONS-->
<!--NONE-->
<!--ATTRIBUTES-->
<rnboattributelist>
<attribute name="clear" size="1" type="bang">
<digest>Clear the set</digest>
<description><p>
Clears all contents of the bag object and immediately sets the item count to 0.
</p></description>
</attribute>
<attribute name="duplicate" size="1" type="number">
<digest>Allow duplicates entries</digest>
<attributelist>
<attribute name="default" type="number" value="0"></attribute>
</attributelist>
<description><p>
When enabled, duplicates of the same value can be stored. Changing the state of this attribute always clears the stored contents and immediately sets the item count to 0.
</p></description>
</attribute>
<attribute name="in1" size="1" type="bang, list, number">
<digest>list Adds/Remove Items</digest>
<description><p>
<m>bang</m>
 : A bang in the left inlet causes bag to output the stored contents as a series of individual values in first-in-last-out (FILO) order.
</p>
<p>
<m>number</m>
 : When a single number is received, it will either be added or removed based on the state of the right inlet. If the right inlet is set to any non-zero value, it will be added, and if it is set to zero, the item will be removed.
</p>
<p>
<m>list</m>
 : When a list is received, the first element will be added if the second is non-zero or removed if it is zero.
</p>
<p>
If the 
<m>duplicate</m>
 attribute is enabled (set to 1), removing a value will remove only the most recently added instance of a number.
</p></description>
</attribute>
<attribute name="right" size="1" type="number">
<digest>Set if items are added (non-zero) or removed (0)</digest>
<description><p>
Sets whether items are added (non-zero) or removed (zero). This only affects incoming messages with a single number. Values that arrive as a list are added or removed based on whether the value of the second element is non-zero or zero.
</p></description>
</attribute>
</rnboattributelist>
<!--INLETS-->
<rnboinletlist>
<inlet id="inlet_in1" name="in1" type="bang, list, number">
<digest>list Adds/Remove Items</digest>
<description><p>
<m>bang</m>
 : A bang in the left inlet causes bag to output the stored contents as a series of individual values in first-in-last-out (FILO) order.
</p>
<p>
<m>number</m>
 : When a single number is received, it will either be added or removed based on the state of the right inlet. If the right inlet is set to any non-zero value, it will be added, and if it is set to zero, the item will be removed.
</p>
<p>
<m>list</m>
 : When a list is received, the first element will be added if the second is non-zero or removed if it is zero.
</p>
<p>
If the 
<m>duplicate</m>
 attribute is enabled (set to 1), removing a value will remove only the most recently added instance of a number.
</p></description>
</inlet>
<inlet id="inlet_right" name="right" type="number">
<digest>Set if items are added (non-zero) or removed (0)</digest>
<description><p>
Sets whether items are added (non-zero) or removed (zero). This only affects incoming messages with a single number. Values that arrive as a list are added or removed based on whether the value of the second element is non-zero or zero.
</p></description>
</inlet>
</rnboinletlist>
<!--OUTLETS-->
<rnbooutletlist>
<outlet id="outlet_out" name="out" type="number">
<digest>Output all items when bang is received</digest>

</outlet>
<outlet id="outlet_sizeOut" name="sizeOut" type="number">
<digest>Size of bag</digest>

</outlet>
</rnbooutletlist>
<!--SEE ALSO-->
<seealsolist>
<seealso name="bag" type="refpage" module="Max"></seealso>
<seealso name="funbuff" type="refpage" module="Max"></seealso>
<seealso name="offer" type="refpage" module="Max"></seealso>
<seealso name="rnbo_list.reg" type="rnborefpage" module="RNBO" display="list.reg"></seealso>
<seealso name="rnbo_list.rev" type="rnborefpage" module="RNBO" display="list.rev"></seealso>
</seealsolist>
</c74object>