PyXMake Developer Guide 1.0
PyXMake
Loading...
Searching...
No Matches
PyXMake.API.Base Class Reference

Abstract base class for all API objects. More...

Inheritance diagram for PyXMake.API.Base:
PyXMake.API.Frontend

Public Member Functions

 __init__ (self, *args, **kwargs)
 
 RedirectException (self, url)
 
 StaticFiles (self, url, path, index="index.html", html=True)
 
 mount (self, *args)
 
 include (self, *args)
 
 create (self)
 
 run (self, Hostname=str(platform.node()), PortID=8020)
 

Public Attributes

 API = APIRouter();
 
str APIObjectKind = "Base"
 
 Router
 

Detailed Description

Abstract base class for all API objects.

Parent class for graphical user interface objects. 

Inherited from built-in ABCMeta & FastAPI. Only compatible with Python 3.6+

Constructor & Destructor Documentation

◆ __init__()

PyXMake.API.Base.__init__ ( self,
* args,
** kwargs )
Low-level initialization of parent class.

Reimplemented in PyXMake.API.Frontend.

Definition at line 85 of file __init__.py.

Member Function Documentation

◆ create()

PyXMake.API.Base.create ( self)
Return current API's main instance handle.

Definition at line 121 of file __init__.py.

◆ include()

PyXMake.API.Base.include ( self,
* args )
Return current API's main instance handle.

Definition at line 115 of file __init__.py.

◆ mount()

PyXMake.API.Base.mount ( self,
* args )
Return current API's main instance handle.

Definition at line 109 of file __init__.py.

◆ RedirectException()

PyXMake.API.Base.RedirectException ( self,
url )

Definition at line 93 of file __init__.py.

◆ run()

PyXMake.API.Base.run ( self,
Hostname = str(platform.node()),
PortID = 8020 )
Run the current API. 

Definition at line 130 of file __init__.py.

◆ StaticFiles()

PyXMake.API.Base.StaticFiles ( self,
url,
path,
index = "index.html",
html = True )
Serve additional static files. Mount them appropriately.

Definition at line 98 of file __init__.py.

Member Data Documentation

◆ API

PyXMake.API.Base.API = APIRouter();

Definition at line 90 of file __init__.py.

◆ APIObjectKind

str PyXMake.API.Base.APIObjectKind = "Base"

Definition at line 91 of file __init__.py.

◆ Router

PyXMake.API.Base.Router

Definition at line 126 of file __init__.py.


The documentation for this class was generated from the following file: