예제 #1
0
 def __init__(self):
     '''
     Just call superclass constructors here and get a member logger.
     '''
     ACSComponent.__init__(self)
     ContainerServices.__init__(self)
     self.logger = self.getLogger()
예제 #2
0
 def __init__(self):
     '''
     Just call superclass constructors here and get a member logger.
     '''
     ACSComponent.__init__(self)
     ContainerServices.__init__(self)
     self.logger = self.getLogger()
예제 #3
0
 def __init__(self):
     '''
     Just call superclass constructors here.
     '''
     ACSComponent.__init__(self)
     ContainerServices.__init__(self)
     return
예제 #4
0
 def __init__(self):
     '''
     Just call superclass constructors here.
     '''
     CharacteristicComponent.__init__(self)
     ContainerServices.__init__(self)
     self.timestampIO = timestampDevIO()
     return
예제 #5
0
    def __init__(self):
        """
        Call superclass constructors and define private variables
        """

        CharacteristicComponent.__init__(self)

        ContainerServices.__init__(self)
예제 #6
0
 def __init__(self):
     '''
     Just call superclass constructors here.
     '''
     CharacteristicComponent.__init__(self)
     ContainerServices.__init__(self)
     self.timestampIO = timestampDevIO()
     return
예제 #7
0
    def __init__(self):
        '''
        Just call superclass constructors here.
        '''
        ACSComponent.__init__(self)
        ContainerServices.__init__(self)

        self.LOGGER = getLogger("CounterSupplier")
        #LOGGER.logInfo('Passed through __init__')
        return
예제 #8
0
    def __init__(self):
        '''
        Just call superclass constructors here.
        '''
        ACSComponent.__init__(self)
        ContainerServices.__init__(self)

        self.LOGGER = getLogger("CounterSupplier")
        #LOGGER.logInfo('Passed through __init__')
        return
예제 #9
0
 def __init__(self,ir=None):
     '''
     Just call superclass constructors here.
     '''
     if ir != None:
         CharacteristicComponent.__init__(self)
         ContainerServices.__init__(self)
         self.ir = ir
         BaseSimulator.__init__(self,ir)
     return
예제 #10
0
 def __init__(self):
     '''
     Just call superclass constructors here and declare members.
     '''
     ACSComponent.__init__(self)
     ContainerServices.__init__(self)
     
     self.brightness = None
     self.cb = None
     self.monitor = None
     return
예제 #11
0
    def __init__(self, name="Python Client"):
        '''
        Initialize the client.

        Parameters:
        - name is what manager will refer to this client instance as
        - runAsSingleton True if the client is a singleton

        Returns: Nothing

        Raises: CORBAProblemExImpl
        '''
        loginName = "UNKNOWN_USER"
        try:
            loginName = pwd.getpwuid(os.getuid())[0]
        except:
            print_exc()
            print "Error getting the user name!"
            
        hostName = "UNKNOWN_HOST"
        try:
            hostName = socket.gethostname().split('.')[0]
        except:
            print_exc()
            print "Error getting the host name!"
        #just to be sure
        name = name + " initialized by " + loginName + "@" + hostName
        name = str(name)
        
        BaseClient.__init__(self, name)
        if _DEBUG: # pragma: NO COVER
            print "Got past BaseClient in SimpleClient"

        #call superclass constructors
        ContainerServices.__init__(self)
        if _DEBUG: # pragma: NO COVER
            print "Got past ContainerServices in SimpleClient"
            
        #set some things to make ContainerServices happy
        self.setAll(self.name,
                    self.token,
                    self.token.h,
                    self.__activateOffShoot)
        if _DEBUG: # pragma: NO COVER
            print "Got past Constructor in SimpleClient"
            
        # Ensure that disconnect is called when python exit
        register(self.disconnect)
        
        global _instance
        
        #If there is no singleton yet; create one
        if _instance == None:
            _instance = self
예제 #12
0
    def __init__(self):
        '''
        Just call superclass constructors here.
        '''
        CharacteristicComponent.__init__(self)
        ContainerServices.__init__(self)

        self.count = 0
        self.size = 0
        self.waitTime = 0L
        return
예제 #13
0
    def __init__(self, name="Python Client"):
        '''
        Initialize the client.

        Parameters:
        - name is what manager will refer to this client instance as
        - runAsSingleton True if the client is a singleton

        Returns: Nothing

        Raises: CORBAProblemExImpl
        '''
        loginName = "UNKNOWN_USER"
        try:
            loginName = pwd.getpwuid(os.getuid())[0]
        except:
            print_exc()
            print "Error getting the user name!"
            
        hostName = "UNKNOWN_HOST"
        try:
            hostName = socket.gethostname()
        except:
            print_exc()
            print "Error getting the host name!"
        #just to be sure
        name = name + ": initialized by " + loginName + "@" + hostName
        name = str(name)
        
        BaseClient.__init__(self, name)
        if _DEBUG: # pragma: NO COVER
            print "Got past BaseClient in SimpleClient"

        #call superclass constructors
        ContainerServices.__init__(self)
        if _DEBUG: # pragma: NO COVER
            print "Got past ContainerServices in SimpleClient"
            
        #set some things to make ContainerServices happy
        self.setAll(self.name,
                    self.token,
                    self.token.h,
                    self.__activateOffShoot)
        if _DEBUG: # pragma: NO COVER
            print "Got past Constructor in SimpleClient"
            
        # Ensure that disconnect is called when python exit
        register(self.disconnect)
        
        global _instance
        
        #If there is no singleton yet; create one
        if _instance == None:
            _instance = self
