public abstract class CreateFromTemplateHandler
extends java.lang.Object
FileBuilder.build()
and handle them themselves. The NetBeans IDE provides default
implementation that allows use of Freemarker templating engine.
Read more in the howto document.
An implementation of CreateHandler should honor CreateDescriptor.hasFreeExtension() and
CreateDescriptor.isPreformatted().| Constructor | Description |
|---|---|
CreateFromTemplateHandler() |
| Modifier and Type | Method | Description |
|---|---|---|
protected abstract boolean |
accept(CreateDescriptor desc) |
Method that allows a handler to reject a file.
|
protected abstract java.util.List<org.openide.filesystems.FileObject> |
createFromTemplate(CreateDescriptor desc) |
Handles the creation of new files.
|
protected abstract boolean accept(CreateDescriptor desc)
FileBuilder.createFromTemplate(org.openide.filesystems.FileObject, org.openide.filesystems.FileObject, java.lang.String, java.util.Map, org.netbeans.api.templates.FileBuilder.Mode)
is going to take place.desc - @NonNull protected abstract java.util.List<org.openide.filesystems.FileObject> createFromTemplate(CreateDescriptor desc) throws java.io.IOException
desc - command objects that describes the file creation requestjava.io.IOException - if something goes wrong with I/OBuilt on April 24 2018. | Portions Copyright 1997-2018 Oracle. All rights reserved.