外部参照のブロック属性値を取得する
Contents
[
Hide
]ブロック属性値の取得
Aspose.CAD for Python APIは、ブロック属性の外部参照を取得することを可能にします。Aspose.CAD APIは、XRefPathName プロパティを公開しており、CadBlockDictionary コレクション内のブロック属性の外部参照を取得します。以下は、ブロック属性の外部参照を取得するためのコードのデモンストレーションです。
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import aspose.cad as cad | |
from aspose.pycore import cast | |
if __name__ == '__main__': | |
image = cad.fileformats.cad.CadImage.load(file) | |
castedImage = cast(cad.fileformats.cad.CadImage, image) | |
for entity in castedImage.block_entities.values: | |
if entity.original_block_name == '*Model_Space': | |
print(entity.x_ref_path_name) |