管道基础大数据平台系统开发-【CS】-ExportMap
13693261870
2024-07-18 5841423dd021e2d070cff5d3cbca8849ae89fa93
添加实体类
已添加5个文件
已修改2个文件
181 ■■■■■ 文件已修改
SimuTools/App.config 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SimuTools/Domain/Duration.cs 23 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SimuTools/Domain/Extension.cs 49 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SimuTools/Domain/Layer.cs 41 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SimuTools/Domain/Terrain.cs 37 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SimuTools/Domain/Water.cs 20 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SimuTools/SimuTools.csproj 10 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SimuTools/App.config
@@ -1,6 +1,7 @@
<?xml version="1.0"?>
<configuration>
  <appSettings>
    <add key="ver" value="0.1"/>
    <add key="sizes" value="64,128,256,512,1024,2048"/>
  </appSettings>
  <startup> 
SimuTools/Domain/Duration.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,23 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace SimuTools.Domain
{
    public class Duration
    {
        private long start { set; get; }
        private long end { set; get; }
        public Duration() { }
        public Duration(long start, long end)
        {
            this.start = start;
            this.end = end;
        }
    }
}
SimuTools/Domain/Extension.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,49 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace SimuTools.Domain
{
    public class Extension
    {
        private double minx { set; get; }
        private double miny { set; get; }
        private double maxx { set; get; }
        private double maxy { set; get; }
        private double minHeight { set; get; }
        private double maxHeight { set; get; }
        public Extension() { }
        public Extension(double minx, double miny, double maxx, double maxy)
        {
            this.minx = minx;
            this.miny = miny;
            this.maxx = maxx;
            this.maxy = maxy;
        }
        public Extension(double minHeight, double maxHeight)
        {
            this.minHeight = minHeight;
            this.maxHeight = maxHeight;
        }
        public Extension(double minx, double miny, double maxx, double maxy, double minHeight, double maxHeight)
        {
            this.minx = minx;
            this.miny = miny;
            this.maxx = maxx;
            this.maxy = maxy;
            this.minHeight = minHeight;
            this.maxHeight = maxHeight;
        }
    }
}
SimuTools/Domain/Layer.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,41 @@
using System;
using System.Collections.Generic;
using System.Configuration;
using System.Linq;
using System.Net.NetworkInformation;
using System.Text;
using System.Threading.Tasks;
namespace SimuTools.Domain
{
    public class Layer
    {
        private String version { set; get; }
        private Duration duration { set; get; }
        private Extension extension { set; get; }
        private Terrain terrain { set; get; }
        private Water waters { set; get; }
        public Layer()
        {
            string ver = ConfigurationManager.AppSettings["ver"];
            if (!string.IsNullOrEmpty(ver))
            {
                this.version = ver;
            }
        }
        public Layer(string version, Duration duration, Extension extension, Terrain terrain, Water waters)
        {
            this.version = version;
            this.duration = duration;
            this.extension = extension;
            this.terrain = terrain;
            this.waters = waters;
        }
    }
}
SimuTools/Domain/Terrain.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,37 @@
using System;
using System.Collections.Generic;
using System.Configuration;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace SimuTools.Domain
{
    public class Terrain
    {
        private List<int[]> size { set; get; }
        public Terrain()
        {
            size = new List<int[]>();
            string str = ConfigurationManager.AppSettings["sizes"];
            if (string.IsNullOrEmpty(str)) return;
            string[] strs = str.Split(',');
            foreach (string s in strs)
            {
                int i;
                if (int.TryParse(s, out i))
                {
                    size.Add(new int[] { i, i });
                }
            }
        }
        public Terrain(List<int[]> size)
        {
            this.size = size;
        }
    }
}
SimuTools/Domain/Water.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,20 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace SimuTools.Domain
{
    public class Water
    {
        private List<long> data { set; get; }
        public Water() { }
        public Water(List<long> data)
        {
            this.data = data;
        }
    }
}
SimuTools/SimuTools.csproj
@@ -38,6 +38,7 @@
      <HintPath>dlls\log4net4.dll</HintPath>
    </Reference>
    <Reference Include="System" />
    <Reference Include="System.Configuration" />
    <Reference Include="System.Core" />
    <Reference Include="System.Xml.Linq" />
    <Reference Include="System.Data.DataSetExtensions" />
@@ -49,6 +50,11 @@
    <Reference Include="System.Xml" />
  </ItemGroup>
  <ItemGroup>
    <Compile Include="Domain\Duration.cs" />
    <Compile Include="Domain\Extension.cs" />
    <Compile Include="Domain\Layer.cs" />
    <Compile Include="Domain\Terrain.cs" />
    <Compile Include="Domain\Water.cs" />
    <Compile Include="FrmMain.cs">
      <SubType>Form</SubType>
    </Compile>
@@ -98,9 +104,7 @@
    <Content Include="dlls\osr_csharp.dll" />
    <Content Include="dlls\osr_wrap.dll" />
  </ItemGroup>
  <ItemGroup>
    <Folder Include="Domain\" />
  </ItemGroup>
  <ItemGroup />
  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
  <!-- To modify your build process, add your task inside one of the targets below and uncomment it. 
       Other similar extension points exist, see Microsoft.Common.targets.