Args should be something like: target=singapore. We want to strip the keyword and equals sign
off. Also, remove single quotes too.

@param args
@return
436507
private Set<String> createTargetList(String targets) throws PauseableComponentControllerRequestFailedException {

        Set<String> targetSet = new HashSet<String>();

        if (targets != null && !targets.equals("")) {
            String targetsList[] = targets.split(",");
            targetSet.addAll(Arrays.asList(targetsList));
        }

        return targetSet;
    }
285568
public java.util.List<String> getArgs() {
        if (args == null) {
            args = new com.amazonaws.internal.SdkInternalList<String>();
        }
        return args;
    }
12642
private boolean isKnownArgument(String arg) {
        final String argName = getArgName(arg);
        for (String key : knownArgs) {
            if (key.equalsIgnoreCase(argName)) {
                return true;
            }
        }
        return false;
    }
565661
private boolean isNamedParam(String arg) {
        return arg.startsWith("--") && (arg.indexOf('=') > 2 && validFirstChar(arg.charAt(2)));
    }
1101619
public static String in(Object[] args) {
		if (EmptyUtil.isEmpty(args) == true) {
			return "";
		}
		StringBuilder sql = new StringBuilder();
		Arrays.asList(args).forEach(arg -> {
			if (arg == null) {
				sql.append("NULL");
			} else if (arg instanceof CharSequence) {
				sql.append("'").append(arg).append("'");
			} else {
				sql.append(arg);
			}
			sql.append(", ");
		});
		sql.setLength(sql.length() - ", ".length());
		return sql.toString().trim();
	}
1349164
@SuppressWarnings({"UnusedDeclaration"})
    public static void main(String[] args){
        Syntax syntax = new Syntax();

        Matcher Q               = syntax.add("Q",              ch('\''));
        Matcher DIGIT           = syntax.add("DIGIT",          range("0-9"));
        Matcher PUBID_CHAR     = syntax.add("PUBID_CHAR",   or(any(" \r\n"), range("A-Z"), range("a-z"), DIGIT, any("-'()+,./:=?;!*#@$_%")));
        Matcher PUBID_CHAR_NQ     = syntax.add("PUBID_CHAR_NQ",   minus(PUBID_CHAR, Q));
        Matcher SPECIAL_CHAR     = syntax.add("SPECIAL_CHAR",   any("^[]-^&\\<"));
        Matcher NON_SPECIAL_CHAR = syntax.add("NON_SPECIAL_CHAR",   not(SPECIAL_CHAR));


//        Matcher GT              = syntax.add("GT",             ch('>'));
//        Matcher BRACKET_CLOSE   = syntax.add("BRACKET_CLOSE",  ch(']'));
//        Matcher DQ              = syntax.add("DQ",             ch('"'));

//        Matcher HEX_DIGIT       = syntax.add("HEX_DIGIT",      or(DIGIT, range("a-f"), range("A-F")));
//        Matcher WS              = syntax.add("WS",             any(" \t\n\r"));
//        Matcher ENCODING_START  = syntax.add("ENCODING_START", or(range("A-Z"), range("a-z")));
//        Matcher ENCODING_PART   = syntax.add("ENCODING_PART",  or(ENCODING_START, DIGIT, any("._-")));
//        Matcher CHAR            = syntax.add("CHAR",           or(any("\t\n\r"), range(" -\uD7FF"), range("\uE000-\uFFFD")/*, range("\u10000-\u10FFFF")*/));
//        Matcher DASH            = syntax.add("DASH",           ch('-'));
//        Matcher NDASH           = syntax.add("NDASH",          minus(CHAR, ch('-')));
//        Matcher NAME_START      = syntax.add("NAME_START",     or(ch(':'), range("A-Z"), ch('_'), range("a-z"), range("\u00C0-\u00D6"), range("\u00D8-\u00F6"), range("\u00F8-\u02FF"), range("\u0370-\u037D"), range("\u037F-\u1FFF"), range("\u200C-\u200D"), range("\u2070-\u218F"), range("\u2C00-\u2FEF"), range("\u3001-\uD7FF"), range("\uF900-\uFDCF"), range("\uFDF0-\uFFFD")/*, range("\u10000-\uEFFFF")*/));
//        Matcher NAME_PART       = syntax.add("NAME_PART",      or(NAME_START, ch('-'), ch('.'), DIGIT,  ch('\u00B7'), range("\u0300-\u036F"), range("\u203F-\u2040")));
//        Matcher NCNAME_START    = syntax.add("NCNAME_START",   minus(NAME_START, ch(':')));
//        Matcher NCNAME_PART     = syntax.add("NCNAME_PART",    minus(NAME_PART, ch(':')));

//        Rule rule = new Rule();
//        rule.node = new Node();
//        syntax.add("Rule1", rule);

        NBLREditor editor = new NBLREditor(syntax);
        editor.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
        editor.setVisible(true);
    }
