Static class

Spry static

Constructors

Static({required Iterable<String> directories, String? prefix, Iterable<String> defaultFiles = const <String>[]})
Create a new static
factory
Static.directory({required String directory, Iterable<String> defaultFiles = const <String>[], String? prefix})
Create a new static from a directory.
factory
Static.raw({required Iterable<String> directories, required PathMatcher matcher, Iterable<String> defaultFiles = const <String>[]})
Create a new static from raw parameters.
const

Properties

defaultFiles Iterable<String>
Default file to serve when a directory is requested.
final
directories Iterable<String>
Directories to serve static files from.
final
hashCode int
The hash code for this object.
no setterinherited
matcher → PathMatcher
Path matcher.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

call(Context context) Future<void>
Handle a spry request.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toMiddleware({bool rear = false}) → Middleware
As the static to a spry middleware.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited