Add parseForegroundCommandLineArgument function.

This function return true when "--foreground" is included in argument.
And I will create switchDaemon function to switch daemon process.