Bonjour,
J'ai déclaré:
j'utilisais ce type dans la séquence:
1 2 3
| project = ProjectsManager.getInstance().getActiveProject();
chain = project.getChains().get(0);
chain.setName( fileName); |
dans cette séquence project reste null, j'ai donc rajouté
project = new IProject();
mais ça ne compile pas, le compilateur me dit :
Multiple markers at this line
- Cannot instantiate the type IProject
- Cannot make a static reference to the non-
static field projectc
si j'essaie de forcer la variable en static
static project = new IProject();
je récupère plus de remarques du compilateur:
Multiple markers at this line
- Illegal modifier for the variable $missing$; only
final is permitted
- Cannot instantiate the type IProject
- project cannot be resolved to a type
- Cannot make a static reference to the non-
static field project
- Syntax error on token "project",
VariableDeclaratorId expected after this token
Quelqu'un saurait-il m'indiquer comment résoudre ce problème ?
Merci d'avance pour votre aide.
Partager