<?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. Rather, use the _ref.xml files found in the 'edits' folder.-->
<c74object name="array.shift" module="max" category="Array">
	<digest>
		Remove an element from the beginning of an array.
	</digest>
	<description>
		Set the array to shift, then send bangs repeatedly to output the elements of the array one at a time. The remainder of the array is sent out the right outlet, and a bang is sent out the leftmost outlet when the array is empty.
	</description>
	<!--METADATA-->
	<metadatalist>
		<metadata name="author">
			Cycling '74
		</metadata>
		<metadata name="tag">
			array
		</metadata>
	</metadatalist>
	<!--INLETS-->
	<inletlist>
		<inlet id="0" type="INLET_TYPE">
			<digest>
				array in
			</digest>
			<description>
				TEXT_HERE
			</description>
		</inlet>
		<inlet id="1" type="INLET_TYPE">
			<digest>
				array in
			</digest>
			<description>
				TEXT_HERE
			</description>
		</inlet>
	</inletlist>
	<!--OUTLETS-->
	<outletlist>
		<outlet id="0" type="OUTLET_TYPE">
			<digest>
				array is empty bang
			</digest>
			<description>
				TEXT_HERE
			</description>
		</outlet>
		<outlet id="1" type="OUTLET_TYPE">
			<digest>
				shifted element
			</digest>
			<description>
				TEXT_HERE
			</description>
		</outlet>
		<outlet id="2" type="OUTLET_TYPE">
			<digest>
				shifted array out
			</digest>
			<description>
				TEXT_HERE
			</description>
		</outlet>
	</outletlist>
	<!--ARGUMENTS-->
	<objarglist>
		<objarg id="0" name="OBJARG_NAME" type="OBJARG_TYPE" optional="0">
			<digest>
				TEXT_HERE
			</digest>
			<description>
				TEXT_HERE
			</description>
		</objarg>
	</objarglist>
	<!--MESSAGES-->
	<methodlist>
		<method name="bang">
			<arglist />
			<digest>
				Trigger output
			</digest>
			<description>
				Remove the first element from the stored array and output it, sending the remainder out the rightmost outlet.
			</description>
		</method>
		<method name="int">
			<arglist>
				<arg name="value" type="int" optional="0" />
			</arglist>
			<digest>
				Convert an integer to an array.
			</digest>
			<description>
				Convert an incoming integer to an array, then process as described for the <m>array</m> message.
			</description>
		</method>
		<method name="float">
			<arglist>
				<arg name="value" type="float" optional="0" />
			</arglist>
			<digest>
				Convert a floating-point number to an array.
			</digest>
			<description>
				Convert an incoming floating-point number to an array, then process as described for the <m>array</m> message.
			</description>
		</method>
		<method name="list">
			<arglist>
				<arg name="list-value" type="list" optional="0" />
			</arglist>
			<digest>
				Convert a list to an array.
			</digest>
			<description>
				Convert an incoming list to an array, then process as described for the <m>array</m> message.
			</description>
		</method>
		<method name="anything">
			<arglist>
				<arg name="list-value" type="list" optional="0" />
			</arglist>
			<digest>
				Convert a list to an array.
			</digest>
			<description>
				Convert an incoming list to an array, then process as described for the <m>array</m> message.
			</description>
		</method>
		<method name="array">
			<arglist>
				<arg name="ARG_NAME_0" type="list" optional="0" />
			</arglist>
			<digest>
				TEXT_HERE
			</digest>
			<description>
				TEXT_HERE
			</description>
		</method>
		<method name="clear">
			<arglist />
			<digest>
				TEXT_HERE
			</digest>
			<description>
				TEXT_HERE
			</description>
		</method>
		<method name="dictionary">
			<arglist>
				<arg name="dictionary-value" type="list" optional="0" />
			</arglist>
			<digest>
				Wrap a dictionary object in an array.
			</digest>
			<description>
				Wrap an incoming dictionary object in an array, then process as described for the <m>array</m> message.
			</description>
		</method>
		<method name="string">
			<arglist>
				<arg name="string-value" type="list" optional="0" />
			</arglist>
			<digest>
				Wrap a string object in an array.
			</digest>
			<description>
				Wrap a string object in an array, then process as described for the <m>array</m> message.
			</description>
		</method>
	</methodlist>
	<!--ATTRIBUTES-->
	<attributelist>
		<attribute name="wrapmode" get="1" set="1" type="int" size="1">
			<digest>
				Wrap elements in array
			</digest>
			<description>
				TEXT_HERE
			</description>
			<attributelist>
				<attribute name="default" get="1" set="1" type="int" size="1" value="0" />
				<attribute name="label" get="1" set="1" type="symbol" size="1" value="Wrap elements in array" />
				<attribute name="style" get="1" set="1" type="symbol" size="1" value="onoff" />
			</attributelist>
		</attribute>
	</attributelist>
	<!--EXAMPLE-->
	<examplelist>
		<example caption="" img="" />
	</examplelist>
	<!--SEEALSO-->
	<seealsolist>
		<seealso name="array" />
		<seealso name="array.concat" />
		<seealso name="array.pop" />
		<seealso name="array.push" />
		<seealso name="array.unshift" />
		<seealso name="zl.queue" />
		<seealso name="zl.stack" />
	</seealsolist>
	<discussion>
		Send an array to the right inlet to set the array to shift. Then, as you send bangs to the first inlet, the object will output the first element of the array, removing the element each time, until the array is empty. Unlike the JavaScript implementation, the input array is not changed in place.
	</discussion>
</c74object>
