Package com.mapr.cli
Class FileFilterCommands
- java.lang.Object
-
- com.mapr.cliframework.base.CLIBaseClass
-
- com.mapr.cli.common.ListCommand
-
- com.mapr.cli.FileFilterCommands
-
- All Implemented Interfaces:
ListIterator,com.mapr.cliframework.base.CLIInterface
public class FileFilterCommands extends ListCommand implements com.mapr.cliframework.base.CLIInterface
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringASCENDING_SORTING_ORDER_PARAMstatic java.lang.StringCOLUMNS_PARAMstatic java.lang.StringDESCENDING_SORTING_ORDER_PARAMstatic com.mapr.cliframework.base.CLICommandfilefilterCommandsstatic com.mapr.cliframework.base.CLICommand[]filefilterCommandsArraystatic java.lang.StringFILTER_DESCRIPTION_PARAMstatic java.lang.StringFILTER_EXTENSIONS_PARAMstatic java.lang.StringFILTER_NAME_PARAMstatic java.lang.StringFILTER_PARAMstatic java.lang.StringfilterCreateUsagestatic java.lang.StringfilterInfoUsagestatic java.lang.StringfilterListUsagestatic java.lang.StringfilterModifyUsagestatic java.lang.StringfilterRemoveUsagestatic java.lang.StringLIMIT_PARAMstatic java.lang.StringMULTI_ARG_SEPstatic java.lang.StringOUTPUT_PARAMstatic java.lang.StringSORTBY_PARAMstatic java.lang.StringSORTING_ORDER_PARAMstatic java.lang.StringSTART_PARAMstatic java.lang.StringvalidCharRegExstatic java.lang.StringvalidCharRegExWithSpacestatic java.util.regex.PatternvalidDescPatternstatic java.util.regex.PatternvalidNamePattern
-
Constructor Summary
Constructors Constructor Description FileFilterCommands(com.mapr.cliframework.base.ProcessedInput input, com.mapr.cliframework.base.CLICommand cliCommand)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description com.mapr.fs.cldb.proto.CLDBProto.FileFilterListRequestbuildNextRequest(com.google.protobuf.MessageLite prevReq, com.google.protobuf.MessageLite prevResp)Builds the next request object by inspecting the previous request and previous response.com.mapr.cliframework.base.CommandOutputexecuteRealCommand()static com.mapr.fs.cldb.proto.CLDBProto.FileFilterLookupResponsefilterLookup(java.lang.String cluster, com.mapr.fs.proto.Security.CredentialsMsg creds, java.lang.String filtername, int filterId)static com.mapr.fs.cldb.proto.CLDBProto.FileFilterLookupResponsefilterLookupById(java.lang.String cluster, com.mapr.fs.proto.Security.CredentialsMsg creds, int filterId)static com.mapr.fs.cldb.proto.CLDBProto.FileFilterLookupResponsefilterLookupByName(java.lang.String cluster, com.mapr.fs.proto.Security.CredentialsMsg creds, java.lang.String filtername)booleanhasMore(com.google.protobuf.MessageLite prevReq, com.google.protobuf.MessageLite prevResp)Inspect the last request and last response to see if there are more records to be fetched.voidprocessResponse(com.mapr.cliframework.base.CommandOutput.OutputHierarchy out, com.google.protobuf.MessageLite response)Parse the response and populate the output hierarchy.com.mapr.fs.cldb.proto.CLDBProto.FileFilterListResponsesendRequest(com.google.protobuf.MessageLite request)Send the request using RPC and fetch the response.-
Methods inherited from class com.mapr.cli.common.ListCommand
getFilters, getNextLimiter, hasMore, list
-
Methods inherited from class com.mapr.cliframework.base.CLIBaseClass
executeCommand, executeSimpleSHHCommand, executeSimpleSHHCommand, getCLICommand, getCommandUsage, getGIds, getInput, getKeyType, getParamBooleanValue, getParamDateValue, getParamIntValue, getParamLongValue, getParamObjectValue, getParamTextValue, getUserCredentials, getUserId, getUserLoginId, getVersion, isParamPresent, isParamValueEmpty, setServerCall, setUserCredentials, setVersion, validateInput
-
-
-
-
Field Detail
-
MULTI_ARG_SEP
public static final java.lang.String MULTI_ARG_SEP
- See Also:
- Constant Field Values
-
COLUMNS_PARAM
public static final java.lang.String COLUMNS_PARAM
- See Also:
- Constant Field Values
-
FILTER_PARAM
public static final java.lang.String FILTER_PARAM
- See Also:
- Constant Field Values
-
START_PARAM
public static final java.lang.String START_PARAM
- See Also:
- Constant Field Values
-
LIMIT_PARAM
public static final java.lang.String LIMIT_PARAM
- See Also:
- Constant Field Values
-
FILTER_NAME_PARAM
public static final java.lang.String FILTER_NAME_PARAM
- See Also:
- Constant Field Values
-
FILTER_DESCRIPTION_PARAM
public static final java.lang.String FILTER_DESCRIPTION_PARAM
- See Also:
- Constant Field Values
-
FILTER_EXTENSIONS_PARAM
public static final java.lang.String FILTER_EXTENSIONS_PARAM
- See Also:
- Constant Field Values
-
SORTBY_PARAM
public static final java.lang.String SORTBY_PARAM
- See Also:
- Constant Field Values
-
SORTING_ORDER_PARAM
public static final java.lang.String SORTING_ORDER_PARAM
- See Also:
- Constant Field Values
-
ASCENDING_SORTING_ORDER_PARAM
public static final java.lang.String ASCENDING_SORTING_ORDER_PARAM
- See Also:
- Constant Field Values
-
DESCENDING_SORTING_ORDER_PARAM
public static final java.lang.String DESCENDING_SORTING_ORDER_PARAM
- See Also:
- Constant Field Values
-
OUTPUT_PARAM
public static final java.lang.String OUTPUT_PARAM
- See Also:
- Constant Field Values
-
validCharRegEx
public static final java.lang.String validCharRegEx
- See Also:
- Constant Field Values
-
validNamePattern
public static final java.util.regex.Pattern validNamePattern
-
validCharRegExWithSpace
public static final java.lang.String validCharRegExWithSpace
- See Also:
- Constant Field Values
-
validDescPattern
public static final java.util.regex.Pattern validDescPattern
-
filterCreateUsage
public static java.lang.String filterCreateUsage
-
filterModifyUsage
public static java.lang.String filterModifyUsage
-
filterRemoveUsage
public static java.lang.String filterRemoveUsage
-
filterInfoUsage
public static java.lang.String filterInfoUsage
-
filterListUsage
public static java.lang.String filterListUsage
-
filefilterCommandsArray
public static com.mapr.cliframework.base.CLICommand[] filefilterCommandsArray
-
filefilterCommands
public static final com.mapr.cliframework.base.CLICommand filefilterCommands
-
-
Method Detail
-
executeRealCommand
public com.mapr.cliframework.base.CommandOutput executeRealCommand() throws com.mapr.cliframework.base.CLIProcessingException- Specified by:
executeRealCommandin classcom.mapr.cliframework.base.CLIBaseClass- Throws:
com.mapr.cliframework.base.CLIProcessingException
-
filterLookupById
public static com.mapr.fs.cldb.proto.CLDBProto.FileFilterLookupResponse filterLookupById(java.lang.String cluster, com.mapr.fs.proto.Security.CredentialsMsg creds, int filterId) throws com.mapr.cliframework.base.CLIProcessingException, com.mapr.security.MaprSecurityException- Throws:
com.mapr.cliframework.base.CLIProcessingExceptioncom.mapr.security.MaprSecurityException
-
filterLookupByName
public static com.mapr.fs.cldb.proto.CLDBProto.FileFilterLookupResponse filterLookupByName(java.lang.String cluster, com.mapr.fs.proto.Security.CredentialsMsg creds, java.lang.String filtername) throws com.mapr.cliframework.base.CLIProcessingException, com.mapr.security.MaprSecurityException- Throws:
com.mapr.cliframework.base.CLIProcessingExceptioncom.mapr.security.MaprSecurityException
-
filterLookup
public static com.mapr.fs.cldb.proto.CLDBProto.FileFilterLookupResponse filterLookup(java.lang.String cluster, com.mapr.fs.proto.Security.CredentialsMsg creds, java.lang.String filtername, int filterId) throws com.mapr.cliframework.base.CLIProcessingException, com.mapr.security.MaprSecurityException- Throws:
com.mapr.cliframework.base.CLIProcessingExceptioncom.mapr.security.MaprSecurityException
-
processResponse
public void processResponse(com.mapr.cliframework.base.CommandOutput.OutputHierarchy out, com.google.protobuf.MessageLite response) throws com.mapr.cliframework.base.CLIProcessingExceptionDescription copied from interface:ListIteratorParse the response and populate the output hierarchy.- Specified by:
processResponsein interfaceListIterator- Specified by:
processResponsein classListCommand- Parameters:
out- -CommandOutput.OutputHierarchyresponse- - response object- Throws:
com.mapr.cliframework.base.CLIProcessingException
-
sendRequest
public com.mapr.fs.cldb.proto.CLDBProto.FileFilterListResponse sendRequest(com.google.protobuf.MessageLite request) throws com.mapr.cliframework.base.CLIProcessingExceptionDescription copied from interface:ListIteratorSend the request using RPC and fetch the response.- Specified by:
sendRequestin interfaceListIterator- Specified by:
sendRequestin classListCommand- Parameters:
request- - request object.- Returns:
- - the response object.
- Throws:
com.mapr.cliframework.base.CLIProcessingException
-
buildNextRequest
public com.mapr.fs.cldb.proto.CLDBProto.FileFilterListRequest buildNextRequest(com.google.protobuf.MessageLite prevReq, com.google.protobuf.MessageLite prevResp) throws com.mapr.cliframework.base.CLIProcessingExceptionDescription copied from interface:ListIteratorBuilds the next request object by inspecting the previous request and previous response.- Specified by:
buildNextRequestin interfaceListIterator- Specified by:
buildNextRequestin classListCommand- Returns:
- - new request object
- Throws:
com.mapr.cliframework.base.CLIProcessingException
-
hasMore
public boolean hasMore(com.google.protobuf.MessageLite prevReq, com.google.protobuf.MessageLite prevResp) throws com.mapr.cliframework.base.CLIProcessingExceptionDescription copied from interface:ListIteratorInspect the last request and last response to see if there are more records to be fetched.- Specified by:
hasMorein interfaceListIterator- Specified by:
hasMorein classListCommand- Returns:
- - true, if there are more records. false, if no more.
- Throws:
com.mapr.cliframework.base.CLIProcessingException
-
-