src/main/java/com/github/ricksbrown/cowsay/Cowsay.java
private static CowFace getCowFace(final CommandLine commandLine) {
		CowFace cowFace;
		cowFace = new CowFace();
		if (commandLine.hasOption(CowsayCli.Opt.EYES.toString())) {
			cowFace.setEyes(commandLine.getOptionValue(CowsayCli.Opt.EYES.toString()));
		}
		if (commandLine.hasOption(CowsayCli.Opt.TONGUE.toString())) {
			cowFace.setTongue(commandLine.getOptionValue(CowsayCli.Opt.TONGUE.toString()));
		}
		return cowFace;
	}
private static CowFace getCowFace(final CommandLine commandLine) {
		CowFace cowFace;
		cowFace = new CowFace();
		if (commandLine.hasOption(CowsayCli.Opt.EYES.toString())) {
			cowFace.setEyes(commandLine.getOptionValue(CowsayCli.Opt.EYES.toString()));
		}
		if (commandLine.hasOption(CowsayCli.Opt.TONGUE.toString())) {
			cowFace.setTongue(commandLine.getOptionValue(CowsayCli.Opt.TONGUE.toString()));
		}
		return cowFace;
	}
private static CowFace getCowFace ( final CommandLine commandLine ) { CowFace cowFace ; cowFace = new CowFace ( ) ; if ( commandLine . hasOption ( CowsayCli . Opt . EYES . toString ( ) ) ) { cowFace . setEyes ( commandLine . getOptionValue ( CowsayCli . Opt . EYES . toString ( ) ) ) ; } if ( commandLine . hasOption ( CowsayCli . Opt . TONGUE . toString ( ) ) ) { cowFace . setTongue ( commandLine . getOptionValue ( CowsayCli . Opt . TONGUE . toString ( ) ) ) ; } return cowFace ; }
Get a regular cow face optionally formatted with custom eyes and tongue from the command line.
@param commandLine The command line with user options.
@return A regular cowface, possibly formatted with custom tongue and/or eyes.
Get a regular cow face optionally formatted with custom eyes and tongue from the command line .