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