0
有,在GeoServer的創造了新的類型特徵代碼:如何用HttpClient對象調用或某些類似方法替換curl調用?
string par = @"/c D:\curl-7.32.0-ssl-sspi-zlib-static-bin-w32\curl.exe -v -u admin:MYPASSWORD -XPOST -H ""Content-type: text/xml"" -d ""<featureType><name>" + name + @"</name><title>" + MyHtmlEncode(title) + @"</title></featureType>"" http://localhost:8080/geoserver/rest/workspaces/cite/datastores/postgis/featuretypes";
Process P = Process.Start(@"C:\Windows\System32\cmd.exe",par);
我想讀服務器的輸出和處理錯誤,他們說我應該HttpClient
取代捲曲,但我不知道怎麼形容授權(-u admin:MYPASSWORD
)。