Skip to content

Commit 99ad2ee

Browse files
committed
docs: updated API reference
1 parent 0be48f1 commit 99ad2ee

21 files changed

+632
-620
lines changed

docs/api-reference/core/Class.mdx

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import {HorizontalDivider} from '/snippets/HorizontalDivider.mdx';
1111
import {GithubLinkNote} from '/snippets/GithubLinkNote.mdx';
1212
import {Attribute} from '/snippets/Attribute.mdx';
1313

14-
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L53-L417" />
14+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L55-L419" />
1515

1616
### Inherits from
1717
[HasBlock](/api-reference/core/HasBlock), [Callable](/api-reference/core/Callable), [Expression](/api-reference/core/Expression), [Usable](/api-reference/core/Usable), [Symbol](/api-reference/core/Symbol), [Editable](/api-reference/core/Editable), [Importable](/api-reference/core/Importable), [HasName](/api-reference/core/HasName)
@@ -147,7 +147,7 @@ import {Attribute} from '/snippets/Attribute.mdx';
147147
<HorizontalDivider />
148148
### <span className="text-primary">add_attribute</span>
149149
Adds an attribute to a class from another class.
150-
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L358-L381" />
150+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L360-L383" />
151151

152152
<ParameterWrapper>
153153
<Parameter
@@ -170,7 +170,7 @@ Adds an attribute to a class from another class.
170170

171171
### <span className="text-primary">add_attribute_from_source</span>
172172
Adds an attribute to a class from raw source code, placing it in a specific location
173-
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L332-L355" />
173+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L334-L357" />
174174

175175
<ParameterWrapper>
176176
<Parameter
@@ -244,7 +244,7 @@ Insert a keyword in the appropriate place before this symbol if it doesn't alrea
244244

245245
### <span className="text-primary">add_source</span>
246246
Add a block of source code to the bottom of a class definition.
247-
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L318-L329" />
247+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L320-L331" />
248248

249249
<ParameterWrapper>
250250
<Parameter
@@ -269,7 +269,7 @@ Find all ancestors of the node of the given type. Does not return itself
269269

270270
### <span className="text-primary">attributes</span>
271271
Retrieves all attributes from this Class including those from its superclasses up to a
272-
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L272-L291" />
272+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L274-L293" />
273273

274274
<ParameterWrapper>
275275
<Parameter
@@ -404,7 +404,7 @@ Adds a visual flag comment to the end of this Editable's source text.
404404

405405
### <span className="text-primary">get_attribute</span>
406406
Returns a specific attribute by name.
407-
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L294-L311" />
407+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L296-L313" />
408408

409409
<ParameterWrapper>
410410
<Parameter
@@ -421,7 +421,7 @@ Returns a specific attribute by name.
421421

422422
### <span className="text-primary">get_method</span>
423423
Returns a specific method by name from the class or any of its superclasses.
424-
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L251-L268" />
424+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L253-L270" />
425425

426426
<ParameterWrapper>
427427
<Parameter
@@ -446,7 +446,7 @@ Returns the name node of the object.
446446

447447
### <span className="text-primary">get_nested_class</span>
448448
Returns a nested class by name from the current class.
449-
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L234-L248" />
449+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L236-L250" />
450450

451451
<ParameterWrapper>
452452
<Parameter
@@ -514,7 +514,7 @@ Retrieves a parameter from the callable by its type.
514514

515515
### <span className="text-primary">get_parent_class</span>
516516
Returns the parent class node with the specified name.
517-
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L111-L123" />
517+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L113-L125" />
518518

519519
<ParameterWrapper>
520520
<Parameter
@@ -642,7 +642,7 @@ Inserts text before the current symbol node in the Abstract Syntax Tree.
642642

643643
### <span className="text-primary">is_subclass_of</span>
644644
Checks if the class inherits from a specified parent class.
645-
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L138-L152" />
645+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L140-L154" />
646646

647647
<ParameterWrapper>
648648
<Parameter
@@ -673,7 +673,7 @@ Check if this node is contained another node of the given class
673673

674674
### <span className="text-primary">methods</span>
675675
Retrieves all methods that exist on this Class, including methods from superclasses, with
676-
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L203-L231" />
676+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L205-L233" />
677677

678678
<ParameterWrapper>
679679
<Parameter
@@ -937,7 +937,7 @@ Sets the name of a code element.
937937

938938
### <span className="text-primary">subclasses</span>
939939
Returns all classes which subclass this class.
940-
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L156-L167" />
940+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L158-L169" />
941941

942942
<ParameterWrapper>
943943
<Parameter
@@ -954,7 +954,7 @@ Returns all classes which subclass this class.
954954

955955
### <span className="text-primary">superclasses</span>
956956
Returns a list of all classes that this class extends, up to max_depth.
957-
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L77-L93" />
957+
<GithubLinkNote link="https://github.com/codegen-sh/codegen-sdk/blob/develop/src/codegen/sdk/core/class_definition.py#L79-L95" />
958958

959959
<ParameterWrapper>
960960
<Parameter

0 commit comments

Comments
 (0)