ch.elexis.data
Class Sticker
java.lang.Object
ch.elexis.data.PersistentObject
ch.elexis.data.Sticker
- All Implemented Interfaces:
- IPersistentObject, ISelectable, ISticker, java.lang.Comparable<ISticker>
public class Sticker
- extends PersistentObject
- implements java.lang.Comparable<ISticker>, ISticker
Eine Markierung für im Prinzip beliebige Objekte. Ein Objekt, das eine Etikette hat, kann diese
Etikette zur Darstellung verwenden
- Author:
- gerry
Fields inherited from class ch.elexis.data.PersistentObject |
CACHE_DEFAULT_LIFETIME, CACHE_MIN_LIFETIME, CFG_CONNECTSTRING, CFG_DRIVER, CFG_PWD, CFG_TYPE, CFG_USER, DELETED, EXISTS, INEXISTENT, INVALID_ID, MATCH_AUTO, MATCH_CONTAINS, MATCH_EXACT, MATCH_REGEXP, MATCH_START |
Constructor Summary |
Sticker(java.lang.String name,
Color fg,
Color bg)
|
Methods inherited from class ch.elexis.data.PersistentObject |
addChangeListener, addSticker, addToList, addXid, begin, checkNull, checkZero, checkZeroDouble, clearCache, connect, connect, deleteList, disconnect, equals, executeSQLScript, exists, exportData, fireChangeEvent, flatten, fold, get, get, getCacheTime, getConnection, getDefaultCacheLifetime, getFieldType, getId, getInt, getLastUpdate, getList, getList, getMap, getSticker, getStickers, getWrappedId, getXid, getXid, getXids, hashCode, isAvailable, isDeleted, isDragOK, isMatching, isMatching, isMatching, isMatching, isShowDeleted, isValid, lock, map, relock, removeChangeListener, removeFromList, removeFromList, removeSticker, resetCache, set, set, setDefaultCacheLifetime, setInt, setMap, setShowDeleted, setTrace, state, storeToString, tableExists, ts, undelete, unlock |
Methods inherited from class java.lang.Object |
getClass, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface ch.elexis.core.data.ISticker |
getId |
IMAGE_ID
public static final java.lang.String IMAGE_ID
- See Also:
- Constant Field Values
BACKGROUND
public static final java.lang.String BACKGROUND
- See Also:
- Constant Field Values
FOREGROUND
public static final java.lang.String FOREGROUND
- See Also:
- Constant Field Values
NAME
public static final java.lang.String NAME
- See Also:
- Constant Field Values
Sticker
public Sticker(java.lang.String name,
Color fg,
Color bg)
createForm
public Composite createForm(Composite parent)
getImage
public Image getImage()
setImage
public void setImage(DBImage image)
setForeground
public void setForeground(java.lang.String fg)
setForeground
public void setForeground(Color fg)
getForeground
public Color getForeground()
setBackground
public void setBackground(java.lang.String bg)
setBackground
public void setBackground(Color bg)
register
public void register()
getBackground
public Color getBackground()
getLabel
public java.lang.String getLabel()
- Description copied from class:
PersistentObject
- Einen menschenlesbaren Identifikationsstring für dieses Objet liefern
- Specified by:
getLabel
in interface IPersistentObject
- Specified by:
getLabel
in interface ISticker
- Specified by:
getLabel
in class PersistentObject
getWert
public int getWert()
- Specified by:
getWert
in interface ISticker
setWert
public void setWert(int w)
- Specified by:
setWert
in interface ISticker
delete
public boolean delete()
- Description copied from class:
PersistentObject
- Ein Objekt und ggf. dessen XID's aus der Datenbank löschen the object is not deleted but
rather marked as deleted. A purge must be applied to remove the object really
- Specified by:
delete
in interface ISticker
- Overrides:
delete
in class PersistentObject
- Returns:
- true on success
setClassForSticker
public void setClassForSticker(java.lang.Class clazz)
- Specified by:
setClassForSticker
in interface ISticker
removeClassForSticker
public void removeClassForSticker(java.lang.Class<?> clazz)
- Specified by:
removeClassForSticker
in interface ISticker
getClassesForSticker
public java.util.List<java.lang.String> getClassesForSticker()
- Specified by:
getClassesForSticker
in interface ISticker
getStickersForClass
public static java.util.List<Sticker> getStickersForClass(java.lang.Class<?> clazz)
- Find all Stickers applicable for a given class
- Parameters:
clazz
-
- Returns:
load
public static Sticker load(java.lang.String id)
compareTo
public int compareTo(ISticker o)
- Specified by:
compareTo
in interface ISticker
- Specified by:
compareTo
in interface java.lang.Comparable<ISticker>
Copyright 2005-2011 by Gerry Weirich, Elexis