Id constructor

const Id({
  1. bool autoIncrement = true,
  2. IDStrategy? strategy = IDStrategy.autoIncrement,
})

Implementation

const Id({
  this.autoIncrement = true,
  this.strategy = IDStrategy.autoIncrement,
}) : assert(
       autoIncrement && strategy != IDStrategy.uuid,
       'autoIncrement is true but strategy is uuid,should use another strategy',
     );