Exemple #1
0
        public static string GetStrategyXmlName(WorkspaceDef wksdef)
        {
            string wkddir   = MifEnvironment.GetWorkspaceDir();
            string identify = wksdef.Identify;
            string filedir  = Path.Combine(wkddir, identify);
            string filename = Path.Combine(filedir, string.Format("StrategyFilter_{0}.xml", identify));

            return(filename);
        }
 private void BuildInternalBuffer()
 {
     if (_identify.IsOutput2WorkspaceDir)
     {
         _fileName = GetWorkspaceFileName(_identify);
     }
     else
     {
         _fileName = MifEnvironment.GetFullFileName(_identify.ToLongString() + ".dat");
     }
     BuildInternalBuffer(_fileName);
 }
        public static string GetWorkspaceFileName(RasterIdentify identify)
        {
            string dir = Path.Combine(MifEnvironment.GetWorkspaceDir(), identify.ProductIdentify);

            if (!Directory.Exists(dir))
            {
                Directory.CreateDirectory(dir);
            }
            dir = Path.Combine(dir, DateTime.Now.ToString("yyyy-MM-dd"));
            if (!Directory.Exists(dir))
            {
                Directory.CreateDirectory(dir);
            }
            return(identify.ToWksFullFileName(".dat"));
        }
Exemple #4
0
        private string GetWksFileDir(string extName)
        {
            string prdIdentify = (ProductIdentify ?? "NULL");
            string productTime = DateTime.Now.ToString("yyyy-MM-dd");
            string dir         = Path.Combine(MifEnvironment.GetWorkspaceDir(), prdIdentify);

            if (!Directory.Exists(dir))
            {
                Directory.CreateDirectory(dir);
            }
            dir = Path.Combine(dir, productTime);
            if (!Directory.Exists(dir))
            {
                Directory.CreateDirectory(dir);
            }
            dir = Path.Combine(dir, GetProductClass(extName));
            if (!Directory.Exists(dir))
            {
                Directory.CreateDirectory(dir);
            }
            return(dir);
        }
Exemple #5
0
 protected string GetWorkspaceDir(string pro, string subPro)
 {
     return(MifEnvironment.GetWorkspaceDir() + "\\" + pro + "\\");
 }