Class InMemoryHistory
java.lang.Object
org.aesh.readline.history.History
org.aesh.readline.history.InMemoryHistory
- Direct Known Subclasses:
FileHistory
A simple in-memory history implementation
By default max size is 500
- Author:
- Ståle W. Pedersen
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclear()int[]find(int[] search) int[]get(int index) List<int[]> getAll()int[]int[]int[]voidpush(int[] entry) int[]search(int[] search) voidsetCurrent(int[] line) voidsetSearchDirection(SearchDirection direction) intsize()voidstop()
-
Constructor Details
-
InMemoryHistory
public InMemoryHistory() -
InMemoryHistory
public InMemoryHistory(int maxSize)
-
-
Method Details
-
push
-
find
-
get
-
size
-
setSearchDirection
- Specified by:
setSearchDirectionin classHistory
-
getSearchDirection
- Specified by:
getSearchDirectionin classHistory
-
getPreviousFetch
public int[] getPreviousFetch()- Specified by:
getPreviousFetchin classHistory
-
getNextFetch
public int[] getNextFetch()- Specified by:
getNextFetchin classHistory
-
search
-
setCurrent
public void setCurrent(int[] line) - Specified by:
setCurrentin classHistory
-
getCurrent
public int[] getCurrent()- Specified by:
getCurrentin classHistory
-
getAll
-
clear
-
stop
-