public class FingerprintsHelper extends AbstractAuthHelper
AUTH_VALUE_MAP_KEY, DEFAULT_LOCK_DELAY, DEFAULT_LOCK_TRY, DEFAULT_LOCK_WAIT, SERVER_ADDRESS_MAP_KEY, USER_NAME_MAP_KEY| Constructor and Description |
|---|
FingerprintsHelper() |
| Modifier and Type | Method and Description |
|---|---|
static Fingerprint |
getFingerprint(String serverAddress,
String trustFilePath)
Get the first found fingerprint in the specified fingerprint file that
matches the specified server address.
|
static Fingerprint |
getFingerprint(String userName,
String serverAddress,
String trustFilePath)
Get the first found fingerprint in the specified trust file that matches
the specified user name and server address.
|
static Fingerprint[] |
getFingerprints(File trustFile)
Get all the fingerprints found in the specified file.
|
static Fingerprint[] |
getFingerprints(String trustFilePath)
Get all the fingerprints found in the file at the specified file path.
|
static String |
getFingerprintValue(String userName,
String serverAddress,
String trustFilePath)
Get the first found fingerprint value that matches the specified user
name and server address.
|
static void |
saveFingerprint(Fingerprint fingerprint,
File trustFile)
Save the specified fingerprint as an entry into the specified trust file.
|
static void |
saveFingerprint(Fingerprint fingerprint,
String trustFilePath)
Save the specified fingerprint as an entry into the specified trust file.
|
static void |
saveFingerprint(String userName,
String serverAddress,
String fingerprintValue,
File trustFile)
Save the specified parameters as an entry into the specified trust file.
|
static void |
saveFingerprint(String userName,
String serverAddress,
String fingerprintValue,
File trustFile,
int lockTry,
long lockDelay,
long LockWait)
Save the specified parameters as an entry into the specified trust file.
|
static void |
saveFingerprint(String userName,
String serverAddress,
String fingerprintValue,
String trustFilePath)
Save the specified parameters as an entry into the specified trust file.
|
static void |
saveFingerprint(String userName,
String serverAddress,
String fingerprintValue,
String trustFilePath,
int lockTry,
long lockDelay,
long lockWait)
Save the specified parameters as an entry into the specified trust file.
|
getFileEntries, getMemoryEntries, getMemoryEntry, saveFileEntry, saveMemoryEntrypublic static String getFingerprintValue(String userName, String serverAddress, String trustFilePath) throws IOException
userName - serverAddress - trustFilePath - IOException - - io exception from reading trust filepublic static Fingerprint[] getFingerprints(String trustFilePath) throws IOException
trustFilePath - IOException - - io exception from reading trust filepublic static Fingerprint[] getFingerprints(File trustFile) throws IOException
trustFile - IOException - - io exception from reading trust filepublic static Fingerprint getFingerprint(String userName, String serverAddress, String trustFilePath) throws IOException
userName - - possibly null user name to match against the found
fingerprintsserverAddress - - non-null server addresstrustFilePath - - path to trust file to searchIOException - - io exception from reading trust filepublic static Fingerprint getFingerprint(String serverAddress, String trustFilePath) throws IOException
serverAddress - - non-null server addresstrustFilePath - - path to trust file to searchIOException - - io exception from reading trust filepublic static void saveFingerprint(Fingerprint fingerprint, String trustFilePath) throws IOException
fingerprint - - non-null fingerprinttrustFilePath - - non-null pathIOExceptionpublic static void saveFingerprint(Fingerprint fingerprint, File trustFile) throws IOException
fingerprint - - non-null fingerprinttrustFile - - non-null fileIOExceptionpublic static void saveFingerprint(String userName, String serverAddress, String fingerprintValue, String trustFilePath) throws IOException
userName - - non-null user nameserverAddress - - non-null server addressfingerprintValue - - non-null fingerprint valuetrustFilePath - - non-null file pathIOExceptionpublic static void saveFingerprint(String userName, String serverAddress, String fingerprintValue, String trustFilePath, int lockTry, long lockDelay, long lockWait) throws IOException
userName - - non-null user nameserverAddress - - non-null server addressfingerprintValue - - non-null fingerprint valuetrustFilePath - - non-null file pathlockTry - - number of tries for lockinglockDelay - - delay time (ms) for lockinglockWait - - wait time (ms) for other process/thread to finish lockingIOExceptionpublic static void saveFingerprint(String userName, String serverAddress, String fingerprintValue, File trustFile) throws IOException
userName - - non-null user nameserverAddress - - non-null server addressfingerprintValue - - possibly null fingerprint valuetrustFile - - non-null fileIOExceptionpublic static void saveFingerprint(String userName, String serverAddress, String fingerprintValue, File trustFile, int lockTry, long lockDelay, long LockWait) throws IOException
userName - - non-null user nameserverAddress - - non-null server addressfingerprintValue - - possibly null fingerprint valuetrustFile - - non-null filelockTry - - number of tries for lockinglockDelay - - delay time (ms) for lockinglockWait - - wait time (ms) for other process/thread to finish lockingIOExceptionCopyright © 2017 Perforce Software. All Rights Reserved.