Search in sources :

Example 1 with SubmitRequirementAttribute

use of com.google.gerrit.server.data.SubmitRequirementAttribute in project gerrit by GerritCodeReview.

the class EventFactory method addSubmitRecordRequirements.

private void addSubmitRecordRequirements(SubmitRecord submitRecord, SubmitRecordAttribute sa) {
    if (submitRecord.requirements != null && !submitRecord.requirements.isEmpty()) {
        sa.requirements = new ArrayList<>();
        for (LegacySubmitRequirement req : submitRecord.requirements) {
            SubmitRequirementAttribute re = new SubmitRequirementAttribute();
            re.fallbackText = req.fallbackText();
            re.type = req.type();
            sa.requirements.add(re);
        }
    }
}
Also used : LegacySubmitRequirement(com.google.gerrit.entities.LegacySubmitRequirement) SubmitRequirementAttribute(com.google.gerrit.server.data.SubmitRequirementAttribute)

Aggregations

LegacySubmitRequirement (com.google.gerrit.entities.LegacySubmitRequirement)1 SubmitRequirementAttribute (com.google.gerrit.server.data.SubmitRequirementAttribute)1