ProductInventory class

Example 5: Model with various constraints

Annotations
  • @AckModel.new(description: 'Product inventory with comprehensive constraints')

Constructors

ProductInventory({required String sku, required int quantity, required double unitPrice, required String lastRestocked, required bool isAvailable})

Properties

hashCode int
The hash code for this object.
no setterinherited
isAvailable bool
final
lastRestocked String
final
quantity int
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
sku String
final
unitPrice double
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

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