//////////////////////////////////////////////////////////////////////////// //--------------------------------- REVISIONS ------------------------------ // Date Name Tracking # Description // --------- ------------------- ------------- ---------------------- // 21JUN2009 James Shen Initial Creation //////////////////////////////////////////////////////////////////////////// /** * get all records based on search condition in give map layer. * @param index the index of given map layer. * @param findConditions the search condition. * @return a hashtable of all matched record.the key is the mapInfo ID. * @ */ public Hashtable Search(int index, FindConditions findConditions) { if (_geoSet != null) { return(_geoSet.Search(index, findConditions)); } return(null); }
//////////////////////////////////////////////////////////////////////////// //--------------------------------- REVISIONS ------------------------------ // Date Name Tracking # Description // --------- ------------------- ------------- ---------------------- // 21JUN2009 James Shen Initial Creation //////////////////////////////////////////////////////////////////////////// /** * get all records based on search condition in give map layer. * @param index the index of given map layer. * @param findConditions the search condition. * @return a hashtable of all matched record.the key is the mapInfo ID. * @ */ public Hashtable Search(int index, FindConditions findConditions) { lock (_mapFeatureLayers) { MapFeatureLayer mapLayer = GetMapFeatureLayer(index); if (mapLayer != null) { return(mapLayer.Search(findConditions)); } return(null); } }
//////////////////////////////////////////////////////////////////////////// //--------------------------------- REVISIONS ------------------------------ // Date Name Tracking # Description // --------- ------------------- ------------- ---------------------- // 21JUN2009 James Shen Initial Creation //////////////////////////////////////////////////////////////////////////// /** * get all records based on given string. the seach will search based on * map layer's key field. * @param matchString * @return a hashtable array Contains of all matched record. * the key is the mapInfo ID. the value is the matched string. * @ */ public Hashtable[] Search(string matchString) { lock (_mapFeatureLayers) { Hashtable[] retTable = new Hashtable[_mapFeatureLayers.Count]; for (int i = 0; i < _mapFeatureLayers.Count; i++) { MapFeatureLayer mapLayer = (MapFeatureLayer)_mapFeatureLayers[i]; FindConditions findConditions = new FindConditions(); findConditions.AddCondition(mapLayer.DataTable.GetFieldIndex(mapLayer.KeyField.GetName()), matchString); retTable[i] = mapLayer.Search(findConditions); } return(retTable); } }
//////////////////////////////////////////////////////////////////////////// //--------------------------------- REVISIONS ------------------------------ // Date Name Tracking # Description // --------- ------------------- ------------- ---------------------- // 21JUN2009 James Shen Initial Creation //////////////////////////////////////////////////////////////////////////// /** * get all records based on search condition. * @param findConditions the search condition. * @return a hashtable of all matched record.the key is the mapInfo ID. the * value is the matched string. */ public Hashtable Search(FindConditions findConditions) { return(_mapFile.Search(findConditions)); }