I added a resource for the module as follows:
<plugin> <groupId>org.codehaus.mojo</groupId> <artifactId>nbm-maven-plugin</artifactId> <extensions>true</extensions> <configuration> <moduleType>eager</moduleType> <nbmResources> <nbmResource> <directory>${basedir}/resources</directory> <targetPath>resources</targetPath> <includes> <include>*.db</include> </includes> <excludes> <exclude>*trace*</exclude> </excludes> </nbmResource> </nbmResources> </configuration> </plugin>
The file is displayed in the Netbeans application at: target/app name/app name/resources/card_manager.mv.db . It looks good.
Now I am trying to get this file location as follows:
File db = InstalledFileLocator.getDefault().locate("card_manager.mv.db", "module.codename.base", false);
But db is always zero. Any idea?
source share