Package com.structurizr.documentation
Class StructurizrDocumentationTemplate
java.lang.Object
com.structurizr.documentation.DocumentationTemplate
com.structurizr.documentation.StructurizrDocumentationTemplate
public class StructurizrDocumentationTemplate extends DocumentationTemplate
A simple documentation template, based upon the "software guidebook" concept in Simon Brown's Software Architecture for Developers book, with the following sections:
- Context (1)
- Functional Overview (2)
- Quality Attributes (2)
- Constraints (2)
- Principles (2)
- Software Architecture (3)
- Containers (3)
- Components (3)
- Code (3)
- Data (3)
- Infrastructure Architecture (4)
- Deployment (4)
- Development Environment (4)
- Operation and Support (4)
- Decision Log (5)
The number in parentheses () represents the grouping, which is simply used to colour code section navigation buttons when rendered.
-
Constructor Summary
Constructors Constructor Description StructurizrDocumentationTemplate(Workspace workspace) -
Method Summary
Modifier and Type Method Description SectionaddCodeSection(Component component, Format format, java.lang.String content)Adds a "Code" section relating to aComponent.SectionaddCodeSection(Component component, java.io.File... files)Adds a "Code" section relating to aComponentfrom one or more files.SectionaddComponentsSection(Container container, Format format, java.lang.String content)Adds a "Components" section relating to aContainer.SectionaddComponentsSection(Container container, java.io.File... files)Adds a "Components" section relating to aContainerfrom one or more files.SectionaddConstraintsSection(SoftwareSystem softwareSystem, Format format, java.lang.String content)Adds a "Constraints" section relating to aSoftwareSystem.SectionaddConstraintsSection(SoftwareSystem softwareSystem, java.io.File... files)Adds a "Constraints" section relating to aSoftwareSystemfrom one or more files.SectionaddContainersSection(SoftwareSystem softwareSystem, Format format, java.lang.String content)Adds a "Containers" section relating to aSoftwareSystem.SectionaddContainersSection(SoftwareSystem softwareSystem, java.io.File... files)Adds a "Containers" section relating to aSoftwareSystemfrom one or more files.SectionaddContextSection(SoftwareSystem softwareSystem, Format format, java.lang.String content)Adds a "Context" section relating to aSoftwareSystem.SectionaddContextSection(SoftwareSystem softwareSystem, java.io.File... files)Adds a "Context" section relating to aSoftwareSystemfrom one or more files.SectionaddDataSection(SoftwareSystem softwareSystem, Format format, java.lang.String content)Adds a "Data" section relating to aSoftwareSystem.SectionaddDataSection(SoftwareSystem softwareSystem, java.io.File... files)Adds a "Data" section relating to aSoftwareSystemfrom one or more files.SectionaddDecisionLogSection(SoftwareSystem softwareSystem, Format format, java.lang.String content)Adds a "Decision Log" section relating to aSoftwareSystem.SectionaddDecisionLogSection(SoftwareSystem softwareSystem, java.io.File... files)Adds a "Decision Log" section relating to aSoftwareSystemfrom one or more files.SectionaddDeploymentSection(SoftwareSystem softwareSystem, Format format, java.lang.String content)Adds a "Deployment" section relating to aSoftwareSystem.SectionaddDeploymentSection(SoftwareSystem softwareSystem, java.io.File... files)Adds a "Deployment" section relating to aSoftwareSystemfrom one or more files.SectionaddDevelopmentEnvironmentSection(SoftwareSystem softwareSystem, Format format, java.lang.String content)Adds a "Development Environment" section relating to aSoftwareSystem.SectionaddDevelopmentEnvironmentSection(SoftwareSystem softwareSystem, java.io.File... files)Adds a "Development Environment" section relating to aSoftwareSystemfrom one or more files.SectionaddFunctionalOverviewSection(SoftwareSystem softwareSystem, Format format, java.lang.String content)Adds a "Functional Overview" section relating to aSoftwareSystem.SectionaddFunctionalOverviewSection(SoftwareSystem softwareSystem, java.io.File... files)Adds a "Functional Overview" section relating to aSoftwareSystemfrom one or more files.SectionaddInfrastructureArchitectureSection(SoftwareSystem softwareSystem, Format format, java.lang.String content)Adds a "Infrastructure Architecture" section relating to aSoftwareSystem.SectionaddInfrastructureArchitectureSection(SoftwareSystem softwareSystem, java.io.File... files)Adds an "Infrastructure Architecture" section relating to aSoftwareSystemfrom one or more files.SectionaddOperationAndSupportSection(SoftwareSystem softwareSystem, Format format, java.lang.String content)Adds a "Operation and Support" section relating to aSoftwareSystem.SectionaddOperationAndSupportSection(SoftwareSystem softwareSystem, java.io.File... files)Adds an "Operation and Support" section relating to aSoftwareSystemfrom one or more files.SectionaddPrinciplesSection(SoftwareSystem softwareSystem, Format format, java.lang.String content)Adds a "Principles" section relating to aSoftwareSystem.SectionaddPrinciplesSection(SoftwareSystem softwareSystem, java.io.File... files)Adds a "Principles" section relating to aSoftwareSystemfrom one or more files.SectionaddQualityAttributesSection(SoftwareSystem softwareSystem, Format format, java.lang.String content)Adds a "Quality Attributes" section relating to aSoftwareSystem.SectionaddQualityAttributesSection(SoftwareSystem softwareSystem, java.io.File... files)Adds a "Quality Attributes" section relating to aSoftwareSystemfrom one or more files.SectionaddSoftwareArchitectureSection(SoftwareSystem softwareSystem, Format format, java.lang.String content)Adds a "Software Architecture" section relating to aSoftwareSystem.SectionaddSoftwareArchitectureSection(SoftwareSystem softwareSystem, java.io.File... files)Adds a "Software Architecture" section relating to aSoftwareSystemfrom one or more files.protected TemplateMetadatagetMetadata()Gets the metadata associated with this template.Methods inherited from class com.structurizr.documentation.DocumentationTemplate
addImage, addImages, addSection, addSection, addSection, addSection, addSection, addSection, addSection, addSection
-
Constructor Details
-
Method Details
-
addContextSection
@Nonnull public Section addContextSection(@Nullable SoftwareSystem softwareSystem, java.io.File... files) throws java.io.IOExceptionAdds a "Context" section relating to aSoftwareSystemfrom one or more files.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates to, or null if it relates to the whole workspacefiles- one or more File objects that point to the documentation content- Returns:
- a documentation
Section - Throws:
java.io.IOException- if there is an error reading the files
-
addContextSection
@Nonnull public Section addContextSection(@Nullable SoftwareSystem softwareSystem, @Nonnull Format format, @Nonnull java.lang.String content)Adds a "Context" section relating to aSoftwareSystem.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates toformat- theFormatof the documentation contentcontent- a String containing the documentation content- Returns:
- a documentation
Section
-
addFunctionalOverviewSection
@Nonnull public Section addFunctionalOverviewSection(@Nullable SoftwareSystem softwareSystem, java.io.File... files) throws java.io.IOExceptionAdds a "Functional Overview" section relating to aSoftwareSystemfrom one or more files.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates tofiles- one or more File objects that point to the documentation content- Returns:
- a documentation
Section - Throws:
java.io.IOException- if there is an error reading the files
-
addFunctionalOverviewSection
@Nonnull public Section addFunctionalOverviewSection(@Nullable SoftwareSystem softwareSystem, @Nonnull Format format, @Nonnull java.lang.String content)Adds a "Functional Overview" section relating to aSoftwareSystem.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates toformat- theFormatof the documentation contentcontent- a String containing the documentation content- Returns:
- a documentation
Section
-
addQualityAttributesSection
@Nonnull public Section addQualityAttributesSection(@Nullable SoftwareSystem softwareSystem, java.io.File... files) throws java.io.IOExceptionAdds a "Quality Attributes" section relating to aSoftwareSystemfrom one or more files.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates tofiles- one or more File objects that point to the documentation content- Returns:
- a documentation
Section - Throws:
java.io.IOException- if there is an error reading the files
-
addQualityAttributesSection
@Nonnull public Section addQualityAttributesSection(@Nullable SoftwareSystem softwareSystem, @Nonnull Format format, @Nonnull java.lang.String content)Adds a "Quality Attributes" section relating to aSoftwareSystem.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates toformat- theFormatof the documentation contentcontent- a String containing the documentation content- Returns:
- a documentation
Section
-
addConstraintsSection
@Nonnull public Section addConstraintsSection(@Nullable SoftwareSystem softwareSystem, java.io.File... files) throws java.io.IOExceptionAdds a "Constraints" section relating to aSoftwareSystemfrom one or more files.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates tofiles- one or more File objects that point to the documentation content- Returns:
- a documentation
Section - Throws:
java.io.IOException- if there is an error reading the files
-
addConstraintsSection
@Nonnull public Section addConstraintsSection(@Nullable SoftwareSystem softwareSystem, @Nonnull Format format, @Nonnull java.lang.String content)Adds a "Constraints" section relating to aSoftwareSystem.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates toformat- theFormatof the documentation contentcontent- a String containing the documentation content- Returns:
- a documentation
Section
-
addPrinciplesSection
@Nonnull public Section addPrinciplesSection(@Nullable SoftwareSystem softwareSystem, java.io.File... files) throws java.io.IOExceptionAdds a "Principles" section relating to aSoftwareSystemfrom one or more files.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates tofiles- one or more File objects that point to the documentation content- Returns:
- a documentation
Section - Throws:
java.io.IOException- if there is an error reading the files
-
addPrinciplesSection
@Nonnull public Section addPrinciplesSection(@Nullable SoftwareSystem softwareSystem, @Nonnull Format format, @Nonnull java.lang.String content)Adds a "Principles" section relating to aSoftwareSystem.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates toformat- theFormatof the documentation contentcontent- a String containing the documentation content- Returns:
- a documentation
Section
-
addSoftwareArchitectureSection
@Nonnull public Section addSoftwareArchitectureSection(@Nullable SoftwareSystem softwareSystem, java.io.File... files) throws java.io.IOExceptionAdds a "Software Architecture" section relating to aSoftwareSystemfrom one or more files.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates tofiles- one or more File objects that point to the documentation content- Returns:
- a documentation
Section - Throws:
java.io.IOException- if there is an error reading the files
-
addSoftwareArchitectureSection
@Nonnull public Section addSoftwareArchitectureSection(@Nullable SoftwareSystem softwareSystem, @Nonnull Format format, @Nonnull java.lang.String content)Adds a "Software Architecture" section relating to aSoftwareSystem.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates toformat- theFormatof the documentation contentcontent- a String containing the documentation content- Returns:
- a documentation
Section
-
addContainersSection
@Nonnull public Section addContainersSection(@Nullable SoftwareSystem softwareSystem, java.io.File... files) throws java.io.IOExceptionAdds a "Containers" section relating to aSoftwareSystemfrom one or more files.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates tofiles- one or more File objects that point to the documentation content- Returns:
- a documentation
Section - Throws:
java.io.IOException- if there is an error reading the files
-
addContainersSection
@Nonnull public Section addContainersSection(@Nullable SoftwareSystem softwareSystem, @Nonnull Format format, @Nonnull java.lang.String content)Adds a "Containers" section relating to aSoftwareSystem.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates toformat- theFormatof the documentation contentcontent- a String containing the documentation content- Returns:
- a documentation
Section
-
addComponentsSection
@Nonnull public Section addComponentsSection(@Nullable Container container, java.io.File... files) throws java.io.IOExceptionAdds a "Components" section relating to aContainerfrom one or more files. -
addComponentsSection
@Nonnull public Section addComponentsSection(@Nullable Container container, @Nonnull Format format, @Nonnull java.lang.String content)Adds a "Components" section relating to aContainer. -
addCodeSection
@Nonnull public Section addCodeSection(@Nullable Component component, java.io.File... files) throws java.io.IOExceptionAdds a "Code" section relating to aComponentfrom one or more files. -
addCodeSection
@Nonnull public Section addCodeSection(@Nullable Component component, @Nonnull Format format, @Nonnull java.lang.String content)Adds a "Code" section relating to aComponent. -
addDataSection
@Nonnull public Section addDataSection(@Nullable SoftwareSystem softwareSystem, java.io.File... files) throws java.io.IOExceptionAdds a "Data" section relating to aSoftwareSystemfrom one or more files.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates tofiles- one or more File objects that point to the documentation content- Returns:
- a documentation
Section - Throws:
java.io.IOException- if there is an error reading the files
-
addDataSection
@Nonnull public Section addDataSection(@Nullable SoftwareSystem softwareSystem, @Nonnull Format format, @Nonnull java.lang.String content)Adds a "Data" section relating to aSoftwareSystem.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates toformat- theFormatof the documentation contentcontent- a String containing the documentation content- Returns:
- a documentation
Section
-
addInfrastructureArchitectureSection
@Nonnull public Section addInfrastructureArchitectureSection(@Nullable SoftwareSystem softwareSystem, java.io.File... files) throws java.io.IOExceptionAdds an "Infrastructure Architecture" section relating to aSoftwareSystemfrom one or more files.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates tofiles- one or more File objects that point to the documentation content- Returns:
- a documentation
Section - Throws:
java.io.IOException- if there is an error reading the files
-
addInfrastructureArchitectureSection
@Nonnull public Section addInfrastructureArchitectureSection(@Nullable SoftwareSystem softwareSystem, @Nonnull Format format, @Nonnull java.lang.String content)Adds a "Infrastructure Architecture" section relating to aSoftwareSystem.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates toformat- theFormatof the documentation contentcontent- a String containing the documentation content- Returns:
- a documentation
Section
-
addDeploymentSection
@Nonnull public Section addDeploymentSection(@Nullable SoftwareSystem softwareSystem, java.io.File... files) throws java.io.IOExceptionAdds a "Deployment" section relating to aSoftwareSystemfrom one or more files.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates tofiles- one or more File objects that point to the documentation content- Returns:
- a documentation
Section - Throws:
java.io.IOException- if there is an error reading the files
-
addDeploymentSection
@Nonnull public Section addDeploymentSection(@Nullable SoftwareSystem softwareSystem, @Nonnull Format format, @Nonnull java.lang.String content)Adds a "Deployment" section relating to aSoftwareSystem.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates toformat- theFormatof the documentation contentcontent- a String containing the documentation content- Returns:
- a documentation
Section
-
addDevelopmentEnvironmentSection
@Nonnull public Section addDevelopmentEnvironmentSection(@Nullable SoftwareSystem softwareSystem, java.io.File... files) throws java.io.IOExceptionAdds a "Development Environment" section relating to aSoftwareSystemfrom one or more files.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates tofiles- one or more File objects that point to the documentation content- Returns:
- a documentation
Section - Throws:
java.io.IOException- if there is an error reading the files
-
addDevelopmentEnvironmentSection
@Nonnull public Section addDevelopmentEnvironmentSection(@Nullable SoftwareSystem softwareSystem, @Nonnull Format format, @Nonnull java.lang.String content)Adds a "Development Environment" section relating to aSoftwareSystem.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates toformat- theFormatof the documentation contentcontent- a String containing the documentation content- Returns:
- a documentation
Section
-
addOperationAndSupportSection
@Nonnull public Section addOperationAndSupportSection(@Nullable SoftwareSystem softwareSystem, java.io.File... files) throws java.io.IOExceptionAdds an "Operation and Support" section relating to aSoftwareSystemfrom one or more files.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates tofiles- one or more File objects that point to the documentation content- Returns:
- a documentation
Section - Throws:
java.io.IOException- if there is an error reading the files
-
addOperationAndSupportSection
@Nonnull public Section addOperationAndSupportSection(@Nullable SoftwareSystem softwareSystem, @Nonnull Format format, @Nonnull java.lang.String content)Adds a "Operation and Support" section relating to aSoftwareSystem.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates toformat- theFormatof the documentation contentcontent- a String containing the documentation content- Returns:
- a documentation
Section
-
addDecisionLogSection
@Nonnull public Section addDecisionLogSection(@Nullable SoftwareSystem softwareSystem, java.io.File... files) throws java.io.IOExceptionAdds a "Decision Log" section relating to aSoftwareSystemfrom one or more files.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates tofiles- one or more File objects that point to the documentation content- Returns:
- a documentation
Section - Throws:
java.io.IOException- if there is an error reading the files
-
addDecisionLogSection
@Nonnull public Section addDecisionLogSection(@Nullable SoftwareSystem softwareSystem, @Nonnull Format format, @Nonnull java.lang.String content)Adds a "Decision Log" section relating to aSoftwareSystem.- Parameters:
softwareSystem- theSoftwareSystemthe documentation content relates toformat- theFormatof the documentation contentcontent- a String containing the documentation content- Returns:
- a documentation
Section
-
getMetadata
Description copied from class:DocumentationTemplateGets the metadata associated with this template.- Specified by:
getMetadatain classDocumentationTemplate- Returns:
- a TemplateMetadata object, or null if there is none
-