separated mod/plugin functions in fileParser for usage by external tools
change output mode selection method
fix bugs