java.lang.Object
com.ibm.jzos.sample.fields.MedicareRecord
A class which maps a fictional Medicare Record.
This class demonstrates how a COBOL copybook can be represented in Java using the
JZOS Field
classes. An instance of the CobolDatatypeFactory
is
used to construct static member fields which represent the various fields from the
copybook. The actual copybook field definitions are included as comments prior
to each Java field definition.
Instances of this class accept a byte array (either on the constructor or via the method
setBytes(byte[])
. This byte array represents a COBOL record matching
the MedicareRecord described by the copybook. Individual fields can be accessed via
the supplied getter and setter methods.
- Since:
- 2.1.0
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionint
int
int
int
int
int
byte[]
getBytes()
Answer the underlying byte array mapped by this object.Get the ClaimNumber.int
Get the CoinsuranceDays.int
Get the DischargeDate.int
Get the FromDate.int
Get the FullDays.Get the InpatientDed.Get the IntermediaryCtrlNum.long
Get the IntermediaryNum.int
Get the LifetimeResDays.Get the MedicareProvider.Get the PatientStatus.int
Get the SequenceCounter.int
Get the ThruDate.Get the TotalCharges.int
Get the TransactionInd.void
setAdmissionDate
(int admissionDate) void
setAutoAdjustmentInd
(String autoAdjustmentInd) void
setBenefitsExhaustInd
(int benefitsExhaustInd) void
setBenefitsPayInd
(int benefitsPayInd) void
setBillSource
(int billSource) void
setBloodDed
(BigDecimal bloodDed) void
setBloodPintsFurnished
(int bloodPintsFurnished) void
setBloodPintsReplaced
(int bloodPintsReplaced) void
setBytes
(byte[] buffer) void
setClaimNumber
(String claimNumber) void
setCoinsuranceDays
(int coinsuranceDays) void
setDischargeDate
(int dischargeDate) void
setFromDate
(int fromDate) void
setFullDays
(int fullDays) void
setInpatientDed
(BigDecimal inpatientDed) void
setIntermediaryCtrlNum
(String intermediaryCtrlNum) void
setIntermediaryNum
(long intermediaryNum) void
setLifetimeResDays
(int lifetimeResDays) void
setMedicareProvider
(String medicareProvider) void
setPatientStatus
(String patientStatus) void
setSequenceCounter
(int sequenceCounter) void
setThruDate
(int thruDate) void
setTotalCharges
(BigDecimal totalCharges) void
setTransactionInd
(int transactionInd)
-
Field Details
-
BUF_LEN
public static final int BUF_LEN- See Also:
-
-
Constructor Details
-
MedicareRecord
public MedicareRecord() -
MedicareRecord
public MedicareRecord(byte[] buffer)
-
-
Method Details
-
getBytes
public byte[] getBytes()Answer the underlying byte array mapped by this object.- Returns:
- byte[]
-
setBytes
public void setBytes(byte[] buffer) -
getAdmissionDate
public int getAdmissionDate() -
setAdmissionDate
public void setAdmissionDate(int admissionDate) -
getAutoAdjustmentInd
-
setAutoAdjustmentInd
-
getBenefitsExhaustInd
public int getBenefitsExhaustInd() -
setBenefitsExhaustInd
public void setBenefitsExhaustInd(int benefitsExhaustInd) -
getBenefitsPayInd
public int getBenefitsPayInd() -
setBenefitsPayInd
public void setBenefitsPayInd(int benefitsPayInd) -
getBillSource
public int getBillSource() -
setBillSource
public void setBillSource(int billSource) -
getBloodDed
-
setBloodDed
-
getBloodPintsFurnished
public int getBloodPintsFurnished() -
setBloodPintsFurnished
public void setBloodPintsFurnished(int bloodPintsFurnished) -
getBloodPintsReplaced
public int getBloodPintsReplaced() -
setBloodPintsReplaced
public void setBloodPintsReplaced(int bloodPintsReplaced) -
getClaimNumber
Get the ClaimNumber.05 ClaimNumber PIC X(19).
- Returns:
- String the ClaimNumber
-
setClaimNumber
- See Also:
-
getCoinsuranceDays
public int getCoinsuranceDays()Get the CoinsuranceDays.05 CoinsuranceDays BINARY PIC 9(4).
- Returns:
- int the CoinsuranceDays
-
setCoinsuranceDays
public void setCoinsuranceDays(int coinsuranceDays) - See Also:
-
getDischargeDate
public int getDischargeDate()Get the DischargeDate.05 DischargeDate PACKED-DECIMAL PIC S9(7).
- Returns:
- int the DischargeDate
-
setDischargeDate
public void setDischargeDate(int dischargeDate) - See Also:
-
getFromDate
public int getFromDate()Get the FromDate.05 FromDate PACKED-DECIMAL PIC S9(7).
- Returns:
- int the FromDate
-
setFromDate
public void setFromDate(int fromDate) - See Also:
-
getFullDays
public int getFullDays()Get the FullDays.05 FullDays PACKED-DECIMAL PIC S9(5).
- Returns:
- int the FullDays
-
setFullDays
public void setFullDays(int fullDays) - See Also:
-
getInpatientDed
Get the InpatientDed.05 InpatientDed PACKED-DECIMAL PIC S9(4)V99.
- Returns:
- BigDecimal the InpatientDed
-
setInpatientDed
- See Also:
-
getIntermediaryCtrlNum
Get the IntermediaryCtrlNum.05 IntermediaryCtrlNum PIC X(23).
- Returns:
- String the IntermediaryCtrlNum
-
setIntermediaryCtrlNum
- See Also:
-
getIntermediaryNum
public long getIntermediaryNum()Get the IntermediaryNum.05 IntermediaryNum BINARY PIC 9(10).
- Returns:
- String the IntermediaryNum
-
setIntermediaryNum
public void setIntermediaryNum(long intermediaryNum) - See Also:
-
getLifetimeResDays
public int getLifetimeResDays()Get the LifetimeResDays.05 LifetimeResDays BINARY PIC 9(6).
- Returns:
- int the LifetimeResDays
-
setLifetimeResDays
public void setLifetimeResDays(int lifetimeResDays) - See Also:
-
getMedicareProvider
Get the MedicareProvider.05 MedicareProvider PIC X(13).
- Returns:
- int the MedicareProvider
-
setMedicareProvider
- See Also:
-
getPatientStatus
Get the PatientStatus.05 PatientStatus PIC X(2).
- Returns:
- String the PatientStatus
-
setPatientStatus
- See Also:
-
getSequenceCounter
public int getSequenceCounter()Get the SequenceCounter.05 SequenceCounter BINARY PIC 9(3).
- Returns:
- int the SequenceCounter
-
setSequenceCounter
public void setSequenceCounter(int sequenceCounter) - See Also:
-
getThruDate
public int getThruDate()Get the ThruDate.05 ThruDate PACKED-DECIMAL PIC S9(7).
- Returns:
- int the ThruDate
-
setThruDate
public void setThruDate(int thruDate) - See Also:
-
getTotalCharges
Get the TotalCharges.05 TotalCharges PIC S9(7)V99 DISPLAY SIGN LEADING.
- Returns:
- BigDecimal the TotalCharges
-
setTotalCharges
- See Also:
-
getTransactionInd
public int getTransactionInd()Get the TransactionInd.05 TransactionInd PIC 9.
- Returns:
- int the TransactionInd
-
setTransactionInd
public void setTransactionInd(int transactionInd) - See Also:
-