Document<T> class
Document model
Handle all the info of your Prismic.io document
- Annotations
-
- @Freezed(genericArgumentFactories: true)
Constructors
-
Document({required List<
String> tags, required String id, required String lang, required String type, @JsonKey(name: 'alternate_languages') List<AlternateLanguage> ? alternateLanguages, @JsonKey(name: 'first_publication_date') String? firstPublicationDate, @JsonKey(name: 'last_publication_date') String? lastPublicationDate, @JsonKey(name: 'linked_documents') List<String> ? linkedDocuments, T? data, List<String> ? slugs, String? href, String? uid}) -
Deafult factory constructor for Document
factory
-
Document.fromJson(Map<
String, dynamic> json, T fromJsonT(Object? json)) -
Creates a Document object from json
factory
Properties
-
alternateLanguages
→ List<
AlternateLanguage> ? -
no setterinherited
-
copyWith
→ $DocumentCopyWith<
T, Document< T> > -
no setterinherited
- data → T?
-
no setterinherited
- firstPublicationDate → String?
-
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- href → String?
-
no setterinherited
- id → String
-
no setterinherited
- lang → String
-
no setterinherited
- lastPublicationDate → String?
-
no setterinherited
-
linkedDocuments
→ List<
String> ? -
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
slugs
→ List<
String> ? -
no setterinherited
-
no setterinherited
- type → String
-
no setterinherited
- uid → String?
-
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
Object? toJsonT(T)) → Map< String, dynamic> - Temporary fix to include Document in custom model
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited