-1
我正在調用一個自定義API azure移動服務。由動態模式給出的響應。 我改變了模式,但似乎天青已經緩存了舊模式。如果我更改爲實體類型作爲返回類型,一切正常。但是當我改回動態模式時,azure使用舊模式。有任何想法嗎 ?移動服務緩存
僅供參考,我的動態模式看起來像這樣
[DataContract]
public class HigscoreItem
{
public HigscoreItem(Int32 aq, Int32 sec, string userId, Int32 rank, bool npb, Int32 distance)
{
AnsweredQuestions = aq;
Seconds = sec;
UserId = userId;
Rank = rank;
NewPersonalBest = npb? 1 : 0;
DistanceLeft = distance;
}
[DataMember(Name = "answeredquestions")]
public Int32 AnsweredQuestions;
[DataMember(Name = "seconds")]
public Int32 Seconds;
[DataMember(Name = "userid")]
public string UserId;
[DataMember(Name = "rank")]
public Int32 Rank;
[DataMember(Name = "distanceleft")]
public Int32 DistanceLeft;
[DataMember(Name = "newpersonalbest")]
public Int32 NewPersonalBest;
}
}
MS文檔建議禁用動態模式[鏈接](http://msdn.microsoft.com/zh-cn/ -us/library/jj193175.aspx)http://msdn.microsoft.com/en-us/library/jj193175.aspx在哪裏完成。也許我誤解了動態模式是什麼? – Knutdag 2014-12-11 04:07:15
不便之處:/ int(0)的值不放在JSON數據包中......這就是欺騙我的原因:P。但仍然想知道MS文檔建議禁用動態模式? – Knutdag 2014-12-11 04:20:59