public StaticFileContext(HttpContext context, StaticFileOptions options, PathString matchUrl, ILogger logger)
        {
            _context = context;
            _options = options;
            _matchUrl = matchUrl;
            _request = context.Request;
            _response = context.Response;
            _logger = logger;
            _requestHeaders = _request.GetTypedHeaders();
            _responseHeaders = _response.GetTypedHeaders();

            _method = null;
            _isGet = false;
            _isHead = false;
            _subPath = PathString.Empty;
            _contentType = null;
            _fileInfo = null;
            _length = 0;
            _lastModified = new DateTimeOffset();
            _etag = null;
            _ifMatchState = PreconditionState.Unspecified;
            _ifNoneMatchState = PreconditionState.Unspecified;
            _ifModifiedSinceState = PreconditionState.Unspecified;
            _ifUnmodifiedSinceState = PreconditionState.Unspecified;
            _ranges = null;
        }
Example #2
0
 public ReadConditionalReqeustDirective()
 {
     typedHeaders = request.GetTypedHeaders();
 }
Example #3
0
 public ReadCacheRequestDirective()
 {
     typedHeaders = request.GetTypedHeaders();
 }