ReleasesHelper

The ReleasesHelper class is useful to manage all the release database operations

Author

N7ghtm4r3 - Tecknobit

See also

Constructors

Link copied to clipboard
constructor()

Properties

Link copied to clipboard
val ASSETS_DIRECTORY: String = "assets"
ASSETS_DIRECTORY the assets directory where are stored the assets of the releases uploaded
Link copied to clipboard
val LOGOS_DIRECTORY: String = "logos"
LOGOS_DIRECTORY the logos directory where are stored the logos of the projects
Link copied to clipboard
notificationsRepository instance useful to manage the notifications
Link copied to clipboard
val PROFILES_DIRECTORY: String = "profiles"
Link copied to clipboard
releaseEventsRepository instance for the events of releases repository
Link copied to clipboard
@Autowired
private open var releasesRepository: ReleasesRepository
releasesRepository instance for the releases repository
Link copied to clipboard
@Autowired
private open var releaseTagRepository: ReleaseTagRepository
releaseTagRepository instance for the tags of releases repository
Link copied to clipboard
val REPORTS_DIRECTORY: String = "reports"
REPORTS_DIRECTORY the reports directory where are stored the reports of the releases created
Link copied to clipboard
val RESOURCES_KEY: String = "resources"
Link copied to clipboard
val RESOURCES_PATH: String = "resources/"
Link copied to clipboard
val RESOURCES_REPORTS_PATH: String = "resources/reports/"
RESOURCES_REPORTS_PATH the complete reports path from resources directory

Functions

Link copied to clipboard
open fun addRelease(requesterUser: String, project: Project, releaseId: String, releaseVersion: String, releaseNotesContent: String)
Method to add a new release
Link copied to clipboard
open fun approveAssets(requesterUser: String, project: Project, releaseId: String, eventId: String)
Method to approve a release assets
Link copied to clipboard
open fun createAssetResource(resource: MultipartFile, resourceId: String): String
Method to create the pathname for an asset
Link copied to clipboard
open fun createLogoResource(resource: MultipartFile, resourceId: String): String
Method to create the pathname for a project logo
Link copied to clipboard
open fun createProfileResource(resource: MultipartFile, resourceId: String): String
Link copied to clipboard
open fun createReportResource(resource: MultipartFile, resourceId: String): String
Method to create the pathname for a report
Link copied to clipboard
open fun createResource(resource: MultipartFile, resourcesDirectory: String, resourceId: String): String
Link copied to clipboard
open fun deleteAssetResource(assetId: String): Boolean
Method to delete an asset
Link copied to clipboard
open fun deleteLogoResource(logoId: String): Boolean
Method to delete a project logo
Link copied to clipboard
Link copied to clipboard
open fun deleteRelease(requesterUser: String, project: Project, release: Release)
Method to delete a release and all the data related to it
Link copied to clipboard
open fun deleteReportResource(reportId: String): Boolean
Method to delete a report
Link copied to clipboard
open fun deleteResource(resourcesDirectory: String, resourceId: String): Boolean
Link copied to clipboard
open fun editRelease(releaseId: String, releaseVersion: String, releaseNotesContent: String)
Method to edit an existing release
Link copied to clipboard
open fun getRelease(releaseId: String): Release
Method to get a release
Link copied to clipboard
open fun getSuffixResource(resource: MultipartFile): String
Link copied to clipboard
open fun insertTagComment(comment: String, rejectedTagId: String)
Method to insert a comment to a RejectedTag
Link copied to clipboard
open fun readAllNotifications(userId: String, releaseId: String)
Method to read all the notifications related to a specific Release for a user
Link copied to clipboard
open fun rejectAsset(requesterUser: String, project: Project, releaseId: String, eventId: String, reasons: String, tags: ArrayList<ReleaseEvent.ReleaseTag>)
Method reject a release assets
Link copied to clipboard
open fun saveResource(resource: MultipartFile, path: String)
Link copied to clipboard
open fun setAlphaStatus(requesterUser: String, project: Project, releaseId: String)
Method to set the Alpha status
Link copied to clipboard
private open fun setApprovedStatus(requesterUser: String, project: Project, releaseId: String)
Method to set the Approved status
Link copied to clipboard
open fun setBetaStatus(requesterUser: String, project: Project, releaseId: String)
Method to set the Beta status
Link copied to clipboard
open fun setLatestStatus(requesterUser: String, project: Project, projectId: String, releaseId: String)
Method to set the Latest status
Link copied to clipboard
private open fun setRejectedStatus(requesterUser: String, project: Project, releaseId: String)
Method to set the Rejected status
Link copied to clipboard
private open fun setReleaseStatus(requesterUser: String, project: Project, releaseId: String, status: Release.ReleaseStatus)
Method to change the status of a release
Link copied to clipboard
private open fun setVerifyingStatus(requesterUser: String, project: Project, releaseId: String)
Method to set the Verifying status
Link copied to clipboard
open fun uploadAssets(requesterUser: String, project: Project, releaseId: String, assets: Array<MultipartFile>, comment: String): Boolean
Method to upload a new assets on a release