namespace OpenAuth.WebApi; public class CommonTopicRequest { /** * The command is sent and the response is matched by the tid and bid fields in the message, * and the reply should keep the tid and bid the same. */ public string tid { get; set; } public string bid { get; set; } public long? timestamp { get; set; } public T data { get; set; } public override string ToString() { return $"CommonTopicRequest{{tid='{tid}', bid='{bid}', timestamp={timestamp}, data={data}}}"; } public CommonTopicRequest SetTid(string tid) { this.tid = tid; return this; } public CommonTopicRequest SetBid(string bid) { this.bid = bid; return this; } public CommonTopicRequest SetTimestamp(long? timestamp) { this.timestamp = timestamp; return this; } public CommonTopicRequest SetData(T data) { this.data = data; return this; } } public class OsdTopicRequest : CommonTopicRequest { public string method { get; set; } public OsdTopicRequest SetTid(string tid) { base.tid = tid; return this; } public OsdTopicRequest SetBid(string bid) { base.bid = bid; return this; } public OsdTopicRequest SetTimestamp(long? timestamp) { base.timestamp = timestamp; return this; } public OsdTopicRequest SetData(T data) { base.data = data; return this; } public OsdTopicRequest SetMethod(string method) { this.method = method; return this; } }