@@ -75,44 +75,82 @@ pub struct BTreeSet<T> {
75
75
}
76
76
77
77
/// An iterator over a `BTreeSet`'s items.
78
+ ///
79
+ /// This structure is created by the [`iter()`] method on [`BTreeSet`].
80
+ ///
81
+ /// [`BTreeSet`]: struct.BTreeSet.html
82
+ /// [`iter()`]: struct.BTreeSet.html#method.iter
78
83
#[ stable( feature = "rust1" , since = "1.0.0" ) ]
79
84
pub struct Iter < ' a , T : ' a > {
80
85
iter : Keys < ' a , T , ( ) > ,
81
86
}
82
87
83
88
/// An owning iterator over a `BTreeSet`'s items.
89
+ ///
90
+ /// This structure is created by the [`into_iter()`] method on [`BTreeSet`]
91
+ /// [`BTreeSet`] (provided by the [`IntoIterator`] trait).
92
+ ///
93
+ /// [`BTreeSet`]: struct.BTreeSet.html
94
+ /// [`IntoIterator`]: ../../iter/trait.IntoIterator.html
95
+ /// [`into_iter()`]: ../../iter/trait.IntoIterator.html#tymethod.into_iter
84
96
#[ stable( feature = "rust1" , since = "1.0.0" ) ]
85
97
pub struct IntoIter < T > {
86
98
iter : :: btree_map:: IntoIter < T , ( ) > ,
87
99
}
88
100
89
101
/// An iterator over a sub-range of `BTreeSet`'s items.
102
+ ///
103
+ /// This structure is created by the [`range()`] method on [`BTreeSet`].
104
+ ///
105
+ /// [`BTreeSet`]: struct.BTreeSet.html
106
+ /// [`range()`]: struct.BTreeSet.html#method.range
90
107
pub struct Range < ' a , T : ' a > {
91
108
iter : :: btree_map:: Range < ' a , T , ( ) > ,
92
109
}
93
110
94
111
/// A lazy iterator producing elements in the set difference (in-order).
112
+ ///
113
+ /// This structure is created by the [`difference()`] method on [`BTreeSet`].
114
+ ///
115
+ /// [`BTreeSet`]: struct.BTreeSet.html
116
+ /// [`difference()`]: struct.BTreeSet.html#method.difference
95
117
#[ stable( feature = "rust1" , since = "1.0.0" ) ]
96
118
pub struct Difference < ' a , T : ' a > {
97
119
a : Peekable < Iter < ' a , T > > ,
98
120
b : Peekable < Iter < ' a , T > > ,
99
121
}
100
122
101
123
/// A lazy iterator producing elements in the set symmetric difference (in-order).
124
+ ///
125
+ /// This structure is created by the [`symmetric_difference()`] method on
126
+ /// [`BTreeSet`].
127
+ ///
128
+ /// [`BTreeSet`]: struct.BTreeSet.html
129
+ /// [`symmetric_difference()`]: struct.BTreeSet.html#method.symmetric_difference
102
130
#[ stable( feature = "rust1" , since = "1.0.0" ) ]
103
131
pub struct SymmetricDifference < ' a , T : ' a > {
104
132
a : Peekable < Iter < ' a , T > > ,
105
133
b : Peekable < Iter < ' a , T > > ,
106
134
}
107
135
108
136
/// A lazy iterator producing elements in the set intersection (in-order).
137
+ ///
138
+ /// This structure is created by the [`intersection()`] method on [`BTreeSet`].
139
+ ///
140
+ /// [`BTreeSet`]: struct.BTreeSet.html
141
+ /// [`intersection()`]: struct.BTreeSet.html#method.intersection
109
142
#[ stable( feature = "rust1" , since = "1.0.0" ) ]
110
143
pub struct Intersection < ' a , T : ' a > {
111
144
a : Peekable < Iter < ' a , T > > ,
112
145
b : Peekable < Iter < ' a , T > > ,
113
146
}
114
147
115
148
/// A lazy iterator producing elements in the set union (in-order).
149
+ ///
150
+ /// This structure is created by the [`union()`] method on [`BTreeSet`].
151
+ ///
152
+ /// [`BTreeSet`]: struct.BTreeSet.html
153
+ /// [`union()`]: struct.BTreeSet.html#method.union
116
154
#[ stable( feature = "rust1" , since = "1.0.0" ) ]
117
155
pub struct Union < ' a , T : ' a > {
118
156
a : Peekable < Iter < ' a , T > > ,
0 commit comments