Пример #1
0
        private static IssueRowWriter CreateRowWriter(
            [NotNull] string className,
            [NotNull] IFeatureWorkspace featureWorkspace,
            [NotNull] IIssueTableFieldManagement fields,
            [CanBeNull] string aliasName = null)
        {
            ITable table = CreateTable(className, featureWorkspace, fields);

            if (StringUtils.IsNotEmpty(aliasName))
            {
                DatasetUtils.TrySetAliasName(table, aliasName);
            }

            var attributeWriter = new IssueAttributeWriter(table, fields);

            return(new IssueRowWriter((IObjectClass)table, attributeWriter));
        }
Пример #2
0
        private static IssueFeatureWriter CreateFeatureWriter(
            [NotNull] string className,
            [NotNull] IFeatureWorkspace featureWorkspace,
            [NotNull] IIssueTableFieldManagement fields,
            esriGeometryType geometryType,
            [NotNull] ISpatialReference spatialReference,
            double gridSize1, double gridSize2, double gridSize3,
            [NotNull] string aliasName)
        {
            IFeatureClass featureClass = CreateFeatureClass(className, featureWorkspace,
                                                            fields, geometryType,
                                                            spatialReference,
                                                            gridSize1, gridSize2, gridSize3);

            DatasetUtils.TrySetAliasName(featureClass, aliasName);

            var attributeWriter = new IssueAttributeWriter((ITable)featureClass, fields);

            return(new IssueFeatureWriter(featureClass, attributeWriter));
        }