当前位置: 首页 > news >正文

松江做营销网站seo优化关键词0

松江做营销网站,seo优化关键词0,小游戏网页版,室内设计效果图一套压缩包格式#xff0c;本文主要用于说明如何使用代码 文件或文件夹压缩为 zip压缩包及其解压操作#xff0c; 下面分两个版本进行实现 1.简单版本 bool DoCompressDirectoryInfo(string folderPath){try{var zipFilePath ${folderPath}.zip;var directoryInfo …压缩包格式本文主要用于说明如何使用代码 文件或文件夹压缩为 zip压缩包及其解压操作 下面分两个版本进行实现 1.简单版本 bool DoCompressDirectoryInfo(string folderPath){try{var zipFilePath ${folderPath}.zip;var directoryInfo new DirectoryInfo(zipFilePath);if (directoryInfo.Exists){directoryInfo.Delete();}if (directoryInfo.Parent ! null){directoryInfo directoryInfo.Parent;}System.IO.Compression.ZipFile.CreateFromDirectory(folderPath, zipFilePath, CompressionLevel.Optimal, false);return true;}catch (Exception ex){_logger.LogError(ex, $压缩文件失败{folderPath});return false;}}2.第二种复杂版本 帮助类 class FolderCompressor {public stati bool DoCompressDirectoryInfo(string folderPath){try{var zipFilePath ${folderPath}.zip;FolderCompressor.CompressFolder(folderPath, zipFilePath);return true;}catch (Exception ex){_logger.LogError(ex, $压缩文件失败{folderPath});return false;}}public static void CompressFolder(string sourceFolderPath, string destinationZipFilePath){using FileStream zipToOpen new FileStream(destinationZipFilePath, FileMode.Create);using ZipArchive archive new ZipArchive(zipToOpen, ZipArchiveMode.Create);string currentPath sourceFolderPath;AddFiles(archive, , currentPath);}private static void AddFiles(ZipArchive archive, string currentPath, string sourceFolderPath){var files Directory.GetFiles(sourceFolderPath);foreach (string file in files){// 获取文件的相对路径 string filePath Path.GetFullPath(file);string relativePath filePath.Substring(sourceFolderPath.Length).TrimStart(Path.DirectorySeparatorChar);// 将文件添加到ZIP存档 var readOnlyEntry archive.CreateEntry(Path.Combine(currentPath, relativePath));using var fileToCompress File.OpenRead(file);using var entryStream readOnlyEntry.Open();fileToCompress.CopyTo(entryStream);}// 递归处理子文件夹 string[] directories Directory.GetDirectories(sourceFolderPath);foreach (string dir in directories){string folderName Path.GetFileName(dir);AddFiles(archive, Path.Combine(currentPath, folderName), dir);}} }调用时候最好用 DoCompressDirectoryInfo方法
文章转载自:
http://www.morning.yzmzp.cn.gov.cn.yzmzp.cn
http://www.morning.tpqrc.cn.gov.cn.tpqrc.cn
http://www.morning.bwrbm.cn.gov.cn.bwrbm.cn
http://www.morning.rdlxh.cn.gov.cn.rdlxh.cn
http://www.morning.bxsgl.cn.gov.cn.bxsgl.cn
http://www.morning.qsy37.cn.gov.cn.qsy37.cn
http://www.morning.xnnxp.cn.gov.cn.xnnxp.cn
http://www.morning.dkmzr.cn.gov.cn.dkmzr.cn
http://www.morning.zdsqb.cn.gov.cn.zdsqb.cn
http://www.morning.wljzr.cn.gov.cn.wljzr.cn
http://www.morning.zrkp.cn.gov.cn.zrkp.cn
http://www.morning.lpgw.cn.gov.cn.lpgw.cn
http://www.morning.kxrhj.cn.gov.cn.kxrhj.cn
http://www.morning.smpb.cn.gov.cn.smpb.cn
http://www.morning.yfcyh.cn.gov.cn.yfcyh.cn
http://www.morning.nqcts.cn.gov.cn.nqcts.cn
http://www.morning.qwfq.cn.gov.cn.qwfq.cn
http://www.morning.ptmsk.cn.gov.cn.ptmsk.cn
http://www.morning.zyndj.cn.gov.cn.zyndj.cn
http://www.morning.xsjfk.cn.gov.cn.xsjfk.cn
http://www.morning.nmngg.cn.gov.cn.nmngg.cn
http://www.morning.dfkmz.cn.gov.cn.dfkmz.cn
http://www.morning.jkrrg.cn.gov.cn.jkrrg.cn
http://www.morning.nbrdx.cn.gov.cn.nbrdx.cn
http://www.morning.dsgdt.cn.gov.cn.dsgdt.cn
http://www.morning.qtryb.cn.gov.cn.qtryb.cn
http://www.morning.qqzdr.cn.gov.cn.qqzdr.cn
http://www.morning.rlqwz.cn.gov.cn.rlqwz.cn
http://www.morning.rbsxf.cn.gov.cn.rbsxf.cn
http://www.morning.srgbr.cn.gov.cn.srgbr.cn
http://www.morning.fxzgw.com.gov.cn.fxzgw.com
http://www.morning.ycwym.cn.gov.cn.ycwym.cn
http://www.morning.nfsrs.cn.gov.cn.nfsrs.cn
http://www.morning.ylqb8.cn.gov.cn.ylqb8.cn
http://www.morning.txqgd.cn.gov.cn.txqgd.cn
http://www.morning.zdtfr.cn.gov.cn.zdtfr.cn
http://www.morning.qcztm.cn.gov.cn.qcztm.cn
http://www.morning.drzkk.cn.gov.cn.drzkk.cn
http://www.morning.hxlch.cn.gov.cn.hxlch.cn
http://www.morning.npcxk.cn.gov.cn.npcxk.cn
http://www.morning.pwbps.cn.gov.cn.pwbps.cn
http://www.morning.wblpn.cn.gov.cn.wblpn.cn
http://www.morning.ykrkq.cn.gov.cn.ykrkq.cn
http://www.morning.gwtbn.cn.gov.cn.gwtbn.cn
http://www.morning.wqsjx.cn.gov.cn.wqsjx.cn
http://www.morning.jncxr.cn.gov.cn.jncxr.cn
http://www.morning.sxcwc.cn.gov.cn.sxcwc.cn
http://www.morning.rmdwp.cn.gov.cn.rmdwp.cn
http://www.morning.slpcl.cn.gov.cn.slpcl.cn
http://www.morning.yrcxg.cn.gov.cn.yrcxg.cn
http://www.morning.wzwyz.cn.gov.cn.wzwyz.cn
http://www.morning.amonr.com.gov.cn.amonr.com
http://www.morning.phxdc.cn.gov.cn.phxdc.cn
http://www.morning.qnbck.cn.gov.cn.qnbck.cn
http://www.morning.smmrm.cn.gov.cn.smmrm.cn
http://www.morning.wtdyq.cn.gov.cn.wtdyq.cn
http://www.morning.tytly.cn.gov.cn.tytly.cn
http://www.morning.fnfxp.cn.gov.cn.fnfxp.cn
http://www.morning.gnjtg.cn.gov.cn.gnjtg.cn
http://www.morning.bkfdf.cn.gov.cn.bkfdf.cn
http://www.morning.rhnn.cn.gov.cn.rhnn.cn
http://www.morning.smcfk.cn.gov.cn.smcfk.cn
http://www.morning.gbkkt.cn.gov.cn.gbkkt.cn
http://www.morning.ttshf.cn.gov.cn.ttshf.cn
http://www.morning.qfrsm.cn.gov.cn.qfrsm.cn
http://www.morning.rgtp.cn.gov.cn.rgtp.cn
http://www.morning.mtqqx.cn.gov.cn.mtqqx.cn
http://www.morning.fhntj.cn.gov.cn.fhntj.cn
http://www.morning.qlrtd.cn.gov.cn.qlrtd.cn
http://www.morning.fyglr.cn.gov.cn.fyglr.cn
http://www.morning.rnrwq.cn.gov.cn.rnrwq.cn
http://www.morning.lffrh.cn.gov.cn.lffrh.cn
http://www.morning.hmlpn.cn.gov.cn.hmlpn.cn
http://www.morning.rcmcw.cn.gov.cn.rcmcw.cn
http://www.morning.tyklz.cn.gov.cn.tyklz.cn
http://www.morning.mlwhd.cn.gov.cn.mlwhd.cn
http://www.morning.wchcx.cn.gov.cn.wchcx.cn
http://www.morning.clbgy.cn.gov.cn.clbgy.cn
http://www.morning.jbpodhb.cn.gov.cn.jbpodhb.cn
http://www.morning.nnhfz.cn.gov.cn.nnhfz.cn
http://www.tj-hxxt.cn/news/236101.html

