@loopback/docs
Version:
Documentation files rendered at [https://loopback.io](https://loopback.io)
139 lines (66 loc) • 2.11 kB
Markdown
---
lang: en
title: 'API docs: context-explorer.contextgraph'
keywords: LoopBack 4.0, LoopBack 4, Node.js, TypeScript, OpenAPI
sidebar: lb4_sidebar
editurl: https://github.com/loopbackio/loopback-next/tree/master/extensions/context-explorer
permalink: /doc/en/lb4/apidocs.context-explorer.contextgraph.html
---
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
[Home](./index.md) > [@loopback/context-explorer](./context-explorer.md) > [ContextGraph](./context-explorer.contextgraph.md)
## ContextGraph class
A graph for context hierarchy
**Signature:**
```typescript
export declare class ContextGraph
```
## Constructors
<table><thead><tr><th>
Constructor
</th><th>
Modifiers
</th><th>
Description
</th></tr></thead>
<tbody><tr><td markdown="1">
[(constructor)(ctx, options)](./context-explorer.contextgraph._constructor_.md)
</td><td markdown="1">
</td><td markdown="1">
Constructs a new instance of the `ContextGraph` class
</td></tr>
</tbody></table>
## Methods
<table><thead><tr><th>
Method
</th><th>
Modifiers
</th><th>
Description
</th></tr></thead>
<tbody><tr><td markdown="1">
[build()](./context-explorer.contextgraph.build.md)
</td><td markdown="1">
</td><td markdown="1">
Build a direct graph
</td></tr>
<tr><td markdown="1">
[render()](./context-explorer.contextgraph.render.md)
</td><td markdown="1">
</td><td markdown="1">
Render the context graph in graphviz dot format
</td></tr>
<tr><td markdown="1">
[renderBinding(parent, { binding, id }, input)](./context-explorer.contextgraph.renderbinding.md)
</td><td markdown="1">
`protected`
</td><td markdown="1">
Render a binding object
</td></tr>
<tr><td markdown="1">
[renderConfig(parent, { binding, level, id }, input)](./context-explorer.contextgraph.renderconfig.md)
</td><td markdown="1">
`protected`
</td><td markdown="1">
Create an edge for a binding to its configuration
</td></tr>
</tbody></table>