FieldType enum
Defines a key-value field of a robots.txt
file specifying a rule.
Values
- userAgent → const FieldType
-
A field specifying the user-agent the following fields apply to.
const FieldType(key: 'User-agent', example: '*')
- disallow → const FieldType
-
A field explicitly disallowing a user-agent to visit a path.
const FieldType(key: 'Disallow', example: '/')
- allow → const FieldType
-
A field explicitly allowing a user-agent to visit a path.
const FieldType(key: 'Allow', example: '/file.txt')
- sitemap → const FieldType
-
A field specifying the location of a sitemap of a website.
const FieldType(key: 'Sitemap', example: 'https://example.com/sitemap.xml')
- crawlDelay → const FieldType
-
A field specifying a delay that crawlers should take into account when crawling the website.
const FieldType(key: 'Crawl-delay', example: '10')
- host → const FieldType
-
A field specifying the preferred domain for a website with multiple mirrors.
const FieldType(key: 'Host', example: 'https://hosting.example.com')
Properties
- example → String
-
An example of a field definition. Used for testing.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- index → int
-
A numeric identifier for the enumerated value.
no setterinherited
- key → String
-
The name of the field key.
final
- name → String
-
Available on Enum, provided by the EnumName extension
The name of the enum value.no setter - runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toField(
[String? value]) → String -
Converts a
FieldType
to arobots.txt
field. -
toString(
) → String -
A string representation of this object.
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Properties
- defaultFieldNameExpression → String
-
A partial regular expression defining a union of the default field names.
final