Project

General

Profile

Actions

Bug #57856

closed

@inject does not work relative to current namespace

Added by Stefan Neufeind over 10 years ago. Updated over 5 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Extbase
Target version:
-
Start date:
2014-04-12
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
7
PHP Version:
Tags:
Complexity:
Is Regression:
No
Sprint Focus:
Remote Sprint

Description

So far you always need to give the full classpath including full namespace for an @inject. That's the way it is currently used. It would be great if @inject would also allow to use the current namespace.

Or maybe even make use of "use"-statements?


Related issues 3 (0 open3 closed)

Related to TYPO3 Core - Task #57878: Cleanup Extbase Reflection classesClosedMarkus Klein2014-04-13

Actions
Related to TYPO3 Core - Bug #85932: Incorrect annotation for property "message" in class "Error".Closed2018-08-23

Actions
Has duplicate TYPO3 Core - Feature #76204: Make it possible to use imported/alias class names in PHPDoc block annotationsClosed2016-05-17

Actions
Actions #1

Updated by Markus Klein over 10 years ago

Flow has a solution for this: https://review.typo3.org/20158

Actions #2

Updated by Markus Klein over 10 years ago

They even support the use statement. But this comes with high costs. You need to parse the file in order to retrieve the use statements. Flow uses the doctrine phpparser for this.
For the purpose of extbase I suggest to only resolve the current namespace, which is easy.

Actions #3

Updated by Stefan Neufeind over 10 years ago

Can't we take that "cost"? Reflection is cached anyway.

We don't have Doctrine yet. So I think for "use" only we can come up with a minimal parser - maybe even with some hardcoded limitations for now. We might get Doctrine anyway afaik, sooner or later.

Thanks for the link to that patch. Looks doable imho ...

Actions #4

Updated by Gerrit Code Review over 10 years ago

  • Status changed from New to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/29436

Actions #5

Updated by Markus Klein over 10 years ago

I agree now that we should add the use stmt support as well.

Actions #6

Updated by Gerrit Code Review over 10 years ago

Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/29436

Actions #7

Updated by Gerrit Code Review over 10 years ago

Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/29436

Actions #8

Updated by Gerrit Code Review over 10 years ago

Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/29436

Actions #9

Updated by Gerrit Code Review almost 10 years ago

Patch set 5 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/29436

Actions #10

Updated by Gerrit Code Review almost 10 years ago

Patch set 6 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/29436

Actions #11

Updated by Gerrit Code Review almost 10 years ago

Patch set 7 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/29436

Actions #12

Updated by Gerrit Code Review over 9 years ago

Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/38359

Actions #13

Updated by Gerrit Code Review over 9 years ago

Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/38359

Actions #14

Updated by Gerrit Code Review over 9 years ago

Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/38359

Actions #15

Updated by Gerrit Code Review over 9 years ago

Patch set 5 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/38359

Actions #16

Updated by Gerrit Code Review over 9 years ago

Patch set 6 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/38359

Actions #17

Updated by Gerrit Code Review over 9 years ago

Patch set 7 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/38359

Actions #18

Updated by Gerrit Code Review over 9 years ago

Patch set 8 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/38359

Actions #19

Updated by Gerrit Code Review over 9 years ago

Patch set 9 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/38359

Actions #20

Updated by Gerrit Code Review over 9 years ago

Patch set 10 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/38359

Actions #21

Updated by Gerrit Code Review over 9 years ago

Patch set 11 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/38359

Actions #22

Updated by Gerrit Code Review over 9 years ago

Patch set 12 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/38359

Actions #23

Updated by Gerrit Code Review over 9 years ago

Patch set 13 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/38359

Actions #24

Updated by Sebastian Michaelsen over 9 years ago

  • Target version set to 7.4 (Backend)
  • Sprint Focus set to On Location Sprint
Actions #25

Updated by Sebastian Michaelsen over 9 years ago

  • TYPO3 Version changed from 6.2 to 7
Actions #26

Updated by Gerrit Code Review over 9 years ago

Patch set 14 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/38359

Actions #27

Updated by Susanne Moog over 9 years ago

  • Target version changed from 7.4 (Backend) to 7.5
Actions #28

Updated by Anja Leichsenring over 9 years ago

  • Sprint Focus changed from On Location Sprint to Remote Sprint
Actions #29

Updated by Gerrit Code Review over 9 years ago

Patch set 15 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/38359

Actions #30

Updated by Benni Mack about 9 years ago

  • Target version deleted (7.5)
Actions #31

Updated by Gerrit Code Review about 9 years ago

Patch set 16 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/38359

Actions #32

Updated by Anja Leichsenring almost 8 years ago

  • Status changed from Under Review to Accepted
Actions #33

Updated by Patryk Ostrowski about 6 years ago

  • Related to Bug #85932: Incorrect annotation for property "message" in class "Error". added
Actions #34

Updated by Georg Ringer over 5 years ago

  • Status changed from Accepted to Resolved

this has been solved in master, therefore issue closed

Actions #35

Updated by Benni Mack over 5 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF