コード例 #1
0
        public IArray get_DatasetNames(esriDatasetType DatasetType)
        {
            if (m_sWkspPath == null)
            {
                return(null);
            }

            //HIGHLIGHT: get_DatasetNames - Go through wksString to look for csp files
            if (DatasetType != esriDatasetType.esriDTAny &&
                DatasetType != esriDatasetType.esriDTTable)
            {
                return(null);
            }

            string[] sFiles = System.IO.Directory.GetFiles(m_sWkspPath, "*.csp");
            if (sFiles == null || sFiles.Length == 0)
            {
                return(null);
            }

            IArray datasets = new ArrayClass();

            foreach (string sFileName in sFiles)
            {
                SimplePointDataset ds = new SimplePointDataset(m_sWkspPath, System.IO.Path.GetFileNameWithoutExtension(sFileName));
                datasets.Add(ds);
            }

            return(datasets);
        }
コード例 #2
0
        public IPlugInDatasetHelper OpenDataset(string localName)
        {
            //HIGHLIGHT: OpenDataset - give workspace path and local file name
            if (m_sWkspPath == null)
            {
                return(null);
            }

            SimplePointDataset ds = new SimplePointDataset(m_sWkspPath, localName);

            return((IPlugInDatasetHelper)ds);
        }