All Packages Class Hierarchy This Package Previous Next Index
Class semper.txlayer.transaction.NRToken
java.lang.Object
|
+----semper.txlayer.transaction.NRToken
- public final class NRToken
- extends Object
- implements Browseable, Serializable
NRTokens contain proofs about things that happened
during a Transaction. The proof is a signed Statement,
containing an NRWrapper with all sorts of data.
We implement the semper.util.browser.Browseable interface.
This is work in progress and not finished.
- See Also:
- Statement, NRView, NRWrapper, NonRepudiation
-
NRToken(Statement)
- Constructor.
-
compareTo(Browseable, int, boolean)
-
Method for sorting Browseables on a specified key.
-
exportToLineOfASCII()
-
Export as a flat ASCII
String
.
-
exportToLineOfHTML()
-
Export as an HTML formatted
String
, consisting of a single line.
-
exportToLinesOfHTML()
-
Export as an HTML formatted
String
, consisting of several lines.
-
getActions()
-
Obtain the names of the actions which can be called for a browseable.
-
getBA()
-
-
getKeys()
-
Obtain the names of the keys which can be used to sort.
-
getMethodName(int)
-
Obtain the name of the method that should be called for a browseable.
-
getName()
-
-
getNrrornro()
-
-
getNRView()
-
-
getReceiver()
-
-
getReceiverTime()
-
-
getSender()
-
-
getSenderTime()
-
-
getStatement()
-
-
getUsedCertificateAsHTML()
-
-
toString()
-
-
verify()
- Verify the signed statement.
-
verifySignature()
-
This method verifies the signature of the NRToken, i.e., the receipt.
-
verifySignatureResultAsHTML()
-
NRToken
public NRToken(Statement statement)
- Constructor.
- Parameters:
- statement - The statement contains the NRView and a signature.
toString
public String toString()
- Overrides:
- toString in class Object
getStatement
public Statement getStatement()
- Returns:
- The signed statement inside us.
getSender
public String getSender()
- Returns:
- The sender inside us.
This is a name from a SituationDescription
used to create the signed statement.
getReceiver
public String getReceiver()
- Returns:
- The receiver inside us.
This is a name from a SituationDescription
used to create the signed statement.
getBA
public String getBA()
- Returns:
- The BA name inside us.
This is a name from a SituationDescription
used to create the signed statement.
getNRView
public NRView getNRView()
- Returns:
- The nrview inside us.
getSenderTime
public Date getSenderTime()
- Returns:
- The local time of the sender when he signed
the NRView.
getReceiverTime
public Date getReceiverTime()
- Returns:
- The local time of the receiver when
the NRView was signed.
getNrrornro
public String getNrrornro()
- Returns:
- Either NRTransfer.NRR or NRTransfer.NRO.
verify
public boolean verify()
- Verify the signed statement.
- Returns:
- True when the signature is ok, false otherwise.
getName
public String getName()
exportToLineOfHTML
public String exportToLineOfHTML()
- Export as an HTML formatted
String
, consisting of a single line.
The HTML should be limited to those HTML tags supported by the Tinguin.
The method gives full control over the formatting.
exportToLinesOfHTML
public String exportToLinesOfHTML()
- Export as an HTML formatted
String
, consisting of several lines.
The HTML should be limited to those HTML tags supported by the Tinguin.
The method gives full control over the formatting.
exportToLineOfASCII
public String exportToLineOfASCII()
- Export as a flat ASCII
String
.
The ASCII String
is to be included in a simply formatted file, for example.
The method gives full control over the formatting.
compareTo
public int compareTo(Browseable other,
int keyno,
boolean reverse)
- Method for sorting Browseables on a specified key.
Other methods could make sorting (and selecting) on individual fields possible.
Precondition: the objects must be of the same type.
- Parameters:
- other - Browseable object to compare with
this
.
- keyno - number of the key field to use in comparisons.
- reverse - if
true
use the reverse order.
- Returns:
- -1, 0, or 1 if
this
is "less than", "equal to", or "larger than"
other, respectively.
getKeys
public String[] getKeys()
- Obtain the names of the keys which can be used to sort.
The index of the key in the result array is its key number.
- Returns:
- a String per key.
getActions
public String[] getActions()
- Obtain the names of the actions which can be called for a browseable.
- Returns:
- a String per action.
getMethodName
public String getMethodName(int n)
- Obtain the name of the method that should be called for a browseable.
- Returns:
- the name of the method.
verifySignature
public boolean verifySignature()
- This method verifies the signature of the NRToken, i.e., the receipt.
- Returns:
- a boolean value of the verification result, i.e., true iff the
signature is valid, false else.
getUsedCertificateAsHTML
public String getUsedCertificateAsHTML()
verifySignatureResultAsHTML
public String verifySignatureResultAsHTML()
All Packages Class Hierarchy This Package Previous Next Index