IService で次のデータ コントラクトを定義しています。
[DataContract]
public class PumpClass {
[DataMember]
public int ID { get; set; }
[DataMember]
public double litresPumped { get; set; }
[DataMember]
public double price { get; set; }
[DataMember]
public string fuelType { get; set; }
[DataMember]
public DateTime date { get; set; }
[DataMember]
public bool requestUse { get; set; }
[DataMember]
public bool requestAccepted { get; set; }
[DataMember]
public bool finished { get; set; }
}
[DataContract]
public class DieselTank {
[DataMember]
public double MaximumLevel { get; set; }
[DataMember]
public double WarningLevel { get; set; }
[DataMember]
public double CurrentLevel { get; set; }
[DataMember]
public bool OrderFuel { get; set; }
}
[DataContract]
public class UnleadedTank {
[DataMember]
public double MaximumLevel { get; set; }
[DataMember]
public double WarningLevel { get; set; }
[DataMember]
public double CurrentLevel { get; set; }
[DataMember]
public bool OrderFuel { get; set; }
}
[DataContract]
public class CostOfFuel {
[DataMember]
public double DieselSupplierPrice { get; set; }
[DataMember]
public double DieselPrice { get; set; }
[DataMember]
public double UnleadedSupplierPrice { get; set; }
[DataMember]
public double UnleadedPrice { get; set; }
}
[DataContract]
public class Sale {
[DataMember]
public double value { get; set; }
[DataMember]
public double volumeSold { get; set; }
[DataMember]
public DateTime dateSold { get; set; }
}
[DataContract]
public class Ordered {
[DataMember]
public double volume { get; set; }
[DataMember]
public double cost { get; set; }
}
しかし、このインターフェースを使用する私のサービスからのみPumpClass
、DieselTank
およびUnleadedTank
を見ることができますが、その理由はわかりません。これら 3 つだけが Visual Studio のデータ ソースにも表示されます。