Package org.jnode.shell.syntax.CommandSyntaxException

Examples of org.jnode.shell.syntax.CommandSyntaxException.Context


                                    arg.complete(completions, "", flags);
                                }
                                backtrack = true;
                            }
                        } catch (CommandSyntaxException ex) {
                            argFailures.add(new Context(token, syntax, source.tell(), ex));
                            if (DEBUG) {
                                log.debug("accept for arg " + argName + " threw SyntaxErrorException('" +
                                        ex.getMessage() + "'");
                            }
                            backtrack = true;
                        }
                        break;
                    case PRESET:
                        MuPreset muPreset = (MuPreset) syntax;
                        arg = bundle.getArgument(muPreset.getArgName());
                        flags = muPreset.getFlags();
                        try {
                            arg.accept(new CommandLine.Token(muPreset.getPreset()), flags);
                            if (!backtrackStack.isEmpty()) {
                                backtrackStack.getFirst().argsModified.add(arg);
                                if (DEBUG) {
                                    log.debug("recording undo for preset arg " + arg.getLabel());
                                }
                            }
                        } catch (CommandSyntaxException ex) {
                            argFailures.add(new Context(null, syntax, source.tell(), ex));
                            backtrack = true;
                        }
                        break;
                    case SEQUENCE:
                        MuSyntax[] elements = ((MuSequence) syntax).getElements();
View Full Code Here

TOP

Related Classes of org.jnode.shell.syntax.CommandSyntaxException.Context

Copyright © 2018 www.massapicom. 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.