All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.structurizr.inspection.model.SoftwareSystemDocumentationInspection Maven / Gradle / Ivy

The newest version!
package com.structurizr.inspection.model;

import com.structurizr.inspection.Inspector;
import com.structurizr.inspection.Violation;
import com.structurizr.model.SoftwareSystem;

public class SoftwareSystemDocumentationInspection extends AbstractSoftwareSystemInspection {

    public SoftwareSystemDocumentationInspection(Inspector inspector) {
        super(inspector);
    }

    @Override
    protected Violation inspect(SoftwareSystem softwareSystem) {
        if (softwareSystem.hasContainers() && softwareSystem.getDocumentation().getSections().isEmpty()) {
            return violation("The " + terminologyFor(softwareSystem).toLowerCase() + " \"" + nameOf(softwareSystem) + "\" has containers, but is missing documentation.");
        }

        return noViolation();
    }

    @Override
    protected String getType() {
        return "model.softwaresystem.documentation";
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy