org.apache.shiro.crypto.hash.format
Interface HashFormat

All Known Subinterfaces:
ModularCryptFormat, ParsableHashFormat
All Known Implementing Classes:
Base64Format, HexFormat, Shiro1CryptFormat

public interface HashFormat

A HashFormat is able to format a Hash instance into a well-defined formatted String.

Note that not all HashFormat algorithms are reversible. That is, they can't be parsed and reconstituted to the original Hash instance. The traditional Unix crypt(3) is one such format.

The formats that are reversible however will be represented as ParsableHashFormat instances.

Since:
1.2
See Also:
ParsableHashFormat

Method Summary
 String format(Hash hash)
          Returns a formatted string representing the specified Hash instance.
 

Method Detail

format

String format(Hash hash)
Returns a formatted string representing the specified Hash instance.

Parameters:
hash - the hash instance to format into a String.
Returns:
a formatted string representing the specified Hash instance.


Copyright © 2004-2014 The Apache Software Foundation. All Rights Reserved.