|
Agent System POND 1.2 (28.2.2002) | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--FIM.payment.AnonymousInvoice | +--FIM.payment.NamedInvoice
An invoice for a certain entity (addressee, not issuer!), which is described as a string or a certificate (or both).
Constructor Summary | |
protected |
NamedInvoice()
Creates a new empty invoice. |
|
NamedInvoice(Element elem)
Create a new invoice from an XML element. |
|
NamedInvoice(String issuer,
Certificate issuerCert,
Date date,
String title,
InvoiceItem[] items,
String addressee,
Certificate addresseeCert)
Create a new invoice. |
Method Summary | |
void |
decodeXMLElement(Element elem)
Parse back the invoice from an XML element. |
String |
getAddressee()
Retrieve the addressee of the invoice as a string. |
Certificate |
getAddresseeCertificate()
Retrieve the addressee of the invoice as a certificate (might be null ). |
Element |
getAsXMLElement(Document doc)
Retrieve the invoice as an XML element. |
byte[] |
getEncoded()
Retrieve the invoice in encoded form to be used for signing. |
String |
toString()
Retrieve the invoice as a string, suitable for presenting to the user in a very simple form. |
Methods inherited from class FIM.payment.AnonymousInvoice |
getAsSerializable, getCertificate, getDate, getIssuer, getIssuerCertificate, getItems, getTitle, getTotalPrice, isSigned, sign, verifySignature, verifySignature |
Methods inherited from class java.lang.Object |
|
Constructor Detail |
public NamedInvoice(String issuer, Certificate issuerCert, Date date, String title, InvoiceItem[] items, String addressee, Certificate addresseeCert)
issuer
- the issuer of the invoiceissuerCert
- the certificate of the issuer of the invoicedata
- the date for the invoicetitle
- the title of the invoiceitem
- an array of items for the invoice. At least one requiredaddressee
- the addressee of the invoiceaddresseeCert
- the certificate of the addressee of the invoicepublic NamedInvoice(Element elem)
elem
- the XML element containing the encoded formprotected NamedInvoice()
decodeXMLElement
.Method Detail |
public String getAddressee()
public Certificate getAddresseeCertificate()
null
).null
public byte[] getEncoded()
getEncoded
in class AnonymousInvoice
public String toString()
toString
in class AnonymousInvoice
public Element getAsXMLElement(Document doc)
getAsXMLElement
in class AnonymousInvoice
doc
- the document within which to create the elementpublic void decodeXMLElement(Element elem) throws IllegalArgumentException
decodeXMLElement
in class AnonymousInvoice
elem
- the element containing the price to parse backIllegalArgumentException
- if the element is incorrect (e. g. wrong tag name)
|
Agent System POND 1.2 (28.2.2002) | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |