org.crsh.cmdline.matcher
Class ClassMatch<T>

java.lang.Object
  extended by org.crsh.cmdline.matcher.CommandMatch<T,ClassDescriptor<T>,ClassFieldBinding>
      extended by org.crsh.cmdline.matcher.ClassMatch<T>

public class ClassMatch<T>
extends CommandMatch<T,ClassDescriptor<T>,ClassFieldBinding>

Version:
$Revision$
Author:
Julien Viet

Field Summary
private  ClassDescriptor<T> descriptor
          .
 
Constructor Summary
ClassMatch(ClassDescriptor<T> descriptor, List<OptionMatch<ClassFieldBinding>> optionMatches, List<ArgumentMatch<ClassFieldBinding>> argumentMatches, String rest)
           
 
Method Summary
protected  Object doInvoke(InvocationContext context, T command, Map<ParameterDescriptor<?>,Object> values)
           
 ClassDescriptor<T> getDescriptor()
           
 List<ParameterMatch<?,?>> getParameterMatches()
           
 Set<ParameterDescriptor<?>> getParameters()
           
 void printMan(Appendable writer)
           
 void printUsage(Appendable writer)
           
 
Methods inherited from class org.crsh.cmdline.matcher.CommandMatch
getArgumentMatches, getOptionMatches, getRest, invoke
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

descriptor

private final ClassDescriptor<T> descriptor
.

Constructor Detail

ClassMatch

public ClassMatch(ClassDescriptor<T> descriptor,
                  List<OptionMatch<ClassFieldBinding>> optionMatches,
                  List<ArgumentMatch<ClassFieldBinding>> argumentMatches,
                  String rest)
Method Detail

getDescriptor

public ClassDescriptor<T> getDescriptor()
Specified by:
getDescriptor in class CommandMatch<T,ClassDescriptor<T>,ClassFieldBinding>

printMan

public void printMan(Appendable writer)
              throws IOException
Specified by:
printMan in class CommandMatch<T,ClassDescriptor<T>,ClassFieldBinding>
Throws:
IOException

printUsage

public void printUsage(Appendable writer)
                throws IOException
Specified by:
printUsage in class CommandMatch<T,ClassDescriptor<T>,ClassFieldBinding>
Throws:
IOException

getParameters

public Set<ParameterDescriptor<?>> getParameters()
Specified by:
getParameters in class CommandMatch<T,ClassDescriptor<T>,ClassFieldBinding>

getParameterMatches

public List<ParameterMatch<?,?>> getParameterMatches()
Specified by:
getParameterMatches in class CommandMatch<T,ClassDescriptor<T>,ClassFieldBinding>

doInvoke

protected Object doInvoke(InvocationContext context,
                          T command,
                          Map<ParameterDescriptor<?>,Object> values)
                   throws CmdInvocationException,
                          CmdSyntaxException
Specified by:
doInvoke in class CommandMatch<T,ClassDescriptor<T>,ClassFieldBinding>
Throws:
CmdInvocationException
CmdSyntaxException


Copyright © 2012 eXo Platform SAS. All Rights Reserved.