Package passwordmanager.decoded
Class ListStorage
java.lang.Object
passwordmanager.decoded.ListStorage
Implementation of a data structure with decrypted records in the form of
array list
- Since:
- 2023-12-14
- See Also:
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionConstructor initializing the list of encrypted records and the name of the structure -
Method Summary
Modifier and TypeMethodDescriptionvoidclear()Method for cleaning up the data structureclone()Method for cloning a data structure with decrypted recordsvoidA method that creates a new entry in the repositoryvoiddelete(int index) Method removing information about a record in the repositoryfilterByInfo(String query) Method for filtering structure recordsgetByIndex(int index) Method that reads an entry from the repositorygetName()Method for getting the name of an decrypted data structurebooleanisEmpty()Method for checking a structure for missing valuesiterator()Method to get list iteratorvoidMethod for setting the name of an encrypted data structureintsize()Method for getting the number of elements in a data structurevoidMethod updating information about a record in the repository
-
Field Details
-
storage
List of decrypted records -
name
Name of an decrypted data structure
-
-
Constructor Details
-
ListStorage
public ListStorage()Constructor initializing the list of encrypted records and the name of the structure
-
-
Method Details
-
create
A method that creates a new entry in the repository -
getByIndex
Method that reads an entry from the repository- Specified by:
getByIndexin interfaceIStorage- Parameters:
index- Index of entry to read in structure
-
update
Method updating information about a record in the repository -
delete
public void delete(int index) Method removing information about a record in the repository -
isEmpty
public boolean isEmpty()Method for checking a structure for missing values -
clear
public void clear()Method for cleaning up the data structure -
size
public int size()Method for getting the number of elements in a data structure -
getName
Method for getting the name of an decrypted data structure -
setName
Method for setting the name of an encrypted data structure -
clone
Method for cloning a data structure with decrypted records -
iterator
Method to get list iterator- Returns:
- list iterator
-
filterByInfo
Method for filtering structure records- Specified by:
filterByInfoin interfaceIStorage- Parameters:
query- filter string
-