Record Class DoctorAdvisory
java.lang.Object
java.lang.Record
com.shaft.doctor.model.DoctorAdvisory
- Record Components:
schemaVersion- Doctor advisory envelope schema versionstatus- advisory outcomeanalysis- schema-validated provider analysismetadata- safe provider and fallback metadata
public record DoctorAdvisory(String schemaVersion, DoctorAdvisory.Status status, DoctorAdvisory.ProviderAnalysis analysis, DoctorAdvisory.Metadata metadata)
extends Record
Separately identified optional provider advisory that never replaces the deterministic diagnosis.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final recordOne provider hypothesis.static final recordSafe provider, timing, usage, cache, and fallback metadata.static final recordOne provider observation.static final recordVersioned provider output accepted by Doctor.static final recordOne provider-recommended action.static enumAdvisory outcome. -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionDoctorAdvisory(String schemaVersion, DoctorAdvisory.Status status, DoctorAdvisory.ProviderAnalysis analysis, DoctorAdvisory.Metadata metadata) Creates a validated advisory. -
Method Summary
Modifier and TypeMethodDescriptionanalysis()Returns the value of theanalysisrecord component.static DoctorAdvisorydisabled()Returns a disabled advisory that is not rendered into deterministic reports.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.metadata()Returns the value of themetadatarecord component.Returns the value of theschemaVersionrecord component.status()Returns the value of thestatusrecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
CURRENT_SCHEMA_VERSION
Current advisory envelope schema version.- See Also:
-
-
Constructor Details
-
DoctorAdvisory
public DoctorAdvisory(String schemaVersion, DoctorAdvisory.Status status, DoctorAdvisory.ProviderAnalysis analysis, DoctorAdvisory.Metadata metadata) Creates a validated advisory.
-
-
Method Details
-
disabled
Returns a disabled advisory that is not rendered into deterministic reports.- Returns:
- disabled advisory
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
schemaVersion
Returns the value of theschemaVersionrecord component.- Returns:
- the value of the
schemaVersionrecord component
-
status
-
analysis
-
metadata
-