Johannes Hofmann 8 лет назад
Родитель
Сommit
7642ba58eb
2 измененных файлов: 12 добавлений и 12 удалений
  1. 8
    8
      src/blob.rs
  2. 4
    4
      src/elements.rs

+ 8
- 8
src/blob.rs Просмотреть файл

@@ -43,7 +43,7 @@ pub enum BlobDecode<'a> {
43 43
 }
44 44
 
45 45
 /// A blob.
46
-/// 
46
+///
47 47
 /// A PBF file consists of a sequence of blobs. This type supports decoding the content of a blob
48 48
 /// to different types of blocks that are usually more interesting to the user.
49 49
 pub struct Blob {
@@ -109,17 +109,17 @@ pub struct BlobReader<R: Read> {
109 109
 
110 110
 impl<R: Read> BlobReader<R> {
111 111
     /// Creates a new `ElementReader`.
112
-    /// 
112
+    ///
113 113
     /// # Example
114 114
     /// ```
115 115
     /// use osmpbf::*;
116
-    /// 
116
+    ///
117 117
     /// # fn foo() -> Result<()> {
118 118
     /// let f = std::fs::File::open("tests/test.osm.pbf")?;
119 119
     /// let buf_reader = std::io::BufReader::new(f);
120
-    /// 
120
+    ///
121 121
     /// let reader = ElementReader::new(buf_reader);
122
-    /// 
122
+    ///
123 123
     /// # Ok(())
124 124
     /// # }
125 125
     /// ```
@@ -133,14 +133,14 @@ impl<R: Read> BlobReader<R> {
133 133
 
134 134
 impl BlobReader<BufReader<File>> {
135 135
     /// Tries to open the file at the given path and constructs a `BlobReader` from this.
136
-    /// 
136
+    ///
137 137
     /// # Errors
138 138
     /// Returns the same errors that `std::fs::File::open` returns.
139
-    /// 
139
+    ///
140 140
     /// # Example
141 141
     /// ```
142 142
     /// use osmpbf::*;
143
-    /// 
143
+    ///
144 144
     /// # fn foo() -> Result<()> {
145 145
     /// let reader = BlobReader::from_path("tests/test.osm.pbf")?;
146 146
     /// # Ok(())

+ 4
- 4
src/elements.rs Просмотреть файл

@@ -57,7 +57,7 @@ impl<'a> Node<'a> {
57 57
 }
58 58
 
59 59
 /// An OpenStreetMap way element (See [OSM wiki](http://wiki.openstreetmap.org/wiki/Way)).
60
-/// 
60
+///
61 61
 /// A way contains an ordered list of node references that can be accessed with the `refs` or the
62 62
 /// `refs_slice` method.
63 63
 pub struct Way<'a> {
@@ -108,7 +108,7 @@ impl<'a> Way<'a> {
108 108
 }
109 109
 
110 110
 /// An OpenStreetMap relation element (See [OSM wiki](http://wiki.openstreetmap.org/wiki/Relation)).
111
-/// 
111
+///
112 112
 /// A relation contains an ordered list of members that can be of any element type.
113 113
 pub struct Relation<'a> {
114 114
     block: &'a PrimitiveBlock,
@@ -149,7 +149,7 @@ impl<'a> Relation<'a> {
149 149
 }
150 150
 
151 151
 /// An iterator over the references of a way.
152
-/// 
152
+///
153 153
 /// Each reference corresponds to a node id.
154 154
 pub struct WayRefIter<'a> {
155 155
     deltas: std::slice::Iter<'a, i64>,
@@ -195,7 +195,7 @@ impl From<osmformat::Relation_MemberType> for RelMemberType {
195 195
 
196 196
 //TODO encapsulate member_id based on member_type (NodeId, WayId, RelationId)
197 197
 /// A member of a relation.
198
-/// 
198
+///
199 199
 /// Each member has a member type and a member id that references an element of that type.
200 200
 pub struct RelMember<'a> {
201 201
     block: &'a PrimitiveBlock,