@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 projectID,
int fileID)
Constructor for our ServerPackModel using a project and file ID from a CurseForge project.
|
ServerPackModel(int id,
int projectID,
int fileID,
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.
|
int |
getFileID()
Getter for the file id of the server pack.
|
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.
|
int |
getProjectID()
Getter for the project id of the 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(java.lang.String fileDiskName)
Setter for the file disk name of the project file from which the server pack was generated.
|
void |
setFileID(int fileID)
Setter for the file id of the server pack.
|
void |
setFileName(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 |
setProjectID(int projectID)
Setter for the project id of the server pack.
|
void |
setProjectName(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.
|
getClientMods, getCopyDirs, getCurseModpack, getIncludeServerIcon, getIncludeServerInstallation, getIncludeServerProperties, getIncludeZipCreation, getJavaArgs, getJavaPath, getMinecraftVersion, getModLoader, getModLoaderVersion, getModpackDir, getServerIconPath, getServerPackSuffix, getServerPropertiesPath, setClientMods, setCopyDirs, setCurseModpack, setIncludeServerIcon, setIncludeServerInstallation, setIncludeServerProperties, setIncludeZipCreation, setJavaArgs, setJavaPath, setMinecraftVersion, setModLoader, setModLoaderVersion, setModpackDir, setServerIconPath, setServerPackSuffix, setServerPropertiesPath, toStringpublic ServerPackModel()
public ServerPackModel(int projectID,
int fileID)
projectID - Integer. The project ID of the CurseForge project.fileID - Integer. The file ID of the CurseForge project file.public ServerPackModel(int id,
int projectID,
int fileID,
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.projectID - The project ID of the CurseForge project.fileID - The file ID of the CurseForge project file.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 - Integer. The database id of the server pack.public int getProjectID()
getProjectID in class ConfigurationModelpublic void setProjectID(int projectID)
setProjectID in class ConfigurationModelprojectID - Integer. The project id with which the server pack was generated.public int getFileID()
getFileID in class ConfigurationModelpublic void setFileID(int fileID)
setFileID in class ConfigurationModelfileID - Integer. The file id with which the server pack was generated.public java.lang.String getProjectName()
getProjectName in class ConfigurationModelpublic void setProjectName(java.lang.String projectName)
setProjectName in class ConfigurationModelprojectName - String. The project name of the server pack.public java.lang.String getFileName()
getFileName in class ConfigurationModelpublic void setFileName(java.lang.String fileName)
setFileName in class ConfigurationModelfileName - String. 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(java.lang.String fileDiskName)
setFileDiskName in class ConfigurationModelfileDiskName - String. 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 - Integer. The amount of downloads this server pack has received.public int getConfirmedWorking()
public void setConfirmedWorking(int confirmedWorking)
confirmedWorking - Integer. 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 - String. The status of a server pack.public java.lang.String getPath()
public void setPath(java.lang.String path)
path - String. The path to the generated server pack.public java.sql.Timestamp getDateCreated()
Timestamp.Timestamp. Returns the date and time at which this server pack entry was created as a Timestamp.public void setDateCreated(java.sql.Timestamp dateCreated)
Timestamp.dateCreated - Timestamp. The date and time at which this server pack was created as a Timestamp.public java.sql.Timestamp getLastModified()
Timestamp.Timestamp. Returns the date and time at which this server pack entry was last modified as a Timestamp.public void setLastModified(java.sql.Timestamp lastModified)
Timestamp.lastModified - Timestamp. The date and time at which this server pack entry was last modified as a Timestamp.public java.lang.String repositoryToString()