All Packages Class Hierarchy This Package Previous Next Index
Class semper.commerce.Description
java.lang.Object
|
+----semper.commerce.Description
- public final class Description
- extends Object
- implements Serializable
This class encapsulates the textual description of a transaction.
Each transaction is described by a free format textual description that
will be inspected by the user and signed if the transaction type requires
signatures. The description is generated by the business application
based on the transaction attributes and the context in which the
transaction is done.
Implementation note: Care must be taken when
modifying this class. It must be impossible for a business application
to alter the transaction after it has been inspected and authorised by
the user.
- Version:
- $Id: Description.java,v 1.4 1998/08/24 11:35:34 semper Exp $
- Author:
- Rolf Michelsen, Stig Mj�lsnes
- See Also:
- Transaction
-
Description(String, String)
- Creates a transaction description.
-
getBody()
- Returns the body of the transaction description.
-
getHeader()
- Returns the header of the transaction description.
-
toString()
- Returns a string representation of this object.
Description
public Description(String header,
String body)
- Creates a transaction description. The description header and body
must be supplied.
Implementation note: This method utilisies the
fact that String objects are immutable. This ensures that the
description cannot be altered by manipulating the header and body
objects after having passed them to this method.
- Parameters:
- header - A one line transaction header.
- body - A detailed description of the transaction.
getHeader
public final String getHeader()
- Returns the header of the transaction description.
- Returns:
- The transaction description header.
getBody
public final String getBody()
- Returns the body of the transaction description.
- Returns:
- The transaction description body.
toString
public final String toString()
- Returns a string representation of this object. This string is just the
description header. The methods
getHeader
and
getBody
are more apropriate for converting the description to
a string.
- Returns:
- A string representation of the description object.
- Overrides:
- toString in class Object
- See Also:
- getHeader, getBody
All Packages Class Hierarchy This Package Previous Next Index