From 4023e5e3860f427a89571d0aa7bdbf56f27f9d75 Mon Sep 17 00:00:00 2001 From: Anatoly Ikorsky Date: Tue, 7 Nov 2023 15:03:30 +0300 Subject: [PATCH] Style ResultSetStream::{columns, columns_ref} in accordance with the rest of the project --- src/queryable/query_result/result_set_stream.rs | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/src/queryable/query_result/result_set_stream.rs b/src/queryable/query_result/result_set_stream.rs index 6c42890d..d9eecc7d 100644 --- a/src/queryable/query_result/result_set_stream.rs +++ b/src/queryable/query_result/result_set_stream.rs @@ -102,13 +102,15 @@ impl<'r, 'a: 'r, 't: 'a, T, P> ResultSetStream<'r, 'a, 't, T, P> { .unwrap_or_default() } - /// Returns type result set. - /// - /// In order to know the type of the returned result in advance, it is helpful to process the type conversion of the data. - pub fn get_columns(&self) -> Arc<[Column]> { - self.columns.clone() + /// See [`QueryResult::columns_ref`]. + pub fn columns_ref(&self) -> &[Column] { + &self.columns[..] } + /// See [`QueryResult::columns`]. + pub fn columns(&self) -> Arc<[Column]> { + self.columns.clone() + } /// See [`Conn::info`][1]. ///