public HttpResponseMessage GetPartLayout(PartitionDTO partitionDto) { var partLayout = new ClientPartitionScript { profileId = Convert.ToInt32(partitionDto.imageProfileId), HdNumberToGet = Convert.ToInt32(partitionDto.hdToGet), NewHdSize = partitionDto.newHdSize, ClientHd = partitionDto.clientHd, TaskType = partitionDto.taskType, partitionPrefix = partitionDto.partitionPrefix, clientBlockSize = Convert.ToInt32(partitionDto.lbs) }; _response.Content = new StringContent(partLayout.GeneratePartitionScript(), Encoding.UTF8, "text/plain"); return(_response); }
public void GetPartLayout(string imageProfileId, string hdToGet, string newHdSize, string clientHd, string taskType, string partitionPrefix, string lbs) { if (!Authorize()) { return; } var partLayout = new ClientPartitionScript { profileId = Convert.ToInt32(imageProfileId), HdNumberToGet = Convert.ToInt32(hdToGet), NewHdSize = newHdSize, ClientHd = clientHd, TaskType = taskType, partitionPrefix = partitionPrefix, clientBlockSize = Convert.ToInt32(lbs) }; HttpContext.Current.Response.Write(partLayout.GeneratePartitionScript()); }