public class KStringHolder extends Object implements EventListener
Modifier and Type | Class and Description |
---|---|
class |
KStringHolder.TagReference<TARGET>
Class that holds and maintains the reference for a tag.
|
Modifier and Type | Field and Description |
---|---|
static String |
BASE_ERROR_ID
The error ID base.
|
Constructor and Description |
---|
KStringHolder(IKStringHolder<?> holder)
Constructor for a holder of a single KString.
|
Modifier and Type | Method and Description |
---|---|
void |
disposeHolder()
Disposes of the instance and the KString and removes property listener.
|
KString |
getRefactoredKString()
Gets the refactored KString.
|
protected boolean |
isReferenceTreeValid()
Verifies if the tree is valid for reference creation, i.e.
|
void |
onEvent(GEvent event)
Called when a property event is send to the holder property.
|
protected void |
onReferenceEvent(ResolveReferencesEvent event)
Called to perform reference resolving.
|
void |
resolve(boolean doReCheck,
GEvent triggerEvent)
Resolves the references.
|
void |
resolveBeforeSend()
Resolves the references in the KString if required before sending it to the
remote party.
|
void |
setKString(KString ks)
Called when a KString is assigned in the holder.
|
void |
verify(PropVerification verification,
String location)
Called when a KString requires verification of the references due to broken or valid references.
|
public static final String BASE_ERROR_ID
public KStringHolder(IKStringHolder<?> holder)
holder
- The holder property.NullPointerException
- If the holder is null.public void disposeHolder()
public void setKString(KString ks)
ks
- The KString, or null for none (same as calling dispose() method).public KString getRefactoredKString()
The returned instance is of the same type, i.e. if a PlainKString is the original string, this will also be the return from this call.
public void resolve(boolean doReCheck, GEvent triggerEvent)
doReCheck
- Re-check flag.triggerEvent
- The triggering property event.public void resolveBeforeSend()
protected boolean isReferenceTreeValid()
public void onEvent(GEvent event)
onEvent
in interface EventListener
event
- The property event.protected void onReferenceEvent(ResolveReferencesEvent event)
Subclasses override this method and only subclasses extending PropCnr
needs to
call super.onReferenceEvent(ResolveReferenceEvent event)
.
event
- The resolve references event.public void verify(PropVerification verification, String location)
verification
- The property verification class.location
- The location.iizi® is a registered trademark of Mindus SARL. © Copyright Mindus SARL, 2020. All rights reserved.