Skip to content

Parsing @method annotations breaks Form documentation #1344

@tmysik

Description

@tmysik

This applies for Nette 2.1, Nette 2.0 does not have this issue.

Steps:

  • create your own base form class
  • register some extension method for it (e.g. "addDateTime()")
  • since you of course want to have this new method in code completion of your favorite IDE (NetBeans in my case), add this new extension method to the class documentation using @method annotation (since this is the standard and expected way, right?)

-> when such form is created, Nette from some reason (why?) parses these annotations and magically handles [get/set/add/remove] prefixes (again - why? is it really worth to save those few lines of implementations or using a trait? I doubt...) - but it horribly fails here, of course, since this is not the case Nette expects.

Currently, I don't see any possible workaround for this issue and I had to remove all the @method annotations so the code completion in my IDE is incomplete/broken :/

Thanks for understanding.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions