@@ -236,32 +236,14 @@ impl Attributes {
236236 Some ( & self . 0 . get ( key) ?. value ( ) ?. value . value )
237237 }
238238
239- /// Returns the annotated attribute with the given key.
240- pub fn get_raw < Q > ( & self , key : & Q ) -> Option < & Annotated < Attribute > >
241- where
242- String : Borrow < Q > ,
243- Q : Ord + ?Sized ,
244- {
245- self . 0 . get ( key)
246- }
247-
248- /// Mutably returns the annotated attribute with the given key.
249- pub fn get_raw_mut < Q > ( & mut self , key : & Q ) -> Option < & mut Annotated < Attribute > >
250- where
251- String : Borrow < Q > ,
252- Q : Ord + ?Sized ,
253- {
254- self . 0 . get_mut ( key)
255- }
256-
257239 /// Inserts an attribute with the given value into this collection.
258240 pub fn insert < K : Into < String > , V : Into < AttributeValue > > ( & mut self , key : K , value : V ) {
259241 fn inner ( slf : & mut Attributes , key : String , value : AttributeValue ) {
260242 let attribute = Annotated :: new ( Attribute {
261243 value,
262244 other : Default :: default ( ) ,
263245 } ) ;
264- slf. insert_raw ( key, attribute) ;
246+ slf. 0 . insert ( key, attribute) ;
265247 }
266248 let value = value. into ( ) ;
267249 if !value. value . is_empty ( ) {
@@ -280,11 +262,6 @@ impl Attributes {
280262 }
281263 }
282264
283- /// Inserts an annotated attribute into this collection.
284- pub fn insert_raw ( & mut self , key : String , attribute : Annotated < Attribute > ) {
285- self . 0 . insert ( key, attribute) ;
286- }
287-
288265 /// Checks whether this collection contains an attribute with the given key.
289266 pub fn contains_key < Q > ( & self , key : & Q ) -> bool
290267 where
@@ -302,31 +279,6 @@ impl Attributes {
302279 {
303280 self . 0 . remove ( key)
304281 }
305-
306- /// Iterates over this collection's attribute keys and values.
307- pub fn iter ( & self ) -> std:: collections:: btree_map:: Iter < ' _ , String , Annotated < Attribute > > {
308- self . 0 . iter ( )
309- }
310-
311- /// Iterates mutably over this collection's attribute keys and values.
312- pub fn iter_mut (
313- & mut self ,
314- ) -> std:: collections:: btree_map:: IterMut < ' _ , String , Annotated < Attribute > > {
315- self . 0 . iter_mut ( )
316- }
317-
318- /// Returns an iterator over the keys in this collection.
319- pub fn keys ( & self ) -> std:: collections:: btree_map:: Keys < ' _ , String , Annotated < Attribute > > {
320- self . 0 . keys ( )
321- }
322-
323- /// Provides mutable access to an entry in this collection.
324- pub fn entry (
325- & mut self ,
326- key : String ,
327- ) -> std:: collections:: btree_map:: Entry < ' _ , String , Annotated < Attribute > > {
328- self . 0 . entry ( key)
329- }
330282}
331283
332284impl IntoIterator for Attributes {
0 commit comments