public EditingCommentCommand(IMotorSystemContext context, ICommentInputProvider commentInputProvider) { Guard.WhenArgument(context, "context").IsNull().Throw(); Guard.WhenArgument(commentInputProvider, "commentInputProvider").IsNull().Throw(); this.motorSystemContext = context; this.commentInputProvider = commentInputProvider; }
public CreateCommentCommand(IMotorSystemContext context, IModelFactory factory, ICommentInputProvider commentInputProvider, IMemoryCacheProvider cache, IDateTimeProvider datetimeProvider) { Guard.WhenArgument(context, "context").IsNull().Throw(); Guard.WhenArgument(factory, "factory").IsNull().Throw(); Guard.WhenArgument(commentInputProvider, "commentInputProvider").IsNull().Throw(); Guard.WhenArgument(cache, "cache").IsNull().Throw(); Guard.WhenArgument(datetimeProvider, "datetimeProvider").IsNull().Throw(); this.context = context; this.factory = factory; this.commentInputProvider = commentInputProvider; this.cache = cache; this.datetimeProvider = datetimeProvider; }