The {@link #applyTo(Image)} method provides an efficient way to replace thecontents of an existing Image
. This is useful in cases where an image changes its appearance based on a user's action. Instead of creating two Image
objects then alternately hiding/showing them, one can use the {@link #applyTo(Image)} method of twoAbstractImagePrototype
objects to transform a single Image
object between two (or more) visual representations. The use of AbstractImagePrototypes
results in an cleaner and more efficient implementation.
This class is also a useful way to encapsulate complex HTML that represents an image without actually instantiating Image
objects. When constructing large HTML fragments, especially those that contain many images, {@link #getHTML()} can be much more efficient.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|