import abc
from abc import ABC, abstractmethod

# Connection Interface
class connection(ABC):
    @abc.abstractmethod
    def getData(self):
        pass

    @abc.abstractmethod
    def setData(self):
        pass

#DB Class
class DatabaseService(connection):

    @classmethod
    def getData(self):
        print("Getting Data From DB")

    @classmethod
    def setData(self):
        print("Setting Data From DB")

#API Class
class APIService(connection):

    @classmethod
    def getData(self):
        print("Getting Data From API")

    @classmethod
    def setData(self):
        print("Setting Data From API")


#Test
DB = DatabaseService()
DB.getData()
DB.setData()

API = APIService()
API.getData()
API.setData()


4ee8b52e71426cb9937118ae4052e2ac15124d47
<mask token>


class DatabaseService(connection):

    @classmethod
    def getData(self):
        print('Getting Data From DB')

    @classmethod
    def setData(self):
        print('Setting Data From DB')


class APIService(connection):

    @classmethod
    def getData(self):
        print('Getting Data From API')

    @classmethod
    def setData(self):
        print('Setting Data From API')


<mask token>

<mask token>


class connection(ABC):
    <mask token>
    <mask token>


class DatabaseService(connection):

    @classmethod
    def getData(self):
        print('Getting Data From DB')

    @classmethod
    def setData(self):
        print('Setting Data From DB')


class APIService(connection):

    @classmethod
    def getData(self):
        print('Getting Data From API')

    @classmethod
    def setData(self):
        print('Setting Data From API')


<mask token>

<mask token>


class connection(ABC):

    @abc.abstractmethod
    def getData(self):
        pass

    @abc.abstractmethod
    def setData(self):
        pass


class DatabaseService(connection):

    @classmethod
    def getData(self):
        print('Getting Data From DB')

    @classmethod
    def setData(self):
        print('Setting Data From DB')


class APIService(connection):

    @classmethod
    def getData(self):
        print('Getting Data From API')

    @classmethod
    def setData(self):
        print('Setting Data From API')


<mask token>
DB.getData()
DB.setData()
<mask token>
API.getData()
API.setData()

import abc
from abc import ABC, abstractmethod


class connection(ABC):

    @abc.abstractmethod
    def getData(self):
        pass

    @abc.abstractmethod
    def setData(self):
        pass


class DatabaseService(connection):

    @classmethod
    def getData(self):
        print('Getting Data From DB')

    @classmethod
    def setData(self):
        print('Setting Data From DB')


class APIService(connection):

    @classmethod
    def getData(self):
        print('Getting Data From API')

    @classmethod
    def setData(self):
        print('Setting Data From API')


DB = DatabaseService()
DB.getData()
DB.setData()
API = APIService()
API.getData()
API.setData()

import abc
from abc import ABC, abstractmethod

# Connection Interface
class connection(ABC):
    @abc.abstractmethod
    def getData(self):
        pass

    @abc.abstractmethod
    def setData(self):
        pass

#DB Class
class DatabaseService(connection):

    @classmethod
    def getData(self):
        print("Getting Data From DB")

    @classmethod
    def setData(self):
        print("Setting Data From DB")

#API Class
class APIService(connection):

    @classmethod
    def getData(self):
        print("Getting Data From API")

    @classmethod
    def setData(self):
        print("Setting Data From API")


#Test
DB = DatabaseService()
DB.getData()
DB.setData()

API = APIService()
API.getData()
API.setData()

