Пример #1
0
Файл: tbip.py Проект: esnet/enos
 def get_ipcontainer():
     """ This method returns the IP container used to store IP address in persistent storage"""
     container = Container.getContainer(IPManagement.IPCONTAINER) 
     if container is None:
         Container.createContainer(IPManagement.IPCONTAINER)
         container = Container.getContainer(IPManagement.IPCONTAINER)
     return container
Пример #2
0
 def get_ipcontainer():
     """ This method returns the IP container used to store IP address in persistent storage"""
     container = Container.getContainer(IPManagement.IPCONTAINER)
     if container is None:
         Container.createContainer(IPManagement.IPCONTAINER)
         container = Container.getContainer(IPManagement.IPCONTAINER)
     return container
Пример #3
0
def createtopo(topology):
    Container.createContainer(topology)
    container = Container.getContainer(topology)
    return container
Пример #4
0
def createtopo(topology):
    Container.createContainer(topology)
    container = Container.getContainer(topology)
    return container
Пример #5
0
def createdb(containerName):
    user = KernelThread.currentKernelThread().getUser()
    if not  BootStrap.getBootStrap().getDataBase().collectionExists(user.getName(),containerName):
        Container.createContainer(user.getName(),containerName)
    container = Container.getContainer(containerName)