How to use and change resource files in a multiproject?

Hi,

I’m trying to use csv files in a java multiproject architecture and don’t know how to set up all corretly. In one csv file a transformation matrix stored. This matrix should be available for other subprojects.

I changed the project structure to the following one:

mainproject/projectA

/src

/res/matrix.csv

/projectB

/src

/res

The src folder contains all java files and the res folder stores all resources like images or textfiles. Let’s say in projectA the matrix is calculated and saved in matrix.csv. In projectB the matrix.csv should be loaded and do some transformations.

My two problems are: 1. When I store the matrix in projectA with a local path (“matrix.csv”) isn’t it saved in build/run folder? That means the file /projectA/res/matrix.csv is never created or changed?

  1. In the build.gradle file of projectB I add this dependency: compile project(’:projectA’) This works fine for all java files but it fails with the resource files. Is it possible to use resources of other subprojects in a multiproject and how I do it?