-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #176 from qbicsoftware/release/2.3.0
Release/2.3.0
- Loading branch information
Showing
16 changed files
with
479 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,7 +4,7 @@ email: [email protected] | |
project_name: data-model-lib | ||
project_short_description: "Data models. A collection of QBiC's central data models\ | ||
\ and DTOs. " | ||
version: 2.2.0 | ||
version: 2.3.0 | ||
domain: lib | ||
language: groovy | ||
project_slug: data-model-lib | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
81 changes: 81 additions & 0 deletions
81
src/main/groovy/life/qbic/datamodel/dtos/business/ProjectApplication.groovy
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,81 @@ | ||
package life.qbic.datamodel.dtos.business | ||
|
||
import life.qbic.datamodel.dtos.business.Customer | ||
import life.qbic.datamodel.dtos.business.OfferId | ||
import life.qbic.datamodel.dtos.business.ProjectManager | ||
import life.qbic.datamodel.dtos.projectmanagement.ProjectCode | ||
import life.qbic.datamodel.dtos.projectmanagement.ProjectSpace | ||
|
||
/** | ||
* Information about a desired project registration in QBiC's project management system. | ||
* | ||
* Instances of this class describe a request to register a new project at QBiC. | ||
* | ||
* Beside the mandatory fields required to be passed to the constructor, there are two optional | ||
* fields: | ||
* 1: projectSpace | ||
* 2: projectCode | ||
* If any of these are not defined, then either of it will be created randomly. | ||
* | ||
* @since 2.3.0 | ||
*/ | ||
class ProjectApplication { | ||
|
||
/** | ||
* The associated offer | ||
*/ | ||
final OfferId linkedOffer | ||
|
||
/** | ||
* A short and precise project title | ||
*/ | ||
final String projectTitle | ||
|
||
/** | ||
* A descriptive project objective | ||
*/ | ||
final String projectObjective | ||
|
||
/** | ||
* A description about the experimental design | ||
*/ | ||
final String experimentalDesign | ||
|
||
/** | ||
* The associated project manager | ||
*/ | ||
final ProjectManager projectManager | ||
|
||
/** | ||
* The associated customer | ||
*/ | ||
final Customer customer | ||
|
||
/** | ||
* The requested project space the project shall be associated with | ||
*/ | ||
final ProjectSpace projectSpace | ||
|
||
/** | ||
* The desired project code | ||
*/ | ||
final ProjectCode projectCode | ||
|
||
ProjectApplication(OfferId linkedOffer, | ||
String projectTitle, | ||
String projectObjective, | ||
String experimentalDesign, | ||
ProjectManager projectManager, | ||
ProjectSpace projectSpace, | ||
Customer customer, | ||
ProjectCode code) { | ||
this.linkedOffer = Objects.requireNonNull(linkedOffer) | ||
this.projectTitle = Objects.requireNonNull(projectTitle) | ||
this.projectObjective = Objects.requireNonNull(projectObjective) | ||
this.experimentalDesign = Objects.requireNonNull(experimentalDesign) | ||
this.projectManager = Objects.requireNonNull(projectManager) | ||
this.customer = Objects.requireNonNull(customer) | ||
this.projectSpace = Objects.requireNonNull(projectSpace) | ||
this.projectCode = Objects.requireNonNull(code) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
66 changes: 66 additions & 0 deletions
66
src/main/groovy/life/qbic/datamodel/dtos/projectmanagement/Project.groovy
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
package life.qbic.datamodel.dtos.projectmanagement | ||
|
||
import life.qbic.datamodel.dtos.business.OfferId | ||
|
||
/** | ||
* A typical scientific QBiC project. | ||
* | ||
* Describes and provides information about a scientific project | ||
* at QBiC. | ||
* | ||
* @since 2.3.0 | ||
*/ | ||
class Project { | ||
|
||
/** | ||
* A short but descriptive project title | ||
*/ | ||
final String projectTitle | ||
|
||
/** | ||
* QBiC's internal project identifier | ||
*/ | ||
final ProjectIdentifier projectId | ||
|
||
/** | ||
* The associated offer | ||
*/ | ||
final OfferId linkedOffer | ||
|
||
private Project(Builder builder) { | ||
this.projectId = Objects.requireNonNull(builder.projectIdentifier) | ||
this.projectTitle = Objects.requireNonNull(builder.projectTitle) | ||
this.linkedOffer = builder.linkedOfferId | ||
} | ||
|
||
static class Builder { | ||
private ProjectIdentifier projectIdentifier | ||
private String projectTitle | ||
private OfferId linkedOfferId | ||
|
||
Builder(ProjectIdentifier projectIdentifier, String projectTitle) { | ||
this.projectIdentifier = projectIdentifier | ||
this.projectTitle = projectTitle | ||
this.linkedOfferId = null | ||
} | ||
|
||
Builder projectIdentifier(ProjectIdentifier projectIdentifier) { | ||
this.projectIdentifier = projectIdentifier | ||
return this | ||
} | ||
|
||
Builder projectTitle(String projectTitle) { | ||
this.projectTitle = projectTitle | ||
return this | ||
} | ||
|
||
Builder linkedOfferId(OfferId offerId) { | ||
this.linkedOfferId = offerId | ||
return this | ||
} | ||
|
||
Project build() { | ||
return new Project(this) | ||
} | ||
} | ||
} |
Oops, something went wrong.