osis-python 0.3.6__tar.gz → 0.3.8__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {osis_python-0.3.6/src/osis_python.egg-info → osis_python-0.3.8}/PKG-INFO +1 -1
- {osis_python-0.3.6 → osis_python-0.3.8/src/osis_python.egg-info}/PKG-INFO +1 -1
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/__init__.py +1 -1
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/boundary/manager.py +7 -4
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/core/engine.py +2 -2
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/dynamic/manager.py +18 -15
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/element/manager.py +15 -17
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/geometry/interface.py +1 -1
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/geometry/manager.py +5 -4
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/live/manager.py +21 -12
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/load/manager.py +27 -18
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/material/manager.py +8 -7
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/property/manager.py +5 -5
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/section/manager.py +127 -86
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/settlement/manager.py +13 -8
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/stability/manager.py +6 -5
- {osis_python-0.3.6 → osis_python-0.3.8}/LICENSE +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/README.md +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/pyproject.toml +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/setup.cfg +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/osis_python.egg-info/SOURCES.txt +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/osis_python.egg-info/dependency_links.txt +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/osis_python.egg-info/requires.txt +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/osis_python.egg-info/top_level.txt +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/boundary/__init__.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/boundary/interface.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/control/__init__.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/control/control.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/control/io.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/control/manager.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/control/nonlinear.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/core/__init__.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/core/all_func.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/core/client.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/core/command.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/dynamic/__init__.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/dynamic/load_to_mass.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/dynamic/modal.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/dynamic/seismic.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/element/__init__.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/element/interface.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/general/__init__.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/general/interface.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/geometry/__init__.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/live/__init__.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/live/analysis.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/live/grade.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/live/lane.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/load/__init__.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/load/loadcase.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/load/static.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/load/tendon.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/material/__init__.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/material/interface.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/node/__init__.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/node/interface.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/node/manager.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/post/__init__.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/post/combine.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/post/design_check.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/post/display.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/post/manager.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/project/__init__.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/project/interface.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/project/manager.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/property/__init__.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/property/component_thickness.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/property/coordinate.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/property/creep_shrink.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/property/damping.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/property/pu_curve.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/quick_building/__init__.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/quick_building/interface.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/result/__init__.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/result/check.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/result/env.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/result/loadcase.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/result/manager.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/result/result.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/section/__init__.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/section/common.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/section/numeric.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/section/param.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/section/rebar.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/section/rib.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/section/steel.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/settlement/__init__.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/settlement/interface.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/stability/__init__.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/stability/buckling.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/stage/__init__.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/stage/define.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/stage/manager.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/stage/overall.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/thickness/__init__.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/thickness/interface.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/thickness/manager.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/transfer/__init__.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/transfer/command_map.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/transfer/generator.py +0 -0
- {osis_python-0.3.6 → osis_python-0.3.8}/src/pyosis/transfer/parser.py +0 -0
|
@@ -7,7 +7,7 @@ A library for extending OSIS functionality.
|
|
|
7
7
|
A library that allows users to use CAE with great flexibility.
|
|
8
8
|
"""
|
|
9
9
|
|
|
10
|
-
__version__ = "0.3.
|
|
10
|
+
__version__ = "0.3.8"
|
|
11
11
|
__author__ = "CCCC Highway Consultant Co. Ltd." # 中交公路规划设计院 - 工程技术研究中心 - lzh - wjh - myf
|
|
12
12
|
|
|
13
13
|
from .core.engine import OSISEngine
|
|
@@ -549,12 +549,15 @@ class BoundaryGroupManager:
|
|
|
549
549
|
单个 BoundaryGroup 对象;如果传入列表则返回对象列表;
|
|
550
550
|
不存在返回 None
|
|
551
551
|
"""
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
552
|
+
|
|
553
|
+
if isinstance(name, list):
|
|
554
|
+
names = [str(x) for x in name]
|
|
555
|
+
else:
|
|
556
|
+
names = [str(name)]
|
|
557
|
+
if not isinstance(names, list):
|
|
555
558
|
raise TypeError(f"不支持的名称类型: {type(name)}")
|
|
556
559
|
|
|
557
|
-
resp = osis_client("GetBoundaryGroupInfoByNames", {"name":
|
|
560
|
+
resp = osis_client("GetBoundaryGroupInfoByNames", {"name": names})
|
|
558
561
|
if not resp['success']:
|
|
559
562
|
raise RuntimeError(f"{resp['error']}")
|
|
560
563
|
|
|
@@ -291,7 +291,7 @@ class OSISEngine:
|
|
|
291
291
|
# ──────────────────────────────────────────
|
|
292
292
|
# 便捷方法(委托给 control manager)
|
|
293
293
|
# ──────────────────────────────────────────
|
|
294
|
-
def export_apdl(self, path) -> None:
|
|
294
|
+
def export_apdl(self, path: str | None = None) -> None:
|
|
295
295
|
"""导出前处理状态为 .out 文件
|
|
296
296
|
|
|
297
297
|
Args:
|
|
@@ -299,7 +299,7 @@ class OSISEngine:
|
|
|
299
299
|
"""
|
|
300
300
|
self.control.export_apdl(path)
|
|
301
301
|
|
|
302
|
-
def import_apdl(self, path: str
|
|
302
|
+
def import_apdl(self, path: str) -> None:
|
|
303
303
|
"""读取 .out / .sml 文件
|
|
304
304
|
|
|
305
305
|
Args:
|
|
@@ -59,13 +59,14 @@ class LoadToMassManager:
|
|
|
59
59
|
|
|
60
60
|
def get(self, name: str | list[str]) -> LoadToMass | list[LoadToMass | None] | None:
|
|
61
61
|
"""根据名称获取荷载转换质量"""
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
...
|
|
62
|
+
|
|
63
|
+
if isinstance(name, list):
|
|
64
|
+
names = [str(x) for x in name]
|
|
66
65
|
else:
|
|
66
|
+
names = [str(name)]
|
|
67
|
+
if not isinstance(names, list):
|
|
67
68
|
raise TypeError(f"不支持的名称类型: {type(name)}")
|
|
68
|
-
resp = osis_client("GetLoadToMassInfoByNames", {"name":
|
|
69
|
+
resp = osis_client("GetLoadToMassInfoByNames", {"name": names})
|
|
69
70
|
if not resp['success']:
|
|
70
71
|
raise RuntimeError(f"{resp['error']}")
|
|
71
72
|
ltm = [LoadToMass._from_dict(d) if d else None for d in resp.get("data", [])]
|
|
@@ -254,13 +255,14 @@ class SeisRspSpecManager:
|
|
|
254
255
|
|
|
255
256
|
def get(self, name: str | list[str]) -> SeisRspSpec | list[SeisRspSpec | None] | None:
|
|
256
257
|
"""根据名称获取地震反应谱"""
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
...
|
|
258
|
+
|
|
259
|
+
if isinstance(name, list):
|
|
260
|
+
names = [str(x) for x in name]
|
|
261
261
|
else:
|
|
262
|
+
names = [str(name)]
|
|
263
|
+
if not isinstance(names, list):
|
|
262
264
|
raise TypeError(f"不支持的名称类型: {type(name)}")
|
|
263
|
-
resp = osis_client("GetSeisRspSpecInfoByNames", {"name":
|
|
265
|
+
resp = osis_client("GetSeisRspSpecInfoByNames", {"name": names})
|
|
264
266
|
if not resp['success']:
|
|
265
267
|
raise RuntimeError(f"{resp['error']}")
|
|
266
268
|
rsp = [SeisRspSpec._from_dict(d) if d else None for d in resp.get("data", [])]
|
|
@@ -409,13 +411,14 @@ class RspecAnalManager:
|
|
|
409
411
|
|
|
410
412
|
def get(self, name: str | list[str]) -> RspecAnal | list[RspecAnal | None] | None:
|
|
411
413
|
"""根据名称获取反应谱工况"""
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
...
|
|
414
|
+
|
|
415
|
+
if isinstance(name, list):
|
|
416
|
+
names = [str(x) for x in name]
|
|
416
417
|
else:
|
|
418
|
+
names = [str(name)]
|
|
419
|
+
if not isinstance(names, list):
|
|
417
420
|
raise TypeError(f"不支持的名称类型: {type(name)}")
|
|
418
|
-
resp = osis_client("GetSeisRespSpecByNames", {"name":
|
|
421
|
+
resp = osis_client("GetSeisRespSpecByNames", {"name": names})
|
|
419
422
|
if not resp['success']:
|
|
420
423
|
raise RuntimeError(f"{resp['error']}")
|
|
421
424
|
rsp = [RspecAnal._from_dict(d) if d else None for d in resp.get("data", [])]
|
|
@@ -35,13 +35,6 @@ class ElementType(Enum):
|
|
|
35
35
|
CABLE = 4
|
|
36
36
|
SHELL = 5
|
|
37
37
|
|
|
38
|
-
ELEMENT_TYPE_NAMES: dict[int, str] = {
|
|
39
|
-
1: "BEAM3D",
|
|
40
|
-
2: "TRUSS",
|
|
41
|
-
3: "SPRING",
|
|
42
|
-
4: "CABLE",
|
|
43
|
-
5: "SHELL",
|
|
44
|
-
}
|
|
45
38
|
|
|
46
39
|
|
|
47
40
|
# ──────────────────────────────────────────────
|
|
@@ -77,9 +70,10 @@ class Element:
|
|
|
77
70
|
@classmethod
|
|
78
71
|
def _from_dict(cls, d: dict) -> Element:
|
|
79
72
|
"""从接口 dict 构造 Material 对象(内部使用)"""
|
|
73
|
+
raw_type = int(d.get("type"))
|
|
80
74
|
return cls(
|
|
81
75
|
no=d.get("no"),
|
|
82
|
-
element_type=
|
|
76
|
+
element_type=ElementType(raw_type) if raw_type in [t.value for t in ElementType] else ElementType.UNASSIGNED,
|
|
83
77
|
mat=d.get("mat"),
|
|
84
78
|
node_vec=d.get("nodeVec"),
|
|
85
79
|
node_i=d.get("nodeI"),
|
|
@@ -329,12 +323,15 @@ class ElementGroupManager:
|
|
|
329
323
|
单个 ElementGroup 对象;如果传入列表则返回对象列表;
|
|
330
324
|
不存在返回 None
|
|
331
325
|
"""
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
326
|
+
|
|
327
|
+
if isinstance(name, list):
|
|
328
|
+
names = [str(x) for x in name]
|
|
329
|
+
else:
|
|
330
|
+
names = [str(name)]
|
|
331
|
+
if not isinstance(names, list):
|
|
335
332
|
raise TypeError(f"不支持的名称类型: {type(name)}")
|
|
336
333
|
|
|
337
|
-
resp = osis_client("GetElementGroupInfoByNames", {"name":
|
|
334
|
+
resp = osis_client("GetElementGroupInfoByNames", {"name": names})
|
|
338
335
|
if not resp['success']:
|
|
339
336
|
raise RuntimeError(f"{resp['error']}")
|
|
340
337
|
|
|
@@ -391,13 +388,14 @@ class TaperEleGroupManager:
|
|
|
391
388
|
Returns:
|
|
392
389
|
TaperEleGroup | list[TaperEleGroup | None]: 变截面单元组对象
|
|
393
390
|
"""
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
...
|
|
391
|
+
|
|
392
|
+
if isinstance(name, list):
|
|
393
|
+
names = [str(x) for x in name]
|
|
398
394
|
else:
|
|
395
|
+
names = [str(name)]
|
|
396
|
+
if not isinstance(names, list):
|
|
399
397
|
raise TypeError(f"不支持的名称类型: {type(name)}")
|
|
400
|
-
resp = osis_client("GetTaperEleGroupInfoByNames", {"name":
|
|
398
|
+
resp = osis_client("GetTaperEleGroupInfoByNames", {"name": names})
|
|
401
399
|
if not resp['success']:
|
|
402
400
|
raise RuntimeError(f"{resp['error']}")
|
|
403
401
|
taper_ele_groups = [
|
|
@@ -280,11 +280,12 @@ class GeometryManager:
|
|
|
280
280
|
Returns:
|
|
281
281
|
单个 Spline 对象,或 Spline 对象列表
|
|
282
282
|
"""
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
names = name
|
|
283
|
+
|
|
284
|
+
if isinstance(name, list):
|
|
285
|
+
names = [str(x) for x in name]
|
|
287
286
|
else:
|
|
287
|
+
names = [str(name)]
|
|
288
|
+
if not isinstance(names, list):
|
|
288
289
|
raise TypeError(f"不支持的名称类型: {type(name)}")
|
|
289
290
|
|
|
290
291
|
resp = osis_client("GetSplineInfoByNames", {"name": names})
|
|
@@ -574,12 +574,15 @@ class LiveGradeManager:
|
|
|
574
574
|
TypeError: 名称类型不支持时抛出
|
|
575
575
|
RuntimeError: 接口调用失败时抛出
|
|
576
576
|
"""
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
577
|
+
|
|
578
|
+
if isinstance(name, list):
|
|
579
|
+
names = [str(x) for x in name]
|
|
580
|
+
else:
|
|
581
|
+
names = [str(name)]
|
|
582
|
+
if not isinstance(names, list):
|
|
580
583
|
raise TypeError(f"不支持的名称类型: {type(name)}")
|
|
581
584
|
|
|
582
|
-
resp = osis_client("GetGradeInfoByNames", {"name":
|
|
585
|
+
resp = osis_client("GetGradeInfoByNames", {"name": names})
|
|
583
586
|
if not resp['success']:
|
|
584
587
|
raise RuntimeError(f"{resp['error']}")
|
|
585
588
|
|
|
@@ -779,12 +782,15 @@ class LaneManager:
|
|
|
779
782
|
TypeError: 名称类型不支持时抛出
|
|
780
783
|
RuntimeError: 接口调用失败时抛出
|
|
781
784
|
"""
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
+
|
|
786
|
+
if isinstance(name, list):
|
|
787
|
+
names = [str(x) for x in name]
|
|
788
|
+
else:
|
|
789
|
+
names = [str(name)]
|
|
790
|
+
if not isinstance(names, list):
|
|
785
791
|
raise TypeError(f"不支持的名称类型: {type(name)}")
|
|
786
792
|
|
|
787
|
-
resp = osis_client("GetLaneInfoByNames", {"name":
|
|
793
|
+
resp = osis_client("GetLaneInfoByNames", {"name": names})
|
|
788
794
|
if not resp['success']:
|
|
789
795
|
raise RuntimeError(f"{resp['error']}")
|
|
790
796
|
|
|
@@ -904,12 +910,15 @@ class LiveCaseManager:
|
|
|
904
910
|
TypeError: 名称类型不支持时抛出
|
|
905
911
|
RuntimeError: 接口调用失败时抛出
|
|
906
912
|
"""
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
913
|
+
|
|
914
|
+
if isinstance(name, list):
|
|
915
|
+
names = [str(x) for x in name]
|
|
916
|
+
else:
|
|
917
|
+
names = [str(name)]
|
|
918
|
+
if not isinstance(names, list):
|
|
910
919
|
raise TypeError(f"不支持的名称类型: {type(name)}")
|
|
911
920
|
|
|
912
|
-
resp = osis_client("GetLiveInfoByNames", {"name":
|
|
921
|
+
resp = osis_client("GetLiveInfoByNames", {"name": names})
|
|
913
922
|
if not resp['success']:
|
|
914
923
|
raise RuntimeError(f"{resp['error']}")
|
|
915
924
|
|
|
@@ -792,12 +792,12 @@ class TendonShape:
|
|
|
792
792
|
def layout(
|
|
793
793
|
self,
|
|
794
794
|
layout_type: Literal['GLOBAL', "ELEMENT"],
|
|
795
|
-
n_ele: int,
|
|
796
|
-
n_beg: int,
|
|
797
|
-
n_dir: int,
|
|
798
|
-
d_offset_x: float =
|
|
799
|
-
d_offset_y: float =
|
|
800
|
-
d_offset_z: float =
|
|
795
|
+
n_ele: int = None,
|
|
796
|
+
n_beg: int = None,
|
|
797
|
+
n_dir: int = None,
|
|
798
|
+
d_offset_x: float = None,
|
|
799
|
+
d_offset_y: float = None,
|
|
800
|
+
d_offset_z: float = None,
|
|
801
801
|
) -> None:
|
|
802
802
|
"""布置钢束形状"""
|
|
803
803
|
ok, err = osis_layout_tendons(self.name, layout_type, n_ele, n_beg, n_dir, d_offset_x, d_offset_y, d_offset_z)
|
|
@@ -1118,12 +1118,15 @@ class TendonPropManager:
|
|
|
1118
1118
|
TypeError: 名称类型不支持时抛出
|
|
1119
1119
|
RuntimeError: 接口调用失败时抛出
|
|
1120
1120
|
"""
|
|
1121
|
-
|
|
1122
|
-
|
|
1123
|
-
|
|
1121
|
+
|
|
1122
|
+
if isinstance(name, list):
|
|
1123
|
+
names = [str(x) for x in name]
|
|
1124
|
+
else:
|
|
1125
|
+
names = [str(name)]
|
|
1126
|
+
if not isinstance(names, list):
|
|
1124
1127
|
raise TypeError(f"不支持的名称类型: {type(name)}")
|
|
1125
1128
|
|
|
1126
|
-
resp = osis_client("GetTendonPropInfoByNames", {"name":
|
|
1129
|
+
resp = osis_client("GetTendonPropInfoByNames", {"name": names})
|
|
1127
1130
|
if not resp['success']:
|
|
1128
1131
|
raise RuntimeError(f"{resp['error']}")
|
|
1129
1132
|
|
|
@@ -1303,12 +1306,15 @@ class TendonShapeManager:
|
|
|
1303
1306
|
TypeError: 名称类型不支持时抛出
|
|
1304
1307
|
RuntimeError: 接口调用失败时抛出
|
|
1305
1308
|
"""
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
+
|
|
1310
|
+
if isinstance(name, list):
|
|
1311
|
+
names = [str(x) for x in name]
|
|
1312
|
+
else:
|
|
1313
|
+
names = [str(name)]
|
|
1314
|
+
if not isinstance(names, list):
|
|
1309
1315
|
raise TypeError(f"不支持的名称类型: {type(name)}")
|
|
1310
1316
|
|
|
1311
|
-
resp = osis_client("GetTendonShapeInfoByNames", {"name":
|
|
1317
|
+
resp = osis_client("GetTendonShapeInfoByNames", {"name": names})
|
|
1312
1318
|
if not resp['success']:
|
|
1313
1319
|
raise RuntimeError(f"{resp['error']}")
|
|
1314
1320
|
|
|
@@ -1490,12 +1496,15 @@ class LoadCaseManager:
|
|
|
1490
1496
|
Returns:
|
|
1491
1497
|
LoadCase 对象或数组;工况不存在返回 None
|
|
1492
1498
|
"""
|
|
1493
|
-
|
|
1494
|
-
|
|
1495
|
-
|
|
1499
|
+
|
|
1500
|
+
if isinstance(name, list):
|
|
1501
|
+
names = [str(x) for x in name]
|
|
1502
|
+
else:
|
|
1503
|
+
names = [str(name)]
|
|
1504
|
+
if not isinstance(names, list):
|
|
1496
1505
|
raise TypeError(f"不支持的名称类型: {type(name)}")
|
|
1497
1506
|
|
|
1498
|
-
resp = osis_client("GetLoadCaseInfoByNames", {"name":
|
|
1507
|
+
resp = osis_client("GetLoadCaseInfoByNames", {"name": names})
|
|
1499
1508
|
if not resp['success']:
|
|
1500
1509
|
raise RuntimeError(f"{resp['error']}")
|
|
1501
1510
|
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
from __future__ import annotations
|
|
12
12
|
|
|
13
13
|
from dataclasses import dataclass
|
|
14
|
-
from typing import Literal
|
|
14
|
+
from typing import Literal, Union
|
|
15
15
|
from enum import Enum
|
|
16
16
|
from ..core.client import osis_client
|
|
17
17
|
from .interface import (
|
|
@@ -61,10 +61,11 @@ class Material:
|
|
|
61
61
|
@classmethod
|
|
62
62
|
def _from_dict(cls, d: dict) -> Material:
|
|
63
63
|
"""从接口 dict 构造 Material 对象(内部使用)"""
|
|
64
|
+
raw_type = int(d.get("materialType"))
|
|
64
65
|
return cls(
|
|
65
66
|
no=d.get("no"),
|
|
66
67
|
name=d.get("name"),
|
|
67
|
-
material_type=
|
|
68
|
+
material_type=MaterialType(raw_type) if raw_type in [t.value for t in MaterialType] else MaterialType.UNASSIGNED ,
|
|
68
69
|
code=d.get("code"),
|
|
69
70
|
grade=d.get("grade"),
|
|
70
71
|
e=d.get("e"),
|
|
@@ -135,8 +136,8 @@ class MaterialManager:
|
|
|
135
136
|
name: str,
|
|
136
137
|
eCode: Literal["JTG3362_2018", "JTGD62_2004"],
|
|
137
138
|
eGrade: Literal["C15", "C20", "C25", "C30", "C35", "C40", "C45", "C50", "C55", "C60", "C65", "C70", "C75", "C80"],
|
|
138
|
-
nCrepShrk: int |
|
|
139
|
-
dDmp: float = 0.
|
|
139
|
+
nCrepShrk: int | str = "",
|
|
140
|
+
dDmp: float = 0.05,
|
|
140
141
|
no: int | None = None,
|
|
141
142
|
) -> Material:
|
|
142
143
|
"""创建混凝土材料
|
|
@@ -269,14 +270,14 @@ class MaterialManager:
|
|
|
269
270
|
def create_custom(
|
|
270
271
|
self,
|
|
271
272
|
name: str,
|
|
272
|
-
|
|
273
|
-
dE: float = 0,
|
|
273
|
+
dE: float = 1,
|
|
274
274
|
dG: float = 0,
|
|
275
275
|
dMu: float = 0,
|
|
276
276
|
dExpCoeff: float = 0,
|
|
277
277
|
dUnitWeight: float = 0,
|
|
278
278
|
dDensity: float = 0,
|
|
279
279
|
dDmp: float = 0,
|
|
280
|
+
no: int | None = None,
|
|
280
281
|
) -> Material:
|
|
281
282
|
"""创建自定义材料
|
|
282
283
|
|
|
@@ -319,7 +320,7 @@ class MaterialManager:
|
|
|
319
320
|
if not ok:
|
|
320
321
|
raise RuntimeError(f"删除材料 {no} 失败: {err}")
|
|
321
322
|
|
|
322
|
-
def renumber(self, old_no: int, new_no: int) -> None:
|
|
323
|
+
def renumber(self, old_no: int, new_no: int) -> Material | list[Material | None]:
|
|
323
324
|
"""修改材料编号
|
|
324
325
|
|
|
325
326
|
Args:
|
|
@@ -253,13 +253,13 @@ class DampingManager:
|
|
|
253
253
|
|
|
254
254
|
def get(self, name: str | list[str]) -> Damping | list[Damping | None] | None:
|
|
255
255
|
"""根据名称获取阻尼模型"""
|
|
256
|
-
if isinstance(name,
|
|
257
|
-
|
|
258
|
-
elif isinstance(name, list):
|
|
259
|
-
...
|
|
256
|
+
if isinstance(name, list):
|
|
257
|
+
names = [str(x) for x in name]
|
|
260
258
|
else:
|
|
259
|
+
names = [str(name)]
|
|
260
|
+
if not isinstance(names, list):
|
|
261
261
|
raise TypeError(f"不支持的名称类型: {type(name)}")
|
|
262
|
-
resp = osis_client("GetDampingInfoByNames", {"name":
|
|
262
|
+
resp = osis_client("GetDampingInfoByNames", {"name": names})
|
|
263
263
|
if not resp['success']:
|
|
264
264
|
raise RuntimeError(f"{resp['error']}")
|
|
265
265
|
dampings = [Damping._from_dict(d) if d else None for d in resp.get("data", [])]
|
|
@@ -10,6 +10,7 @@ from __future__ import annotations
|
|
|
10
10
|
|
|
11
11
|
from dataclasses import dataclass, field
|
|
12
12
|
from typing import Literal
|
|
13
|
+
from enum import Enum
|
|
13
14
|
|
|
14
15
|
from ..core.client import osis_client
|
|
15
16
|
|
|
@@ -72,6 +73,40 @@ from .rib import (
|
|
|
72
73
|
)
|
|
73
74
|
|
|
74
75
|
|
|
76
|
+
class SectionType(Enum):
|
|
77
|
+
UNASSIGNED = 0 # 未分配
|
|
78
|
+
LSHAPE = 1 # L形与倒L形
|
|
79
|
+
TSHAPE = 2 # T形与倒T形
|
|
80
|
+
ISHAPE = 3 # 工字形
|
|
81
|
+
CIRCLE = 4 # 圆形与圆管形
|
|
82
|
+
RECTANGLE = 5 # 实腹与空腹矩形(可倒圆/斜角)
|
|
83
|
+
ROUNDEDEND = 6 # 实腹与空腹圆端形
|
|
84
|
+
HOLLOWSLAB = 7 # 空心板梁
|
|
85
|
+
SMALLBOX = 8 # 小箱梁
|
|
86
|
+
TGIRDER = 9 # T梁
|
|
87
|
+
CONVENTIONALBOX = 10 # 常规箱梁
|
|
88
|
+
FLATBOX = 11 # 扁平箱梁
|
|
89
|
+
DOUBLESIDEBOX = 12 # 双边箱梁
|
|
90
|
+
RIBBEDSLAB = 13 # 肋板式
|
|
91
|
+
CUSTOM = 14 # 常规自定义截面
|
|
92
|
+
|
|
93
|
+
STEELI = 21 # 工字钢梁截面
|
|
94
|
+
STEELBOX = 22 # 箱型钢梁截面
|
|
95
|
+
STEELBOXTHREECELL = 23 # 单箱单/三室钢梁截面
|
|
96
|
+
STEELBOXITF = 24 # 单箱单室斜顶板钢梁界面
|
|
97
|
+
STEELCANTIBOX = 25 # 悬臂单箱单/双室钢梁界面
|
|
98
|
+
STEELCANTIBOXIBF = 26 # 悬臂单箱单/双室斜底板钢梁截面
|
|
99
|
+
STEELCUSTOM = 27 # 钢梁自定义截面,采用几何点线形式输入
|
|
100
|
+
STEELCUSTOMPLATE = 28 # 钢梁自定义截面,采用参数板形式输入
|
|
101
|
+
|
|
102
|
+
COMPOSITESTEELI = 41 # 钢-工字型组合截面
|
|
103
|
+
COMPOSITESTEELTROUGH = 42 # 钢-槽型组合截面
|
|
104
|
+
COMPOSITESTEELBOX = 43 # 钢-箱型组合截面
|
|
105
|
+
COMPOSITECUSTOM = 44 # 自定义组合截面
|
|
106
|
+
|
|
107
|
+
NUMERICAL = 51 # 数值截面
|
|
108
|
+
|
|
109
|
+
|
|
75
110
|
# ──────────────────────────────────────────────
|
|
76
111
|
# Section 基类
|
|
77
112
|
# ──────────────────────────────────────────────
|
|
@@ -86,31 +121,32 @@ class Section:
|
|
|
86
121
|
"""
|
|
87
122
|
|
|
88
123
|
no: int # 截面编号
|
|
89
|
-
name: str
|
|
90
|
-
|
|
91
|
-
prop: dict
|
|
92
|
-
prop_factor: dict
|
|
93
|
-
offset_type_y: int
|
|
94
|
-
offset_value_y: float
|
|
95
|
-
offset_type_z: int
|
|
96
|
-
offset_value_z: float
|
|
97
|
-
stress_points: list[dict]
|
|
98
|
-
boundary: dict
|
|
99
|
-
height: float
|
|
100
|
-
modeling_point_x: float
|
|
101
|
-
modeling_point_y: float
|
|
102
|
-
contour: list[dict]
|
|
103
|
-
has_concrete_section: bool
|
|
104
|
-
has_steel_section: bool
|
|
105
|
-
related_elements: list[int]
|
|
124
|
+
name: str # 截面名称
|
|
125
|
+
section_type: SectionType # 截面类型
|
|
126
|
+
prop: dict # 截面属性
|
|
127
|
+
prop_factor: dict # 截面因子
|
|
128
|
+
offset_type_y: int # 偏移类型 Y
|
|
129
|
+
offset_value_y: float # 偏移值 Y
|
|
130
|
+
offset_type_z: int # 偏移类型 Z
|
|
131
|
+
offset_value_z: float # 偏移值 Z
|
|
132
|
+
stress_points: list[dict] # 应力点
|
|
133
|
+
boundary: dict # 边界
|
|
134
|
+
height: float # 高度
|
|
135
|
+
modeling_point_x: float # 模型点 X
|
|
136
|
+
modeling_point_y: float # 模型点 Y
|
|
137
|
+
contour: list[dict] # 轮廓
|
|
138
|
+
has_concrete_section: bool # 是否有混凝土截面
|
|
139
|
+
has_steel_section: bool # 是否有钢截面
|
|
140
|
+
related_elements: list[int] # 相关单元
|
|
106
141
|
|
|
107
142
|
@classmethod
|
|
108
143
|
def _from_dict(cls, d: dict) -> Section:
|
|
109
144
|
"""从接口 dict 构造 Section 对象(内部使用)"""
|
|
145
|
+
raw_type = int(d.get("type", 0))
|
|
110
146
|
return cls(
|
|
111
147
|
no=d.get("no"),
|
|
112
148
|
name=d.get("name"),
|
|
113
|
-
|
|
149
|
+
section_type=SectionType(raw_type) if raw_type in [t.value for t in SectionType] else SectionType.UNASSIGNED,
|
|
114
150
|
prop=d.get("prop"),
|
|
115
151
|
prop_factor=d.get("propFactor"),
|
|
116
152
|
offset_type_y=d.get("offsetTypeY"),
|
|
@@ -129,7 +165,7 @@ class Section:
|
|
|
129
165
|
)
|
|
130
166
|
|
|
131
167
|
def __repr__(self) -> str:
|
|
132
|
-
return f"Section(no={self.no}, name={self.name!r}, type={self.
|
|
168
|
+
return f"Section(no={self.no}, name={self.name!r}, type={self.section_type.name})"
|
|
133
169
|
|
|
134
170
|
# ── 实例方法 ──────────────────────────────
|
|
135
171
|
|
|
@@ -812,12 +848,13 @@ class SectionManager:
|
|
|
812
848
|
def create_steel_i(
|
|
813
849
|
self,
|
|
814
850
|
name: str,
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
851
|
+
# 暂时去掉默认值
|
|
852
|
+
h: float,
|
|
853
|
+
bt: float,
|
|
854
|
+
bb: float,
|
|
855
|
+
tt: float,
|
|
856
|
+
tb: float,
|
|
857
|
+
tw: float,
|
|
821
858
|
web_rib_pos: Literal["Left", "Right", "Both"] = "Both",
|
|
822
859
|
no: int | None = None,
|
|
823
860
|
) -> Section:
|
|
@@ -844,14 +881,14 @@ class SectionManager:
|
|
|
844
881
|
def create_steel_box(
|
|
845
882
|
self,
|
|
846
883
|
name: str,
|
|
847
|
-
h: float
|
|
848
|
-
bt: float
|
|
849
|
-
bct: float
|
|
850
|
-
bb: float
|
|
851
|
-
bcb: float
|
|
852
|
-
tt: float
|
|
853
|
-
tb: float
|
|
854
|
-
tw: float
|
|
884
|
+
h: float,
|
|
885
|
+
bt: float,
|
|
886
|
+
bct: float,
|
|
887
|
+
bb: float,
|
|
888
|
+
bcb: float,
|
|
889
|
+
tt: float,
|
|
890
|
+
tb: float,
|
|
891
|
+
tw: float,
|
|
855
892
|
same_layout: Literal[0, 1] = 1,
|
|
856
893
|
no: int | None = None,
|
|
857
894
|
) -> Section:
|
|
@@ -880,21 +917,22 @@ class SectionManager:
|
|
|
880
917
|
def create_steel_box_three_cell(
|
|
881
918
|
self,
|
|
882
919
|
name: str,
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
920
|
+
# 暂时去掉默认值
|
|
921
|
+
h: float,
|
|
922
|
+
bt: float,
|
|
923
|
+
bb: float,
|
|
924
|
+
i: float,
|
|
925
|
+
a1: float,
|
|
926
|
+
a2: float,
|
|
927
|
+
dt: float,
|
|
928
|
+
tt1: float,
|
|
929
|
+
tt2: float,
|
|
930
|
+
tb1: float,
|
|
931
|
+
db: float,
|
|
932
|
+
tb2: float,
|
|
933
|
+
tb3: float,
|
|
934
|
+
tw1: float,
|
|
935
|
+
dw: float,
|
|
898
936
|
has_web: Literal[0, 1] = 1,
|
|
899
937
|
tw2: float = 0.0,
|
|
900
938
|
web_rib_pos: Literal["Left", "Right", "Both"] = "Both",
|
|
@@ -937,22 +975,23 @@ class SectionManager:
|
|
|
937
975
|
def create_steel_box_itf(
|
|
938
976
|
self,
|
|
939
977
|
name: str,
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
|
|
946
|
-
|
|
947
|
-
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
|
|
978
|
+
# 暂时去掉默认值
|
|
979
|
+
h: float,
|
|
980
|
+
b: float,
|
|
981
|
+
bt: float,
|
|
982
|
+
bb: float,
|
|
983
|
+
i: float,
|
|
984
|
+
a1: float,
|
|
985
|
+
a2: float,
|
|
986
|
+
dt: float,
|
|
987
|
+
tt1: float,
|
|
988
|
+
tt2: float,
|
|
989
|
+
tt3: float,
|
|
990
|
+
tb1: float,
|
|
991
|
+
db: float,
|
|
992
|
+
tb2: float,
|
|
993
|
+
tb3: float,
|
|
994
|
+
tw1: float,
|
|
956
995
|
no: int | None = None,
|
|
957
996
|
) -> Section:
|
|
958
997
|
"""创建单箱单室斜顶板钢截面(STEELBOXITF)。
|
|
@@ -990,16 +1029,17 @@ class SectionManager:
|
|
|
990
1029
|
def create_steel_canti_box(
|
|
991
1030
|
self,
|
|
992
1031
|
name: str,
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
|
|
1002
|
-
|
|
1032
|
+
# 暂时去掉默认值
|
|
1033
|
+
h: float,
|
|
1034
|
+
bt: float,
|
|
1035
|
+
bb: float,
|
|
1036
|
+
i: float,
|
|
1037
|
+
a: float,
|
|
1038
|
+
dt: float,
|
|
1039
|
+
tt1: float,
|
|
1040
|
+
tt2: float,
|
|
1041
|
+
tb1: float,
|
|
1042
|
+
tw1: float,
|
|
1003
1043
|
has_web: Literal[0, 1] = 1,
|
|
1004
1044
|
tw2: float = 0.0,
|
|
1005
1045
|
web_rib_pos: Literal["Left", "Right", "Both"] = "Both",
|
|
@@ -1041,18 +1081,19 @@ class SectionManager:
|
|
|
1041
1081
|
def create_steel_canti_box_ibf(
|
|
1042
1082
|
self,
|
|
1043
1083
|
name: str,
|
|
1044
|
-
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
|
|
1053
|
-
|
|
1054
|
-
|
|
1055
|
-
|
|
1084
|
+
# 暂时去掉默认值
|
|
1085
|
+
h: float,
|
|
1086
|
+
bt: float,
|
|
1087
|
+
bb: float,
|
|
1088
|
+
bc: float,
|
|
1089
|
+
i: float,
|
|
1090
|
+
a: float,
|
|
1091
|
+
dt: float,
|
|
1092
|
+
tt1: float,
|
|
1093
|
+
tt2: float,
|
|
1094
|
+
tb1: float,
|
|
1095
|
+
tb2: float,
|
|
1096
|
+
tw1: float,
|
|
1056
1097
|
has_web: Literal[0, 1] = 1,
|
|
1057
1098
|
tw2: float = 0.0,
|
|
1058
1099
|
web_rib_pos: Literal["Left", "Right", "Both"] = "Both",
|
|
@@ -220,12 +220,14 @@ class SettlementGroupManager:
|
|
|
220
220
|
单个 SettlementGroup 对象;如果传入列表则返回对象列表;
|
|
221
221
|
不存在返回 None
|
|
222
222
|
"""
|
|
223
|
-
if isinstance(name,
|
|
224
|
-
|
|
225
|
-
|
|
223
|
+
if isinstance(name, list):
|
|
224
|
+
names = [str(x) for x in name]
|
|
225
|
+
else:
|
|
226
|
+
names = [str(name)]
|
|
227
|
+
if not isinstance(names, list):
|
|
226
228
|
raise TypeError(f"不支持的名称类型: {type(name)}")
|
|
227
229
|
|
|
228
|
-
resp = osis_client("GetSetlGrpInfoByNames", {"name":
|
|
230
|
+
resp = osis_client("GetSetlGrpInfoByNames", {"name": names})
|
|
229
231
|
if not resp['success']:
|
|
230
232
|
raise RuntimeError(f"{resp['error']}")
|
|
231
233
|
|
|
@@ -332,12 +334,15 @@ class SettlementManager:
|
|
|
332
334
|
单个 Settlement 对象;如果传入列表则返回对象列表;
|
|
333
335
|
不存在返回 None
|
|
334
336
|
"""
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
337
|
+
|
|
338
|
+
if isinstance(name, list):
|
|
339
|
+
names = [str(x) for x in name]
|
|
340
|
+
else:
|
|
341
|
+
names = [str(name)]
|
|
342
|
+
if not isinstance(names, list):
|
|
338
343
|
raise TypeError(f"不支持的名称类型: {type(name)}")
|
|
339
344
|
|
|
340
|
-
resp = osis_client("GetSettlementInfoByNames", {"name":
|
|
345
|
+
resp = osis_client("GetSettlementInfoByNames", {"name": names})
|
|
341
346
|
if not resp['success']:
|
|
342
347
|
raise RuntimeError(f"{resp['error']}")
|
|
343
348
|
|
|
@@ -94,13 +94,14 @@ class StabilityManager:
|
|
|
94
94
|
return buckl_cases
|
|
95
95
|
def get(self, name: str | list[str]) -> BucklCase | list[BucklCase | None] | None:
|
|
96
96
|
"""根据名称获取屈曲工况"""
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
...
|
|
97
|
+
|
|
98
|
+
if isinstance(name, list):
|
|
99
|
+
names = [str(x) for x in name]
|
|
101
100
|
else:
|
|
101
|
+
names = [str(name)]
|
|
102
|
+
if not isinstance(names, list):
|
|
102
103
|
raise TypeError(f"不支持的名称类型: {type(name)}")
|
|
103
|
-
resp = osis_client("GetBucklingInfoByNames", {"name":
|
|
104
|
+
resp = osis_client("GetBucklingInfoByNames", {"name": names})
|
|
104
105
|
if not resp['success']:
|
|
105
106
|
raise RuntimeError(f"{resp['error']}")
|
|
106
107
|
buckl_cases = [BucklCase._from_dict(d) if d else None for d in resp.get("data", [])]
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|