@Entity public class ServerPackModel extends ConfigurationModel
ConfigurationModel we inherit all
basic fields required for the generation of a server pack and can add only those we require in
the REST API portion of ServerPackCreator.Entity because we
also use this class for storing information in our database.| Constructor and Description |
|---|
ServerPackModel()
Constructor for our ServerPackModel.
|
ServerPackModel(int id,
java.lang.String fileName,
java.lang.String displayName,
double size,
int downloads,
int confirmedWorking,
java.lang.String status,
java.sql.Timestamp dateCreated,
java.sql.Timestamp lastModified)
Constructor for our ServerPackModel, setting id, projectID, fileID, fileName, displayName,
size, downloads, confirmedWorking, status, dateCreated, lastModified manually.
|
| Modifier and Type | Method and Description |
|---|---|
int |
getConfirmedWorking()
Getter for the amount of votes indicating whether this server pack works.
|
java.sql.Timestamp |
getDateCreated()
Getter for the date and time at which this server pack entry was created as a
Timestamp. |
int |
getDownloads()
Getter for the amount of downloads this server pack has received.
|
java.lang.String |
getFileDiskName()
Getter for the file disk name of the project file from which the server pack was generated.
|
java.lang.String |
getFileName()
Getter for the file display name of the project file from which the server pack was generated.
|
int |
getId()
Getter for the database id of a server pack.
|
java.sql.Timestamp |
getLastModified()
Getter for the date and time at which this server pack entry was last modified as a
Timestamp. |
java.lang.String |
getPath()
Getter for the path to the generated server pack.
|
java.lang.String |
getProjectName()
Getter for the name of the project of the server pack.
|
double |
getSize()
Getter for the size of the generated server pack in MB.
|
java.lang.String |
getStatus()
Getter for the status of the server pack.
|
java.lang.String |
repositoryToString()
String concatenation of all important values of our server pack entry.
|
void |
setConfirmedWorking(int confirmedWorking)
Setter for the amount of votes indicating whether this server pack works.
|
void |
setDateCreated(java.sql.Timestamp dateCreated)
Setter for the date and time at which this server pack entry was created as a
Timestamp. |
void |
setDownloads(int downloads)
Setter for the amount of downloads this server pack has received.
|
void |
setFileDiskName(@NotNull java.lang.String fileDiskName)
Setter for the file disk name of the project file from which the server pack was generated.
|
void |
setFileName(@NotNull java.lang.String fileName)
Setter for the file display name of the project file from which the server pack was generated.
|
void |
setId(int id)
Setter for the database id of a server pack.
|
void |
setLastModified(java.sql.Timestamp lastModified)
Setter for the date and time at which this server pack entry was last modified as a
Timestamp. |
void |
setPath(java.lang.String path)
Setter for the path to the generated server pack.
|
void |
setProjectName(@NotNull java.lang.String projectName)
Setter for the project name of the project of the server pack.
|
void |
setSize(double size)
Setter for the size of the generated server pack in MB.
|
void |
setStatus(java.lang.String status)
Setter for the status of a server pack.
|
getAddonConfigs, getClientMods, getCopyDirs, getIncludeServerIcon, getIncludeServerInstallation, getIncludeServerProperties, getIncludeZipCreation, getJavaArgs, getMinecraftVersion, getModLoader, getModLoaderVersion, getModpackDir, getModpackJson, getOrCreateAddonConfigList, getScriptSettings, getServerIconPath, getServerPackSuffix, getServerPropertiesPath, save, setClientMods, setCopyDirs, setIncludeServerIcon, setIncludeServerInstallation, setIncludeServerProperties, setIncludeZipCreation, setJavaArgs, setMinecraftVersion, setModLoader, setModLoaderVersion, setModpackDir, setModpackJson, setScriptSettings, setServerIconPath, setServerPackSuffix, setServerPropertiesPath, toStringpublic ServerPackModel()
public ServerPackModel(int id,
java.lang.String fileName,
java.lang.String displayName,
double size,
int downloads,
int confirmedWorking,
java.lang.String status,
java.sql.Timestamp dateCreated,
java.sql.Timestamp lastModified)
id - The ID of the server pack in our database.fileName - The disk name of the CurseForge project file.displayName - The display name of the CurseForge project file.size - The size of the generated server pack, in MB.downloads - The amount of times this server pack was downloaded.confirmedWorking - The amount of votes indicating whether this server pack works.status - The status of this server pack. Either Queued,
Generating , Available.dateCreated - The date and time at which this server pack was requested for
generation.lastModified - The date and time this server pack was last modified. Be it either due
to regeneration or something else.public int getId()
public void setId(int id)
id - The database id of the server pack.public java.lang.String getProjectName()
getProjectName in class ConfigurationModelpublic void setProjectName(@NotNull
@NotNull java.lang.String projectName)
setProjectName in class ConfigurationModelprojectName - The project name of the server pack.public java.lang.String getFileName()
getFileName in class ConfigurationModelpublic void setFileName(@NotNull
@NotNull java.lang.String fileName)
setFileName in class ConfigurationModelfileName - The file display name of the project file from which the server pack was
generated.public java.lang.String getFileDiskName()
getFileDiskName in class ConfigurationModelpublic void setFileDiskName(@NotNull
@NotNull java.lang.String fileDiskName)
setFileDiskName in class ConfigurationModelfileDiskName - The file disk name of the project file from which the server pack was
generated.public double getSize()
public void setSize(double size)
size - Double. The size of the generated server pack in MB.public int getDownloads()
public void setDownloads(int downloads)
downloads - The amount of downloads this server pack has received.public int getConfirmedWorking()
public void setConfirmedWorking(int confirmedWorking)
confirmedWorking - The amount of votes indicating whether this server pack works.public java.lang.String getStatus()
Queued, Generating,
Available.public void setStatus(java.lang.String status)
Queued, Generating,
Available.status - The status of a server pack.public java.lang.String getPath()
public void setPath(java.lang.String path)
path - The path to the generated server pack.public java.sql.Timestamp getDateCreated()
Timestamp.Timestamp.public void setDateCreated(java.sql.Timestamp dateCreated)
Timestamp.dateCreated - The date and time at which this server pack was created as a
Timestamp.public java.sql.Timestamp getLastModified()
Timestamp.Timestamp.public void setLastModified(java.sql.Timestamp lastModified)
Timestamp.lastModified - The date and time at which this server pack entry was last modified as a
Timestamp.public java.lang.String repositoryToString()