|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.qedeq.kernel.bo.service.basis.QedeqVoBuilder
public class QedeqVoBuilder
TODO 20110125 m31: why do we need this builder? To make copies. Why don't we take the original? At least use director pattern or transfer creation methods into BOs or use visitor pattern! We have lots of duplicate code here!
An builder for creating QedeqVo
s. This builder takes
something that implements the QEDEQ interfaces (beginning with
(@link org.qedeq.kernel.base.module.Qedeq} and makes copies that are out of the package
org.qedeq.kernel.dto.*
. Only elements that are not null
are
copied.
Constructor Summary | |
---|---|
protected |
QedeqVoBuilder(ModuleAddress address)
Constructor. |
Method Summary | |
---|---|
protected QedeqVo |
create(Qedeq original)
Create out of an Qedeq instance. |
static QedeqVo |
createQedeq(ModuleAddress address,
Qedeq original)
Create QedeqVo out of an Qedeq instance. |
protected ModuleContext |
getCurrentContext()
Get current context within original. |
protected Qedeq |
getQedeqOriginal()
Get original QEDEQ module. |
protected void |
setLocationWithinModule(java.lang.String locationWithinModule)
Set location information where are we within the original module. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
protected QedeqVoBuilder(ModuleAddress address)
address
- QEDEQ address.Method Detail |
---|
public static QedeqVo createQedeq(ModuleAddress address, Qedeq original) throws ModuleDataException
QedeqVo
out of an Qedeq
instance.
The resulting object has no references to the original Qedeq
instance.
During the creation process the caller must assert that no modifications are made
to the Qedeq
instance including its referenced objects.
address
- Module address.original
- Basic QEDEQ module object.
ModuleDataException
- Invalid data found.protected final QedeqVo create(Qedeq original) throws IllegalModuleDataException
Qedeq
instance.
During that procedure some basic checking is done. E.g. the uniqueness of entries
is tested. The resulting business object has no references to the original
Qedeq
instance.
During the creation process the caller must assert that no modifications are made
to the Qedeq
instance including its referenced objects.
original
- Basic QEDEQ module object.
IllegalModuleDataException
- Basic semantic error occurred.protected void setLocationWithinModule(java.lang.String locationWithinModule)
locationWithinModule
- Location within module.protected final ModuleContext getCurrentContext()
protected final Qedeq getQedeqOriginal()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |