├── .gitattributes
├── .gitignore
├── README.md
└── insertingFeatures
├── insertingFeatures.sln
├── insertingFeatures.v12.suo
└── insertingFeatures
├── App.config
├── Form1.Designer.cs
├── Form1.cs
├── Form1.resx
├── Program.cs
├── Properties
├── AssemblyInfo.cs
├── Resources.Designer.cs
├── Resources.resx
├── Settings.Designer.cs
└── Settings.settings
├── bin
└── Debug
│ ├── ESRI.ArcGIS.ADF.dll
│ ├── ESRI.ArcGIS.ADF.xml
│ ├── insertingFeatures.exe
│ ├── insertingFeatures.exe.config
│ ├── insertingFeatures.pdb
│ ├── insertingFeatures.vshost.exe
│ ├── insertingFeatures.vshost.exe.config
│ ├── insertingFeatures.vshost.exe.manifest
│ └── test.gdb
│ ├── a00000001.TablesByName.atx
│ ├── a00000001.freelist
│ ├── a00000001.gdbindexes
│ ├── a00000001.gdbtable
│ ├── a00000001.gdbtablx
│ ├── a00000002.gdbtable
│ ├── a00000002.gdbtablx
│ ├── a00000003.gdbindexes
│ ├── a00000003.gdbtable
│ ├── a00000003.gdbtablx
│ ├── a00000004.CatItemsByPhysicalName.atx
│ ├── a00000004.CatItemsByType.atx
│ ├── a00000004.FDO_UUID.atx
│ ├── a00000004.freelist
│ ├── a00000004.gdbindexes
│ ├── a00000004.gdbtable
│ ├── a00000004.gdbtablx
│ ├── a00000004.spx
│ ├── a00000005.CatItemTypesByName.atx
│ ├── a00000005.CatItemTypesByParentTypeID.atx
│ ├── a00000005.CatItemTypesByUUID.atx
│ ├── a00000005.gdbindexes
│ ├── a00000005.gdbtable
│ ├── a00000005.gdbtablx
│ ├── a00000006.CatRelsByDestinationID.atx
│ ├── a00000006.CatRelsByOriginID.atx
│ ├── a00000006.CatRelsByType.atx
│ ├── a00000006.FDO_UUID.atx
│ ├── a00000006.freelist
│ ├── a00000006.gdbindexes
│ ├── a00000006.gdbtable
│ ├── a00000006.gdbtablx
│ ├── a00000007.CatRelTypesByBackwardLabel.atx
│ ├── a00000007.CatRelTypesByDestItemTypeID.atx
│ ├── a00000007.CatRelTypesByForwardLabel.atx
│ ├── a00000007.CatRelTypesByName.atx
│ ├── a00000007.CatRelTypesByOriginItemTypeID.atx
│ ├── a00000007.CatRelTypesByUUID.atx
│ ├── a00000007.gdbindexes
│ ├── a00000007.gdbtable
│ ├── a00000007.gdbtablx
│ ├── a0000000d.gdbindexes
│ ├── a0000000d.gdbtable
│ ├── a0000000d.gdbtablx
│ ├── a0000000d.spx
│ ├── gdb
│ └── timestamps
├── insertingFeatures.csproj
└── obj
└── Debug
├── DesignTimeResolveAssemblyReferences.cache
├── DesignTimeResolveAssemblyReferencesInput.cache
├── TemporaryGeneratedFile_036C0B5B-1481-4323-8D20-8F5ADCB23D92.cs
├── TemporaryGeneratedFile_5937a670-0e60-4077-877b-f7221da3dda1.cs
├── TemporaryGeneratedFile_E7A71F73-0F8D-4B9B-B56E-8E70B10BC5D3.cs
├── insertingFeatures.Form1.resources
├── insertingFeatures.Properties.Resources.resources
├── insertingFeatures.csproj.FileListAbsolute.txt
├── insertingFeatures.csproj.GenerateResource.Cache
├── insertingFeatures.exe
└── insertingFeatures.pdb
/.gitattributes:
--------------------------------------------------------------------------------
1 | # Auto detect text files and perform LF normalization
2 | * text=auto
3 |
4 | # Custom for Visual Studio
5 | *.cs diff=csharp
6 |
7 | # Standard to msysgit
8 | *.doc diff=astextplain
9 | *.DOC diff=astextplain
10 | *.docx diff=astextplain
11 | *.DOCX diff=astextplain
12 | *.dot diff=astextplain
13 | *.DOT diff=astextplain
14 | *.pdf diff=astextplain
15 | *.PDF diff=astextplain
16 | *.rtf diff=astextplain
17 | *.RTF diff=astextplain
18 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | # Windows image file caches
2 | Thumbs.db
3 | ehthumbs.db
4 |
5 | # Folder config file
6 | Desktop.ini
7 |
8 | # Recycle Bin used on file shares
9 | $RECYCLE.BIN/
10 |
11 | # Windows Installer files
12 | *.cab
13 | *.msi
14 | *.msm
15 | *.msp
16 |
17 | # Windows shortcuts
18 | *.lnk
19 |
20 | # =========================
21 | # Operating System Files
22 | # =========================
23 |
24 | # OSX
25 | # =========================
26 |
27 | .DS_Store
28 | .AppleDouble
29 | .LSOverride
30 |
31 | # Thumbnails
32 | ._*
33 |
34 | # Files that might appear in the root of a volume
35 | .DocumentRevisions-V100
36 | .fseventsd
37 | .Spotlight-V100
38 | .TemporaryItems
39 | .Trashes
40 | .VolumeIcon.icns
41 |
42 | # Directories potentially created on remote AFP share
43 | .AppleDB
44 | .AppleDesktop
45 | Network Trash Folder
46 | Temporary Items
47 | .apdisk
48 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # Engine中如何往已有要素类中插入数据
2 | 您在Engine程序开发过程中是否遇到过要将新获取的数据向已有要素类中插入?对于数据插入的几种方法您是否清楚?各种方法的效率您对比过吗?今天我们讨论的话题为Engine中如何往已有要素类中插入数据,上述问题的答案会为您一一揭晓。
3 |
4 |
5 | ##一、往已有要素类中插入数据的几种方式及其优缺点:
6 |
7 | 1,**IFeatureClass.CreateFeature配合IFeature.Store使用**。该方法在调用Store时会触发所有与Feature相关的行为,不但会触发IObjectClassEvents,还会触发涉及网络、注记要素,以及参与拓扑的要素等特殊的行为(比如向参加拓扑的要素类中添加要素后会自动创建dirty area)。
8 |
9 | 该方法在调用CreateFeature方法时,创建要素的OID,执行Store时将要素存入数据库中。
10 |
11 | ***优点:***代码简单;
12 | ***缺点:***效率低,如果仅仅插入几个要素或者进行测试而不考虑性能的话可以考虑。
13 |
14 | 2,**IFeatureClass.CreateFeatureBuffer配合insert cursor使用**。不会触发事件,该方法常常用来一次性插入大量要素,比第一种方法效率高很多。此外,IFeatureClass.Insert(bool useBuffering)方法中参数useBuffering建议总将其设为true,这样数据会先缓冲在客户端,然后执行Flush时批量写入,以提升效率。
15 |
16 | 该方法创建的IFeatureBuffer可以进行多次赋值,在执行InsertFeature时,创建要素的OID,但是此时数据并没有写入到数据库中,只有在执行IFeatureCursor.Flush时数据才会真正写入到数据库中。注意Flush方法是需要手动调用的,如果不执行,在程序释放时自动执行,但这样会无法检测错误,比如要素类空间不够了就会报错。
17 |
18 | ***优点:***效率高,尤其是插入大量数据时。如果仅就性能而言,除非插入一个要素,其余情况都推荐使用该方法;
19 | ***缺点:***代码相比第一种,稍显复杂,注意需要释放ICursor和IFeatureBuffer对象。
20 |
21 | 这里提一下,该方法中涉及到cursor的释放,有两种方法释放游标:
22 | a, 直接使用ComReleaser.ReleaseCOMObject(cursor); 或者Marshal.FinalReleaseComObject(cursor);
23 |
24 | b, 使用using(){ }方式,如下:
25 |
26 | ```
27 | using(ComReleaser comReleaser = new ComReleaser())
28 | {
29 | // Create a feature buffer.
30 | IFeatureBuffer featureBuffer = featureClass.CreateFeatureBuffer();
31 | comReleaser.ManageLifetime(featureBuffer);
32 |
33 | // Create an insert cursor.
34 | IFeatureCursor insertCursor = featureClass.Insert(true);
35 | comReleaser.ManageLifetime(insertCursor);
36 |
37 | …
38 | }
39 |
40 | ```
41 |
42 | 执行完using后会自动释放insertCursor和featureBuffer,可以避免程序比较复杂时不确定在哪释放或者忘记释放的情况,是比较优秀的编程方式,推荐使用。
43 |
44 | 3,**使用Load-Only模式插入数据(SDE以及FileGDB都支持)**。这种方法是对第二种方法的升级,主要用来在插入数据量特别大的情况下提高性能。Load-Only模式仅能用来插入新的要素,而不能用于编辑已有要素。原理是开启Load-Only模式后,插入数据时会停止更新空间索引和属性索引,解除Load-Only后才重建索引(*重建索引是重建该要素类所有要素的索引,如果已有要素类中含有大量要素,而插入数据量不太大时,重建索引可能会影响性能*)。开启Load-Only模式时,其它程序不能访问该数据,可以在获取排它锁之后设置Load-Only。如下:
45 |
46 | ```
47 | // Cast the feature class to the IFeatureClassLoad interface.
48 | IFeatureClassLoad featureClassLoad = (IFeatureClassLoad)featureClass;
49 |
50 | // Acquire an exclusive schema lock for the class.
51 | ISchemaLock schemaLock = (ISchemaLock)featureClass;
52 | try
53 | {
54 | schemaLock.ChangeSchemaLock(esriSchemaLock.esriExclusiveSchemaLock);
55 |
56 | // Enable load-only mode on the feature class.
57 | featureClassLoad.LoadOnlyMode = true;
58 | using(ComReleaser comReleaser = new ComReleaser())
59 | {
60 | // Create the feature buffer.
61 | IFeatureBuffer featureBuffer = featureClass.CreateFeatureBuffer();
62 | comReleaser.ManageLifetime(featureBuffer);
63 |
64 | // Create an insert cursor.
65 | IFeatureCursor insertCursor = featureClass.Insert(true);
66 | comReleaser.ManageLifetime(insertCursor);
67 |
68 | …
69 | }
70 | }
71 | catch (Exception)
72 | {
73 | // Handle the failure in a way appropriate to the application.
74 | }
75 | finally
76 | {
77 | // Disable load-only mode on the feature class.
78 | featureClassLoad.LoadOnlyMode = false;
79 |
80 | // Demote the exclusive schema lock to a shared lock.
81 | schemaLock.ChangeSchemaLock(esriSchemaLock.esriSharedSchemaLock);
82 | }
83 | ```
84 |
85 | 插入数据常用的就是以上三种方式,下面两种方式也可以插入数据,但是不常用,简要介绍一下。
86 |
87 | 4,**IObjectLoader.LoadObjects方法。**该方法***只能在Desktop产品下***使用,也就是Engine许可无法使用,相比之前的方法,该方法代码简单,对于属性值的复制也更为简单,如下:
88 |
89 | ```
90 | IObjectLoader objectLoader = new ObjectLoaderClass();
91 | IFeatureClass sourceFeatureClass = getFeatureClass("esriDataSourcesGDB.FileGDBWorkspaceFactory", fileGDBPath, sourceFCName);
92 | IFeatureClass targetFeatureClass = getFeatureClass("esriDataSourcesGDB.SdeWorkspaceFactory", sdePath, targetFCName);
93 |
94 | string sInFieldList = targetFeatureClass.Fields.get_Field(0).Name;
95 | for(int i=1;i< targetFeatureClass.Fields.FieldCount;i++)
96 | sInFieldList = sInFieldList + "," + targetFeatureClass.Fields.get_Field(i).Name;
97 |
98 | IQueryFilter queryFilter = new QueryFilterClass();
99 | queryFilter.WhereClause = queryClause;
100 | queryFilter.SubFields = sInFieldList;
101 |
102 | IEnumInvalidObject invalidObject;
103 | objectLoader.LoadObjects(null, sourceFeatureClass as ITable, queryFilter, targetFeatureClass as ITable, targetFeatureClass.Fields, false, 0, false, false, 1000, out invalidObject);
104 | ```
105 |
106 | ***优点:***代码简单,属性值复制也更为简单;
107 | ***缺点:***只能在Desktop许可下使用。
108 |
109 | 5,**IFeatureClass.CreateFeature配合IFeatureClassWrite.WriteFeature/WriteFeatures使用**。IFeatureClassWrite是low-level的接口,不会触发任何事件。只是使用WriteFeature/WriteFeatures替换IFeature.Store将要素写入数据库,用的人很少。
110 |
111 | 以上就是插入数据的几种方式,您是否都清楚了?接下来,在程序的编写过程中有哪些需要注意的呢?
112 |
113 | a, 以下数据类型需要EngineGeoDB许可或者Desktop产品的Standard或者Advanced许可:涉及几何网络、拓扑、Dimension要素类、注记类、ArcSDE数据库的。
114 |
115 | b, 以下情况需要开启编辑会话:涉及拓扑、几何网络、terrain、representation以及ArcSDE中的版本数据的。
116 |
117 | c, 在给要素赋予Shape时,有必要执行一下**ITopologicalOperator.Simplify**来验证几何,尤其是往SDE中插入时,有几何错误会导致失败。
118 |
119 | d, 插入数据可能导致要素类的Extent发生变化,插入完后建议调用**IFeatureClassManage. UpdateExtent**更新范围(*需要获取要素类的排他锁,也就是不能有别的用户或程序访问该要素类*),不然有可能执行缩放到图层或全图时数据显示不全。
120 |
121 | e, Geometry的空间参考需要与目标要素类的空间参考相一致,否则会进行动态投影而影响性能。
122 |
123 | f, 如果源要素类中有Z值或M值,注意赋Shape时需要使用IZAware或者IMAware进行设置。
124 |
125 |
126 | ##二、效率对比
127 |
128 | 由于经常碰到用户需要将本地数据库的数据往SDE中导入,所以本文以将FileGDB中的点要素类插入到ArcSDE中已有的字段结构相同的要素类中为例进行测试。
129 |
130 | 代码可参考:[ArcObjects帮助文档](http://resources.arcgis.com/en/help/arcobjects-net/conceptualhelp/#/Creating_features/00010000049v000000/)
131 |
132 | **测试结果:**
133 |
134 | 1, 将100个点要素从FileGDB中插入SDE要素类中使用五种方法分别用时:2.25秒、0.19秒、0.21秒、0.23秒、2.40秒。
135 |
136 | 2, 将10000个点要素从FileGDB中插入SDE要素类中使用五种方法分别用时:185秒、14.5秒、11.3秒、13.2秒、204秒。
137 |
138 | 3, 将100000个点要素从FileGDB中插入SDE要素类中使用五种方法分别用时:1345秒、163秒、127秒、146秒、1409秒。
139 |
140 | 4, 文中提到使用游标方式插入数据,如果将IFeatureClass.Insert(bool useBuffering)方法中参数useBuffering设为true会提高效率,现在就来测试一下。将100000个点要素插入SDE中,设为false所用时间为:164秒,设为true所用时间为:122秒。
141 |
142 | 5, 开启编辑会话会不会提高效率呢?将100000个点要素插入SDE中,设为false所用时间为:161秒,设为true所用时间为:117秒。相比不开启编辑会话,几乎没有差别。
143 |
144 |
145 | **从上述测试结果可以看出:**
146 |
147 | a, 无论是插入少量数据还是插入大量数据,Insert方式都比CreateFeature方式快;
148 |
149 | b, 如果仅插入少量数据,使用LoadOnly模式反而会慢(文中插入100个点),如果插入大量要素使用LoadOnly会快(文中插入1万和10万个点),但是如果该要素类中已有大量要素,而仅插入不是太多数据的话重建索引可能会影响性能;
150 |
151 | c, IFeatureClassWrite.WriteFeature方法比IFeature.Store还要慢,这大概也是该方法用的很少的原因之一吧;
152 |
153 | d, IObjectLoader.LoadObjects方法比Insert稍快,但是比LoadOnly要慢些(文中插入1万和10万个点)。由于测试数据中仅含有两个自定义字段,如果字段个数较多的话,我觉得这种方法会更快;
154 |
155 | e, IFeatureClass.Insert(bool useBuffering)方法中参数useBuffering设为true确实可以提高效率;
156 |
157 | f, 开启编辑会话与不开启效率几乎一样,当然如果涉及到拓扑,几何网络等复杂情况时必须开启编辑会话。
158 |
159 |
160 | ##Demo
161 |
162 | 使用ArcGIS Engine 10.4,Visual Studio 2013编写,汇总了往已有要素类中插入数据的几种方法,右侧的comboBox里可以选择查询条件。读者们可以自行选择合适的方法,界面为:
163 | 
164 |
165 |
166 | ###工程下载地址:
167 |
168 | [InsertingFeatures](https://github.com/xinying180/InsertingFeatures)
169 |
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures.sln:
--------------------------------------------------------------------------------
1 |
2 | Microsoft Visual Studio Solution File, Format Version 12.00
3 | # Visual Studio 2013
4 | VisualStudioVersion = 12.0.40629.0
5 | MinimumVisualStudioVersion = 10.0.40219.1
6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "insertingFeatures", "insertingFeatures\insertingFeatures.csproj", "{7905B0C6-802B-4BF6-8682-1DFB4C71CC8D}"
7 | EndProject
8 | Global
9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution
10 | Debug|Any CPU = Debug|Any CPU
11 | Release|Any CPU = Release|Any CPU
12 | EndGlobalSection
13 | GlobalSection(ProjectConfigurationPlatforms) = postSolution
14 | {7905B0C6-802B-4BF6-8682-1DFB4C71CC8D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
15 | {7905B0C6-802B-4BF6-8682-1DFB4C71CC8D}.Debug|Any CPU.Build.0 = Debug|Any CPU
16 | {7905B0C6-802B-4BF6-8682-1DFB4C71CC8D}.Release|Any CPU.ActiveCfg = Release|Any CPU
17 | {7905B0C6-802B-4BF6-8682-1DFB4C71CC8D}.Release|Any CPU.Build.0 = Release|Any CPU
18 | EndGlobalSection
19 | GlobalSection(SolutionProperties) = preSolution
20 | HideSolutionNode = FALSE
21 | EndGlobalSection
22 | EndGlobal
23 |
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures.v12.suo:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/xinying180/InsertingFeatures/bdb543fcd11a86d8324e8854f1a4d2766fa89ca3/insertingFeatures/insertingFeatures.v12.suo
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/App.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/Form1.Designer.cs:
--------------------------------------------------------------------------------
1 | namespace insertingFeatures
2 | {
3 | partial class Form1
4 | {
5 | ///
6 | /// Required designer variable.
7 | ///
8 | private System.ComponentModel.IContainer components = null;
9 |
10 | ///
11 | /// Clean up any resources being used.
12 | ///
13 | /// true if managed resources should be disposed; otherwise, false.
14 | protected override void Dispose(bool disposing)
15 | {
16 | if (disposing && (components != null))
17 | {
18 | components.Dispose();
19 | }
20 | base.Dispose(disposing);
21 | }
22 |
23 | #region Windows Form Designer generated code
24 |
25 | ///
26 | /// Required method for Designer support - do not modify
27 | /// the contents of this method with the code editor.
28 | ///
29 | private void InitializeComponent()
30 | {
31 | this.menuStrip1 = new System.Windows.Forms.MenuStrip();
32 | this.往已有要素类中插入数据ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
33 | this.createFeatureToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
34 | this.insertFeatureToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
35 | this.loadOnlyToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
36 | this.objectLoaderToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
37 | this.featureClassWriteToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
38 | this.comboBox1 = new System.Windows.Forms.ComboBox();
39 | this.menuStrip1.SuspendLayout();
40 | this.SuspendLayout();
41 | //
42 | // menuStrip1
43 | //
44 | this.menuStrip1.ImageScalingSize = new System.Drawing.Size(20, 20);
45 | this.menuStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
46 | this.往已有要素类中插入数据ToolStripMenuItem});
47 | this.menuStrip1.Location = new System.Drawing.Point(0, 0);
48 | this.menuStrip1.Name = "menuStrip1";
49 | this.menuStrip1.Size = new System.Drawing.Size(636, 28);
50 | this.menuStrip1.TabIndex = 0;
51 | this.menuStrip1.Text = "menuStrip1";
52 | //
53 | // 往已有要素类中插入数据ToolStripMenuItem
54 | //
55 | this.往已有要素类中插入数据ToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
56 | this.createFeatureToolStripMenuItem,
57 | this.insertFeatureToolStripMenuItem,
58 | this.loadOnlyToolStripMenuItem,
59 | this.objectLoaderToolStripMenuItem,
60 | this.featureClassWriteToolStripMenuItem});
61 | this.往已有要素类中插入数据ToolStripMenuItem.Name = "往已有要素类中插入数据ToolStripMenuItem";
62 | this.往已有要素类中插入数据ToolStripMenuItem.Size = new System.Drawing.Size(197, 24);
63 | this.往已有要素类中插入数据ToolStripMenuItem.Text = "往已有要素类中插入数据";
64 | //
65 | // createFeatureToolStripMenuItem
66 | //
67 | this.createFeatureToolStripMenuItem.Name = "createFeatureToolStripMenuItem";
68 | this.createFeatureToolStripMenuItem.Size = new System.Drawing.Size(202, 26);
69 | this.createFeatureToolStripMenuItem.Text = "CreateFeature";
70 | this.createFeatureToolStripMenuItem.Click += new System.EventHandler(this.createFeatureToolStripMenuItem_Click);
71 | //
72 | // insertFeatureToolStripMenuItem
73 | //
74 | this.insertFeatureToolStripMenuItem.Name = "insertFeatureToolStripMenuItem";
75 | this.insertFeatureToolStripMenuItem.Size = new System.Drawing.Size(202, 26);
76 | this.insertFeatureToolStripMenuItem.Text = "InsertFeature";
77 | this.insertFeatureToolStripMenuItem.Click += new System.EventHandler(this.insertFeatureToolStripMenuItem_Click);
78 | //
79 | // loadOnlyToolStripMenuItem
80 | //
81 | this.loadOnlyToolStripMenuItem.Name = "loadOnlyToolStripMenuItem";
82 | this.loadOnlyToolStripMenuItem.Size = new System.Drawing.Size(202, 26);
83 | this.loadOnlyToolStripMenuItem.Text = "LoadOnly";
84 | this.loadOnlyToolStripMenuItem.Click += new System.EventHandler(this.loadOnlyToolStripMenuItem_Click);
85 | //
86 | // objectLoaderToolStripMenuItem
87 | //
88 | this.objectLoaderToolStripMenuItem.Name = "objectLoaderToolStripMenuItem";
89 | this.objectLoaderToolStripMenuItem.Size = new System.Drawing.Size(202, 26);
90 | this.objectLoaderToolStripMenuItem.Text = "ObjectLoader";
91 | this.objectLoaderToolStripMenuItem.Click += new System.EventHandler(this.objectLoaderToolStripMenuItem_Click);
92 | //
93 | // featureClassWriteToolStripMenuItem
94 | //
95 | this.featureClassWriteToolStripMenuItem.Name = "featureClassWriteToolStripMenuItem";
96 | this.featureClassWriteToolStripMenuItem.Size = new System.Drawing.Size(202, 26);
97 | this.featureClassWriteToolStripMenuItem.Text = "FeatureClassWrite";
98 | this.featureClassWriteToolStripMenuItem.Click += new System.EventHandler(this.featureClassWriteToolStripMenuItem_Click);
99 | //
100 | // comboBox1
101 | //
102 | this.comboBox1.FormattingEnabled = true;
103 | this.comboBox1.Items.AddRange(new object[] {
104 | "OBJECTID <2",
105 | "OBJECTID <101",
106 | "OBJECTID <10001",
107 | "OBJECTID <100001"});
108 | this.comboBox1.Location = new System.Drawing.Point(434, 31);
109 | this.comboBox1.Name = "comboBox1";
110 | this.comboBox1.Size = new System.Drawing.Size(190, 24);
111 | this.comboBox1.TabIndex = 1;
112 | this.comboBox1.SelectedIndexChanged += new System.EventHandler(this.comboBox1_SelectedIndexChanged);
113 | //
114 | // Form1
115 | //
116 | this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 16F);
117 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
118 | this.ClientSize = new System.Drawing.Size(636, 310);
119 | this.Controls.Add(this.comboBox1);
120 | this.Controls.Add(this.menuStrip1);
121 | this.MainMenuStrip = this.menuStrip1;
122 | this.Name = "Form1";
123 | this.Text = "Form1";
124 | this.menuStrip1.ResumeLayout(false);
125 | this.menuStrip1.PerformLayout();
126 | this.ResumeLayout(false);
127 | this.PerformLayout();
128 |
129 | }
130 |
131 | #endregion
132 |
133 | private System.Windows.Forms.MenuStrip menuStrip1;
134 | private System.Windows.Forms.ToolStripMenuItem 往已有要素类中插入数据ToolStripMenuItem;
135 | private System.Windows.Forms.ToolStripMenuItem createFeatureToolStripMenuItem;
136 | private System.Windows.Forms.ToolStripMenuItem insertFeatureToolStripMenuItem;
137 | private System.Windows.Forms.ToolStripMenuItem loadOnlyToolStripMenuItem;
138 | private System.Windows.Forms.ToolStripMenuItem objectLoaderToolStripMenuItem;
139 | private System.Windows.Forms.ComboBox comboBox1;
140 | private System.Windows.Forms.ToolStripMenuItem featureClassWriteToolStripMenuItem;
141 | }
142 | }
143 |
144 |
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/Form1.cs:
--------------------------------------------------------------------------------
1 | using ESRI.ArcGIS.ADF;
2 | using ESRI.ArcGIS.Catalog;
3 | using ESRI.ArcGIS.EditorExt;
4 | using ESRI.ArcGIS.esriSystem;
5 | using ESRI.ArcGIS.Geodatabase;
6 | using System;
7 | using System.Collections.Generic;
8 | using System.ComponentModel;
9 | using System.Data;
10 | using System.Diagnostics;
11 | using System.Drawing;
12 | using System.Linq;
13 | using System.Text;
14 | using System.Threading.Tasks;
15 | using System.Windows.Forms;
16 |
17 | namespace insertingFeatures
18 | {
19 | public partial class Form1 : Form
20 | {
21 | public Form1()
22 | {
23 | InitializeComponent();
24 | }
25 | string sdePath = @"C:\Users\Xinying\AppData\Roaming\ESRI\Desktop10.4\ArcCatalog\Connection to 192.168.220.132 (3).sde";
26 | string fileGDBPath = Application.StartupPath + "\\test.gdb";
27 | string sourceFCName = "testPoint_10w";
28 | string targetFCName = "testPoint_10w_sde";
29 | string queryClause = "OBJECTID <101";
30 | private void createFeatureToolStripMenuItem_Click(object sender, EventArgs e)
31 | {
32 | Stopwatch myWatch = Stopwatch.StartNew();
33 |
34 | IFeatureClass sourceFeatureClass = getFeatureClass("esriDataSourcesGDB.FileGDBWorkspaceFactory", fileGDBPath, sourceFCName);
35 | IFeatureClass targetFeatureClass = getFeatureClass("esriDataSourcesGDB.SdeWorkspaceFactory", sdePath, targetFCName);
36 |
37 | createFeature(sourceFeatureClass, targetFeatureClass);
38 |
39 | myWatch.Stop();
40 | string time = myWatch.Elapsed.TotalSeconds.ToString();
41 | MessageBox.Show(time + " Seconds");
42 |
43 | }
44 |
45 | public void createFeature(IFeatureClass sourceFeatureClass, IFeatureClass targetFeatureClass)
46 | {
47 | IQueryFilter queryFilter = new QueryFilterClass();
48 | queryFilter.WhereClause = queryClause;
49 | IFeatureCursor cursor = sourceFeatureClass.Search(queryFilter, true);
50 | IFeature sourceFeature = cursor.NextFeature();
51 | while (sourceFeature != null)
52 | {
53 | IFeature targetFeature = targetFeatureClass.CreateFeature();
54 |
55 | //如果是线或面要素类需要执行下Simplify,这里用的点要素类,不做验证了
56 | targetFeature.Shape = sourceFeature.ShapeCopy;
57 |
58 | for (int i = 0; i < sourceFeature.Fields.FieldCount; i++)
59 | {
60 | IField field = sourceFeature.Fields.get_Field(i);
61 | if (field.Type != esriFieldType.esriFieldTypeOID && field.Type != esriFieldType.esriFieldTypeGeometry && field.Type != esriFieldType.esriFieldTypeGlobalID && field.Type != esriFieldType.esriFieldTypeGUID)
62 | {
63 | string fieldName = field.Name;
64 | int index = targetFeature.Fields.FindField(fieldName);
65 | if (index > -1 && fieldName != "Shape_Length" && fieldName != "Shape_Area")
66 | targetFeature.set_Value(index, sourceFeature.get_Value(i));
67 | }
68 |
69 | }
70 | targetFeature.Store();
71 | sourceFeature = cursor.NextFeature();
72 |
73 | }
74 | ComReleaser.ReleaseCOMObject(cursor);
75 |
76 | IFeatureClassManage targetFeatureClassManage = targetFeatureClass as IFeatureClassManage;
77 | targetFeatureClassManage.UpdateExtent();
78 | }
79 | private IFeatureClass getFeatureClass(string WorkspaceFactoryProgID, string GDBPath, string featureClassName)
80 | {
81 | IWorkspaceName workspaceName = new WorkspaceNameClass
82 | {
83 | WorkspaceFactoryProgID = WorkspaceFactoryProgID,
84 | PathName = GDBPath
85 | };
86 |
87 | IName workspaceIName = (IName)workspaceName;
88 | IWorkspace workspace = (IWorkspace)workspaceIName.Open();
89 |
90 | IFeatureClass featureClass = (workspace as IFeatureWorkspace).OpenFeatureClass(featureClassName);
91 |
92 | return featureClass;
93 | }
94 |
95 | private void insertFeatureToolStripMenuItem_Click(object sender, EventArgs e)
96 | {
97 | Stopwatch myWatch = Stopwatch.StartNew();
98 |
99 | IFeatureClass sourceFeatureClass = getFeatureClass("esriDataSourcesGDB.FileGDBWorkspaceFactory", fileGDBPath, sourceFCName);
100 | IFeatureClass targetFeatureClass = getFeatureClass("esriDataSourcesGDB.SdeWorkspaceFactory", sdePath, targetFCName);
101 |
102 | InsertFeaturesUsingCursor(sourceFeatureClass, targetFeatureClass);
103 |
104 | myWatch.Stop();
105 | string time = myWatch.Elapsed.TotalSeconds.ToString();
106 | MessageBox.Show(time + " Seconds");
107 | }
108 | public void InsertFeaturesUsingCursor(IFeatureClass sourceFeatureClass, IFeatureClass targetFeatureClass)
109 | {
110 | using (ComReleaser comReleaser = new ComReleaser())
111 | {
112 | // Create a feature buffer.
113 | IFeatureBuffer featureBuffer = targetFeatureClass.CreateFeatureBuffer();
114 | comReleaser.ManageLifetime(featureBuffer);
115 |
116 | // Create an insert cursor.
117 | IFeatureCursor insertCursor = targetFeatureClass.Insert(true);
118 | comReleaser.ManageLifetime(insertCursor);
119 |
120 | IQueryFilter queryFilter = new QueryFilterClass();
121 | queryFilter.WhereClause = queryClause;
122 | IFeatureCursor cursor = sourceFeatureClass.Search(queryFilter, true);
123 |
124 | IFeature sourceFeature = cursor.NextFeature();
125 |
126 | while (sourceFeature != null)
127 | {
128 | //如果是线或面要素类需要执行下Simplify,这里用的点要素类,不做验证了
129 | featureBuffer.Shape = sourceFeature.ShapeCopy;
130 |
131 | for (int i = 0; i < sourceFeature.Fields.FieldCount; i++)
132 | {
133 | IField field = sourceFeature.Fields.get_Field(i);
134 | if (field.Type != esriFieldType.esriFieldTypeOID && field.Type != esriFieldType.esriFieldTypeGeometry && field.Type != esriFieldType.esriFieldTypeGlobalID && field.Type != esriFieldType.esriFieldTypeGUID)
135 | {
136 | string fieldName = field.Name;
137 | int index = featureBuffer.Fields.FindField(fieldName);
138 | if (index > -1 && fieldName != "Shape_Length" && fieldName != "Shape_Area")
139 | featureBuffer.set_Value(index, sourceFeature.get_Value(i));
140 | }
141 |
142 | }
143 | insertCursor.InsertFeature(featureBuffer);
144 | sourceFeature = cursor.NextFeature();
145 | }
146 |
147 | // Flush the buffer to the geodatabase.
148 | insertCursor.Flush();
149 | ComReleaser.ReleaseCOMObject(cursor);
150 |
151 | }
152 | IFeatureClassManage targetFeatureClassManage = targetFeatureClass as IFeatureClassManage;
153 | targetFeatureClassManage.UpdateExtent();
154 | }
155 |
156 | private void loadOnlyToolStripMenuItem_Click(object sender, EventArgs e)
157 | {
158 | Stopwatch myWatch = Stopwatch.StartNew();
159 |
160 | IFeatureClass sourceFeatureClass = getFeatureClass("esriDataSourcesGDB.FileGDBWorkspaceFactory", fileGDBPath, sourceFCName);
161 | IFeatureClass targetFeatureClass = getFeatureClass("esriDataSourcesGDB.SdeWorkspaceFactory", sdePath, targetFCName);
162 |
163 | LoadOnlyModeInsert(sourceFeatureClass, targetFeatureClass);
164 |
165 | myWatch.Stop();
166 | string time = myWatch.Elapsed.TotalSeconds.ToString();
167 | MessageBox.Show(time + " Seconds");
168 | }
169 | public void LoadOnlyModeInsert(IFeatureClass sourceFeatureClass, IFeatureClass targetFeatureClass)
170 | {
171 | // Cast the feature class to the IFeatureClassLoad interface.
172 | IFeatureClassLoad featureClassLoad = (IFeatureClassLoad)targetFeatureClass;
173 |
174 | // Acquire an exclusive schema lock for the class.
175 | ISchemaLock schemaLock = (ISchemaLock)targetFeatureClass;
176 | try
177 | {
178 | schemaLock.ChangeSchemaLock(esriSchemaLock.esriExclusiveSchemaLock);
179 |
180 | // Enable load-only mode on the feature class.
181 | featureClassLoad.LoadOnlyMode = true;
182 | using (ComReleaser comReleaser = new ComReleaser())
183 | {
184 | // Create the feature buffer.
185 | IFeatureBuffer featureBuffer = targetFeatureClass.CreateFeatureBuffer();
186 | comReleaser.ManageLifetime(featureBuffer);
187 |
188 | // Create an insert cursor.
189 | IFeatureCursor insertCursor = targetFeatureClass.Insert(true);
190 | comReleaser.ManageLifetime(insertCursor);
191 |
192 | IQueryFilter queryFilter = new QueryFilterClass();
193 | queryFilter.WhereClause = queryClause;
194 | IFeatureCursor cursor = sourceFeatureClass.Search(queryFilter, true);
195 |
196 | IFeature sourceFeature = cursor.NextFeature();
197 |
198 | while (sourceFeature != null)
199 | {
200 | //如果是线或面要素类需要执行下Simplify,这里用的点要素类,不做验证了
201 | featureBuffer.Shape = sourceFeature.ShapeCopy;
202 |
203 | for (int i = 0; i < sourceFeature.Fields.FieldCount; i++)
204 | {
205 | IField field = sourceFeature.Fields.get_Field(i);
206 | if (field.Type != esriFieldType.esriFieldTypeOID && field.Type != esriFieldType.esriFieldTypeGeometry && field.Type != esriFieldType.esriFieldTypeGlobalID && field.Type != esriFieldType.esriFieldTypeGUID)
207 | {
208 | string fieldName = field.Name;
209 | int index = featureBuffer.Fields.FindField(fieldName);
210 | if (index > -1 && fieldName != "Shape_Length" && fieldName != "Shape_Area")
211 | featureBuffer.set_Value(index, sourceFeature.get_Value(i));
212 | }
213 |
214 | }
215 | insertCursor.InsertFeature(featureBuffer);
216 | sourceFeature = cursor.NextFeature();
217 | }
218 |
219 | // Flush the buffer to the geodatabase.
220 | insertCursor.Flush();
221 | ComReleaser.ReleaseCOMObject(cursor);
222 | IFeatureClassManage targetFeatureClassManage = targetFeatureClass as IFeatureClassManage;
223 | targetFeatureClassManage.UpdateExtent();
224 | }
225 | }
226 | catch (Exception)
227 | {
228 | // Handle the failure in a way appropriate to the application.
229 | MessageBox.Show("无法获取该要素类的排它锁,检查ArcMap是否打开了该要素类,建议关闭!");
230 | }
231 | finally
232 | {
233 | // Disable load-only mode on the feature class.
234 | featureClassLoad.LoadOnlyMode = false;
235 |
236 | // Demote the exclusive schema lock to a shared lock.
237 | schemaLock.ChangeSchemaLock(esriSchemaLock.esriSharedSchemaLock);
238 | }
239 |
240 | }
241 |
242 | private void objectLoaderToolStripMenuItem_Click(object sender, EventArgs e)
243 | {
244 | Stopwatch myWatch = Stopwatch.StartNew();
245 |
246 | IObjectLoader objectLoader = new ObjectLoaderClass();
247 | IFeatureClass sourceFeatureClass = getFeatureClass("esriDataSourcesGDB.FileGDBWorkspaceFactory", fileGDBPath, sourceFCName);
248 | IFeatureClass targetFeatureClass = getFeatureClass("esriDataSourcesGDB.SdeWorkspaceFactory", sdePath, targetFCName);
249 |
250 | string sInFieldList = targetFeatureClass.Fields.get_Field(0).Name;
251 | for (int i = 1; i < targetFeatureClass.Fields.FieldCount; i++)
252 | sInFieldList = sInFieldList + "," + targetFeatureClass.Fields.get_Field(i).Name;
253 |
254 | IQueryFilter queryFilter = new QueryFilterClass();
255 | queryFilter.WhereClause = queryClause;
256 | queryFilter.SubFields = sInFieldList;
257 |
258 | IEnumInvalidObject invalidObject;
259 | objectLoader.LoadObjects(null, sourceFeatureClass as ITable, queryFilter, targetFeatureClass as ITable, targetFeatureClass.Fields, false, 0, false, false, 1000, out invalidObject);
260 | IFeatureClassManage targetFeatureClassManage = targetFeatureClass as IFeatureClassManage;
261 | targetFeatureClassManage.UpdateExtent();
262 |
263 | myWatch.Stop();
264 | string time = myWatch.Elapsed.TotalSeconds.ToString();
265 | MessageBox.Show(time + " Seconds");
266 | }
267 |
268 | private void comboBox1_SelectedIndexChanged(object sender, EventArgs e)
269 | {
270 | queryClause = comboBox1.Text;
271 | }
272 |
273 | private void featureClassWriteToolStripMenuItem_Click(object sender, EventArgs e)
274 | {
275 | Stopwatch myWatch = Stopwatch.StartNew();
276 |
277 | IFeatureClass sourceFeatureClass = getFeatureClass("esriDataSourcesGDB.FileGDBWorkspaceFactory", fileGDBPath, sourceFCName);
278 | IFeatureClass targetFeatureClass = getFeatureClass("esriDataSourcesGDB.SdeWorkspaceFactory", sdePath, targetFCName);
279 |
280 | featureClassWrite(sourceFeatureClass, targetFeatureClass);
281 |
282 | myWatch.Stop();
283 | string time = myWatch.Elapsed.TotalSeconds.ToString();
284 | MessageBox.Show(time + " Seconds");
285 | }
286 | public void featureClassWrite(IFeatureClass sourceFeatureClass, IFeatureClass targetFeatureClass)
287 | {
288 | IQueryFilter queryFilter = new QueryFilterClass();
289 | queryFilter.WhereClause = queryClause;
290 | IFeatureCursor cursor = sourceFeatureClass.Search(queryFilter, true);
291 | IFeature sourceFeature = cursor.NextFeature();
292 | IFeatureClassWrite featureClassWrite = targetFeatureClass as IFeatureClassWrite;
293 | ISet setAdd = new SetClass();
294 | while (sourceFeature != null)
295 | {
296 | IFeature targetFeature = targetFeatureClass.CreateFeature();
297 |
298 | //如果是线或面要素类需要执行下Simplify,这里用的点要素类,不做验证了
299 | targetFeature.Shape = sourceFeature.ShapeCopy;
300 |
301 | for (int i = 0; i < sourceFeature.Fields.FieldCount; i++)
302 | {
303 | IField field = sourceFeature.Fields.get_Field(i);
304 | if (field.Type != esriFieldType.esriFieldTypeOID && field.Type != esriFieldType.esriFieldTypeGeometry && field.Type != esriFieldType.esriFieldTypeGlobalID && field.Type != esriFieldType.esriFieldTypeGUID)
305 | {
306 | string fieldName = field.Name;
307 | int index = targetFeature.Fields.FindField(fieldName);
308 | if (index > -1 && fieldName != "Shape_Length" && fieldName != "Shape_Area")
309 | targetFeature.set_Value(index, sourceFeature.get_Value(i));
310 | }
311 |
312 | }
313 | //setAdd.Add(targetFeature);
314 | featureClassWrite.WriteFeature(targetFeature);
315 | sourceFeature = cursor.NextFeature();
316 |
317 | }
318 | //featureClassWrite.WriteFeatures(setAdd);//与WriteFeature没啥效率上的区别
319 | ComReleaser.ReleaseCOMObject(cursor);
320 |
321 | IFeatureClassManage targetFeatureClassManage = targetFeatureClass as IFeatureClassManage;
322 | targetFeatureClassManage.UpdateExtent();
323 | }
324 | }
325 | }
326 |
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/Form1.resx:
--------------------------------------------------------------------------------
1 |
2 |
3 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
109 | text/microsoft-resx
110 |
111 |
112 | 2.0
113 |
114 |
115 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
116 |
117 |
118 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
119 |
120 |
121 | 17, 17
122 |
123 |
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/Program.cs:
--------------------------------------------------------------------------------
1 | using ESRI.ArcGIS;
2 | using System;
3 | using System.Collections.Generic;
4 | using System.Linq;
5 | using System.Threading.Tasks;
6 | using System.Windows.Forms;
7 |
8 | namespace insertingFeatures
9 | {
10 | static class Program
11 | {
12 | ///
13 | /// The main entry point for the application.
14 | ///
15 | [STAThread]
16 | static void Main()
17 | {
18 | if (!RuntimeManager.Bind(ProductCode.Desktop))
19 | {
20 |
21 | MessageBox.Show("Unable to bind to ArcGIS runtime. Application will be shut down.");
22 | return;
23 |
24 | }
25 | ESRI.ArcGIS.esriSystem.IAoInitialize ao = new ESRI.ArcGIS.esriSystem.AoInitialize();
26 | ao.Initialize(ESRI.ArcGIS.esriSystem.esriLicenseProductCode.esriLicenseProductCodeAdvanced);
27 | Application.EnableVisualStyles();
28 | Application.SetCompatibleTextRenderingDefault(false);
29 | Application.Run(new Form1());
30 | }
31 | }
32 | }
33 |
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.CompilerServices;
3 | using System.Runtime.InteropServices;
4 |
5 | // General Information about an assembly is controlled through the following
6 | // set of attributes. Change these attribute values to modify the information
7 | // associated with an assembly.
8 | [assembly: AssemblyTitle("insertingFeatures")]
9 | [assembly: AssemblyDescription("")]
10 | [assembly: AssemblyConfiguration("")]
11 | [assembly: AssemblyCompany("")]
12 | [assembly: AssemblyProduct("insertingFeatures")]
13 | [assembly: AssemblyCopyright("Copyright © 2017")]
14 | [assembly: AssemblyTrademark("")]
15 | [assembly: AssemblyCulture("")]
16 |
17 | // Setting ComVisible to false makes the types in this assembly not visible
18 | // to COM components. If you need to access a type in this assembly from
19 | // COM, set the ComVisible attribute to true on that type.
20 | [assembly: ComVisible(false)]
21 |
22 | // The following GUID is for the ID of the typelib if this project is exposed to COM
23 | [assembly: Guid("66ca6f96-eeb7-4c3c-b9a6-f888322a8680")]
24 |
25 | // Version information for an assembly consists of the following four values:
26 | //
27 | // Major Version
28 | // Minor Version
29 | // Build Number
30 | // Revision
31 | //
32 | // You can specify all the values or you can default the Build and Revision Numbers
33 | // by using the '*' as shown below:
34 | // [assembly: AssemblyVersion("1.0.*")]
35 | [assembly: AssemblyVersion("1.0.0.0")]
36 | [assembly: AssemblyFileVersion("1.0.0.0")]
37 |
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/Properties/Resources.Designer.cs:
--------------------------------------------------------------------------------
1 | //------------------------------------------------------------------------------
2 | //
3 | // This code was generated by a tool.
4 | // Runtime Version:4.0.30319.42000
5 | //
6 | // Changes to this file may cause incorrect behavior and will be lost if
7 | // the code is regenerated.
8 | //
9 | //------------------------------------------------------------------------------
10 |
11 | namespace insertingFeatures.Properties
12 | {
13 |
14 |
15 | ///
16 | /// A strongly-typed resource class, for looking up localized strings, etc.
17 | ///
18 | // This class was auto-generated by the StronglyTypedResourceBuilder
19 | // class via a tool like ResGen or Visual Studio.
20 | // To add or remove a member, edit your .ResX file then rerun ResGen
21 | // with the /str option, or rebuild your VS project.
22 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
23 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
24 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
25 | internal class Resources
26 | {
27 |
28 | private static global::System.Resources.ResourceManager resourceMan;
29 |
30 | private static global::System.Globalization.CultureInfo resourceCulture;
31 |
32 | [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
33 | internal Resources()
34 | {
35 | }
36 |
37 | ///
38 | /// Returns the cached ResourceManager instance used by this class.
39 | ///
40 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
41 | internal static global::System.Resources.ResourceManager ResourceManager
42 | {
43 | get
44 | {
45 | if ((resourceMan == null))
46 | {
47 | global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("insertingFeatures.Properties.Resources", typeof(Resources).Assembly);
48 | resourceMan = temp;
49 | }
50 | return resourceMan;
51 | }
52 | }
53 |
54 | ///
55 | /// Overrides the current thread's CurrentUICulture property for all
56 | /// resource lookups using this strongly typed resource class.
57 | ///
58 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
59 | internal static global::System.Globalization.CultureInfo Culture
60 | {
61 | get
62 | {
63 | return resourceCulture;
64 | }
65 | set
66 | {
67 | resourceCulture = value;
68 | }
69 | }
70 | }
71 | }
72 |
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/Properties/Resources.resx:
--------------------------------------------------------------------------------
1 |
2 |
3 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 | text/microsoft-resx
107 |
108 |
109 | 2.0
110 |
111 |
112 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
113 |
114 |
115 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
116 |
117 |
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/Properties/Settings.Designer.cs:
--------------------------------------------------------------------------------
1 | //------------------------------------------------------------------------------
2 | //
3 | // This code was generated by a tool.
4 | // Runtime Version:4.0.30319.42000
5 | //
6 | // Changes to this file may cause incorrect behavior and will be lost if
7 | // the code is regenerated.
8 | //
9 | //------------------------------------------------------------------------------
10 |
11 | namespace insertingFeatures.Properties
12 | {
13 |
14 |
15 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
16 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "11.0.0.0")]
17 | internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase
18 | {
19 |
20 | private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
21 |
22 | public static Settings Default
23 | {
24 | get
25 | {
26 | return defaultInstance;
27 | }
28 | }
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/Properties/Settings.settings:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/bin/Debug/ESRI.ArcGIS.ADF.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/xinying180/InsertingFeatures/bdb543fcd11a86d8324e8854f1a4d2766fa89ca3/insertingFeatures/insertingFeatures/bin/Debug/ESRI.ArcGIS.ADF.dll
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/bin/Debug/insertingFeatures.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/xinying180/InsertingFeatures/bdb543fcd11a86d8324e8854f1a4d2766fa89ca3/insertingFeatures/insertingFeatures/bin/Debug/insertingFeatures.exe
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/bin/Debug/insertingFeatures.exe.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/bin/Debug/insertingFeatures.pdb:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/xinying180/InsertingFeatures/bdb543fcd11a86d8324e8854f1a4d2766fa89ca3/insertingFeatures/insertingFeatures/bin/Debug/insertingFeatures.pdb
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/bin/Debug/insertingFeatures.vshost.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/xinying180/InsertingFeatures/bdb543fcd11a86d8324e8854f1a4d2766fa89ca3/insertingFeatures/insertingFeatures/bin/Debug/insertingFeatures.vshost.exe
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/bin/Debug/insertingFeatures.vshost.exe.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/bin/Debug/insertingFeatures.vshost.exe.manifest:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/bin/Debug/test.gdb/a00000001.TablesByName.atx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/xinying180/InsertingFeatures/bdb543fcd11a86d8324e8854f1a4d2766fa89ca3/insertingFeatures/insertingFeatures/bin/Debug/test.gdb/a00000001.TablesByName.atx
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/bin/Debug/test.gdb/a00000001.freelist:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/xinying180/InsertingFeatures/bdb543fcd11a86d8324e8854f1a4d2766fa89ca3/insertingFeatures/insertingFeatures/bin/Debug/test.gdb/a00000001.freelist
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/bin/Debug/test.gdb/a00000001.gdbindexes:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/xinying180/InsertingFeatures/bdb543fcd11a86d8324e8854f1a4d2766fa89ca3/insertingFeatures/insertingFeatures/bin/Debug/test.gdb/a00000001.gdbindexes
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/bin/Debug/test.gdb/a00000001.gdbtable:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/xinying180/InsertingFeatures/bdb543fcd11a86d8324e8854f1a4d2766fa89ca3/insertingFeatures/insertingFeatures/bin/Debug/test.gdb/a00000001.gdbtable
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/bin/Debug/test.gdb/a00000001.gdbtablx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/xinying180/InsertingFeatures/bdb543fcd11a86d8324e8854f1a4d2766fa89ca3/insertingFeatures/insertingFeatures/bin/Debug/test.gdb/a00000001.gdbtablx
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/bin/Debug/test.gdb/a00000002.gdbtable:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/xinying180/InsertingFeatures/bdb543fcd11a86d8324e8854f1a4d2766fa89ca3/insertingFeatures/insertingFeatures/bin/Debug/test.gdb/a00000002.gdbtable
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/bin/Debug/test.gdb/a00000002.gdbtablx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/xinying180/InsertingFeatures/bdb543fcd11a86d8324e8854f1a4d2766fa89ca3/insertingFeatures/insertingFeatures/bin/Debug/test.gdb/a00000002.gdbtablx
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/bin/Debug/test.gdb/a00000003.gdbindexes:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/xinying180/InsertingFeatures/bdb543fcd11a86d8324e8854f1a4d2766fa89ca3/insertingFeatures/insertingFeatures/bin/Debug/test.gdb/a00000003.gdbindexes
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/bin/Debug/test.gdb/a00000003.gdbtable:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/xinying180/InsertingFeatures/bdb543fcd11a86d8324e8854f1a4d2766fa89ca3/insertingFeatures/insertingFeatures/bin/Debug/test.gdb/a00000003.gdbtable
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/bin/Debug/test.gdb/a00000003.gdbtablx:
--------------------------------------------------------------------------------
1 | $
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/bin/Debug/test.gdb/a00000004.CatItemsByPhysicalName.atx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/xinying180/InsertingFeatures/bdb543fcd11a86d8324e8854f1a4d2766fa89ca3/insertingFeatures/insertingFeatures/bin/Debug/test.gdb/a00000004.CatItemsByPhysicalName.atx
--------------------------------------------------------------------------------
/insertingFeatures/insertingFeatures/bin/Debug/test.gdb/a00000004.CatItemsByType.atx:
--------------------------------------------------------------------------------
1 | {70737809-852C-4A03-9E22-2CECEA5B9BFA}{C673FE0F-7280-404F-8532-20755DD8FC06}{F3783E6F-65CA-4514-8315-CE3985DAD3B1} &