added isPrepared check function for code unification
fixed isTemplateFileFromStreamExists
added stream closing
updated stream test to verify on stream operations, not
templateFileManager
added getInstance
using template manager get instance
added cache test testProcess_fileMultiRun
added javadoc, removed wrong cleanup method