Gis:feature-has-attribute

提供:GizmoLabs - だいたい CAD LISP なサイト
構文
(gis:feature-has-attribute featureId attName)


機能
featureId で指定した 'GIS フィーチャー' オブジェクトが 'GIS フィーチャ属性' を持っているかどうかを返す。


引数
  • featureId: GIS フィーチャ属性を問い合わせる「GISフィーチャ」の「ハンドル」識別子の整数。
  • attName: 検索する「GISフィーチャー属性」の名前(大文字と小文字は区別されない)


戻り値
属性を持って入れは T 、それ以外は nil


メモ

  • 「GISフィーチャ属性」はGISデータベーステーブルの「列」を表し、各「GISフィーチャ」(dwgエンティティから構築される)はそのテーブルの「行」である。
  • 「GISフィーチャ属性」の名前文字列は常に大文字と小文字を区別しない!


サンプル
(vl-load-gis)
T

(setq layers (gis:get-layers))
("shp_3857_point_2d_utf8")

(setq name (car layers))
"shp_3857_point_2d_utf8"

(setq layerId (gis:get-layer name))
1736983018068

(setq features (gis:layer-get-features layerId))
(1685094904232 1685094904233)

(setq featureId (car features))
1685094904232

(gis:layer-get-attributes layerId)
("id" "name" "int_number" "dec_number" "date")

(gis:feature-has-attribute featureId "ID")
T

(gis:feature-has-attribute featureId "ID2")
nil



関連事項