setContainer method

void setContainer(
  1. Container? container
)

Sets the container for this request This is useful for passing data between middleware and the controller but is also necessary as Steward expects the container to be present. If you new up a request manually, you will almost certainly want to set the container yourself.

Implementation

void setContainer(Container? container) {
  if (container != null) {
    this.container = container;
  }
}