You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
calculate-utils-3-console-gui/api/gui/ClientClass.py

27 lines
809 B

#!/usr/bin/python
#-*- coding: utf-8 -*-
from calculate.lib.cl_datavars import DataVars
from calculate.api.cl_api import DataVarsApi
from Box import Example
class ApiClient:
def __init__(self):
# Initialization of system variables
Vars = DataVarsApi()
Vars.importApi()
Vars.flIniFile()
clVars = DataVars()
clVars.flIniFile()
# Initialization other variables
self.homePath = clVars.Get('ur_home_path')
path_to_cert = '~/.calculate/client_cert/'
self.path_to_cert = path_to_cert.replace("~",self.homePath)
self.WindowTitle = 'cl-api-client'
self.default_host = 'localhost'
self.default_port = '8888'
self.client = None
self.MainWidget = Example(self)