@@ -63,15 +63,15 @@ pub struct Client {
6363}
6464
6565impl Client {
66- /// Creates a client connection to a bitcoind JSON-RPC server with authentication
66+ /// Creates a client connection to a bitcoind JSON-RPC server with authentication.
6767 ///
6868 /// Requires authentication via username/password or cookie file.
6969 /// For connections without authentication, use `with_transport` instead.
7070 ///
7171 /// # Arguments
7272 ///
7373 /// * `url` - URL of the RPC server
74- /// * `auth` - authentication method (`UserPass` or `CookieFile`).
74+ /// * `auth` - authentication method (`UserPass` or `CookieFile`)
7575 ///
7676 /// # Errors
7777 ///
@@ -109,7 +109,7 @@ impl Client {
109109 }
110110 }
111111
112- /// Calls the underlying RPC `method` with given `args` list
112+ /// Calls the underlying RPC `method` with the given `args`.
113113 ///
114114 /// This is the generic function used by all specific RPC methods.
115115 pub fn call < T > ( & self , method : & str , args : & [ serde_json:: Value ] ) -> Result < T , Error >
@@ -124,9 +124,9 @@ impl Client {
124124 }
125125}
126126
127- /// `Bitcoind ` RPC methods implementation for `Client`
127+ /// `bitcoind ` RPC methods implementation for `Client`.
128128impl Client {
129- /// Retrieves the raw block data for a given block hash (verbosity 0)
129+ /// Retrieves the raw block data for a given block hash (verbosity 0).
130130 ///
131131 /// # Arguments
132132 ///
@@ -140,7 +140,7 @@ impl Client {
140140 . and_then ( |block_hex| deserialize_hex ( & block_hex) . map_err ( Error :: DecodeHex ) )
141141 }
142142
143- /// Retrieves the hash of the tip of the best block chain.
143+ /// Retrieves the hash of the best chain's block .
144144 ///
145145 /// # Returns
146146 ///
@@ -150,7 +150,7 @@ impl Client {
150150 . and_then ( |blockhash_hex| blockhash_hex. parse ( ) . map_err ( Error :: HexToArray ) )
151151 }
152152
153- /// Retrieves the number of blocks in the longest chain
153+ /// Retrieves the number of blocks in the longest chain.
154154 ///
155155 /// # Returns
156156 ///
@@ -162,36 +162,36 @@ impl Client {
162162 . map_err ( Error :: TryFromInt )
163163 }
164164
165- /// Retrieves the block hash at a given height
165+ /// Retrieves the ['BlockHash'] of the block at ` height`.
166166 ///
167167 /// # Arguments
168168 ///
169169 /// * `height`: The block height
170170 ///
171171 /// # Returns
172172 ///
173- /// The `BlockHash` for the given height
173+ /// The [ `BlockHash`] of the block at ` height`
174174 pub fn get_block_hash ( & self , height : u32 ) -> Result < BlockHash , Error > {
175175 self . call :: < String > ( "getblockhash" , & [ json ! ( height) ] )
176176 . and_then ( |blockhash_hex| blockhash_hex. parse ( ) . map_err ( Error :: HexToArray ) )
177177 }
178178
179- /// Retrieve the `basic` BIP 157 content filter for a particular block
179+ /// Retrieve the Compact Block Filter ( BIP-0158) with type `basic` for the block given its `Blockhash`.
180180 ///
181181 /// # Arguments
182182 ///
183183 /// * `block_hash`: The hash of the block whose filter is requested
184184 ///
185185 /// # Returns
186186 ///
187- /// The `GetBlockFilter` structure containing the filter data
187+ /// The `GetBlockFilter` structure containing the filter data for the block
188188 pub fn get_block_filter ( & self , block_hash : & BlockHash ) -> Result < GetBlockFilter , Error > {
189189 let block_filter: v30:: GetBlockFilter =
190190 self . call ( "getblockfilter" , & [ json ! ( block_hash) ] ) ?;
191191 block_filter. into_model ( ) . map_err ( Error :: GetBlockFilter )
192192 }
193193
194- /// Retrieves the raw block header for a given block hash .
194+ /// Retrieves the `Header` for a `Block` given its `BlockHash` .
195195 ///
196196 /// # Arguments
197197 ///
@@ -205,7 +205,7 @@ impl Client {
205205 . and_then ( |header_hex : String | deserialize_hex ( & header_hex) . map_err ( Error :: DecodeHex ) )
206206 }
207207
208- /// Retrieves the transaction IDs of all transactions currently in the mempool
208+ /// Retrieves the `Txid`s for all transactions in the mempool.
209209 ///
210210 /// # Returns
211211 ///
@@ -215,7 +215,7 @@ impl Client {
215215 . map ( |txids| txids. 0 )
216216 }
217217
218- /// Retrieves the raw transaction data for a given transaction ID
218+ /// Retrieves the raw transaction data for a given transaction ID.
219219 ///
220220 /// # Arguments
221221 ///
0 commit comments