Record Class DatasetDescription
java.lang.Object
java.lang.Record
org.variantsync.diffdetective.datasets.DatasetDescription
- Record Components:
name
- The name of the dataset that is used to identify it (e.g., "Linux").repoURL
- The url of the remote repository (e.g., the HTTPS url of a github repository).domain
- A description of the datasets domain (i.e., the software's purpose such as "operating system" or "database").commits
- The estimated number of commits in the repository as a string. Can be empty.
public record DatasetDescription(String name, String repoURL, String domain, String commits)
extends Record
Description of a git repository dataset.
Such a dataset should refer to a git repository of a C preprocessor based software product line.
- Author:
- Paul Bittner, Benjamin Moosherr
-
Field Summary
-
Constructor Summary
ConstructorDescriptionDatasetDescription
(String name, String repoURL, String domain, String commits) Creates an instance of aDatasetDescription
record class. -
Method Summary
Modifier and TypeMethodDescriptionstatic String
asLaTeXTable
(List<DatasetDescription> datasets) Turns the given descriptions into a LaTeX table to include in papers.commits()
Returns the value of thecommits
record component.domain()
Returns the value of thedomain
record component.final boolean
Indicates whether some other object is "equal to" this one.static List<DatasetDescription>
fromMarkdown
(Path markdownFile) Loads all dataset descriptions in the given markdown file.final int
hashCode()
Returns a hash code value for this object.private static boolean
Returns true iff the given string equals "y" ignoring case and whitespace.name()
Returns the value of thename
record component.repoURL()
Returns the value of therepoURL
record component.static DatasetDescription
final String
toString()
Returns a string representation of this record class.
-
Field Details
-
Constructor Details
-
Method Details
-
summary
-
fromMarkdown
Loads all dataset descriptions in the given markdown file. This expects the markdown file only be a table with the columns- Project name
- Domain
- Source code available (**y**es/**n**o)?: This should only be a "y" or "n"
- Is it a git repository (**y**es/**n**o)?: This should only be a "y" or "n"
- Repository URL
- Clone URL
- Estimated number of commits
- Parameters:
markdownFile
- Path to a markdown file containing dataset descriptions.- Returns:
- All parsed dataset descriptions.
- Throws:
IOException
- If the file could not be read for some reason.
-
asLaTeXTable
Turns the given descriptions into a LaTeX table to include in papers. Each dataset will be a row in the table.- Parameters:
datasets
- The datasets to put into the LaTeX table.- Returns:
- A LaTeX table giving an overview on all datasets.
-
isYes
Returns true iff the given string equals "y" ignoring case and whitespace. -
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)
. -
name
Returns the value of thename
record component.- Returns:
- the value of the
name
record component
-
repoURL
Returns the value of therepoURL
record component.- Returns:
- the value of the
repoURL
record component
-
domain
Returns the value of thedomain
record component.- Returns:
- the value of the
domain
record component
-
commits
Returns the value of thecommits
record component.- Returns:
- the value of the
commits
record component
-