feat(tsl-api-reference): add class and framework API lookup

This commit is contained in:
csh
2026-08-20 13:49:55 +08:00
parent 7233646398
commit 651c1f68d2
637 changed files with 25498 additions and 36673 deletions
@@ -46,7 +46,7 @@ return fund7DaysAnnualRate("OF162206", 20210302T);
```tsl
setSysParam(Pn_Stock(), "OF000001");
endt := 20230112T;
return fundAdjustNaw(endt, 1); // 0.9952
return fundAdjustNaw(endt, 1); // 输出:0.9952
```
## `fundIpoC()`
@@ -114,7 +114,7 @@ Return FundIPOV();
```tsl
Setsysparam(pn_stock(), 'OF040001') ;
ReturnFundMaxMinNAW(inttodate(20040930), inttodate(20121018), 0, 0);
return FundMaxMinNAW(inttodate(20040930), inttodate(20121018), 0, 0);
```
## `fundMaxMinNAw2(end_t, type, return_type)`
@@ -140,7 +140,7 @@ ReturnFundMaxMinNAW(inttodate(20040930), inttodate(20121018), 0, 0);
```tsl
// 返回华安创新上市以来到2012年10月18日之间的最大单位净值
setSysParam(pn_stock(), 'OF040001') ;
ReturnFundMaxMinNAW2(intToDate(20121018), 0, 0);
return FundMaxMinNAW2(intToDate(20121018), 0, 0);
// 输出:4.452
```
@@ -276,10 +276,8 @@ Return FundNAWLAccumulativeNetAsset(20180822T);
```tsl
// 取华安创新2012年10月10日到2012年10月19日之间的单位净值和累计净值
Setsysparam(pn_stock(), 'OF040001') ;
ReturnFundNAWLInfo(inttodate(20121010), inttodate(20121019), 2);
return FundNAWLInfo(inttodate(20121010), inttodate(20121019), 2);
```
## `fundNAwlInfo2(end_t, type)`
@@ -303,10 +301,8 @@ ReturnFundNAWLInfo(inttodate(20121010), inttodate(20121019), 2);
```tsl
// 取华安创新2012年10月19日的单位净值和累计净值
Setsysparam(pn_stock(), 'OF040001') ;
ReturnFundNAWLInfo2 (inttodate(20121019), 2);
return FundNAWLInfo2 (inttodate(20121019), 2);
```
## `fundNAwlInfoFromBegT(beg_t, end_t, type)`
@@ -331,11 +327,8 @@ ReturnFundNAWLInfo2 (inttodate(20121019), 2);
```tsl
// 取华安创新2012年10月10日到2012年10月19日之间的累计净值
Setsysparam(pn_stock(), 'OF040001') ;
Return
FundNAWLInfoFromBegT(inttodate(20121010), inttodate(20121019), 1);
```
@@ -355,7 +348,7 @@ FundNAWLInfoFromBegT(inttodate(20121010), inttodate(20121019), 1);
```tsl
Setsysparam(pn_stock(), 'OF040001') ;
ReturnFundNAWLJ();
return FundNAWLJ();
```
## `fundNAwlNetAsset(end_t)`
@@ -428,7 +421,7 @@ return fundNawmwfjjdwsy(20180822T);
```tsl
// 取华安创新2012年10月10日到2012年10月19日之间的区间净值增长率(%)
setSysParam(pn_stock(), 'OF040001') ;
ReturnFundNAWZf(intToDate(20121010), intToDate(20121019));
return FundNAWZf(intToDate(20121010), intToDate(20121019));
// 输出:0.17
```
@@ -447,8 +440,8 @@ ReturnFundNAWZf(intToDate(20121010), intToDate(20121019));
范例01:调用函数
```tsl
{取华安创新2012年10月19日的最新日收益率(%)
注意,函数必须先设置当前时间,再设置当前股票。原因是设置当前的时间跟时间序列数据有关,如果先设置股票为'OF040001',而开放式基金是没有二级市场交易数据的,之后再设置时间为指定日,会导致当前的时间为0。从而取不出数据。}
// 取华安创新2012年10月19日的最新日收益率(%)
// 注意,函数必须先设置当前时间,再设置当前股票。原因是设置当前的时间跟时间序列数据有关,如果先设置股票为'OF040001',而开放式基金是没有二级市场交易数据的,之后再设置时间为指定日,会导致当前的时间为0。从而取不出数据。
Setsysparam(pn_date(), inttodate(20121019));
Setsysparam(pn_stock(), 'OF040001') ;
Return FundNAWZf3();
@@ -475,7 +468,7 @@ Return FundNAWZf3();
```tsl
// 取华安创新2012年10月19日的日收益率(%)
setSysParam(pn_stock(), 'OF040001') ;
ReturnFundNAWZf4(intToDate(20121019));
return FundNAWZf4(intToDate(20121019));
// 输出:-0.17
```
@@ -500,10 +493,8 @@ ReturnFundNAWZf4(intToDate(20121019));
```tsl
// 取华安创新2012年10月10日到2012年10月19日之间的区间复合收益率(%)
Setsysparam(pn_stock(), 'OF040001') ;
ReturnFundNAWZf_fh(inttodate(20121010), inttodate(20121019));
return FundNAWZf_fh(inttodate(20121010), inttodate(20121019));
// 输出:0.17
```