Examples of ReplacementCommand


Examples of com.github.zathrus_writer.commandsex.helpers.scripting.ReplacementCommand

          if (scriptmode.equals(">")){
            char method = ' ';
            if (!methodstr.isEmpty()) method = methodstr.charAt(0);
            switch (method){
            case 'c': //command method - to force command instead of chat replacement
              rp = new ReplacementCommand(regex, repl, replopts, caseSensitive, sameOutputCase); break;
            case 'r': //random method - choose from one of the ; separated list
              if (mc != MatchingContext.Chat) {
                LogHelper.logWarning(_("cmdRandomReplacementNotAllowed", "")+lineno);
                continue;
              }
              rp = new ReplacementRandom(regex, repl, caseSensitive, sameOutputCase); break;
            case ' ':
            default:
              switch (mc){
              case Command:
                rp = new ReplacementCommand(regex, repl, replopts, caseSensitive, sameOutputCase); break;
              case Chat: //only use ReplacementString for chat
                rp = new ReplacementString(regex, repl, replopts, caseSensitive, sameOutputCase); break;
              }
              break;
            }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.