FeatureLayer.Get 方法用于返回要素图层属性的字典。
声明
public Dictionary<string, string> Esri.ArcGISForAutoCAD.FeatureLayer.Get(Document doc, string flName)
参数
| 类型 | 名称 | 描述 | 必填 |
|---|---|---|---|
文档 | doc | 要进行操作的 AutoCAD 文档。 | 必填 |
string | flName | 工程图中现有的要素图层名称。 | 必填 |
返回
| 类型 | 描述 |
|---|---|
Dictionary<string, string> | 要素图层属性的字典,其中可能包含以下内容:
|
错误条件备注
如果参数无效,则此方法可能会抛出异常或者返回 null。
示例
打印 Buildings 要素图层的要素图层属性。// Initialize
var doc = Application.DocumentManager.MdiActiveDocument;
// Get the feature layer properties
var buildingsProperties = Esri.ArcGISForAutoCAD.FeatureLayer.Get(doc, "Buildings");
// Print the properties
foreach (var property in buildingsProperties)
{
doc.Editor.WriteMessage("\nKey = {0}, Value = {1}", property.Key, property.Value);
}
/* Example output
Key = NAME, Value = Buildings
Key = GEOMTYPE, Value = Polygon
Key = TYPEFIELD, Value =
Key = FLTYPE, Value = Document
*/
另请参阅
esri_featurelayer_get - 此 AutoLISP 函数用于返回要素图层属性的关联列表。