I have the following piece of code:
class Train{
static{
InputStream inpStr = Train.class.getClassLoader().getResourceAsStream("ABC.properties");
Properties props = new Properties();
props.load(inpStr);
}
}
I want to know the absolute file path of this file ABC.properties, i.e from where inpStr is reading it?
Through debugging, I realised the object assigned to inpStr is actually of java.io.ByteArrayInputStream
. But I unable to find a way to get the abolute file path. Please help