public void ProcessRequest(HttpContext context) { using (QueryContainer qc = new QueryContainer()) { string query = context.Request["q"]; string type = context.Request["type"]; string[] lots; switch (type) { case "active": lots = qc.GetActiveContainerNames(query); break; case "hold": lots = qc.GetHoldContainerNames(query); break; case "all": default: lots = qc.GetAllContainerNames(query); break; } context.Response.ContentType = "text/plain"; context.Response.Write(QueryContainer.GetStringWithNewLine(lots)); } }