public abstract class AbstractComposite extends AbstractType implements Composite
Modifier and Type | Field and Description |
---|---|
protected org.slf4j.Logger |
log |
Constructor and Description |
---|
AbstractComposite(Message message) |
Modifier and Type | Method and Description |
---|---|
boolean |
accept(MessageVisitor visitor,
Location location)
Callback method for the visitor.
|
void |
clear()
Clears all data from this type
|
protected <T extends Type> |
getTyped(int idx,
Class<T> type) |
boolean |
isEmpty()
Returns true if this Visitable has actual content
|
Location |
provideLocation(Location location,
int index,
int repetition)
Reusing the location of this object's parent, this method returns its own
location within the message.
|
encode, getExtraComponents, getMessage, getName, parse, toString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getComponent, getComponents
encode, getExtraComponents, getMessage, getName, parse
protected org.slf4j.Logger log
public AbstractComposite(Message message)
public void clear()
AbstractType
clear
in interface Type
clear
in class AbstractType
public boolean isEmpty() throws HL7Exception
AbstractType
isEmpty
in interface Visitable
isEmpty
in class AbstractType
HL7Exception
- if an error occurred while determining emptinesspublic boolean accept(MessageVisitor visitor, Location location) throws HL7Exception
Visitable
this
as parameter, or
traverse through a hierarchical substructure and call accept(MessageVisitor)
for each visited element.accept
in interface Visitable
visitor
- MessageVisitor instance to be called backlocation
- location of this objecttrue
if the visit process shall continueHL7Exception
- if a problem occurred during visitingpublic Location provideLocation(Location location, int index, int repetition)
Visitable
provideLocation
in interface Visitable
provideLocation
in class AbstractType
location
- the parents locationindex
- index of this objectrepetition
- repetition of this objectCopyright © 2001–2017 University Health Network. All rights reserved.