org.salespointframework.core.data.filters
Class CurrencyFilter<T extends CurrencyItem>

java.lang.Object
  extended by org.salespointframework.core.data.filters.CatalogFilter<T>
      extended by org.salespointframework.core.data.filters.CurrencyFilter<T>
All Implemented Interfaces:
java.lang.Comparable<java.lang.Object>, java.util.EventListener, CatalogChangeListener<T>, DatasourceChangeListener, ExternalModificationListener, Catalog<T>, CatalogItem, Currency<T>, DataBasketEntryDestination, DataBasketEntrySource, ListenableCatalog<T>, Nameable, SpAggregate, SpItem, HelpableListener

public abstract class CurrencyFilter<T extends CurrencyItem>
extends CatalogFilter<T>
implements Currency<T>

A CatalogFilter that filters Currencies.

Since:
v2.0
Version:
2.0 19/08/1999
Author:
Steffen Zschaler

Field Summary
 
Fields inherited from class org.salespointframework.core.data.filters.CatalogFilter
m_cOrg, m_lhListeners
 
Fields inherited from interface org.salespointframework.core.data.interfaces.CatalogItem
VALUE_PROPERTY
 
Fields inherited from interface org.salespointframework.core.data.interfaces.Nameable
NAME_PROPERTY
 
Constructor Summary
CurrencyFilter(Currency<T> c)
          Create a new CurrencyFilter.
 
Method Summary
 NumberValue parse(java.lang.String s)
          Try to parse the given String as a Currency value using the source Currency.
 java.lang.String toString(NumberValue nv)
          Convert the given value to its String representation using the source Currency.
 
Methods inherited from class org.salespointframework.core.data.filters.CatalogFilter
add, addCatalogChangeListener, addedCatalogItem, addNameListener, addPropertyChangeListener, addValueListener, attach, canEditCatalogItem, canRemoveCatalogItem, commitedAddCatalogItem, commitEditCatalogItem, commitedRemoveCatalogItem, compareTo, contains, DatasourceChanged, detachNC, editingCatalogItem, externalModificationOccurred, fireCanEditCatalogItem, fireCanRemoveCatalogItem, fireCatalogItemAddCommit, fireCatalogItemAdded, fireCatalogItemAddRollback, fireCatalogItemDataChanged, fireCatalogItemRemoveCommit, fireCatalogItemRemoved, fireCatalogItemRemoveRollback, fireCommitEditCatalogItem, fireEditingCatalogItem, fireNoEditCatalogItem, fireNoRemoveCatalogItem, firePropertyChanged, fireRollbackEditCatalogItem, get, getCatalog, getImage, getMainCatalog, getName, getValue, iterator, keySet, match, noEditCatalogItem, noRemoveCatalogItem, remove, remove, removeCatalogChangeListener, removedCatalogItem, removeNameListener, removePropertyChangeListener, removeValueListener, rollbackEditCatalogItem, rolledbackAddCatalogItem, rolledbackRemoveCatalogItem, setImage, setName, size, subscribe, unsubscribe, updateModel
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.salespointframework.core.data.interfaces.Catalog
add, contains, get, iterator, keySet, remove, remove, size
 
Methods inherited from interface org.salespointframework.core.data.interfaces.CatalogItem
addValueListener, firePropertyChanged, getCatalog, getImage, getValue, removeValueListener, setImage
 
Methods inherited from interface org.salespointframework.core.data.interfaces.Nameable
addNameListener, addPropertyChangeListener, attach, detachNC, getName, removeNameListener, removePropertyChangeListener, setName
 
Methods inherited from interface java.lang.Comparable
compareTo
 
Methods inherited from interface org.salespointframework.core.data.interfaces.SpItem
getName
 
Methods inherited from interface org.salespointframework.core.data.events.DatasourceChangeListener
DatasourceChanged
 
Methods inherited from interface org.salespointframework.core.data.events.ExternalModificationListener
externalModificationOccurred
 

Constructor Detail

CurrencyFilter

public CurrencyFilter(Currency<T> c)
Create a new CurrencyFilter.

Parameters:
c - the Currency to be filtered.
Method Detail

toString

public java.lang.String toString(NumberValue nv)
Convert the given value to its String representation using the source Currency.

Specified by:
toString in interface Currency<T extends CurrencyItem>
Parameters:
nv - the value to be converted

parse

public NumberValue parse(java.lang.String s)
                  throws java.text.ParseException
Try to parse the given String as a Currency value using the source Currency.

Specified by:
parse in interface Currency<T extends CurrencyItem>
Parameters:
s - the text to be parsed
Returns:
the interpreted value in the smallest unit of the currency.
Throws:
java.text.ParseException - if the input could not be parsed.