added pipe and fileIO functionality