Gets whether the arguments have been sufficiently set to execute a CLI
task.

@return true if the CLI arguments have been sufficiently set.
977236
public boolean isSet() {
        if (isUsageMode()) {
            return true;
        }
        if (getJobFile() != null) {
            return true;
        }
        if (getListType() != null) {
            return true;
        }
        return false;
    }
376645
public static function isSupported()
    {
        if (null === self::$supported) {
            self::$supported = function_exists('cli_set_process_title') || function_exists('setproctitle');
        }

        return self::$supported;
    }
854140
@SuppressWarnings("unchecked")
    @Override
    public Boolean execute() {
        try {
            api.changeRoomCapacity(CommandUtil.getSfsUser(owner, api),
                    CommandUtil.getSfsRoom(targetRoom, extension), 
                    maxUsers, maxSpectators);
        } catch (SFSRoomException e) {
            throw new IllegalStateException(e);
        }
        return Boolean.TRUE;
    }
1055835
public static boolean isEmptyAny(String... args) {
        for (String arg : args) {
            if (isEmpty(arg)) {
                return true;
            }
        }
        return false;
    }
1246093
public boolean hasException() {
        return Optional.ofNullable(commandResult)
                        .map(result -> StringUtils.hasText(result.getException()))
                        .orElse(false);
    }
134124
public boolean isWordCommand(final ICmdLineArg<?> argDef)
    {
        if (argDef.getKeyword() == null || isUsed() || !isWordCommand() || getValue().length() < 3)
            return false;
        if (getWordCommand().length() == argDef.getKeyword().length())
        {
            if (getWordCommand().equalsIgnoreCase(argDef.getKeyword()))
                return true;
        } else if (getWordCommand().length() < argDef.getKeyword().length())
        {
            if (argDef.getKeyword().substring(0, getWordCommand().length()).equalsIgnoreCase(getWordCommand()))
                return true;
            if (argDef.isCamelCapsAllowed())
                /*
                 * Check for camel caps
                 */
                if (argDef.getCamelCaps() != null)
                    if (argDef.getCamelCaps().equalsIgnoreCase(getWordCommand()))
                        return true;
            if (argDef.isMetaphoneAllowed())
                /*
                 * Check for metaphone
                 */
                if (argDef.getMetaphone() != null)
                    if (new Metaphone().metaphone(getWordCommand()).equals(argDef.getMetaphone()))
                        return true;
        }
        return false;
    }
840616
@Override
	public boolean hasNext() {

		validateState();

		if (!delegate.hasNext() && !isFinished()) {
			load(getCursorMark());
		}

		if (delegate.hasNext()) {
			return true;
		}

		return false;
	}
951794
public synchronized static boolean hasSudo()
	{
		if (!sudoTested)
		{
			String[] cmdArr = new String[]{"which", "sudo"};
			List<String> cmd = new ArrayList<String>(cmdArr.length);
			Collections.addAll(cmd, cmdArr);

			ProcessBuilder whichsudo = new ProcessBuilder(cmd);

			try
			{
				Process p = whichsudo.start();
				try
				{
					Execed e = new Execed(cmd, p, false);

					// Let it run
					int returnCode = e.waitForExit(new Deadline(3, TimeUnit.SECONDS));

					sudoSupported = (returnCode == 0);
					sudoTested = true;
				}
				finally
				{
					p.destroy();
				}
			}
			catch (Throwable t)
			{
				sudoSupported = false;
				sudoTested = true;
			}
		}

		return sudoSupported;
	}
496134
function() {
      var count = _.size(arguments);
      if (count === 1) return true;
      if (count === 2) return arguments[0] < arguments[1];

      for (var i = 1; i < count; i++) {
        if (arguments[i-1] >= arguments[i]) {
          return false;
        }
      }

      return true;
    }
889934
private static void checkArguments(final Object... args) {
        for (Object o : args) {
            if (o == null) {
                throw new NullPointerException("argument can not be null " + Arrays.toString(args));
            }
        }
    }
319588
function validateArgs(args) {
    if (args.length === 0) {
      grunt.log.error('Unable to run task: no action specified (e.g. run or update)');
      return false;
    } else if (args.length === 1) {
      grunt.log.error('Unable to run task: no target specified');
      return false;
    } else if (args.length > 3) {
      grunt.log.error('Unable to run task: too many arguments (up to 4 allowed)');
      return false;
    }

    return true;
  }
928008
public static function isShellExecution()
    {
        $sapiType = php_sapi_name();

        if ( $sapiType == 'cli' )
            return true;

        // For CGI we have to check, if the script has been executed over shell.
        // Currently it looks like the HTTP_HOST variable is the most reasonable to check.
        if ( substr( $sapiType, 0, 3 ) == 'cgi' )
        {
            if ( !self::serverVariable( 'HTTP_HOST', true ) )
                return true;
            else
                return false;
        }
        return false;
    }
367775
private boolean hasExpandableVarArgs(IMockMethod method, List<Object> args) {
    List<Class<?>> paramTypes = method.getParameterTypes();
    return !paramTypes.isEmpty()
        && CollectionUtil.getLastElement(paramTypes).isArray()
        && CollectionUtil.getLastElement(args) != null;
  }
868469
public function is_configured() {
        if ($this->get_config('runningmethod') === 'commandline') {
            return (bool)$this->get_config('pathtoclam');
        } else if ($this->get_config('runningmethod') === 'unixsocket') {
            return (bool)$this->get_config('pathtounixsocket');
        }
        return false;
    }
1141898
public boolean canRun() {
    Status status = getStatus();
    return Status.STATUS_READY.equals(status) || Status.STATUS_COMPLETE.equals(status);
  }
942723
public function cliMode(): bool
    {
        if (!isset($this->cache[self::CLI_MODE])) {
            $this->cache[self::CLI_MODE] = php_sapi_name() === 'cli';
        }

        return $this->cache[self::CLI_MODE];
    }
540890
private boolean hasParametersChanged()
	{
		boolean changed = false;
		for (ICachedData<?> data : parameters.values())
		{
			data.update();
			if (data.hasChanged())
				changed |= true; //can't return early, we need to call update on each data
		}
		return changed;
	}