|
|
|
|
using ESRI.ArcGIS.Geodatabase;
|
|
|
|
|
using System;
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using System.Data;
|
|
|
|
|
using System.Linq;
|
|
|
|
|
using System.Text;
|
|
|
|
|
|
|
|
|
|
namespace Kingo.RuleCheck.AEHelper
|
|
|
|
|
{
|
|
|
|
|
public interface IFeatureClassAPI
|
|
|
|
|
{
|
|
|
|
|
IFeatureClass FeatureClass
|
|
|
|
|
{
|
|
|
|
|
get;
|
|
|
|
|
}
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 关闭/释放要素类
|
|
|
|
|
/// </summary>
|
|
|
|
|
bool CloseFeatureClass();
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 通过条件过滤筛选要素
|
|
|
|
|
/// </summary>
|
|
|
|
|
List<IFeature> QueryFeatures(IQueryFilter pQueryFilter);
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 空间过滤筛选要素
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="pFilter">筛选条件</param>
|
|
|
|
|
/// <param name="IsCut">是否裁切图形</param>
|
|
|
|
|
/// <returns></returns>
|
|
|
|
|
List<IFeature> SpatialFilterQueryFeatures(ISpatialFilter pFilter, bool IsCut = false);
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 根据筛选条件查询要素到DataTable
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="pQueryFilter">筛选条件</param>
|
|
|
|
|
/// <param name="pQueryCount">查询数据条数</param>
|
|
|
|
|
/// <param name="pResult">输出结果</param>
|
|
|
|
|
/// <returns>满足筛选条件的总数据量</returns>
|
|
|
|
|
int QueryFeaturesToDataTable(IQueryFilter pQueryFilter, int pQueryCount, out DataTable pResult);
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 通过OID获取要素
|
|
|
|
|
/// </summary>
|
|
|
|
|
IFeature GetFeature(int OID);
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 添加要素
|
|
|
|
|
/// </summary>
|
|
|
|
|
bool AddFeature(IFeature pFeature);
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 添加要素并返回
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="pFeature"></param>
|
|
|
|
|
/// <returns></returns>
|
|
|
|
|
IFeature AddFeatureAndReturn(ESRI.ArcGIS.Geodatabase.IFeature pFeature);
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 添加要素
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="pDicData">字段、值集合</param>
|
|
|
|
|
/// <returns></returns>
|
|
|
|
|
bool AddFeature(List<K_Field> pDicData);
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 获取所有字段
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <returns></returns>
|
|
|
|
|
List<K_Field> GetFields();
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 更新要素
|
|
|
|
|
/// </summary>
|
|
|
|
|
bool UpdateFeature(IFeature pFeature);
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 删除要素
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="OID">要素ID</param>
|
|
|
|
|
/// <returns></returns>
|
|
|
|
|
bool DelFeatures(int OID);
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 添加字段
|
|
|
|
|
/// </summary>
|
|
|
|
|
bool AddField(IField pField);
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 添加字段
|
|
|
|
|
/// </summary>
|
|
|
|
|
bool AddField(string pFieldName, esriFieldType pFieldType, string pAliasName);
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 删除字段
|
|
|
|
|
/// </summary>
|
|
|
|
|
bool DeleteField(string pFieldName);
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 重命名要素类
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="newName">修改后的要素类名称</param>
|
|
|
|
|
bool RenameFeatureClass(string newName);
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 将数据拷贝到目标要素类中
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="pFc">目标要素类</param>
|
|
|
|
|
/// <param name="pFilter">过滤条件</param>
|
|
|
|
|
/// <param name="pIsCut">是否裁剪</param>
|
|
|
|
|
bool FcToFc(IFeatureClass pFc, IQueryFilter pFilter, bool pIsCut);
|
|
|
|
|
}
|
|
|
|
|
}
|