public TransportServiceType() { _mServices = new List <IService>(); _mServiceProperties = new Dictionary <string, IServiceProperty>(); Name = "Transport"; IServiceProperty props = new ServiceProperty { Name = "name", Type = "string", ServiceType = this }; ServiceProperties.Add("name", props); props = new ServiceProperty { Name = "location", Type = "string", ServiceType = this }; ServiceProperties.Add("location", props); props = new ServiceProperty { Name = "price", Type = "double", ServiceType = this }; ServiceProperties.Add("price", props); props = new ServiceProperty { Name = "description", Type = "string", ServiceType = this }; ServiceProperties.Add("description", props); props = new ServiceProperty { Name = "quantity", Type = "double", ServiceType = this }; ServiceProperties.Add("quantity", props); DataHolder.GetInstance().ServiceTypes.Add(this); }
public static ServiceProperties CreateChangeState(string serviceName, string state) { var result = new ServiceProperties(); result.ServiceName = serviceName; result.Add("ServiceState", state); return(result); }