gnu.crypto.mac

Class MacFactory

public class MacFactory extends Object implements Registry

A Factory that instantiates instances of every supported Message Authentication Code algorithms, including all HMAC algorithms.

Version: $Revision: 1.8 $

Method Summary
static IMacgetInstance(String name)

Returns an instance of a MAC algorithm given its name.

static SetgetNames()

Returns a java.util.Set of names of MAC algorithms supported by this Factory.

Method Detail

getInstance

public static IMac getInstance(String name)

Returns an instance of a MAC algorithm given its name.

Parameters: name the name of the MAC algorithm.

Returns: an instance of the MAC algorithm, or null if none can be constructed.

Throws: InternalError if the implementation does not pass its self-test.

getNames

public static final Set getNames()

Returns a java.util.Set of names of MAC algorithms supported by this Factory.

Returns: a java.util.Set of MAC names (Strings).

Copyright © 2001, 2002, 2003 Free Software Foundation, Inc. All Rights Reserved.