Class JCoHelper.RecordWrapper
java.lang.Object
de.hybris.platform.sap.core.bol.backend.jco.JCoHelper.RecordWrapper
- Enclosing class:
- JCoHelper
Wraps around a JCo record and decorates the record with convenient methods to set the record's data.
An important feature is that changelists (the X-structures) are maintained transparently and that you are able to directly pass the higher level internet sales data structures to the JCo struct.
Secondly the handling of boolean values is improved (no more "X").
An important feature is that changelists (the X-structures) are maintained transparently and that you are able to directly pass the higher level internet sales data structures to the JCo struct.
Secondly the handling of boolean values is improved (no more "X").
- Version:
- 1.0
-
Constructor Summary
ConstructorsConstructorDescriptionRecordWrapper(com.sap.conn.jco.JCoRecord record) Creates a new wrapper around the JCo structure.RecordWrapper(com.sap.conn.jco.JCoRecord record, com.sap.conn.jco.JCoRecord changeList) Creates a new wrapper around the JCo record. -
Method Summary
Modifier and TypeMethodDescriptionbooleangetBoolean(String field) Returns the value of the specified field as a Java languagebooleanprimitive type.com.sap.conn.jco.JCoRecordReturns the JCO.Record that is wrapped by this class and is used as a X-Structure.com.sap.conn.jco.JCoRecordReturns the JCO.Record that is wrapped by this class.Returns the value of the specified field as a Java languageStringobject.getTechKey(String field) Returns the value of the specified field as aTechKeyobject.voidSets the given field of the JCo structure to the provided value.voidSets the given field of the JCo structure to the provided value.voidSets the given field of the JCo structure to the provided value.voidSets the given field of the JCo structure to the provided value.voidSets the given field of the JCo structure to the provided value.voidSets the given field of the JCo structure to the provided value.voidSets the given field of the JCo structure to the value of the provided technical key (the TechKey is an abstraction of the SAP GUI).voidSets the given field of the JCo record to the value of the provided technical key (the TechKey is an abstraction of the SAP GUI).voidSets the given field of the JCo structure to the provided value.voidSets the given field of the JCo structure to the provided value.voidsetValueFilledLeft(String value, String field, String filler) Sets the given field of the JCo structure to the provided value.
-
Constructor Details
-
RecordWrapper
public RecordWrapper(com.sap.conn.jco.JCoRecord record, com.sap.conn.jco.JCoRecord changeList) Creates a new wrapper around the JCo record.- Parameters:
record- The record to store the data inchangeList- Changelist used by the X-structures
-
RecordWrapper
public RecordWrapper(com.sap.conn.jco.JCoRecord record) Creates a new wrapper around the JCo structure.- Parameters:
record- The record to store the data in
-
-
Method Details
-
getRecord
public com.sap.conn.jco.JCoRecord getRecord()Returns the JCO.Record that is wrapped by this class.- Returns:
- the wrapped
JCoRecord
-
getChangeList
public com.sap.conn.jco.JCoRecord getChangeList()Returns the JCO.Record that is wrapped by this class and is used as a X-Structure.- Returns:
- the wrapped
JCoRecord
-
setValue
Sets the given field of the JCo structure to the provided value. The changelist, if present, is automatically maintained.- Parameters:
value- Value to be setfield- JCo field to be filled with the value
-
setValueFilledLeft
Sets the given field of the JCo structure to the provided value. The value is filled up with filler to the left The changelist, if present, is automatically maintained.- Parameters:
value- Value to be setfield- JCo field to be filled with the valuefiller- The single-char-string to fill up value to the left
-
setValue
Sets the given field of the JCo structure to the provided value. The changelist, if present, is only maintained if themaintainChangeflag is set totrue.- Parameters:
value- Value to be setfield- JCo field to be filled with the valuemaintainChange- Indicates whether the changelist should be maintained or not
-
setValue
Sets the given field of the JCo structure to the provided value. The changelist, if present, is automatically maintained.- Parameters:
value- Value to be setfield- JCo field to be filled with the value
-
setValue
Sets the given field of the JCo structure to the provided value. The changelist, if present, is automatically maintained.- Parameters:
value- Value to be setfield- JCo field to be filled with the value
-
setValue
Sets the given field of the JCo structure to the provided value. The changelist, if present, is only maintained if themaintainChangeflag is set totrue.- Parameters:
value- Value to be setfield- JCo field to be filled with the valuemaintainChange- Indicates whether the changelist should be maintained or not
-
setValue
Sets the given field of the JCo structure to the provided value. The changelist, if present, is only maintained if themaintainChangeflag is set totrue.- Parameters:
value- Value to be setfield- JCo field to be filled with the valuemaintainChange- Indicates whether the changelist should be maintained or not
-
setValue
Sets the given field of the JCo structure to the provided value. The changelist, if present, is automatically maintained.- Parameters:
value- Value to be setfield- JCo field to be filled with the value
-
setValue
Sets the given field of the JCo structure to the provided value. The changelist, if present, is only maintained if themaintainChangeflag is set totrue.- Parameters:
value- Value to be setfield- JCo field to be filled with the valuemaintainChange- Indicates whether the changelist should be maintained or not
-
setValue
Sets the given field of the JCo structure to the value of the provided technical key (the TechKey is an abstraction of the SAP GUI).
The changelist, if present, is automatically maintained.
If the provided key isnullnothing is done and the method returns immediately.- Parameters:
techkey- Technical key to be setfield- JCo field to be filled with the value
-
setValue
Sets the given field of the JCo record to the value of the provided technical key (the TechKey is an abstraction of the SAP GUI).
The changelist, if present, is only maintained if themaintainChangeflag is set totrue.
If the provided tech key isnullnothing is done and the method returns immediately.- Parameters:
techkey- Technical key to be setfield- JCo field to be filled with the valuemaintainChange- Indicates whether the changelist should be maintained or not
-
getTechKey
Returns the value of the specified field as aTechKeyobject.- Parameters:
field- JCo field to be retrieved- Returns:
- TechKey constructed from the value of the given field
-
getString
Returns the value of the specified field as a Java languageStringobject.- Parameters:
field- JCo field to be retrieved- Returns:
- String constructed from the value of the given field
-
getBoolean
Returns the value of the specified field as a Java languagebooleanprimitive type.- Parameters:
field- JCo field to be retrieved- Returns:
- Boolean constructed from the value of the given field
-