pub trait IntoIterator {
type Item;
type IntoIter: Iterator<Item = Self::Item>;
// Required method
fn into_iter(self) -> Self::IntoIter;
}
dep_bytemuck
only.Expand description
Conversion into an Iterator
.
By implementing IntoIterator
for a type, you define how it will be
converted to an iterator. This is common for types which describe a
collection of some kind.
One benefit of implementing IntoIterator
is that your type will work
with Rust’s for
loop syntax.
See also: FromIterator
.
§Examples
Basic usage:
let v = [1, 2, 3];
let mut iter = v.into_iter();
assert_eq!(Some(1), iter.next());
assert_eq!(Some(2), iter.next());
assert_eq!(Some(3), iter.next());
assert_eq!(None, iter.next());
Implementing IntoIterator
for your type:
// A sample collection, that's just a wrapper over Vec<T>
#[derive(Debug)]
struct MyCollection(Vec<i32>);
// Let's give it some methods so we can create one and add things
// to it.
impl MyCollection {
fn new() -> MyCollection {
MyCollection(Vec::new())
}
fn add(&mut self, elem: i32) {
self.0.push(elem);
}
}
// and we'll implement IntoIterator
impl IntoIterator for MyCollection {
type Item = i32;
type IntoIter = std::vec::IntoIter<Self::Item>;
fn into_iter(self) -> Self::IntoIter {
self.0.into_iter()
}
}
// Now we can make a new collection...
let mut c = MyCollection::new();
// ... add some stuff to it ...
c.add(0);
c.add(1);
c.add(2);
// ... and then turn it into an Iterator:
for (i, n) in c.into_iter().enumerate() {
assert_eq!(i as i32, n);
}
It is common to use IntoIterator
as a trait bound. This allows
the input collection type to change, so long as it is still an
iterator. Additional bounds can be specified by restricting on
Item
:
fn collect_as_strings<T>(collection: T) -> Vec<String>
where
T: IntoIterator,
T::Item: std::fmt::Debug,
{
collection
.into_iter()
.map(|item| format!("{item:?}"))
.collect()
}
Required Associated Types§
Required Methods§
1.0.0 · Sourcefn into_iter(self) -> Self::IntoIter
fn into_iter(self) -> Self::IntoIter
Creates an iterator from a value.
See the module-level documentation for more.
§Examples
let v = [1, 2, 3];
let mut iter = v.into_iter();
assert_eq!(Some(1), iter.next());
assert_eq!(Some(2), iter.next());
assert_eq!(Some(3), iter.next());
assert_eq!(None, iter.next());
Implementors§
§impl IntoIterator for KeyEventState
impl IntoIterator for KeyEventState
type Item = KeyEventState
type IntoIter = Iter<KeyEventState>
§impl IntoIterator for KeyModifiers
impl IntoIterator for KeyModifiers
type Item = KeyModifiers
type IntoIter = Iter<KeyModifiers>
§impl IntoIterator for KeyboardEnhancementFlags
impl IntoIterator for KeyboardEnhancementFlags
type Item = KeyboardEnhancementFlags
type IntoIter = Iter<KeyboardEnhancementFlags>
§impl IntoIterator for FileAccess
impl IntoIterator for FileAccess
type Item = FileAccess
type IntoIter = Iter<FileAccess>
§impl IntoIterator for FileChooserType
impl IntoIterator for FileChooserType
type Item = FileChooserType
type IntoIter = Iter<FileChooserType>
§impl IntoIterator for FileDialogOptions
impl IntoIterator for FileDialogOptions
type Item = FileDialogOptions
type IntoIter = Iter<FileDialogOptions>
§impl IntoIterator for CallbackTrigger
impl IntoIterator for CallbackTrigger
type Item = CallbackTrigger
type IntoIter = Iter<CallbackTrigger>
§impl IntoIterator for ColorChooser
impl IntoIterator for ColorChooser
type Item = Widget
type IntoIter = IntoIter<<ColorChooser as IntoIterator>::Item>
§impl IntoIterator for Flex
impl IntoIterator for Flex
§impl IntoIterator for Grid
impl IntoIterator for Grid
§impl IntoIterator for Group
impl IntoIterator for Group
§impl IntoIterator for Pack
impl IntoIterator for Pack
§impl IntoIterator for Scroll
impl IntoIterator for Scroll
§impl IntoIterator for Tabs
impl IntoIterator for Tabs
§impl IntoIterator for Tile
impl IntoIterator for Tile
§impl IntoIterator for Wizard
impl IntoIterator for Wizard
§impl IntoIterator for AnimGifImageFlags
impl IntoIterator for AnimGifImageFlags
type Item = AnimGifImageFlags
type IntoIter = Iter<AnimGifImageFlags>
§impl IntoIterator for Choice
impl IntoIterator for Choice
§impl IntoIterator for MenuBar
impl IntoIterator for MenuBar
§impl IntoIterator for MenuButton
impl IntoIterator for MenuButton
type Item = MenuItem
type IntoIter = IntoIter<<MenuButton as IntoIterator>::Item>
§impl IntoIterator for MenuItem
impl IntoIterator for MenuItem
§impl IntoIterator for SysMenuBar
impl IntoIterator for SysMenuBar
type Item = MenuItem
type IntoIter = IntoIter<<SysMenuBar as IntoIterator>::Item>
§impl IntoIterator for devela::_dep::fltk::table::Table
impl IntoIterator for devela::_dep::fltk::table::Table
§impl IntoIterator for TableRow
impl IntoIterator for TableRow
§impl IntoIterator for Terminal
impl IntoIterator for Terminal
§impl IntoIterator for Tree
impl IntoIterator for Tree
§impl IntoIterator for DoubleWindow
impl IntoIterator for DoubleWindow
type Item = Widget
type IntoIter = IntoIter<<DoubleWindow as IntoIterator>::Item>
§impl IntoIterator for MenuWindow
impl IntoIterator for MenuWindow
type Item = Widget
type IntoIter = IntoIter<<MenuWindow as IntoIterator>::Item>
§impl IntoIterator for OverlayWindow
impl IntoIterator for OverlayWindow
type Item = Widget
type IntoIter = IntoIter<<OverlayWindow as IntoIterator>::Item>
§impl IntoIterator for SingleWindow
impl IntoIterator for SingleWindow
type Item = Widget
type IntoIter = IntoIter<<SingleWindow as IntoIterator>::Item>
Source§impl IntoIterator for devela::_dep::js_sys::Array
impl IntoIterator for devela::_dep::js_sys::Array
Source§impl IntoIterator for Iterator
impl IntoIterator for Iterator
§impl IntoIterator for devela::_dep::rustix::event::epoll::CreateFlags
impl IntoIterator for devela::_dep::rustix::event::epoll::CreateFlags
type Item = CreateFlags
type IntoIter = Iter<CreateFlags>
§impl IntoIterator for EventfdFlags
impl IntoIterator for EventfdFlags
type Item = EventfdFlags
type IntoIter = Iter<EventfdFlags>
§impl IntoIterator for devela::_dep::rustix::fs::inotify::CreateFlags
impl IntoIterator for devela::_dep::rustix::fs::inotify::CreateFlags
type Item = CreateFlags
type IntoIter = Iter<CreateFlags>
§impl IntoIterator for WatchFlags
impl IntoIterator for WatchFlags
type Item = WatchFlags
type IntoIter = Iter<WatchFlags>
§impl IntoIterator for FallocateFlags
impl IntoIterator for FallocateFlags
type Item = FallocateFlags
type IntoIter = Iter<FallocateFlags>
§impl IntoIterator for MemfdFlags
impl IntoIterator for MemfdFlags
type Item = MemfdFlags
type IntoIter = Iter<MemfdFlags>
§impl IntoIterator for MountFlags
impl IntoIterator for MountFlags
type Item = MountFlags
type IntoIter = Iter<MountFlags>
§impl IntoIterator for MountPropagationFlags
impl IntoIterator for MountPropagationFlags
type Item = MountPropagationFlags
type IntoIter = Iter<MountPropagationFlags>
§impl IntoIterator for RenameFlags
impl IntoIterator for RenameFlags
type Item = RenameFlags
type IntoIter = Iter<RenameFlags>
§impl IntoIterator for ResolveFlags
impl IntoIterator for ResolveFlags
type Item = ResolveFlags
type IntoIter = Iter<ResolveFlags>
§impl IntoIterator for StatVfsMountFlags
impl IntoIterator for StatVfsMountFlags
type Item = StatVfsMountFlags
type IntoIter = Iter<StatVfsMountFlags>
§impl IntoIterator for StatxFlags
impl IntoIterator for StatxFlags
type Item = StatxFlags
type IntoIter = Iter<StatxFlags>
§impl IntoIterator for UnmountFlags
impl IntoIterator for UnmountFlags
type Item = UnmountFlags
type IntoIter = Iter<UnmountFlags>
§impl IntoIterator for XattrFlags
impl IntoIterator for XattrFlags
type Item = XattrFlags
type IntoIter = Iter<XattrFlags>
§impl IntoIterator for ReadWriteFlags
impl IntoIterator for ReadWriteFlags
type Item = ReadWriteFlags
type IntoIter = Iter<ReadWriteFlags>
§impl IntoIterator for EventFlags
impl IntoIterator for EventFlags
type Item = EventFlags
type IntoIter = Iter<EventFlags>
§impl IntoIterator for IoringAcceptFlags
impl IntoIterator for IoringAcceptFlags
type Item = IoringAcceptFlags
type IntoIter = Iter<IoringAcceptFlags>
§impl IntoIterator for IoringAsyncCancelFlags
impl IntoIterator for IoringAsyncCancelFlags
type Item = IoringAsyncCancelFlags
type IntoIter = Iter<IoringAsyncCancelFlags>
§impl IntoIterator for IoringCqFlags
impl IntoIterator for IoringCqFlags
type Item = IoringCqFlags
type IntoIter = Iter<IoringCqFlags>
§impl IntoIterator for IoringCqeFlags
impl IntoIterator for IoringCqeFlags
type Item = IoringCqeFlags
type IntoIter = Iter<IoringCqeFlags>
§impl IntoIterator for IoringEnterFlags
impl IntoIterator for IoringEnterFlags
type Item = IoringEnterFlags
type IntoIter = Iter<IoringEnterFlags>
§impl IntoIterator for IoringFeatureFlags
impl IntoIterator for IoringFeatureFlags
type Item = IoringFeatureFlags
type IntoIter = Iter<IoringFeatureFlags>
§impl IntoIterator for IoringFsyncFlags
impl IntoIterator for IoringFsyncFlags
type Item = IoringFsyncFlags
type IntoIter = Iter<IoringFsyncFlags>
§impl IntoIterator for IoringMsgringFlags
impl IntoIterator for IoringMsgringFlags
type Item = IoringMsgringFlags
type IntoIter = Iter<IoringMsgringFlags>
§impl IntoIterator for IoringOpFlags
impl IntoIterator for IoringOpFlags
type Item = IoringOpFlags
type IntoIter = Iter<IoringOpFlags>
§impl IntoIterator for IoringPollFlags
impl IntoIterator for IoringPollFlags
type Item = IoringPollFlags
type IntoIter = Iter<IoringPollFlags>
§impl IntoIterator for IoringRecvFlags
impl IntoIterator for IoringRecvFlags
type Item = IoringRecvFlags
type IntoIter = Iter<IoringRecvFlags>
§impl IntoIterator for IoringRegisterFlags
impl IntoIterator for IoringRegisterFlags
type Item = IoringRegisterFlags
type IntoIter = Iter<IoringRegisterFlags>
§impl IntoIterator for IoringRsrcFlags
impl IntoIterator for IoringRsrcFlags
type Item = IoringRsrcFlags
type IntoIter = Iter<IoringRsrcFlags>
§impl IntoIterator for IoringSendFlags
impl IntoIterator for IoringSendFlags
type Item = IoringSendFlags
type IntoIter = Iter<IoringSendFlags>
§impl IntoIterator for IoringSetupFlags
impl IntoIterator for IoringSetupFlags
type Item = IoringSetupFlags
type IntoIter = Iter<IoringSetupFlags>
§impl IntoIterator for IoringSqFlags
impl IntoIterator for IoringSqFlags
type Item = IoringSqFlags
type IntoIter = Iter<IoringSqFlags>
§impl IntoIterator for IoringSqeFlags
impl IntoIterator for IoringSqeFlags
type Item = IoringSqeFlags
type IntoIter = Iter<IoringSqeFlags>
§impl IntoIterator for IoringTimeoutFlags
impl IntoIterator for IoringTimeoutFlags
type Item = IoringTimeoutFlags
type IntoIter = Iter<IoringTimeoutFlags>
§impl IntoIterator for RecvmsgOutFlags
impl IntoIterator for RecvmsgOutFlags
type Item = RecvmsgOutFlags
type IntoIter = Iter<RecvmsgOutFlags>
§impl IntoIterator for SocketFlags
impl IntoIterator for SocketFlags
type Item = SocketFlags
type IntoIter = Iter<SocketFlags>
§impl IntoIterator for devela::_dep::rustix::io_uring::SpliceFlags
impl IntoIterator for devela::_dep::rustix::io_uring::SpliceFlags
type Item = SpliceFlags
type IntoIter = Iter<SpliceFlags>
§impl IntoIterator for MlockAllFlags
impl IntoIterator for MlockAllFlags
type Item = MlockAllFlags
type IntoIter = Iter<MlockAllFlags>
§impl IntoIterator for MlockFlags
impl IntoIterator for MlockFlags
type Item = MlockFlags
type IntoIter = Iter<MlockFlags>
§impl IntoIterator for MprotectFlags
impl IntoIterator for MprotectFlags
type Item = MprotectFlags
type IntoIter = Iter<MprotectFlags>
§impl IntoIterator for MremapFlags
impl IntoIterator for MremapFlags
type Item = MremapFlags
type IntoIter = Iter<MremapFlags>
§impl IntoIterator for MsyncFlags
impl IntoIterator for MsyncFlags
type Item = MsyncFlags
type IntoIter = Iter<MsyncFlags>
§impl IntoIterator for UserfaultfdFlags
impl IntoIterator for UserfaultfdFlags
type Item = UserfaultfdFlags
type IntoIter = Iter<UserfaultfdFlags>
§impl IntoIterator for FsMountFlags
impl IntoIterator for FsMountFlags
type Item = FsMountFlags
type IntoIter = Iter<FsMountFlags>
§impl IntoIterator for FsOpenFlags
impl IntoIterator for FsOpenFlags
type Item = FsOpenFlags
type IntoIter = Iter<FsOpenFlags>
§impl IntoIterator for FsPickFlags
impl IntoIterator for FsPickFlags
type Item = FsPickFlags
type IntoIter = Iter<FsPickFlags>
§impl IntoIterator for MountAttrFlags
impl IntoIterator for MountAttrFlags
type Item = MountAttrFlags
type IntoIter = Iter<MountAttrFlags>
§impl IntoIterator for MoveMountFlags
impl IntoIterator for MoveMountFlags
type Item = MoveMountFlags
type IntoIter = Iter<MoveMountFlags>
§impl IntoIterator for OpenTreeFlags
impl IntoIterator for OpenTreeFlags
type Item = OpenTreeFlags
type IntoIter = Iter<OpenTreeFlags>
§impl IntoIterator for SockaddrXdpFlags
impl IntoIterator for SockaddrXdpFlags
type Item = SockaddrXdpFlags
type IntoIter = Iter<SockaddrXdpFlags>
§impl IntoIterator for XdpDescOptions
impl IntoIterator for XdpDescOptions
type Item = XdpDescOptions
type IntoIter = Iter<XdpDescOptions>
§impl IntoIterator for XdpOptionsFlags
impl IntoIterator for XdpOptionsFlags
type Item = XdpOptionsFlags
type IntoIter = Iter<XdpOptionsFlags>
§impl IntoIterator for XdpRingFlags
impl IntoIterator for XdpRingFlags
type Item = XdpRingFlags
type IntoIter = Iter<XdpRingFlags>
§impl IntoIterator for XdpUmemRegFlags
impl IntoIterator for XdpUmemRegFlags
type Item = XdpUmemRegFlags
type IntoIter = Iter<XdpUmemRegFlags>
§impl IntoIterator for devela::_dep::rustix::pipe::SpliceFlags
impl IntoIterator for devela::_dep::rustix::pipe::SpliceFlags
type Item = SpliceFlags
type IntoIter = Iter<SpliceFlags>
§impl IntoIterator for FloatingPointEmulationControl
impl IntoIterator for FloatingPointEmulationControl
type Item = FloatingPointEmulationControl
type IntoIter = Iter<FloatingPointEmulationControl>
§impl IntoIterator for FloatingPointExceptionMode
impl IntoIterator for FloatingPointExceptionMode
type Item = FloatingPointExceptionMode
type IntoIter = Iter<FloatingPointExceptionMode>
§impl IntoIterator for MembarrierQuery
impl IntoIterator for MembarrierQuery
type Item = MembarrierQuery
type IntoIter = Iter<MembarrierQuery>
§impl IntoIterator for PidfdFlags
impl IntoIterator for PidfdFlags
type Item = PidfdFlags
type IntoIter = Iter<PidfdFlags>
§impl IntoIterator for PidfdGetfdFlags
impl IntoIterator for PidfdGetfdFlags
type Item = PidfdGetfdFlags
type IntoIter = Iter<PidfdGetfdFlags>
§impl IntoIterator for SpeculationFeatureControl
impl IntoIterator for SpeculationFeatureControl
type Item = SpeculationFeatureControl
type IntoIter = Iter<SpeculationFeatureControl>
§impl IntoIterator for SpeculationFeatureState
impl IntoIterator for SpeculationFeatureState
type Item = SpeculationFeatureState
type IntoIter = Iter<SpeculationFeatureState>
§impl IntoIterator for UnalignedAccessControl
impl IntoIterator for UnalignedAccessControl
type Item = UnalignedAccessControl
type IntoIter = Iter<UnalignedAccessControl>
§impl IntoIterator for WaitOptions
impl IntoIterator for WaitOptions
type Item = WaitOptions
type IntoIter = Iter<WaitOptions>
§impl IntoIterator for WaitidOptions
impl IntoIterator for WaitidOptions
type Item = WaitidOptions
type IntoIter = Iter<WaitidOptions>
§impl IntoIterator for OpenptFlags
impl IntoIterator for OpenptFlags
type Item = OpenptFlags
type IntoIter = Iter<OpenptFlags>
§impl IntoIterator for GetRandomFlags
impl IntoIterator for GetRandomFlags
type Item = GetRandomFlags
type IntoIter = Iter<GetRandomFlags>
§impl IntoIterator for ControlModes
impl IntoIterator for ControlModes
type Item = ControlModes
type IntoIter = Iter<ControlModes>
§impl IntoIterator for InputModes
impl IntoIterator for InputModes
type Item = InputModes
type IntoIter = Iter<InputModes>
§impl IntoIterator for LocalModes
impl IntoIterator for LocalModes
type Item = LocalModes
type IntoIter = Iter<LocalModes>
§impl IntoIterator for OutputModes
impl IntoIterator for OutputModes
type Item = OutputModes
type IntoIter = Iter<OutputModes>
§impl IntoIterator for CapabilitiesSecureBits
impl IntoIterator for CapabilitiesSecureBits
type Item = CapabilitiesSecureBits
type IntoIter = Iter<CapabilitiesSecureBits>
§impl IntoIterator for CapabilityFlags
impl IntoIterator for CapabilityFlags
type Item = CapabilityFlags
type IntoIter = Iter<CapabilityFlags>
§impl IntoIterator for devela::_dep::rustix::thread::FutexFlags
impl IntoIterator for devela::_dep::rustix::thread::FutexFlags
§impl IntoIterator for TaggedAddressMode
impl IntoIterator for TaggedAddressMode
type Item = TaggedAddressMode
type IntoIter = Iter<TaggedAddressMode>
§impl IntoIterator for ThreadNameSpaceType
impl IntoIterator for ThreadNameSpaceType
type Item = ThreadNameSpaceType
type IntoIter = Iter<ThreadNameSpaceType>
type Item = UnshareFlags
type IntoIter = Iter<UnshareFlags>
§impl IntoIterator for TimerfdFlags
impl IntoIterator for TimerfdFlags
type Item = TimerfdFlags
type IntoIter = Iter<TimerfdFlags>
§impl IntoIterator for TimerfdTimerFlags
impl IntoIterator for TimerfdTimerFlags
type Item = TimerfdTimerFlags
type IntoIter = Iter<TimerfdTimerFlags>
§impl IntoIterator for MessageBoxButtonFlag
impl IntoIterator for MessageBoxButtonFlag
type Item = MessageBoxButtonFlag
type IntoIter = Iter<MessageBoxButtonFlag>
§impl IntoIterator for MessageBoxFlag
impl IntoIterator for MessageBoxFlag
type Item = MessageBoxFlag
type IntoIter = Iter<MessageBoxFlag>
§impl IntoIterator for devela::_dep::toml_edit::Array
impl IntoIterator for devela::_dep::toml_edit::Array
§impl IntoIterator for ArrayOfTables
impl IntoIterator for ArrayOfTables
§impl IntoIterator for InlineTable
impl IntoIterator for InlineTable
type Item = (InternalString, Value)
type IntoIter = Box<dyn Iterator<Item = (InternalString, Value)>>
§impl IntoIterator for devela::_dep::toml_edit::Table
impl IntoIterator for devela::_dep::toml_edit::Table
type Item = (InternalString, Item)
type IntoIter = Box<dyn Iterator<Item = (InternalString, Item)>>
§impl IntoIterator for EpollCreateFlags
impl IntoIterator for EpollCreateFlags
1.6.0 · Source§impl<'a> IntoIterator for &'a Path
impl<'a> IntoIterator for &'a Path
1.6.0 · Source§impl<'a> IntoIterator for &'a PathBuf
impl<'a> IntoIterator for &'a PathBuf
1.10.0 · Source§impl<'a> IntoIterator for &'a UnixListener
impl<'a> IntoIterator for &'a UnixListener
Source§impl<'a> IntoIterator for &'a Iterator
impl<'a> IntoIterator for &'a Iterator
§impl<'a> IntoIterator for &'a GlobResults<'a>
impl<'a> IntoIterator for &'a GlobResults<'a>
§impl<'a> IntoIterator for &'a Components
impl<'a> IntoIterator for &'a Components
§impl<'a> IntoIterator for &'a Networks
impl<'a> IntoIterator for &'a Networks
type Item = (&'a String, &'a NetworkData)
type IntoIter = Iter<'a, String, NetworkData>
§impl<'a> IntoIterator for &'a mut Components
impl<'a> IntoIterator for &'a mut Components
§impl<'a> IntoIterator for &'a mut Groups
impl<'a> IntoIterator for &'a mut Groups
§impl<'a> IntoIterator for FeatureNames<'a>
impl<'a> IntoIterator for FeatureNames<'a>
§impl<'a> IntoIterator for SvgDocumentsList<'a>
impl<'a> IntoIterator for SvgDocumentsList<'a>
§impl<'a> IntoIterator for SvgDocumentsList<'a>
impl<'a> IntoIterator for SvgDocumentsList<'a>
§impl<'a, 'b, T> IntoIterator for &'b GetAll<'a, T>where
'b: 'a,
impl<'a, 'b, T> IntoIterator for &'b GetAll<'a, T>where
'b: 'a,
§impl<'a, 'b, T> IntoIterator for &'b OccupiedEntry<'a, T>where
'b: 'a,
impl<'a, 'b, T> IntoIterator for &'b OccupiedEntry<'a, T>where
'b: 'a,
§impl<'a, 'b, T> IntoIterator for &'b mut OccupiedEntry<'a, T>where
'b: 'a,
impl<'a, 'b, T> IntoIterator for &'b mut OccupiedEntry<'a, T>where
'b: 'a,
§impl<'a, 'bump, T> IntoIterator for &'a devela::_dep::bumpalo::collections::Vec<'bump, T>
impl<'a, 'bump, T> IntoIterator for &'a devela::_dep::bumpalo::collections::Vec<'bump, T>
§impl<'a, 'bump, T> IntoIterator for &'a mut devela::_dep::bumpalo::collections::Vec<'bump, T>
impl<'a, 'bump, T> IntoIterator for &'a mut devela::_dep::bumpalo::collections::Vec<'bump, T>
§impl<'a, A> IntoIterator for &'a SmallVec<A>where
A: Array,
impl<'a, A> IntoIterator for &'a SmallVec<A>where
A: Array,
§impl<'a, A> IntoIterator for &'a mut SmallVec<A>where
A: Array,
impl<'a, A> IntoIterator for &'a mut SmallVec<A>where
A: Array,
§impl<'a, E> IntoIterator for &'a mut SignalsInfo<E>where
E: Exfiltrator,
impl<'a, E> IntoIterator for &'a mut SignalsInfo<E>where
E: Exfiltrator,
§impl<'a, I> IntoIterator for &'a IntoChunks<I>
impl<'a, I> IntoIterator for &'a IntoChunks<I>
§impl<'a, K, I, F> IntoIterator for &'a ChunkBy<K, I, F>
impl<'a, K, I, F> IntoIterator for &'a ChunkBy<K, I, F>
§impl<'a, K, V> IntoIterator for &'a Slice<K, V>
impl<'a, K, V> IntoIterator for &'a Slice<K, V>
§impl<'a, K, V> IntoIterator for &'a mut Slice<K, V>
impl<'a, K, V> IntoIterator for &'a mut Slice<K, V>
1.0.0 · Source§impl<'a, K, V, A> IntoIterator for &'a BTreeMap<K, V, A>
impl<'a, K, V, A> IntoIterator for &'a BTreeMap<K, V, A>
1.0.0 · Source§impl<'a, K, V, A> IntoIterator for &'a mut BTreeMap<K, V, A>
impl<'a, K, V, A> IntoIterator for &'a mut BTreeMap<K, V, A>
1.0.0 · Source§impl<'a, K, V, S> IntoIterator for &'a devela::_dep::_std::collections::HashMap<K, V, S>
impl<'a, K, V, S> IntoIterator for &'a devela::_dep::_std::collections::HashMap<K, V, S>
§impl<'a, K, V, S> IntoIterator for &'a IndexMap<K, V, S>
impl<'a, K, V, S> IntoIterator for &'a IndexMap<K, V, S>
1.0.0 · Source§impl<'a, K, V, S> IntoIterator for &'a mut devela::_dep::_std::collections::HashMap<K, V, S>
impl<'a, K, V, S> IntoIterator for &'a mut devela::_dep::_std::collections::HashMap<K, V, S>
§impl<'a, K, V, S> IntoIterator for &'a mut IndexMap<K, V, S>
impl<'a, K, V, S> IntoIterator for &'a mut IndexMap<K, V, S>
§impl<'a, K, V, S, A> IntoIterator for &'a devela::all::HashMap<K, V, S, A>where
A: Allocator,
impl<'a, K, V, S, A> IntoIterator for &'a devela::all::HashMap<K, V, S, A>where
A: Allocator,
§impl<'a, K, V, S, A> IntoIterator for &'a mut devela::all::HashMap<K, V, S, A>where
A: Allocator,
impl<'a, K, V, S, A> IntoIterator for &'a mut devela::all::HashMap<K, V, S, A>where
A: Allocator,
1.4.0 · Source§impl<'a, T> IntoIterator for &'a Option<T>
impl<'a, T> IntoIterator for &'a Option<T>
1.0.0 · Source§impl<'a, T> IntoIterator for &'a [T]
impl<'a, T> IntoIterator for &'a [T]
Source§impl<'a, T> IntoIterator for &'a ConstList<'a, T>
impl<'a, T> IntoIterator for &'a ConstList<'a, T>
Source§impl<'a, T> IntoIterator for &'a devela::_dep::_std::sync::mpmc::Receiver<T>
impl<'a, T> IntoIterator for &'a devela::_dep::_std::sync::mpmc::Receiver<T>
1.1.0 · Source§impl<'a, T> IntoIterator for &'a devela::_dep::_std::sync::mpsc::Receiver<T>
impl<'a, T> IntoIterator for &'a devela::_dep::_std::sync::mpsc::Receiver<T>
§impl<'a, T> IntoIterator for &'a devela::_dep::flume::Receiver<T>
This exists as a shorthand for Receiver::iter
.
impl<'a, T> IntoIterator for &'a devela::_dep::flume::Receiver<T>
This exists as a shorthand for Receiver::iter
.
§impl<'a, T> IntoIterator for &'a HeaderMap<T>
impl<'a, T> IntoIterator for &'a HeaderMap<T>
1.4.0 · Source§impl<'a, T> IntoIterator for &'a mut Option<T>
impl<'a, T> IntoIterator for &'a mut Option<T>
1.0.0 · Source§impl<'a, T> IntoIterator for &'a mut [T]
impl<'a, T> IntoIterator for &'a mut [T]
§impl<'a, T> IntoIterator for &'a mut HeaderMap<T>
impl<'a, T> IntoIterator for &'a mut HeaderMap<T>
§impl<'a, T> IntoIterator for &'a mut Arena<T>
impl<'a, T> IntoIterator for &'a mut Arena<T>
§impl<'a, T> IntoIterator for &'a mut VecMap<T>
impl<'a, T> IntoIterator for &'a mut VecMap<T>
§impl<'a, T> IntoIterator for OccupiedEntry<'a, T>
impl<'a, T> IntoIterator for OccupiedEntry<'a, T>
§impl<'a, T> IntoIterator for LazyArray16<'a, T>where
T: FromData,
impl<'a, T> IntoIterator for LazyArray16<'a, T>where
T: FromData,
§impl<'a, T> IntoIterator for LazyArray16<'a, T>where
T: FromData,
impl<'a, T> IntoIterator for LazyArray16<'a, T>where
T: FromData,
§impl<'a, T> IntoIterator for LazyArray32<'a, T>where
T: FromData,
impl<'a, T> IntoIterator for LazyArray32<'a, T>where
T: FromData,
§impl<'a, T> IntoIterator for LazyArray32<'a, T>where
T: FromData,
impl<'a, T> IntoIterator for LazyArray32<'a, T>where
T: FromData,
§impl<'a, T> IntoIterator for ReadChunk<'a, T>
impl<'a, T> IntoIterator for ReadChunk<'a, T>
§impl<'a, T> IntoIterator for RecordList<'a, T>where
T: RecordListItem<'a>,
impl<'a, T> IntoIterator for RecordList<'a, T>where
T: RecordListItem<'a>,
§impl<'a, T> IntoIterator for RecordList<'a, T>where
T: RecordListItem<'a>,
impl<'a, T> IntoIterator for RecordList<'a, T>where
T: RecordListItem<'a>,
1.0.0 · Source§impl<'a, T, A> IntoIterator for &'a BTreeSet<T, A>
impl<'a, T, A> IntoIterator for &'a BTreeSet<T, A>
1.0.0 · Source§impl<'a, T, A> IntoIterator for &'a BinaryHeap<T, A>where
A: Allocator,
impl<'a, T, A> IntoIterator for &'a BinaryHeap<T, A>where
A: Allocator,
1.0.0 · Source§impl<'a, T, A> IntoIterator for &'a LinkedList<T, A>where
A: Allocator,
impl<'a, T, A> IntoIterator for &'a LinkedList<T, A>where
A: Allocator,
1.0.0 · Source§impl<'a, T, A> IntoIterator for &'a devela::all::Vec<T, A>where
A: Allocator,
impl<'a, T, A> IntoIterator for &'a devela::all::Vec<T, A>where
A: Allocator,
1.0.0 · Source§impl<'a, T, A> IntoIterator for &'a VecDeque<T, A>where
A: Allocator,
impl<'a, T, A> IntoIterator for &'a VecDeque<T, A>where
A: Allocator,
§impl<'a, T, A> IntoIterator for &'a HashTable<T, A>where
A: Allocator,
impl<'a, T, A> IntoIterator for &'a HashTable<T, A>where
A: Allocator,
1.0.0 · Source§impl<'a, T, A> IntoIterator for &'a mut LinkedList<T, A>where
A: Allocator,
impl<'a, T, A> IntoIterator for &'a mut LinkedList<T, A>where
A: Allocator,
1.0.0 · Source§impl<'a, T, A> IntoIterator for &'a mut devela::all::Vec<T, A>where
A: Allocator,
impl<'a, T, A> IntoIterator for &'a mut devela::all::Vec<T, A>where
A: Allocator,
1.0.0 · Source§impl<'a, T, A> IntoIterator for &'a mut VecDeque<T, A>where
A: Allocator,
impl<'a, T, A> IntoIterator for &'a mut VecDeque<T, A>where
A: Allocator,
§impl<'a, T, A> IntoIterator for &'a mut HashTable<T, A>where
A: Allocator,
impl<'a, T, A> IntoIterator for &'a mut HashTable<T, A>where
A: Allocator,
1.4.0 · Source§impl<'a, T, E> IntoIterator for &'a Result<T, E>
impl<'a, T, E> IntoIterator for &'a Result<T, E>
1.4.0 · Source§impl<'a, T, E> IntoIterator for &'a mut Result<T, E>
impl<'a, T, E> IntoIterator for &'a mut Result<T, E>
1.0.0 · Source§impl<'a, T, S> IntoIterator for &'a devela::_dep::_std::collections::HashSet<T, S>
impl<'a, T, S> IntoIterator for &'a devela::_dep::_std::collections::HashSet<T, S>
§impl<'a, T, S, A> IntoIterator for &'a devela::all::HashSet<T, S, A>where
A: Allocator,
impl<'a, T, S, A> IntoIterator for &'a devela::all::HashSet<T, S, A>where
A: Allocator,
Source§impl<'a, T, const CAP: usize> IntoIterator for &'a arrayvec::arrayvec::ArrayVec<T, CAP>where
T: 'a,
Iterate the ArrayVec
with references to each element.
impl<'a, T, const CAP: usize> IntoIterator for &'a arrayvec::arrayvec::ArrayVec<T, CAP>where
T: 'a,
Iterate the ArrayVec
with references to each element.
use arrayvec::ArrayVec;
let array = ArrayVec::from([1, 2, 3]);
for elt in &array {
// ...
}
Source§impl<'a, T, const CAP: usize> IntoIterator for &'a mut arrayvec::arrayvec::ArrayVec<T, CAP>where
T: 'a,
Iterate the ArrayVec
with mutable references to each element.
impl<'a, T, const CAP: usize> IntoIterator for &'a mut arrayvec::arrayvec::ArrayVec<T, CAP>where
T: 'a,
Iterate the ArrayVec
with mutable references to each element.
use arrayvec::ArrayVec;
let mut array = ArrayVec::from([1, 2, 3]);
for elt in &mut array {
// ...
}
1.0.0 · Source§impl<'a, T, const N: usize> IntoIterator for &'a [T; N]
impl<'a, T, const N: usize> IntoIterator for &'a [T; N]
§impl<'a, T, const N: usize> IntoIterator for &'a devela::_dep::ureq::unversioned::resolver::ArrayVec<T, N>
impl<'a, T, const N: usize> IntoIterator for &'a devela::_dep::ureq::unversioned::resolver::ArrayVec<T, N>
1.0.0 · Source§impl<'a, T, const N: usize> IntoIterator for &'a mut [T; N]
impl<'a, T, const N: usize> IntoIterator for &'a mut [T; N]
§impl<'bump, T> IntoIterator for devela::_dep::bumpalo::collections::Vec<'bump, T>where
T: 'bump,
impl<'bump, T> IntoIterator for devela::_dep::bumpalo::collections::Vec<'bump, T>where
T: 'bump,
§impl<'py> IntoIterator for &Bound<'py, PyDict>
impl<'py> IntoIterator for &Bound<'py, PyDict>
§impl<'py> IntoIterator for &Bound<'py, PyFrozenSet>
impl<'py> IntoIterator for &Bound<'py, PyFrozenSet>
§impl<'py> IntoIterator for &Bound<'py, PyIterator>
impl<'py> IntoIterator for &Bound<'py, PyIterator>
§impl<'py> IntoIterator for &Bound<'py, PyList>
impl<'py> IntoIterator for &Bound<'py, PyList>
§impl<'py> IntoIterator for &Bound<'py, PySet>
impl<'py> IntoIterator for &Bound<'py, PySet>
§impl<'py> IntoIterator for &Bound<'py, PyTuple>
impl<'py> IntoIterator for &Bound<'py, PyTuple>
§impl<'py> IntoIterator for Bound<'py, PyDict>
impl<'py> IntoIterator for Bound<'py, PyDict>
§impl<'py> IntoIterator for Bound<'py, PyFrozenSet>
impl<'py> IntoIterator for Bound<'py, PyFrozenSet>
§impl<'py> IntoIterator for Bound<'py, PyList>
impl<'py> IntoIterator for Bound<'py, PyList>
§impl<'py> IntoIterator for Bound<'py, PySet>
impl<'py> IntoIterator for Bound<'py, PySet>
§impl<'py> IntoIterator for Bound<'py, PyTuple>
impl<'py> IntoIterator for Bound<'py, PyTuple>
§impl<'s> IntoIterator for &'s devela::_dep::toml_edit::Array
impl<'s> IntoIterator for &'s devela::_dep::toml_edit::Array
§impl<'s> IntoIterator for &'s ArrayOfTables
impl<'s> IntoIterator for &'s ArrayOfTables
§impl<'s> IntoIterator for &'s InlineTable
impl<'s> IntoIterator for &'s InlineTable
§impl<'s> IntoIterator for &'s devela::_dep::toml_edit::Table
impl<'s> IntoIterator for &'s devela::_dep::toml_edit::Table
Source§impl<A> IntoIterator for Range<A>where
A: Step,
impl<A> IntoIterator for Range<A>where
A: Step,
Source§impl<A> IntoIterator for RangeFrom<A>where
A: Step,
impl<A> IntoIterator for RangeFrom<A>where
A: Step,
Source§impl<A> IntoIterator for RangeInclusive<A>where
A: Step,
impl<A> IntoIterator for RangeInclusive<A>where
A: Step,
§impl<A> IntoIterator for SmallVec<A>where
A: Array,
impl<A> IntoIterator for SmallVec<A>where
A: Array,
§impl<I> IntoIterator for &RcIter<I>where
I: Iterator,
Return an iterator from &RcIter<I>
(by simply cloning it).
impl<I> IntoIterator for &RcIter<I>where
I: Iterator,
Return an iterator from &RcIter<I>
(by simply cloning it).
1.0.0 · Source§impl<I> IntoIterator for Iwhere
I: Iterator,
impl<I> IntoIterator for Iwhere
I: Iterator,
1.0.0 · Source§impl<K, V, A> IntoIterator for BTreeMap<K, V, A>
impl<K, V, A> IntoIterator for BTreeMap<K, V, A>
1.0.0 · Source§impl<K, V, S> IntoIterator for devela::_dep::_std::collections::HashMap<K, V, S>
impl<K, V, S> IntoIterator for devela::_dep::_std::collections::HashMap<K, V, S>
§impl<K, V, S, A> IntoIterator for devela::all::HashMap<K, V, S, A>where
A: Allocator,
impl<K, V, S, A> IntoIterator for devela::all::HashMap<K, V, S, A>where
A: Allocator,
1.0.0 · Source§impl<T> IntoIterator for Option<T>
impl<T> IntoIterator for Option<T>
Source§impl<T> IntoIterator for devela::_dep::_std::sync::mpmc::Receiver<T>
impl<T> IntoIterator for devela::_dep::_std::sync::mpmc::Receiver<T>
1.1.0 · Source§impl<T> IntoIterator for devela::_dep::_std::sync::mpsc::Receiver<T>
impl<T> IntoIterator for devela::_dep::_std::sync::mpsc::Receiver<T>
§impl<T> IntoIterator for devela::_dep::flume::Receiver<T>
impl<T> IntoIterator for devela::_dep::flume::Receiver<T>
§impl<T> IntoIterator for HeaderMap<T>
impl<T> IntoIterator for HeaderMap<T>
1.0.0 · Source§impl<T, A> IntoIterator for BTreeSet<T, A>
impl<T, A> IntoIterator for BTreeSet<T, A>
1.0.0 · Source§impl<T, A> IntoIterator for BinaryHeap<T, A>where
A: Allocator,
impl<T, A> IntoIterator for BinaryHeap<T, A>where
A: Allocator,
1.0.0 · Source§impl<T, A> IntoIterator for LinkedList<T, A>where
A: Allocator,
impl<T, A> IntoIterator for LinkedList<T, A>where
A: Allocator,
1.0.0 · Source§impl<T, A> IntoIterator for devela::all::Vec<T, A>where
A: Allocator,
impl<T, A> IntoIterator for devela::all::Vec<T, A>where
A: Allocator,
1.0.0 · Source§impl<T, A> IntoIterator for VecDeque<T, A>where
A: Allocator,
impl<T, A> IntoIterator for VecDeque<T, A>where
A: Allocator,
§impl<T, A> IntoIterator for HashTable<T, A>where
A: Allocator,
impl<T, A> IntoIterator for HashTable<T, A>where
A: Allocator,
1.0.0 · Source§impl<T, E> IntoIterator for Result<T, E>
impl<T, E> IntoIterator for Result<T, E>
1.0.0 · Source§impl<T, S> IntoIterator for devela::_dep::_std::collections::HashSet<T, S>
impl<T, S> IntoIterator for devela::_dep::_std::collections::HashSet<T, S>
§impl<T, S, A> IntoIterator for devela::all::HashSet<T, S, A>where
A: Allocator,
impl<T, S, A> IntoIterator for devela::all::HashSet<T, S, A>where
A: Allocator,
§impl<T, U> IntoIterator for Chain<T, U>where
T: Buf,
U: Buf,
impl<T, U> IntoIterator for Chain<T, U>where
T: Buf,
U: Buf,
Source§impl<T, const CAP: usize> IntoIterator for arrayvec::arrayvec::ArrayVec<T, CAP>
Iterate the ArrayVec
with each element by value.
impl<T, const CAP: usize> IntoIterator for arrayvec::arrayvec::ArrayVec<T, CAP>
Iterate the ArrayVec
with each element by value.
The vector is consumed by this operation.
use arrayvec::ArrayVec;
for elt in ArrayVec::from([1, 2, 3]) {
// ...
}