add func for parsing arguments.