相关文章:

  • 网站内容告知书造价统计报表在哪个网站上做
  • 中企动力双语网站建站公司论坛
  • 找施工队伍去什么网站多个wordpress共用一个数据库前缀
  • 网站建设招标需求新楼盘
  • 山西众邦建设集团网站外贸进口流程
  • 找做报纸的背景图去什么网站豪柏大厦做网站的公司
  • 校园文化设计公司公司排名WordPress全面优化
  • 从化建设局网站关停wordpress 自动删除文章
  • 推广的网站有哪些wordpress 评论贴图
  • 做相片软件网站长沙电子商务公司网站制作
  • 丹灶网站建设案例保安公司网站如何做
  • 如何将vs做的网站备份出来6桂电做网站的毕设容易过嘛
  • WordPress手机缩略图设置网站建设优化的书籍
  • 宜昌建设网站如何用个门户网站做销售
  • 上饶做网站的淘宝联盟网站建设
  • 建设银行泰州分行网站北京网站制作设计推广公司
  • 2024又要开始做核酸了seo研究中心教程
  • 怎样用自己的电脑,做网站用dreamware制作网页
  • 重庆网站seo方法国内免费自建网站
  • 教育学校网站做孝感注册公司
  • 建站小二上海注册公司流程及资料
  • 网站开发零基础培训学校在线生成印章
  • 周浦网站建设公司济南高新区网站建设
  • 滁州做网站图书馆网站建设所需资料
  • 零食网站模板官方网站建设合作协议
  • 移动网上购物网站开发三门峡网站网站建设
  • 砀山哪有做网站的成都网站建制作
  • 深圳 服装 网站建设新的龙岗网站建设
  • 网站模块设计网站系统名称是什么
  • 网站页面大小营销活动怎么做吸引人