예제 #14
0
    def __init__(self):
        '''
        Just call superclass constructors here.
        '''
        ACSComponent.__init__(self)
        ContainerServices.__init__(self)

        self.eventCount = 0
        self.contFlag = True
        self.LOGGER = getLogger("CounterConsumer")

        return
예제 #15
0
    def __init__(self):
        '''
        Just call superclass constructors here.
        '''
        ACSComponent.__init__(self)
        ContainerServices.__init__(self)

        self.eventCount = 0
        self.contFlag = True
        self.LOGGER = getLogger("CounterConsumer")

        return
예제 #16
0
파일: SimServer.py 프로젝트: jjpopski/ACS
    def __init__(self):
        """Constructor.
        """
        ACSComponent.__init__(self)
        ContainerServices.__init__(self)

        self.logger = self.getLogger()

        # Stores method information for all components
        # self.methods is indexed by component name
        # self.methods[comp_name] is a map indexed by method name
        # self.methods[comp_name][method_name] is an instance of MethodInfo
        self.methods = {}

        # Stores method information for all interfaces
        # self.methods is indexed by interface ('IDL:bla/bla/bla:1.0') name
        # self.methods[if_name] is a map indexed by method name
        # self.methods[if_name][method_name] is an instance of MethodInfo
        self.if_methods = {}
예제 #17
0
    def __init__(self):
        '''Constructor.
        '''
        ACSComponent.__init__(self)
        ContainerServices.__init__(self)

        self.logger = self.getLogger()

        # Stores method information for all components
        # self.methods is indexed by component name
        # self.methods[comp_name] is a map indexed by method name
        # self.methods[comp_name][method_name] is an instance of MethodInfo
        self.methods = {}

        # Stores method information for all interfaces
        # self.methods is indexed by interface ('IDL:bla/bla/bla:1.0') name
        # self.methods[if_name] is a map indexed by method name
        # self.methods[if_name][method_name] is an instance of MethodInfo
        self.if_methods = {}
예제 #18
0
    def __init__(self, name="Python Client"):
        '''
        Initialize the client.

        Parameters:
        - name is what manager will refer to this client instance as

        Returns: Nothing

        Raises: CORBAProblemExImpl
        '''
        global _myInstanceCount
        #increment our own reference counter
        _myInstanceCount = _myInstanceCount + 1
        
        #just to be sure
        try:
            name = name + ": " + os.getlogin() + " at " + socket.gethostname()
        except:
            name = name
        name = str(name)
        
        #call superclass constructors
        ContainerServices.__init__(self)
        if _DEBUG: # pragma: NO COVER
            print "Got past ContainerServices in SimpleClient"
        BaseClient.__init__(self, name)
        if _DEBUG: # pragma: NO COVER
            print "Got past BaseClient in SimpleClient"

        #set some things to make ContainerServices happy
        self.setAll(self.name,
                    self.token,
                    self.token.h,
                    self.__activateOffShoot)
        if _DEBUG: # pragma: NO COVER
            print "Got past Constructor in SimpleClient"
        register(self.disconnect)
예제 #19
0
 def __init__(self):
     ACSComponent.__init__(self)
     ComponentLifecycle.__init__(self)
     ContainerServices.__init__(self)
예제 #20
0
파일: PyTest.py 프로젝트: ACS-Community/ACS
 def __init__(self):
     ACSComponent.__init__(self)
     ContainerServices.__init__(self)
     return
예제 #21
0
# MA 02111-1307  USA
#
# @(#) $Id: acspyTestContainerServices.py,v 1.7 2006/04/06 21:44:58 dfugate Exp $
###############################################################################
'''
Tests the Container Services.
'''
from Acspy.Servants.ContainerServices import ContainerServices


###############################################################################
def dummie():
    pass


if __name__ == "__main__":
    g = ContainerServices()
    print g.__dict__
    print

    g.setAll(
        "blar",  #string-name of component
        None,  #handle...
        None,  #handle
        dummie  #Container's method
    )
    print g.__dict__
    print
    print "Thread: ", g.getThread(dummie, "dummie thread")
    print "Done..."
#
# You should have received a copy of the GNU Lesser General Public
# License along with this library; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, 
# MA 02111-1307  USA
#
# @(#) $Id: acspyTestContainerServices.py,v 1.7 2006/04/06 21:44:58 dfugate Exp $
###############################################################################
'''
Tests the Container Services.
'''
from Acspy.Servants.ContainerServices import ContainerServices
###############################################################################
def dummie():
    pass

if __name__=="__main__":
    g = ContainerServices()
    print g.__dict__
    print
    
    g.setAll("blar",  #string-name of component
             None,  #handle...
             None,  #handle
             dummie  #Container's method
             )
    print g.__dict__
    print
    print "Thread: ", g.getThread(dummie, "dummie thread")
    print "Done..."
예제 #23
0
 def __init__(self):
     cc.__init__(self)
     services.__init__(self)
예제 #24
0
	def __init__(self):
		ACSComponent.__init__(self)
		ComponentLifecycle.__init__(self)
		ContainerServices.__init__(self)
예제 #25
0
 def __init__(self, *args, **kw):
     ACSComponent.__init__(self)
     ContainerServices.__init__(self, *args, **kw)
     self._a_number = 0
예제 #26
0
 def __init__(self):
     cc.__init__(self)
     services.__init__(self)
     self.position = 0
     self.sequence = (1.1, 2.2, 3.3)
예제 #27
0
 def __init__(self):
     ACSComponent.__init__(self)
     ContainerServices.__init__(self)
     return