Expand description
Shared constructor-property extraction for events.rs/jobs.rs -
both a converted Event and a converted Job are simple field-only
structs whose fields come from the Laravel class’s own constructor.
Real Laravel code uses two styles, both detected here: modern
constructor-promoted properties (public function __construct(public Order $order) {}) and the older explicit-property-plus-assignment
style (public $order; public function __construct(Order $order) { $this->order = $order; }) - both produce the same flat field list.
Whole-item safety, not per-field: constructor fields are the
struct’s entire field list - there’s no safe way to emit a
partially-wrong struct the way Phase 2a can emit a form-request field
bare. Any parameter this module can’t confidently type rejects the
whole extraction; the caller (events.rs/jobs.rs) skips that whole
class.
Structs§
Functions§
- extract
Ok(vec![])if the class has no constructor at all (not an error - some classes genuinely have no properties).Errif any parameter that looks like it’s meant to be a field has a type this module doesn’t recognize.