documentation python classes updated.

This commit is contained in:
Bram Barbieri
2024-04-03 11:35:42 +02:00
parent 355a2b4f75
commit a92b6b58d6
2 changed files with 26 additions and 4 deletions

View File

@@ -36,8 +36,9 @@ At the start of every class the "__init__" function is called.
For further information visit https://www.w3schools.com/python/gloss_python_class_init.asp)
The parent node is able to be further evolved, but for now is able do always provide the node ID to all child-classes.
and a variable with the MAC-addresses.
```py
# A general class which acts as a database connector and a node identifyer
# A general class which acts as a database connector and a node identifier
class Node():
def __init__(self, macAdress):
@@ -48,7 +49,7 @@ The function below uses the infromation from the database to find the correspond
It searches inside of the database and finds a match with the given MAC-address.
It frist makes a connection with the database by calling the previous function, then it executes the given querry, and searches for the node ID corresponding with the inserted MAC-address.
It first makes a connection with the database by calling the previous function, then it executes the given querry, and searches for the node ID corresponding with the inserted MAC-address.
After this search, it inserts that given id into the ID variable.
```py