public class Dictionary extends Object
Dictionaries need to use all lower case keys for the words they contain for the algorithm to work correctly.
| Constructor and Description |
|---|
Dictionary(String dictionary_name,
Map<String,Integer> dictonary,
boolean exclusion)
Object used for dictionary matching.
|
| Modifier and Type | Method and Description |
|---|---|
String |
getDictionaryName()
A description of the values contained in the dictionary.
|
Map<String,Integer> |
getDictonary()
The values within this dictionary.
|
List<String> |
getSortedDictionary()
This contains the same values as in getDictionary, but is sorted for optimizing the speed
of the distance calculation
|
Map<Integer,Integer> |
getSortedDictionaryLengthLookup()
A map containing different lengths, and the first index they appear in the sorted dictionary.
|
boolean |
isExclusion()
Returns if this dictionary is used for password exclusion or not.
|
public Dictionary(String dictionary_name, Map<String,Integer> dictonary, boolean exclusion)
dictionary_name - unique name of dictionary.dictonary - Map with the word and it's rank. The key must be lowercase for the matching to work properly.exclusion - true when desiring to disallow any password contained in this dictionary; false otherwise.public Map<String,Integer> getDictonary()
public List<String> getSortedDictionary()
public Map<Integer,Integer> getSortedDictionaryLengthLookup()
public boolean isExclusion()
public String getDictionaryName()
Copyright © 2017. All rights reserved.