public abstract class SimpleDataElt extends DataElt
Constructor and Description |
---|
SimpleDataElt(java.lang.String name,
SimpleDataEltType type) |
SimpleDataElt(java.lang.String name,
SimpleDataEltType type,
java.lang.String propertyname)
Creates a simple data element
|
Modifier and Type | Method and Description |
---|---|
void |
addPayload(MessageReader reader)
for each element, should read and add content for all elements between the
"TYP" field (excluded) and the "DELT" structure end (also excluded)
|
abstract SimpleDataElt |
cloneElt()
makes a deep copy of the element
|
abstract java.lang.String |
defaultTextRepresentation() |
abstract void |
forceContent(java.lang.String constraintvalue) |
protected static SimpleDataElementCreator |
getEltCreator(MessageReader reader) |
protected abstract java.lang.Object |
getMessageArrayValue() |
protected abstract MessageFieldSpec |
getMessageFieldSpec() |
java.lang.String |
getPropertyname() |
void |
setPropertyname(java.lang.String propertyname)
sets the property name for the field (this is linked to how Open Lowcode
stores data object
|
java.lang.String |
toString() |
abstract void |
writePayload(MessageWriter writer)
writes the payload for network transport
|
void |
WriteSpecToMessage(MessageWriter writer) |
void |
writeToMessage(MessageWriter writer)
writes the element for network transmission
|
void |
writeToMessage(MessageWriter writer,
java.util.HashMap<java.lang.String,NamedInterface> hiddenfields) |
getType, readFromCML, writeReferenceToCML
changeName, cleanName, equals, getName
public SimpleDataElt(java.lang.String name, SimpleDataEltType type, java.lang.String propertyname)
name
- name of the propertytype
- type of the elementpropertyname
- name of the propertypublic SimpleDataElt(java.lang.String name, SimpleDataEltType type)
name
- name of the elementtype
- type of the elementpublic java.lang.String getPropertyname()
public void setPropertyname(java.lang.String propertyname)
propertyname
- name of the propertypublic abstract SimpleDataElt cloneElt()
public abstract void writePayload(MessageWriter writer) throws java.io.IOException
writer
- writerjava.io.IOException
- if anything wrongs happens in the message sendingpublic abstract java.lang.String defaultTextRepresentation()
public void writeToMessage(MessageWriter writer) throws java.io.IOException
writer
- the message writerjava.io.IOException
- in case anything goes wrong in the network transmissionpublic void WriteSpecToMessage(MessageWriter writer) throws java.io.IOException
java.io.IOException
public void writeToMessage(MessageWriter writer, java.util.HashMap<java.lang.String,NamedInterface> hiddenfields) throws java.io.IOException
writeToMessage
in class DataElt
hiddenfields
- if the data is made of Data Objects, it is possible to
hide fieldsjava.io.IOException
public abstract void forceContent(java.lang.String constraintvalue)
constraintvalue
- force the content in payload. May not be implemented
for all the typesprotected abstract MessageFieldSpec getMessageFieldSpec()
protected abstract java.lang.Object getMessageArrayValue()
protected static SimpleDataElementCreator getEltCreator(MessageReader reader) throws OLcRemoteException, java.io.IOException
OLcRemoteException
java.io.IOException
public void addPayload(MessageReader reader) throws OLcRemoteException, java.io.IOException
DataElt
addPayload
in class DataElt
reader
- readerOLcRemoteException
- if anything happened to the other partyjava.io.IOException
- if any communication error happens