2
當供應薩翁:爲什麼選擇savon:屬性!不與對象調用對象的工作
hash = {
"Objects" => { //stuff here },
:attributes! => { "Objects" => {"xsi:type" => "Something"}}
}
我得到:
<Objects>...</Objects>
當別的我得到預期的結果提供薩翁:
hash = {
"foo" => { //stuff here },
:attributes! => { "foo" => {"xsi:type" => "Something"}}
}
我得到:
<foo xsi:type="Something"></foo>
我必須使用字符串「Objects」作爲鍵。我正在編寫第三方SOAP Web服務。我不能使用符號,因爲第一個字母會變成下限。
謝謝,