mangusbrother
mangusbrother

Reputation: 4156

Passing variables to template on class creation inside IntelliJ Plugin

I am creating a Java class inside an IntelliJ plugin using:

new JavaDirectoryServiceImpl().createClass(directory, className, templateName);

I would like to pass parameters that are used within the template. how can i do so?

Upvotes: 0

Views: 48

Answers (1)

yole
yole

Reputation: 97138

new JavaDirectoryServiceImpl() is absolutely not intended for use by plugin developers. The correct way to create a file from template with parameters is FileTemplateUtil.createFromTemplate().

Upvotes: 1

Related Questions