ModelIdentifier.php 790 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. <?php
  2. namespace Illuminate\Contracts\Database;
  3. class ModelIdentifier
  4. {
  5. /**
  6. * The class name of the model.
  7. *
  8. * @var string
  9. */
  10. public $class;
  11. /**
  12. * The unique identifier of the model.
  13. *
  14. * This may be either a single ID or an array of IDs.
  15. *
  16. * @var mixed
  17. */
  18. public $id;
  19. /**
  20. * The connection name of the model.
  21. *
  22. * @var string|null
  23. */
  24. public $connection;
  25. /**
  26. * Create a new model identifier.
  27. *
  28. * @param string $class
  29. * @param mixed $id
  30. * @param mixed $connection
  31. * @return void
  32. */
  33. public function __construct($class, $id, $connection)
  34. {
  35. $this->id = $id;
  36. $this->class = $class;
  37. $this->connection = $connection;
  38. }
  39. }