Class SphinxIntegration
- All Implemented Interfaces:
 SmithyIntegration<DocSettings,,DocWriter, DocGenerationContext> DocIntegration
This integration runs in low priority to allow other integrations to generate
 files that will be picked up by sphinx-build. To have an integration reliably run
 after this, override SmithyIntegration.runAfter() with the output of
 name() in the list. Similarly, to guarantee an integration
 is run before this, override SmithyIntegration.runBefore() with the same argument.
 
To customize the project files generated by this integration, you can make use
 of SmithyIntegration.interceptors(C) to intercept and modify the files before
 they're written. The following named code sections are used:
 
ConfSection: Creates theconf.pyMakefileSection: Creates theMakefilebuild script for unix.WindowsMakeSection: Creates themake.batbuild script for Windows.RequirementsSection: Creates therequirements.txtused to build the docs. Any dependencies here will be installed into the environment used to runsphinx-build.
SphinxIntegration.SphinxSettings. These settings are configured similarly to the doc
 generation plugin settings. Below is an example smithy-build.json with
 sphinx project auto build disabled.
 
 {
     "version": "1.0",
     "projections": {
         "sphinx-markdown": {
             "plugins": {
                 "docgen": {
                     "service": "com.example#DocumentedService",
                     "format": "sphinx-markdown",
                     "integrations": {
                         "sphinx": {
                             "autoBuild": false
                         }
                     }
                 }
             }
         }
     }
 }
 - 
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final recordSettings for sphinx projects, regardless of their intermediate format. - 
Constructor Summary
Constructors - 
Method Summary
Modifier and TypeMethodDescriptionvoidconfigure(DocSettings settings, ObjectNode integrationSettings) Configures the integration.voidcustomize(DocGenerationContext context) Allows generators to write additional files, perform additional tasks, and interact directly with aFileManifestused to write files to the plugin's output.docFormats(DocSettings settings) AddsDocFormats to the list of supported formats.name()Gets the name of the integration.bytepriority()Gets the priority ordering relative to the topologically ordered integration graph determined bySmithyIntegration.runBefore()andSmithyIntegration.runAfter().Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface software.amazon.smithy.codegen.core.SmithyIntegration
decorateSymbolProvider, interceptors, preprocessModel, runAfter, runBefore 
- 
Constructor Details
- 
SphinxIntegration
public SphinxIntegration() 
 - 
 - 
Method Details
- 
name
Description copied from interface:SmithyIntegrationGets the name of the integration.This name is referred to when ordering the graph of integrations. The name defaults to the canonical class name if not overridden.
- Specified by:
 namein interfaceSmithyIntegration<DocSettings,DocWriter, DocGenerationContext> - Returns:
 - Returns the integration name.
 
 - 
priority
public byte priority()Description copied from interface:SmithyIntegrationGets the priority ordering relative to the topologically ordered integration graph determined bySmithyIntegration.runBefore()andSmithyIntegration.runAfter().Higher numbers come before lower numbers.
When ordering, implementations must not allow cycles, and no two integrations may have the same name.
- Specified by:
 priorityin interfaceSmithyIntegration<DocSettings,DocWriter, DocGenerationContext> - Returns:
 - Returns the priority order.
 
 - 
configure
Description copied from interface:SmithyIntegrationConfigures the integration.This provides access to both the parsed settings for the generator and an unparsed
ObjectNodecontaining settings for this particular integration.The following
smithy-build.jsonfile contains an example of how this configuration will be set.{ "version": "1.0", "projections": { "codegen-projection": { "plugins": { "code-generator": { "service": "com.example#DocumentedService", "integrations": { "my-integration": { "example-setting": "foo" } } } } } } }In this example, an integration whose
SmithyIntegration.name()ismy-integrationWould receive the extra settings from the key of the same name within theintegrationsnode.Integrations SHOULD use modeled traits as much as possible to drive configuration. This is intended for configuration that doesn't make sense as a trait, such as configuring a documentation theme.
- Specified by:
 configurein interfaceSmithyIntegration<DocSettings,DocWriter, DocGenerationContext> - Parameters:
 settings- Settings used to generate code.integrationSettings- Settings used to configure integrations.
 - 
docFormats
Description copied from interface:DocIntegrationAddsDocFormats to the list of supported formats.When resolving the format implementation, the first format found with a matching name will be used. Use
SmithyIntegration.priority()to adjust which integration is seen first.- Specified by:
 docFormatsin interfaceDocIntegration- Parameters:
 settings- The documentation generation settings.- Returns:
 - A list of formats to add.
 
 - 
customize
Description copied from interface:SmithyIntegrationAllows generators to write additional files, perform additional tasks, and interact directly with aFileManifestused to write files to the plugin's output.This method should generally be invoked at the end of the code generation process.
- Specified by:
 customizein interfaceSmithyIntegration<DocSettings,DocWriter, DocGenerationContext> - Parameters:
 context- Code generation context that can be queried when writing additional files.
 
 -