1022977
protected final void args(Object... args) {
        if (args == null) args = NO_ARGS;
        this.args = args;
        retry();
    }
492281
protected void validateArgumentList(String[] args, boolean supportsTarget, boolean supportsDefaultTarget) {
        checkRequiredArguments(args, !supportsTarget || supportsDefaultTarget);

        // If the command supports a target name
        // skip the first argument if it is the target name.
        int firstArg = 1;
        if (supportsTarget) {
            if (!supportsDefaultTarget) {
                firstArg = 2;
            } else {
                if (args.length > 1) {
                    String primArg = args[1];
                    if (!primArg.startsWith("-"))
                        firstArg = 2;
                }
            }
        }

        // Arguments and values come in pairs (expect -password).
        // Anything outside of that pattern is invalid.
        // Loop through, jumping in pairs except when we encounter
        // -password -- that may be an interactive prompt which won't
        // define a value.
        for (int i = firstArg; i < args.length; i++) {
            String argName = getArgName(args[i]);
            if (!isKnownArgument(argName)) {
                throw new IllegalArgumentException(getMessage("invalidArg", argName));
            }
            // Everything we accept as an arg expects an name=value pair.
            // If we see anything without the =value pair, error
            if (!args[i].contains("=")) {
                throw new IllegalArgumentException(getMessage("missingValue", argName));
            }
        }
    }
141823
protected static boolean argIsOption(String arg, String option) {
        return arg.equalsIgnoreCase(option) || arg.equalsIgnoreCase('-' + option);
    }
1311308
private StringBuffer getArgsString(Object[] args) {
        StringBuffer buffer = new StringBuffer();
        String prefix = "args ";
        for (int i = 0; i < args.length; i++) {
            if (args.length > 1) {
                buffer.append(prefix + (i + 1));
            }
            buffer.append("\r\t");
            buffer.append(getResultString(args[i]));
            buffer.append("\n");
        }
        return buffer;
    }
471129
protected String getValue(String arg) {
        String[] split = arg.split("=");
        if (split.length <= 1) {
            return null;
        }
        return split[1];
    }
133188
public static byte[] encodeDataList(Object... args) {
        ByteArrayOutputStream baos = new ByteArrayOutputStream();
        for (Object arg : args) {
            byte[] val = encodeValFor32Bits(arg);
            try {
                baos.write(val);
            } catch (IOException e) {
                throw new Error("Happen something that should never happen ", e);
            }
        }
        return baos.toByteArray();
    }
50027
public static String format(String pattern, Object... arguments) {
        String msg = pattern;
        if (arguments != null) {
            for (int index = 0; index < arguments.length; index++) {
                msg = msg.replaceAll("\\{" + (index + 1) + "\\}", String.valueOf(arguments[index]));
            }
        }
        return msg;
    }
717361
function(args) {
            args = this.trim(args, '&\?#');

            var parts = args.split('&');
            var output = {};

            var key;
            var value;
            var equalsSegments;
            var lim = parts.length;
            for (var i=0,l=lim; i<l; i++) {
                equalsSegments = parts[i].split('=');
                key = decodeURIComponent(equalsSegments.shift());
                value = equalsSegments.join("=");
                output[key] = decodeURIComponent(value);
            }
            return output;
        }
1266613
protected boolean narrowArguments(Object[] args) {
    boolean narrowed = false;
    for (int a = 0; a < args.length; ++a) {
      Object arg = args[a];
      if (arg instanceof Number) {
        Object narg = narrow((Number) arg);
        if (narg != arg) {
          narrowed = true;
        }
        args[a] = narg;
      }
    }
    return narrowed;
  }
985988
public static boolean checkArgs(String[] args) {        
        if (args.length < 4) {
            return false;
        }
        
        if (args[0].compareToIgnoreCase("-modeldir") != 0) {
            return false;
        }
        
        if (!(args[2].compareToIgnoreCase("-inputfile") == 0 ||
                args[2].compareToIgnoreCase("-inputdir") == 0)) {
            return false;
        }
        
        return true;
    }
234712
@SafeVarargs
  public final QueryBuilder arguments(Object...args) {
    set(Param.QUERY_ARGS, "");
    queryArgs = args.clone();
    return this;
  }