1. 单位装饰器支持INT转换

2. 升级配置项
This commit is contained in:
csh
2024-08-14 13:45:00 +08:00
parent fedb1cd28a
commit 7936d19b98
13 changed files with 264 additions and 32 deletions
@@ -0,0 +1,36 @@
type StyleAdapter = class
public
function Create(_obj: Style);
function Init();
function GetTblStylePrByType(_key: string);
function SetTblStylePrByType(_key: string; _value: tslobj);
private
object_: Style;
tblstylepr_hash_: tableArray;
end;
function StyleAdapter.Create(_obj: Style);
begin
object_ := _obj;
tblstylepr_hash_ := array();
{self.}Init();
end;
function StyleAdapter.Init();
begin
elements := object_.TblStylePrs();
for k,v in elements do
tblstylepr_hash_[v.Type] := v;
end;
function StyleAdapter.GetTblStylePrByType(_key: string);
begin
return tblstylepr_hash_[_key];
end;
function StyleAdapter.SetTblStylePrByType(_key: string; _value: tslobj);
begin
tblstylepr_hash_[_key] := _value;
end;