Ticket #10 (closed defect: invalid)
Mappers broken: missing argument for constructor
| Reported by: | frank.kleine@… | Owned by: | |
|---|---|---|---|
| Priority: | major | Milestone: | 2.2.0 |
| Component: | Version: | 2.2.0RC1 | |
| Keywords: | Cc: |
Description
Using mappers is currently broken and gives an error message: Fatal error: Argument 1 must be an object of class Project in /path/to/phing/2.2.0RC1/classes/phing/types/Mapper.php on line 52
Mapper seems to be instantiated in Project::createDataType() with $type = new $cls(); on line 650. However Mapper::__construct() requires an argument of type Project which is missing here and leads to the error message named above.
Changing the instantiation to $type = new $cls($this); doesn't help as other classes inherited from DataType expect other arguments on their constructor method.
Attachments
Change History
comment:2 Changed 6 years ago by hans
Sorry, to be more clear, could you paste in the portion of your build.xml where you are referencing the <mapper>?

I'm fairly certain that I am using Mapper classes in one or more buildfiles. Can you show a snippet of code where you are using the Mapper? Are you using a Mapper in a Task that supports Mappers?