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


Python ObjCGenerator.variable_name_prefix_for_domain方法代码示例

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


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

示例1: _generate_dealloc

# 需要导入模块: from objc_generator import ObjCGenerator [as 别名]
# 或者: from objc_generator.ObjCGenerator import variable_name_prefix_for_domain [as 别名]
 def _generate_dealloc(self, domains):
     lines = []
     lines.append('- (void)dealloc')
     lines.append('{')
     for domain in domains:
         if domain.commands and self._command_filter(domain):
             lines.append('    [_%sHandler release];' % ObjCGenerator.variable_name_prefix_for_domain(domain))
         if domain.events and self._event_filter(domain):
             lines.append('    [_%sEventDispatcher release];' % ObjCGenerator.variable_name_prefix_for_domain(domain))
     lines.append('    [super dealloc];')
     lines.append('}')
     return lines
开发者ID:Comcast,项目名称:WebKitForWayland,代码行数:14,代码来源:generate_objc_configuration_implementation.py

示例2: _generate_ivars

# 需要导入模块: from objc_generator import ObjCGenerator [as 别名]
# 或者: from objc_generator.ObjCGenerator import variable_name_prefix_for_domain [as 别名]
 def _generate_ivars(self, domains):
     lines = []
     for domain in domains:
         if domain.commands and self._command_filter(domain):
             objc_class_name = "%s%sDomainHandler" % (ObjCGenerator.OBJC_PREFIX, domain.domain_name)
             ivar_name = "_%sHandler" % ObjCGenerator.variable_name_prefix_for_domain(domain)
             lines.append("    id<%s> %s;" % (objc_class_name, ivar_name))
         if domain.events and self._event_filter(domain):
             objc_class_name = "%s%sDomainEventDispatcher" % (ObjCGenerator.OBJC_PREFIX, domain.domain_name)
             ivar_name = "_%sEventDispatcher" % ObjCGenerator.variable_name_prefix_for_domain(domain)
             lines.append("    %s *%s;" % (objc_class_name, ivar_name))
     return lines
开发者ID:rhythmkay,项目名称:webkit,代码行数:14,代码来源:generate_objc_configuration_implementation.py

示例3: _generate_ivars

# 需要导入模块: from objc_generator import ObjCGenerator [as 别名]
# 或者: from objc_generator.ObjCGenerator import variable_name_prefix_for_domain [as 别名]
 def _generate_ivars(self, domains):
     lines = []
     for domain in domains:
         if self.should_generate_commands_for_domain(domain):
             objc_class_name = '%s%sDomainHandler' % (self.objc_prefix(), domain.domain_name)
             ivar_name = '_%sHandler' % ObjCGenerator.variable_name_prefix_for_domain(domain)
             lines.append('    id<%s> %s;' % (objc_class_name, ivar_name))
         if self.should_generate_events_for_domain(domain):
             objc_class_name = '%s%sDomainEventDispatcher' % (self.objc_prefix(), domain.domain_name)
             ivar_name = '_%sEventDispatcher' % ObjCGenerator.variable_name_prefix_for_domain(domain)
             lines.append('    %s *%s;' % (objc_class_name, ivar_name))
     return lines
开发者ID:mjparme,项目名称:openjdk-jfx,代码行数:14,代码来源:generate_objc_configuration_implementation.py

示例4: _generate_event_dispatcher_getter_for_domain

# 需要导入模块: from objc_generator import ObjCGenerator [as 别名]
# 或者: from objc_generator.ObjCGenerator import variable_name_prefix_for_domain [as 别名]
 def _generate_event_dispatcher_getter_for_domain(self, domain):
     getter_args = {
         "objcPrefix": ObjCGenerator.OBJC_PREFIX,
         "domainName": domain.domain_name,
         "variableNamePrefix": ObjCGenerator.variable_name_prefix_for_domain(domain),
     }
     return Template(ObjCTemplates.ConfigurationGetterImplementation).substitute(None, **getter_args)
开发者ID:rhythmkay,项目名称:webkit,代码行数:9,代码来源:generate_objc_configuration_implementation.py

示例5: _generate_handler_setter_for_domain

