Class QualifyingConditionCodesEligibility

java.lang.Object
org.mitre.synthea.world.agents.behaviors.planeligibility.QualifyingConditionCodesEligibility
All Implemented Interfaces:
Serializable, IPlanEligibility

public class QualifyingConditionCodesEligibility extends Object implements IPlanEligibility
An algorithm that defines the logic for eligibility based on a set of qualifying condition codes. The codes can either be input as seperated by "xxx|xxx" or can be input in a file with a heading "codes". This can be used to define Social Security eligibility, as described by: https://www.ssa.gov/disability/professionals/bluebook/AdultListings.htm Note that the SSD file (ssd_dsiabilities.csv) list is incomplete, some condtions are not currently simulated in Synthea.
See Also:
  • Constructor Details

    • QualifyingConditionCodesEligibility

      public QualifyingConditionCodesEligibility(String codes)
      Constructor.
      Parameters:
      codes - The "|" delimited string or file of qualifying attributes.
  • Method Details

    • isPersonEligible

      public boolean isPersonEligible(Person person, long time)
      Description copied from interface: IPlanEligibility
      Returns whether the given person meets the eligibility criteria of this algorithm at the given time.
      Specified by:
      isPersonEligible in interface IPlanEligibility
      Parameters:
      person - The person to check against.
      time - The time.
      Returns:
      Whether the person is eligible.
    • getEarliestDiagnosis

      public long getEarliestDiagnosis(Person person)
      Gets the earliest occurrence of a qualifying condition that is active/present on the person.
      Parameters:
      person - The person.
      Returns:
      Start time of the earliest qualifying condition, or Long.MAX_VALUE if not present.