コード例 #1
0
 public IWaterOneFlowParser GetParser(DataServiceInfo dataService)
 {
     IWaterOneFlowParser parser;
     switch (dataService.Version.ToString("F1", CultureInfo.InvariantCulture))
     {
         case "1.0":
             parser = new WaterOneFlow10Parser();
             break;
         case "1.1":
             parser = new WaterOneFlow11Parser();
             break;
         case "2.0":
             parser = new WaterOneFlow20Parser();
             break;
         default:
             parser = new WaterOneFlow11Parser();
             break;
     }
     return parser;
 }
コード例 #2
0
 /// <summary>
 /// Creates a new instance of a WaterOneFlow client for accessing REST services
 /// </summary>
 public RestWaterOneFlowClient()
 {
     _parser           = new WaterOneFlow10Parser();
     DownloadDirectory = Path.Combine(Path.GetTempPath(), "HydroDesktop");
 }
コード例 #3
0
 /// <summary>
 /// Creates a new instance of a WaterOneFlow client for accessing REST services
 /// </summary>
 public RestWaterOneFlowClient()
 {
     _parser = new WaterOneFlow10Parser();
     DownloadDirectory = Path.Combine(Path.GetTempPath(), "HydroDesktop");
 }