515 lines
31 KiB
JSON
515 lines
31 KiB
JSON
{
|
||
"module": "docforge.renderers",
|
||
"content": {
|
||
"path": "docforge.renderers",
|
||
"docstring": "# Summary\n\nRenderers layer for doc-forge.\n\nThe `docforge.renderers` package transforms the internal documentation\nmodels into files formatted for specific documentation systems.\n\n---\n\n# Overview\n\nRenderers consume the doc-forge project model and generate output suitable\nfor documentation tools or machine interfaces.\n\nCurrent implementations:\n\n- **MkDocsRenderer** – Produces Markdown files compatible with MkDocs and\n the `mkdocstrings` plugin. It automatically handles package hierarchy\n and generates `index.md` files for packages.\n- **MCPRenderer** – Emits structured JSON resources designed for consumption\n by Model Context Protocol (MCP) clients.\n\n---\n\n# Extending\n\nNew renderers can be added by implementing the `DocRenderer` protocol\ndefined in `docforge.renderers.base`.\n\n---",
|
||
"objects": {
|
||
"MkDocsRenderer": {
|
||
"name": "MkDocsRenderer",
|
||
"kind": "class",
|
||
"path": "docforge.renderers.MkDocsRenderer",
|
||
"signature": null,
|
||
"docstring": "Renderer that produces Markdown documentation for MkDocs.\n\nGenerated pages use mkdocstrings directives to reference Python modules,\nallowing MkDocs to render API documentation dynamically.",
|
||
"members": {
|
||
"name": {
|
||
"name": "name",
|
||
"kind": "attribute",
|
||
"path": "docforge.renderers.MkDocsRenderer.name",
|
||
"signature": null,
|
||
"docstring": null
|
||
},
|
||
"generate_sources": {
|
||
"name": "generate_sources",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.MkDocsRenderer.generate_sources",
|
||
"signature": "generate_sources(project: Project, out_dir: Path, module_is_source: bool | None = None)",
|
||
"docstring": "Generate Markdown documentation files for a project.\n\nThis method renders a documentation structure from the provided\nproject model and writes the resulting Markdown files to the\nspecified output directory.\n\nArgs:\n project (Project):\n Project model containing modules to document.\n\n out_dir (Path):\n Directory where generated Markdown files will be written.\n\n module_is_source (bool | None):\n If True, treat the specified module as the documentation root\n rather than nesting it inside a folder."
|
||
},
|
||
"generate_readme": {
|
||
"name": "generate_readme",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.MkDocsRenderer.generate_readme",
|
||
"signature": "generate_readme(project: Project, docs_dir: Path, module_is_source: bool | None = None, readme_dir: Path | None = None)",
|
||
"docstring": "Generate a `README.md` file from the root module docstring.\n\nNotes:\n - If `module_is_source` is True, `README.md` is written to the\n project root directory.\n - If False, README generation is currently not implemented.\n\nArgs:\n project (Project):\n Project model containing documentation metadata.\n\n docs_dir (Path):\n Directory containing generated documentation sources.\n\n module_is_source (bool | None):\n Whether the module is treated as the project source root.\n\n readme_dir (Path | None):\n Directory where the generated README.md should be written.\n Defaults to the parent of `docs_dir`."
|
||
}
|
||
}
|
||
},
|
||
"MCPRenderer": {
|
||
"name": "MCPRenderer",
|
||
"kind": "class",
|
||
"path": "docforge.renderers.MCPRenderer",
|
||
"signature": null,
|
||
"docstring": "Renderer that generates MCP-compatible documentation resources.\n\nThis renderer converts doc-forge project models into structured JSON\nresources suitable for consumption by systems implementing the Model\nContext Protocol (MCP).",
|
||
"members": {
|
||
"name": {
|
||
"name": "name",
|
||
"kind": "attribute",
|
||
"path": "docforge.renderers.MCPRenderer.name",
|
||
"signature": null,
|
||
"docstring": null
|
||
},
|
||
"generate_sources": {
|
||
"name": "generate_sources",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.MCPRenderer.generate_sources",
|
||
"signature": "generate_sources(project: Project, out_dir: Path)",
|
||
"docstring": "Generate MCP documentation resources for a project.\n\nThe renderer serializes each module into a JSON resource and produces\nsupporting metadata files such as `nav.json` and `index.json`.\n\nArgs:\n project (Project):\n Documentation project model to render.\n\n out_dir (Path):\n Directory where MCP resources will be written."
|
||
}
|
||
}
|
||
},
|
||
"base": {
|
||
"name": "base",
|
||
"kind": "module",
|
||
"path": "docforge.renderers.base",
|
||
"signature": null,
|
||
"docstring": "# Summary\n\nRenderer base interfaces and configuration models.\n\nThis module defines the base protocol and configuration container used by\ndoc-forge renderers. Concrete renderer implementations should implement the\n`DocRenderer` protocol.",
|
||
"members": {
|
||
"Project": {
|
||
"name": "Project",
|
||
"kind": "class",
|
||
"path": "docforge.renderers.base.Project",
|
||
"signature": "Project(name: str)",
|
||
"docstring": "Representation of a documentation project.\n\nA `Project` serves as the root container for all modules discovered during\nintrospection. Each module is stored by its dotted import path.\n\nAttributes:\n name (str):\n Name of the project.\n\n modules (dict[str, Module]):\n Mapping of module paths to `Module` instances.",
|
||
"members": {
|
||
"name": {
|
||
"name": "name",
|
||
"kind": "attribute",
|
||
"path": "docforge.renderers.base.Project.name",
|
||
"signature": null,
|
||
"docstring": null
|
||
},
|
||
"modules": {
|
||
"name": "modules",
|
||
"kind": "attribute",
|
||
"path": "docforge.renderers.base.Project.modules",
|
||
"signature": null,
|
||
"docstring": null
|
||
},
|
||
"add_module": {
|
||
"name": "add_module",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.base.Project.add_module",
|
||
"signature": "add_module(module: Module)",
|
||
"docstring": "Register a module in the project.\n\nArgs:\n module (Module):\n Module instance to add to the project."
|
||
},
|
||
"get_module": {
|
||
"name": "get_module",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.base.Project.get_module",
|
||
"signature": "get_module(path: str)",
|
||
"docstring": "Retrieve a module by its dotted path.\n\nArgs:\n path (str):\n Fully qualified dotted module path (for example `pkg.module`).\n\nReturns:\n Module:\n The corresponding `Module` instance.\n\nRaises:\n KeyError:\n If the module does not exist in the project."
|
||
},
|
||
"get_all_modules": {
|
||
"name": "get_all_modules",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.base.Project.get_all_modules",
|
||
"signature": "get_all_modules()",
|
||
"docstring": "Return all modules contained in the project.\n\nReturns:\n Iterable[Module]:\n An iterable of `Module` instances."
|
||
},
|
||
"get_module_list": {
|
||
"name": "get_module_list",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.base.Project.get_module_list",
|
||
"signature": "get_module_list()",
|
||
"docstring": "Return the list of module import paths.\n\nReturns:\n list[str]:\n A list containing the dotted paths of all modules in the project."
|
||
}
|
||
}
|
||
},
|
||
"RendererConfig": {
|
||
"name": "RendererConfig",
|
||
"kind": "class",
|
||
"path": "docforge.renderers.base.RendererConfig",
|
||
"signature": "RendererConfig(out_dir: Path, project: Project)",
|
||
"docstring": "Configuration container for documentation renderers.\n\nA `RendererConfig` instance groups together the project model and the\noutput directory used during rendering.\n\nAttributes:\n out_dir (Path):\n Directory where generated documentation files will be written.\n\n project (Project):\n Documentation project model to be rendered.",
|
||
"members": {
|
||
"out_dir": {
|
||
"name": "out_dir",
|
||
"kind": "attribute",
|
||
"path": "docforge.renderers.base.RendererConfig.out_dir",
|
||
"signature": null,
|
||
"docstring": null
|
||
},
|
||
"project": {
|
||
"name": "project",
|
||
"kind": "attribute",
|
||
"path": "docforge.renderers.base.RendererConfig.project",
|
||
"signature": null,
|
||
"docstring": null
|
||
}
|
||
}
|
||
},
|
||
"DocRenderer": {
|
||
"name": "DocRenderer",
|
||
"kind": "class",
|
||
"path": "docforge.renderers.base.DocRenderer",
|
||
"signature": null,
|
||
"docstring": "Protocol defining the interface for documentation renderers.\n\nImplementations of this protocol are responsible for transforming a\n`Project` model into renderer-specific documentation sources.",
|
||
"members": {
|
||
"name": {
|
||
"name": "name",
|
||
"kind": "attribute",
|
||
"path": "docforge.renderers.base.DocRenderer.name",
|
||
"signature": null,
|
||
"docstring": null
|
||
},
|
||
"generate_sources": {
|
||
"name": "generate_sources",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.base.DocRenderer.generate_sources",
|
||
"signature": "generate_sources(project: Project, out_dir: Path) -> None",
|
||
"docstring": "Generate renderer-specific documentation sources.\n\nArgs:\n project (Project):\n Project model containing modules and documentation objects.\n\n out_dir (Path):\n Directory where generated documentation sources should be written."
|
||
}
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"mcp_renderer": {
|
||
"name": "mcp_renderer",
|
||
"kind": "module",
|
||
"path": "docforge.renderers.mcp_renderer",
|
||
"signature": null,
|
||
"docstring": "# Summary\n\nMCP renderer implementation.\n\nThis module defines the `MCPRenderer` class, which generates documentation\nresources compatible with the Model Context Protocol (MCP).",
|
||
"members": {
|
||
"DocObject": {
|
||
"name": "DocObject",
|
||
"kind": "class",
|
||
"path": "docforge.renderers.mcp_renderer.DocObject",
|
||
"signature": "DocObject(name: str, kind: str, path: str, signature: str | None = None, docstring: str | None = None)",
|
||
"docstring": "Representation of a documented Python object.\n\nA `DocObject` models a single Python entity discovered during\nintrospection. Objects may contain nested members, allowing the structure\nof modules, classes, and other containers to be represented recursively.\n\nAttributes:\n name (str):\n Local name of the object.\n\n kind (str):\n Type of object (for example `class`, `function`, `method`, or `attribute`).\n\n path (str):\n Fully qualified dotted path to the object.\n\n signature (str | None):\n Callable signature if the object represents a callable.\n\n docstring (str | None):\n Raw docstring text extracted from the source code.\n\n members (dict[str, DocObject]):\n Mapping of member names to child `DocObject` instances.",
|
||
"members": {
|
||
"name": {
|
||
"name": "name",
|
||
"kind": "attribute",
|
||
"path": "docforge.renderers.mcp_renderer.DocObject.name",
|
||
"signature": null,
|
||
"docstring": null
|
||
},
|
||
"kind": {
|
||
"name": "kind",
|
||
"kind": "attribute",
|
||
"path": "docforge.renderers.mcp_renderer.DocObject.kind",
|
||
"signature": null,
|
||
"docstring": null
|
||
},
|
||
"path": {
|
||
"name": "path",
|
||
"kind": "attribute",
|
||
"path": "docforge.renderers.mcp_renderer.DocObject.path",
|
||
"signature": null,
|
||
"docstring": null
|
||
},
|
||
"signature": {
|
||
"name": "signature",
|
||
"kind": "attribute",
|
||
"path": "docforge.renderers.mcp_renderer.DocObject.signature",
|
||
"signature": null,
|
||
"docstring": null
|
||
},
|
||
"docstring": {
|
||
"name": "docstring",
|
||
"kind": "attribute",
|
||
"path": "docforge.renderers.mcp_renderer.DocObject.docstring",
|
||
"signature": null,
|
||
"docstring": null
|
||
},
|
||
"members": {
|
||
"name": "members",
|
||
"kind": "attribute",
|
||
"path": "docforge.renderers.mcp_renderer.DocObject.members",
|
||
"signature": null,
|
||
"docstring": null
|
||
},
|
||
"add_member": {
|
||
"name": "add_member",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.mcp_renderer.DocObject.add_member",
|
||
"signature": "add_member(obj: DocObject)",
|
||
"docstring": "Add a child documentation object.\n\nThis is typically used when attaching methods to classes or\nnested objects to their parent containers.\n\nArgs:\n obj (DocObject):\n Documentation object to add as a member."
|
||
},
|
||
"get_member": {
|
||
"name": "get_member",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.mcp_renderer.DocObject.get_member",
|
||
"signature": "get_member(name: str)",
|
||
"docstring": "Retrieve a member object by name.\n\nArgs:\n name (str):\n Name of the member to retrieve.\n\nReturns:\n DocObject:\n The corresponding `DocObject` instance.\n\nRaises:\n KeyError:\n If the member does not exist."
|
||
},
|
||
"get_all_members": {
|
||
"name": "get_all_members",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.mcp_renderer.DocObject.get_all_members",
|
||
"signature": "get_all_members()",
|
||
"docstring": "Return all child members of the object.\n\nReturns:\n Iterable[DocObject]:\n An iterable of `DocObject` instances representing nested members."
|
||
}
|
||
}
|
||
},
|
||
"Module": {
|
||
"name": "Module",
|
||
"kind": "class",
|
||
"path": "docforge.renderers.mcp_renderer.Module",
|
||
"signature": "Module(path: str, docstring: str | None = None)",
|
||
"docstring": "Representation of a documented Python module or package.\n\nA `Module` stores metadata about the module itself and maintains a\ncollection of top-level documentation objects discovered during\nintrospection.\n\nAttributes:\n path (str):\n Dotted import path of the module.\n\n docstring (str | None):\n Module-level documentation string, if present.\n\n members (dict[str, DocObject]):\n Mapping of object names to their corresponding `DocObject` representations.",
|
||
"members": {
|
||
"path": {
|
||
"name": "path",
|
||
"kind": "attribute",
|
||
"path": "docforge.renderers.mcp_renderer.Module.path",
|
||
"signature": null,
|
||
"docstring": null
|
||
},
|
||
"docstring": {
|
||
"name": "docstring",
|
||
"kind": "attribute",
|
||
"path": "docforge.renderers.mcp_renderer.Module.docstring",
|
||
"signature": null,
|
||
"docstring": null
|
||
},
|
||
"members": {
|
||
"name": "members",
|
||
"kind": "attribute",
|
||
"path": "docforge.renderers.mcp_renderer.Module.members",
|
||
"signature": null,
|
||
"docstring": null
|
||
},
|
||
"add_object": {
|
||
"name": "add_object",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.mcp_renderer.Module.add_object",
|
||
"signature": "add_object(obj: DocObject)",
|
||
"docstring": "Add a documented object to the module.\n\nArgs:\n obj (DocObject):\n Documentation object to register as a top-level member of the module."
|
||
},
|
||
"get_object": {
|
||
"name": "get_object",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.mcp_renderer.Module.get_object",
|
||
"signature": "get_object(name: str)",
|
||
"docstring": "Retrieve a documented object by name.\n\nArgs:\n name (str):\n Name of the object to retrieve.\n\nReturns:\n DocObject:\n The corresponding `DocObject` instance.\n\nRaises:\n KeyError:\n If no object with the given name exists."
|
||
},
|
||
"get_all_objects": {
|
||
"name": "get_all_objects",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.mcp_renderer.Module.get_all_objects",
|
||
"signature": "get_all_objects()",
|
||
"docstring": "Return all top-level documentation objects in the module.\n\nReturns:\n Iterable[DocObject]:\n An iterable of `DocObject` instances representing the module's public members."
|
||
}
|
||
}
|
||
},
|
||
"Project": {
|
||
"name": "Project",
|
||
"kind": "class",
|
||
"path": "docforge.renderers.mcp_renderer.Project",
|
||
"signature": "Project(name: str)",
|
||
"docstring": "Representation of a documentation project.\n\nA `Project` serves as the root container for all modules discovered during\nintrospection. Each module is stored by its dotted import path.\n\nAttributes:\n name (str):\n Name of the project.\n\n modules (dict[str, Module]):\n Mapping of module paths to `Module` instances.",
|
||
"members": {
|
||
"name": {
|
||
"name": "name",
|
||
"kind": "attribute",
|
||
"path": "docforge.renderers.mcp_renderer.Project.name",
|
||
"signature": null,
|
||
"docstring": null
|
||
},
|
||
"modules": {
|
||
"name": "modules",
|
||
"kind": "attribute",
|
||
"path": "docforge.renderers.mcp_renderer.Project.modules",
|
||
"signature": null,
|
||
"docstring": null
|
||
},
|
||
"add_module": {
|
||
"name": "add_module",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.mcp_renderer.Project.add_module",
|
||
"signature": "add_module(module: Module)",
|
||
"docstring": "Register a module in the project.\n\nArgs:\n module (Module):\n Module instance to add to the project."
|
||
},
|
||
"get_module": {
|
||
"name": "get_module",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.mcp_renderer.Project.get_module",
|
||
"signature": "get_module(path: str)",
|
||
"docstring": "Retrieve a module by its dotted path.\n\nArgs:\n path (str):\n Fully qualified dotted module path (for example `pkg.module`).\n\nReturns:\n Module:\n The corresponding `Module` instance.\n\nRaises:\n KeyError:\n If the module does not exist in the project."
|
||
},
|
||
"get_all_modules": {
|
||
"name": "get_all_modules",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.mcp_renderer.Project.get_all_modules",
|
||
"signature": "get_all_modules()",
|
||
"docstring": "Return all modules contained in the project.\n\nReturns:\n Iterable[Module]:\n An iterable of `Module` instances."
|
||
},
|
||
"get_module_list": {
|
||
"name": "get_module_list",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.mcp_renderer.Project.get_module_list",
|
||
"signature": "get_module_list()",
|
||
"docstring": "Return the list of module import paths.\n\nReturns:\n list[str]:\n A list containing the dotted paths of all modules in the project."
|
||
}
|
||
}
|
||
},
|
||
"MCPRenderer": {
|
||
"name": "MCPRenderer",
|
||
"kind": "class",
|
||
"path": "docforge.renderers.mcp_renderer.MCPRenderer",
|
||
"signature": null,
|
||
"docstring": "Renderer that generates MCP-compatible documentation resources.\n\nThis renderer converts doc-forge project models into structured JSON\nresources suitable for consumption by systems implementing the Model\nContext Protocol (MCP).",
|
||
"members": {
|
||
"name": {
|
||
"name": "name",
|
||
"kind": "attribute",
|
||
"path": "docforge.renderers.mcp_renderer.MCPRenderer.name",
|
||
"signature": null,
|
||
"docstring": null
|
||
},
|
||
"generate_sources": {
|
||
"name": "generate_sources",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.mcp_renderer.MCPRenderer.generate_sources",
|
||
"signature": "generate_sources(project: Project, out_dir: Path) -> None",
|
||
"docstring": "Generate MCP documentation resources for a project.\n\nThe renderer serializes each module into a JSON resource and produces\nsupporting metadata files such as `nav.json` and `index.json`.\n\nArgs:\n project (Project):\n Documentation project model to render.\n\n out_dir (Path):\n Directory where MCP resources will be written."
|
||
}
|
||
}
|
||
}
|
||
}
|
||
},
|
||
"mkdocs_renderer": {
|
||
"name": "mkdocs_renderer",
|
||
"kind": "module",
|
||
"path": "docforge.renderers.mkdocs_renderer",
|
||
"signature": null,
|
||
"docstring": "# Summary\n\nMkDocs renderer implementation.\n\nThis module defines the `MkDocsRenderer` class, which generates Markdown\ndocumentation sources compatible with MkDocs Material and the mkdocstrings\nplugin.\n\nThe renderer ensures a consistent documentation structure by:\n\n- Creating a root `index.md` if one does not exist\n- Generating package index pages automatically\n- Linking child modules within parent package pages\n- Optionally generating `README.md` from the root package docstring",
|
||
"members": {
|
||
"Module": {
|
||
"name": "Module",
|
||
"kind": "class",
|
||
"path": "docforge.renderers.mkdocs_renderer.Module",
|
||
"signature": "Module(path: str, docstring: str | None = None)",
|
||
"docstring": "Representation of a documented Python module or package.\n\nA `Module` stores metadata about the module itself and maintains a\ncollection of top-level documentation objects discovered during\nintrospection.\n\nAttributes:\n path (str):\n Dotted import path of the module.\n\n docstring (str | None):\n Module-level documentation string, if present.\n\n members (dict[str, DocObject]):\n Mapping of object names to their corresponding `DocObject` representations.",
|
||
"members": {
|
||
"path": {
|
||
"name": "path",
|
||
"kind": "attribute",
|
||
"path": "docforge.renderers.mkdocs_renderer.Module.path",
|
||
"signature": null,
|
||
"docstring": null
|
||
},
|
||
"docstring": {
|
||
"name": "docstring",
|
||
"kind": "attribute",
|
||
"path": "docforge.renderers.mkdocs_renderer.Module.docstring",
|
||
"signature": null,
|
||
"docstring": null
|
||
},
|
||
"members": {
|
||
"name": "members",
|
||
"kind": "attribute",
|
||
"path": "docforge.renderers.mkdocs_renderer.Module.members",
|
||
"signature": null,
|
||
"docstring": null
|
||
},
|
||
"add_object": {
|
||
"name": "add_object",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.mkdocs_renderer.Module.add_object",
|
||
"signature": "add_object(obj: DocObject)",
|
||
"docstring": "Add a documented object to the module.\n\nArgs:\n obj (DocObject):\n Documentation object to register as a top-level member of the module."
|
||
},
|
||
"get_object": {
|
||
"name": "get_object",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.mkdocs_renderer.Module.get_object",
|
||
"signature": "get_object(name: str)",
|
||
"docstring": "Retrieve a documented object by name.\n\nArgs:\n name (str):\n Name of the object to retrieve.\n\nReturns:\n DocObject:\n The corresponding `DocObject` instance.\n\nRaises:\n KeyError:\n If no object with the given name exists."
|
||
},
|
||
"get_all_objects": {
|
||
"name": "get_all_objects",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.mkdocs_renderer.Module.get_all_objects",
|
||
"signature": "get_all_objects()",
|
||
"docstring": "Return all top-level documentation objects in the module.\n\nReturns:\n Iterable[DocObject]:\n An iterable of `DocObject` instances representing the module's public members."
|
||
}
|
||
}
|
||
},
|
||
"Project": {
|
||
"name": "Project",
|
||
"kind": "class",
|
||
"path": "docforge.renderers.mkdocs_renderer.Project",
|
||
"signature": "Project(name: str)",
|
||
"docstring": "Representation of a documentation project.\n\nA `Project` serves as the root container for all modules discovered during\nintrospection. Each module is stored by its dotted import path.\n\nAttributes:\n name (str):\n Name of the project.\n\n modules (dict[str, Module]):\n Mapping of module paths to `Module` instances.",
|
||
"members": {
|
||
"name": {
|
||
"name": "name",
|
||
"kind": "attribute",
|
||
"path": "docforge.renderers.mkdocs_renderer.Project.name",
|
||
"signature": null,
|
||
"docstring": null
|
||
},
|
||
"modules": {
|
||
"name": "modules",
|
||
"kind": "attribute",
|
||
"path": "docforge.renderers.mkdocs_renderer.Project.modules",
|
||
"signature": null,
|
||
"docstring": null
|
||
},
|
||
"add_module": {
|
||
"name": "add_module",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.mkdocs_renderer.Project.add_module",
|
||
"signature": "add_module(module: Module)",
|
||
"docstring": "Register a module in the project.\n\nArgs:\n module (Module):\n Module instance to add to the project."
|
||
},
|
||
"get_module": {
|
||
"name": "get_module",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.mkdocs_renderer.Project.get_module",
|
||
"signature": "get_module(path: str)",
|
||
"docstring": "Retrieve a module by its dotted path.\n\nArgs:\n path (str):\n Fully qualified dotted module path (for example `pkg.module`).\n\nReturns:\n Module:\n The corresponding `Module` instance.\n\nRaises:\n KeyError:\n If the module does not exist in the project."
|
||
},
|
||
"get_all_modules": {
|
||
"name": "get_all_modules",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.mkdocs_renderer.Project.get_all_modules",
|
||
"signature": "get_all_modules()",
|
||
"docstring": "Return all modules contained in the project.\n\nReturns:\n Iterable[Module]:\n An iterable of `Module` instances."
|
||
},
|
||
"get_module_list": {
|
||
"name": "get_module_list",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.mkdocs_renderer.Project.get_module_list",
|
||
"signature": "get_module_list()",
|
||
"docstring": "Return the list of module import paths.\n\nReturns:\n list[str]:\n A list containing the dotted paths of all modules in the project."
|
||
}
|
||
}
|
||
},
|
||
"MkDocsRenderer": {
|
||
"name": "MkDocsRenderer",
|
||
"kind": "class",
|
||
"path": "docforge.renderers.mkdocs_renderer.MkDocsRenderer",
|
||
"signature": null,
|
||
"docstring": "Renderer that produces Markdown documentation for MkDocs.\n\nGenerated pages use mkdocstrings directives to reference Python modules,\nallowing MkDocs to render API documentation dynamically.",
|
||
"members": {
|
||
"name": {
|
||
"name": "name",
|
||
"kind": "attribute",
|
||
"path": "docforge.renderers.mkdocs_renderer.MkDocsRenderer.name",
|
||
"signature": null,
|
||
"docstring": null
|
||
},
|
||
"generate_sources": {
|
||
"name": "generate_sources",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.mkdocs_renderer.MkDocsRenderer.generate_sources",
|
||
"signature": "generate_sources(project: Project, out_dir: Path, module_is_source: bool | None = None) -> None",
|
||
"docstring": "Generate Markdown documentation files for a project.\n\nThis method renders a documentation structure from the provided\nproject model and writes the resulting Markdown files to the\nspecified output directory.\n\nArgs:\n project (Project):\n Project model containing modules to document.\n\n out_dir (Path):\n Directory where generated Markdown files will be written.\n\n module_is_source (bool | None):\n If True, treat the specified module as the documentation root\n rather than nesting it inside a folder."
|
||
},
|
||
"generate_readme": {
|
||
"name": "generate_readme",
|
||
"kind": "function",
|
||
"path": "docforge.renderers.mkdocs_renderer.MkDocsRenderer.generate_readme",
|
||
"signature": "generate_readme(project: Project, docs_dir: Path, module_is_source: bool | None = None, readme_dir: Path | None = None) -> None",
|
||
"docstring": "Generate a `README.md` file from the root module docstring.\n\nNotes:\n - If `module_is_source` is True, `README.md` is written to the\n project root directory.\n - If False, README generation is currently not implemented.\n\nArgs:\n project (Project):\n Project model containing documentation metadata.\n\n docs_dir (Path):\n Directory containing generated documentation sources.\n\n module_is_source (bool | None):\n Whether the module is treated as the project source root.\n\n readme_dir (Path | None):\n Directory where the generated README.md should be written.\n Defaults to the parent of `docs_dir`."
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
} |