# 需要导入模块: from objc_generator import ObjCGenerator [as 别名]
# 或者: from objc_generator.ObjCGenerator import variable_name_prefix_for_domain [as 别名]
 def _generate_handler_setter_for_domain(self, domain):
     setter_args = {
         "objcPrefix": ObjCGenerator.OBJC_PREFIX,
         "domainName": domain.domain_name,
         "variableNamePrefix": ObjCGenerator.variable_name_prefix_for_domain(domain),
     }
     return Template(ObjCTemplates.ConfigurationCommandPropertyImplementation).substitute(None, **setter_args)
开发者ID:rhythmkay,项目名称:webkit,代码行数:9,代码来源:generate_objc_configuration_implementation.py

示例6: _generate_event_dispatcher_getter_for_domain

# 需要导入模块: from objc_generator import ObjCGenerator [as 别名]
# 或者: from objc_generator.ObjCGenerator import variable_name_prefix_for_domain [as 别名]
 def _generate_event_dispatcher_getter_for_domain(self, domain):
     getter_args = {
         'objcPrefix': self.objc_prefix(),
         'domainName': domain.domain_name,
         'variableNamePrefix': ObjCGenerator.variable_name_prefix_for_domain(domain),
     }
     return Template(ObjCTemplates.ConfigurationGetterImplementation).substitute(None, **getter_args)
开发者ID:Comcast,项目名称:WebKitForWayland,代码行数:9,代码来源:generate_objc_configuration_implementation.py

示例7: _generate_handler_setter_for_domain

# 需要导入模块: from objc_generator import ObjCGenerator [as 别名]
# 或者: from objc_generator.ObjCGenerator import variable_name_prefix_for_domain [as 别名]
 def _generate_handler_setter_for_domain(self, domain):
     setter_args = {
         'objcPrefix': self.objc_prefix(),
         'domainName': domain.domain_name,
         'variableNamePrefix': ObjCGenerator.variable_name_prefix_for_domain(domain),
     }
     return Template(ObjCTemplates.ConfigurationCommandPropertyImplementation).substitute(None, **setter_args)
开发者ID:Comcast,项目名称:WebKitForWayland,代码行数:9,代码来源:generate_objc_configuration_implementation.py

示例8: _generate_properties_for_domain

# 需要导入模块: from objc_generator import ObjCGenerator [as 别名]
# 或者: from objc_generator.ObjCGenerator import variable_name_prefix_for_domain [as 别名]
    def _generate_properties_for_domain(self, domain):
        property_args = {
            'objcPrefix': ObjCGenerator.OBJC_PREFIX,
            'domainName': domain.domain_name,
            'variableNamePrefix': ObjCGenerator.variable_name_prefix_for_domain(domain),
        }

        lines = []
        if domain.commands and self._command_filter(domain):
            lines.append(Template(ObjCTemplates.ConfigurationCommandProperty).substitute(None, **property_args))
        if domain.events and self._event_filter(domain):
            lines.append(Template(ObjCTemplates.ConfigurationEventProperty).substitute(None, **property_args))
        return lines
开发者ID:samcook88,项目名称:webkit,代码行数:15,代码来源:generate_objc_configuration_header.py

示例9: _generate_properties_for_domain

# 需要导入模块: from objc_generator import ObjCGenerator [as 别名]
# 或者: from objc_generator.ObjCGenerator import variable_name_prefix_for_domain [as 别名]
    def _generate_properties_for_domain(self, domain):
        property_args = {
            'objcPrefix': self.objc_prefix(),
            'domainName': domain.domain_name,
            'variableNamePrefix': ObjCGenerator.variable_name_prefix_for_domain(domain),
        }

        lines = []

        if self.should_generate_commands_for_domain(domain):
            lines.append(Template(ObjCTemplates.ConfigurationCommandProperty).substitute(None, **property_args))
        if self.should_generate_events_for_domain(domain):
            lines.append(Template(ObjCTemplates.ConfigurationEventProperty).substitute(None, **property_args))
        return lines
开发者ID:caiolima,项目名称:webkit,代码行数:16,代码来源:generate_objc_configuration_header.py


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