modddels_annotation_internal library

Classes

ContentFailure
A ContentFailure is the failure of a contentValidation.
DependencyParamAnnotation
EntityFailure
An EntityFailure is a Failure specific to Entities.
Failure
A Failure represents a validation that failed for a specific reason, making the modddel invalid. A valid modddel has no failures, while an invalid Modddel has at least one failure.
FailureType<F extends Failure>
InvalidEntity
An InvalidEntity is an interface implemented by the "invalid" union-case of Entities.
InvalidModddel
This is the base interface for the "invalid" union-case of a modddel.
InvalidParamAnnotation
InvalidValueObject
An InvalidValueObject is an interface implemented by the "invalid" union-case of ValueObjects.
InvalidWithGetterAnnotation
Modddel
Flags a class to be processed by the Modddels Generator.
ModddelInvalidMember
A ModddelInvalidMember is a wrapper class that holds an invalid member of an Entity, and its description in that Entity.
NullFailure
This annotation can be used inside any modddel / union of modddels, in front of a nullable member parameter.
SharedProp
TypeTemplate
An IterableEntity or Iterable2Entity have only one member parameter, which is the collection of modddels. For example, a 'BookList' ListEntity will have one member parameter List<Book> books.
Validation
ValidationStep
ValidEntity
A ValidEntity is an interface implemented by the "valid" union-case of Entities.
ValidModddel
This is the base interface for the "valid" union-case of a modddel.
ValidParamAnnotation
ValidValueObject
A ValidValueObject is an interface implemented by the "valid" union-case of ValueObjects.
ValidWithGetterAnnotation
ValueFailure
A ValueFailure is a Failure specific to ValueObjects.
WithGetterAnnotation

Constants

contentValidation → const Validation
dependencyParam → const DependencyParamAnnotation
This annotation can be used inside any modddel / union of modddels, in front of a factory parameter.
invalidParam → const InvalidParamAnnotation
This annotation can only be used inside a SimpleEntity, in front of a nullable member parameter.
invalidWithGetter → const InvalidWithGetterAnnotation
Same as specifying both the invalidParam and withGetter annotations.
validParam → const ValidParamAnnotation
This annotation can only be used inside a SimpleEntity, in front of a member parameter.
validWithGetter → const ValidWithGetterAnnotation
Same as specifying both the validParam and withGetter annotations.
withGetter → const WithGetterAnnotation
This annotation can be used inside any modddel / union of modddels, in front of a member parameter.

Functions

ellipsize(String text, {required int maxLength, bool showEllipsisCount = true}) String
Shortens the text using an ellipsis if its number of characters exceeds maxLength.

Exceptions / Errors

UnreachableError
Thrown when a part of the code is supposed to be unreachable.