Class GemFaker
java.lang.Object
de.gematik.test.erezept.fhir.builder.GemFaker
-
Method Summary
Modifier and TypeMethodDescriptionstatic Stringstatic floatcost()static floatcost(float min) static floatcost(float min, float max) static Stringstatic Stringstatic AccessCodestatic intstatic intfakerAmount(int min, int max) static Datestatic Stringstatic booleanstatic StringBetriebsstättennummerstatic Stringstatic Stringstatic Stringstatic Stringstatic Stringstatic Stringstatic Stringstatic Stringstatic Stringstatic de.gematik.bbriccs.fhir.de.valueset.Countrystatic DoctorProfessionstatic Stringstatic Stringstatic Stringstatic Stringstatic Stringstatic Datestatic StringLebenslage Arztnummer uses method generateControlNo(int docID)static Stringstatic Stringstatic Stringstatic Stringstatic PrescriptionIdstatic PrescriptionIdfakerPrescriptionId(PrescriptionFlowType flowType) Build a fake PrescriptionID with valid checking numberstatic Stringstatic QualificationTypestatic Stringstatic Stringstatic Stringstatic <V extends Enum<?>>
VfakerValueSet(Class<V> valueSet) Get a random value from a given Enumstatic <V extends Enum<?>>
VfakerValueSet(Class<V> valueSet, List<V> exclude) static <V extends Enum<?>>
VfakerValueSet(Class<V> valueSet, V exclude) static StringZahnarztnummer* possible: use ZANR.random() insteadstatic Stringstatic StringAttention: this might include a secondary appendix to the street name which might be an invalid address in FHIR resourcesstatic StringfullStreetName(boolean withSecondary) Attention: use with caution, ifwithSecondaryargument is set to true, the street might be invalid for certain FHIR profilesstatic intgenerateControlNo(int docID) generate a controlNumber by multiply each first digit with 4 and each second digit with 9 until reached last digit (6) result = 10 - ( sum() -> "% 10" );static intgenerateControlNo(String docId) generate a controlNumber by multiply each first digit with 4 and each second digit with 9 until reached last digit (6) result = 10 - ( sum() -> "% 10" );static com.github.javafaker.FakergetFaker()static Stringgenerate combination from HEALTH_INSURANCE_NAMES and wop.getDisplay()static StringinsuranceName(Wop wop) builds a combination of HEALTH_INSURANCE_NAMES and Wop with max 45 digits uses randomElement(HEALTH_INSURANCE_NAMES) uses wop.getDisplay()mvo()mvo(boolean isMultiple) static Stringstatic <T> TrandomElement(List<T> list) static <T> TrandomElement(T... elements) static floatvatRate()static floatvatRate(float min, float max)
-
Method Details
-
getFaker
public static com.github.javafaker.Faker getFaker() -
fakerDrugName
-
fakerLotNumber
-
fakerFutureExpirationDate
-
fakerTelematikId
-
fakerName
-
fakerFirstName
-
fakerLastName
-
fakerBirthday
-
fakerBirthdayAsString
-
insuranceName
builds a combination of HEALTH_INSURANCE_NAMES and Wop with max 45 digits uses randomElement(HEALTH_INSURANCE_NAMES) uses wop.getDisplay()- Parameters:
wop- from Wop.class- Returns:
- StingCombination with max size of 45
-
insuranceName
generate combination from HEALTH_INSURANCE_NAMES and wop.getDisplay()- Returns:
- StingCombination with max size of 45
-
pharmacyName
-
fakerBsnr
Betriebsstättennummer- Returns:
- String (BSNR generated by original format)
- See Also:
-
- BSNR first and second digits as region number (Wop)
-
fakerLanr
Lebenslage Arztnummer uses method generateControlNo(int docID)- Returns:
- a random valid LANR as a String
- See Also:
-
- Wikipedia LANR
- invalid input: '<a href="https://wiki.hl7.de/index.php?title=LANR_und_BSNR>HL7 Wiki</a>'
-
generateControlNo
generate a controlNumber by multiply each first digit with 4 and each second digit with 9 until reached last digit (6) result = 10 - ( sum() -> "% 10" );- Parameters:
docId- with 6 digits as String- Returns:
- 1 digit int
-
generateControlNo
public static int generateControlNo(int docID) generate a controlNumber by multiply each first digit with 4 and each second digit with 9 until reached last digit (6) result = 10 - ( sum() -> "% 10" );- Parameters:
docID- with 6 digits- Returns:
- 1 digit int
-
fakerZanr
Zahnarztnummer* possible: use ZANR.random() insteaduses method generateControlNo(int docID)
- Returns:
- a random valid ZANR as a String
- See Also:
-
fakerPrescriptionId
-
fakerPrescriptionId
Build a fake PrescriptionID with valid checking number- Returns:
- a valid randomly generated Prescription ID
- See Also:
-
fakerAccessCode
-
fakerSecret
-
fakerAmount
public static int fakerAmount() -
fakerAmount
public static int fakerAmount(int min, int max) -
fakerBool
public static boolean fakerBool() -
fakerDosage
-
fakerPhone
-
fakerEMail
-
eMail
-
eMail
-
fakerCity
-
fakerZipCode
-
fullStreetName
Attention: this might include a secondary appendix to the street name which might be an invalid address in FHIR resources- Returns:
- a street name
-
fullStreetName
Attention: use with caution, ifwithSecondaryargument is set to true, the street might be invalid for certain FHIR profiles- Parameters:
withSecondary- defines if a secondary appendix should be added to the address- Returns:
- a street name
-
fakerStreetName
-
buildingNumber
-
fakerCountry
public static de.gematik.bbriccs.fhir.de.valueset.Country fakerCountry() -
fakerQualificationType
-
fakerProfession
-
fakerDoctorProfessionAsString
-
fakerDoctorProfession
-
fakerCommunicationInfoReqMessage
-
fakerCommunicationDispReqMessage
-
fakerCommunicationReplyMessage
-
fakerCommunicationRepresentativeMessage
-
fakerCommunicationChargeItemChangeRequest
-
fakerCommunicationChargeItemChangeReply
-
fakerCommunicationMessage
-
fakerChargeItemCommunicationMessage
-
mvo
-
mvo
-
vatRate
public static float vatRate() -
vatRate
public static float vatRate(float min, float max) -
cost
public static float cost() -
cost
public static float cost(float min) -
cost
public static float cost(float min, float max) -
fakerValueSet
Get a random value from a given Enum- Type Parameters:
V- is the type of the- Parameters:
valueSet- is the class of the Enum- Returns:
- a random choice
-
fakerValueSet
-
fakerValueSet
-
randomElement
-
randomElement
-