This commit is contained in:
Alex Ford 2023-06-23 13:11:00 +01:00
Родитель f8140bcad3
Коммит 4f9f41acd5
2 изменённых файлов: 5 добавлений и 0 удалений

Просмотреть файл

@ -94,12 +94,16 @@ module App {
* proc that takes a single `env` argument and returns a rack response.
*/
abstract class App extends TApp {
/** Gets a textual representation of this element. */
string toString() { result = "Rack application" }
/** Gets the `DataFlow::CallableNode` that will handle requests to this app. */
abstract CallNode getCall();
/** Gets the response returned from a request to this app. */
RP::PotentialResponseNode getResponse() { result = this.getCall().getResponse() }
/** Gets the `env` parameter passed to this app when it handles a request. */
DataFlow::ParameterNode getEnv() { result = this.getCall().getParameter(0) }
}

Просмотреть файл

@ -99,6 +99,7 @@ module Public {
result = getHeaderValue(this, "content-type")
}
/** Gets the headers returned with this response. */
DataFlow::Node getHeaders() { result = this.(Private::PotentialResponseNode).getHeaders() }
// TODO: is there a sensible value for this?