当前位置: 首页>>代码示例>>Python>>正文


Python Action.__init__方法代码示例

本文整理汇总了Python中Action.Action.__init__方法的典型用法代码示例。如果您正苦于以下问题:Python Action.__init__方法的具体用法?Python Action.__init__怎么用?Python Action.__init__使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Action.Action的用法示例。


在下文中一共展示了Action.__init__方法的13个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: __init__

# 需要导入模块: from Action import Action [as 别名]
# 或者: from Action.Action import __init__ [as 别名]
	def __init__(self, nodeName, imageName, node, newText):
		Action.__init__(self, node.documentOwner)
		self.nodeName = nodeName
		self.imageName = imageName
		self.node = node
		self.newText = newText
		self.oldText = self.node.GetText()
开发者ID:nsmoooose,项目名称:csp,代码行数:9,代码来源:ModifyXmlAction.py

示例2: __init__

# 需要导入模块: from Action import Action [as 别名]
# 或者: from Action.Action import __init__ [as 别名]
    def __init__(self, **kwargs):
        Action.__init__(self, **kwargs)

        # Push Bullet settings -- set up in site.cfg, or override in local-site.cfg
        self.access_token = kwargs.get('access_token', "XXX")
        self.triggers = json.loads(kwargs.get('triggers',"[]"))
        print "Got Triggers: ",self.triggers
        self.start()
开发者ID:jbum,项目名称:carillon,代码行数:10,代码来源:PushBullet.py

示例3: __init__

# 需要导入模块: from Action import Action [as 别名]
# 或者: from Action.Action import __init__ [as 别名]
 def __init__ (self, command, *matchers):
     """
     Command: command to execute
     matchers: string(s) to match
     """
     self.matchers = []
     for m in matchers:
         self.matchers.append(m.lower())
     Action.__init__(self, command)
开发者ID:nosemeocurrenada,项目名称:StupidClip,代码行数:11,代码来源:StringAction.py

示例4: __init__

# 需要导入模块: from Action import Action [as 别名]
# 或者: from Action.Action import __init__ [as 别名]
    def __init__(self, target, lookAt = None):
        Action.__init__(self)
        self.command = commands.Attack
        self.target = target

        self.params['description'] = 'Attack'

        if lookAt is not None:
            self.params['lookAt'] = lookAt
开发者ID:etiennenoel,项目名称:ctf,代码行数:11,代码来源:ActionAttack.py

示例5: __init__

# 需要导入模块: from Action import Action [as 别名]
# 或者: from Action.Action import __init__ [as 别名]
    def __init__(self, **kwargs):
        Action.__init__(self, **kwargs)

        # settings for XBee radio connect -- set up in site.cfg, or override in local-site.cfg
        self.port = kwargs.get('port', "/dev/tty.usbmodem1431")
        self.baud = int(kwargs.get('baud', 9600))
        self.start_mute = int(kwargs.get('start_mute', 0)) # HHMM
        self.end_mute = int(kwargs.get('end_mute', 0)) # HHMM
        self.start()
        self.timezone = kwargs.get('timezone', 'America/Los_Angeles')
开发者ID:jbum,项目名称:carillon,代码行数:12,代码来源:Chime.py

示例6: __init__

# 需要导入模块: from Action import Action [as 别名]
# 或者: from Action.Action import __init__ [as 别名]
    def __init__(self, target):
        Action.__init__(self)

        #Command
        self.command = commands.Defend

        #Facing direction
        self.target = target

        #Parametres supplementaires
        self.params['description'] = 'Defend'
开发者ID:etiennenoel,项目名称:ctf,代码行数:13,代码来源:ActionDefend.py

示例7: __init__

# 需要导入模块: from Action import Action [as 别名]
# 或者: from Action.Action import __init__ [as 别名]
    def __init__(self, **kwargs):
        Action.__init__(self, **kwargs)

        # clock settings -- set up in site.cfg, or override in local-site.cfg
        self.ring_quarters = parse_bool(kwargs.get('ring_quarters', False))
        self.xmas_mode = parse_bool(kwargs.get('xmas_mode', False))
        self.timezone = kwargs.get('timezone', 'America/Los_Angeles')
        self.chimes = json.loads(kwargs.get('chimes',"{}"))
        self.xmas_hours =  json.loads(kwargs.get('xmas_hours',"[]"))
        print "Got chimes", self.chimes
        print "Got xmas_hours", self.xmas_hours

        self.start()
开发者ID:jbum,项目名称:carillon,代码行数:15,代码来源:Clock.py

示例8: __init__

# 需要导入模块: from Action import Action [as 别名]
# 或者: from Action.Action import __init__ [as 别名]
    def __init__(self, **kwargs):
        Action.__init__(self, **kwargs)

        self.songs = json.loads(kwargs.get('songs',"{}"))
        print "Got Songs", self.songs
        self.start()
开发者ID:jbum,项目名称:carillon,代码行数:8,代码来源:Transcribe.py

示例9: __init__

# 需要导入模块: from Action import Action [as 别名]
# 或者: from Action.Action import __init__ [as 别名]
 def __init__(self, target):
     Action.__init__(self)
     self.command = commands.Charge
     self.target = target
     self.params['description'] = 'Charge'
开发者ID:etiennenoel,项目名称:ctf,代码行数:7,代码来源:ActionCharge.py

示例10: __init__

# 需要导入模块: from Action import Action [as 别名]
# 或者: from Action.Action import __init__ [as 别名]
 def __init__(self, command):
     Action.__init__(self,command)
     self.name = "RegexAction" + str(self.uid)
开发者ID:nosemeocurrenada,项目名称:StupidClip,代码行数:5,代码来源:RegexAction.py

示例11: __init__

# 需要导入模块: from Action import Action [as 别名]
# 或者: from Action.Action import __init__ [as 别名]
 def __init__(self, actor, sentry, label = '', routine = None,
              arguments = {}, **kwds ):
     Action.__init__(self, actor, label, routine, arguments, **kwds )
     self.sentry = sentry
     return
开发者ID:danse-inelastic,项目名称:inelastic-svn,代码行数:7,代码来源:ActionRequireAuthentication.py

示例12: __init__

# 需要导入模块: from Action import Action [as 别名]
# 或者: from Action.Action import __init__ [as 别名]
 def __init__( self, mgr, duration ):
     Action.__init__( self )
     self.__mgr = mgr
     self.__duration = duration
开发者ID:jacquev6,项目名称:ViDE,代码行数:6,代码来源:test_Action.py

示例13: __init__

# 需要导入模块: from Action import Action [as 别名]
# 或者: from Action.Action import __init__ [as 别名]
	def __init__(self, mem):
		Action.__init__(self)
		self.target = WorldState()
		self.parentId = None
		self.m = mem
开发者ID:kumar54,项目名称:Dev-PSchema,代码行数:7,代码来源:TargetAction.py


注:本文中的Action.Action.__init__方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。