gnu.crypto.keyring

Class EnvelopeEntry

public abstract class EnvelopeEntry extends Entry

An envelope entry is a generic container for some number of primitive and other envelope entries.
Field Summary
protected EnvelopeEntrycontainingEnvelope
The envelope that contains this one (if any).
protected Listentries
The contained entries.
Constructor Summary
EnvelopeEntry(int type, Properties properties)
protected EnvelopeEntry(int type)
Method Summary
voidadd(Entry entry)
Adds an entry to this envelope.
booleancontainsAlias(String alias)
Tests if this envelope contains a primitive entry with the given alias.
booleancontainsEntry(Entry entry)
Tests if this envelope contains the given entry.
protected voiddecodeEnvelope(DataInputStream in)
protected voidencodePayload()
Listget(String alias)
Gets all primitive entries that have the given alias.
StringgetAliasList()
Returns the list of all aliases contained by this envelope, separated by a semicolon (';').
ListgetEntries()
Returns a copy of all entries this envelope contains.
booleanremove(Entry entry)
Removes the specified entry.
voidremove(String alias)
Removes all primitive entries that have the specified alias.
protected voidsetContainingEnvelope(EnvelopeEntry e)

Field Detail

containingEnvelope

protected EnvelopeEntry containingEnvelope
The envelope that contains this one (if any).

entries

protected List entries
The contained entries.

Constructor Detail

EnvelopeEntry

public EnvelopeEntry(int type, Properties properties)

EnvelopeEntry

protected EnvelopeEntry(int type)

Method Detail

add

public void add(Entry entry)
Adds an entry to this envelope.

Parameters: entry The entry to add.

containsAlias

public boolean containsAlias(String alias)
Tests if this envelope contains a primitive entry with the given alias.

Parameters: alias The alias to test.

Returns: True if this envelope (or one of the contained envelopes) contains a primitive entry with the given alias.

containsEntry

public boolean containsEntry(Entry entry)
Tests if this envelope contains the given entry.

Parameters: entry The entry to test.

Returns: True if this envelope contains the given entry.

decodeEnvelope

protected void decodeEnvelope(DataInputStream in)

encodePayload

protected void encodePayload()

get

public List get(String alias)
Gets all primitive entries that have the given alias. If there are any masked entries that contain the given alias, they will be returned as well.

Parameters: alias The alias of the entries to get.

Returns: A list of all primitive entries that have the given alias.

getAliasList

public String getAliasList()
Returns the list of all aliases contained by this envelope, separated by a semicolon (';').

Returns: The list of aliases.

getEntries

public List getEntries()
Returns a copy of all entries this envelope contains.

Returns: All contained entries.

remove

public boolean remove(Entry entry)
Removes the specified entry.

Parameters: entry The entry.

Returns: True if an entry was removed.

remove

public void remove(String alias)
Removes all primitive entries that have the specified alias.

Parameters: alias The alias of the entries to remove.

setContainingEnvelope

protected void setContainingEnvelope(EnvelopeEntry e)
Copyright © 2001, 2002, 2003 Free Software Foundation, Inc. All Rights Reserved.