financial_api/fund/
financials.rs1use crate::endpoints;
2use crate::{
3 Client, Error, FundBalanceSheetsData, FundFinancialIndicatorsData, FundIncomeStatementsData,
4 FundType, Response, Thscode, ValidationError,
5};
6
7impl Client {
8 #[doc = concat!(
12 "```no_run\n",
13 include_str!("../../examples/fund_financials_indicators.rs"),
14 "\n```"
15 )]
16 pub async fn fund_financials_indicators(
17 &self,
18 fund_type: FundType,
19 thscode: impl TryInto<Thscode, Error: Into<ValidationError>>,
20 ) -> Result<Response<FundFinancialIndicatorsData>, Error> {
21 self.fund_detail(endpoints::FUND_INDICATORS, fund_type, thscode)
22 .await
23 }
24
25 #[doc = concat!(
29 "```no_run\n",
30 include_str!("../../examples/fund_financials_income_statements.rs"),
31 "\n```"
32 )]
33 pub async fn fund_financials_income_statements(
34 &self,
35 fund_type: FundType,
36 thscode: impl TryInto<Thscode, Error: Into<ValidationError>>,
37 ) -> Result<Response<FundIncomeStatementsData>, Error> {
38 self.fund_detail(endpoints::FUND_INCOME_STATEMENTS, fund_type, thscode)
39 .await
40 }
41
42 #[doc = concat!(
46 "```no_run\n",
47 include_str!("../../examples/fund_financials_balance_sheets.rs"),
48 "\n```"
49 )]
50 pub async fn fund_financials_balance_sheets(
51 &self,
52 fund_type: FundType,
53 thscode: impl TryInto<Thscode, Error: Into<ValidationError>>,
54 ) -> Result<Response<FundBalanceSheetsData>, Error> {
55 self.fund_detail(endpoints::FUND_BALANCE_SHEETS, fund_type, thscode)
56 .await
57 }
58}