Package edu.ucsb.cs.scaffold.services
Record Class PrairieLearnService.CourseInstanceInfo
java.lang.Object
java.lang.Record
edu.ucsb.cs.scaffold.services.PrairieLearnService.CourseInstanceInfo
- Enclosing class:
PrairieLearnService
public static record PrairieLearnService.CourseInstanceInfo(Long courseInstanceId, String longName, String shortName)
extends Record
The parts of a course instance response this app uses; the numeric id is the crucial one, since
it cannot be obtained from the GitHub repo.
-
Constructor Summary
ConstructorsConstructorDescriptionCourseInstanceInfo(Long courseInstanceId, String longName, String shortName) Creates an instance of aCourseInstanceInforecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thecourseInstanceIdrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.longName()Returns the value of thelongNamerecord component.Returns the value of theshortNamerecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
CourseInstanceInfo
Creates an instance of aCourseInstanceInforecord class.- Parameters:
courseInstanceId- the value for thecourseInstanceIdrecord componentlongName- the value for thelongNamerecord componentshortName- the value for theshortNamerecord component
-
-
Method Details
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
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). -
courseInstanceId
Returns the value of thecourseInstanceIdrecord component.- Returns:
- the value of the
courseInstanceIdrecord component
-
longName
Returns the value of thelongNamerecord component.- Returns:
- the value of the
longNamerecord component
-
shortName
Returns the value of theshortNamerecord component.- Returns:
- the value of the
shortNamerecord component
-