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


Python Request.__init__方法代码示例

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


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

示例1: __init__

# 需要导入模块: from supriya.tools.requesttools.Request import Request [as 别名]
# 或者: from supriya.tools.requesttools.Request.Request import __init__ [as 别名]
 def __init__(
     self,
     buffer_id=None,
     completion_message=None,
     file_path=None,
     frame_count=None,
     leave_open=None,
     starting_frame_in_buffer=None,
     starting_frame_in_file=None,
     ):
     Request.__init__(self)
     self._buffer_id = int(buffer_id)
     self._completion_message = self._coerce_completion_message_input(
         completion_message)
     self._file_path = str(file_path)
     if frame_count is not None:
         frame_count = int(frame_count)
         assert -1 <= frame_count
     self._frame_count = frame_count
     if leave_open is not None:
         leave_open = bool(leave_open)
     self._leave_open = leave_open
     if starting_frame_in_buffer is not None:
         starting_frame_in_buffer = int(starting_frame_in_buffer)
         assert 0 <= starting_frame_in_buffer
     self._starting_frame_in_buffer = starting_frame_in_buffer
     if starting_frame_in_file is not None:
         starting_frame_in_file = int(starting_frame_in_file)
         assert 0 <= starting_frame_in_file
     self._starting_frame_in_file = starting_frame_in_file
开发者ID:andrewyoung1991,项目名称:supriya,代码行数:32,代码来源:BufferReadRequest.py

示例2: __init__

# 需要导入模块: from supriya.tools.requesttools.Request import Request [as 别名]
# 或者: from supriya.tools.requesttools.Request.Request import __init__ [as 别名]
 def __init__(
     self,
     buffer_ids=None,
     ):
     Request.__init__(self)
     if buffer_ids:
         buffer_ids = tuple(int(buffer_id) for buffer_id in buffer_ids)
     self._buffer_ids = buffer_ids
开发者ID:digideskio,项目名称:supriya,代码行数:10,代码来源:BufferQueryRequest.py

示例3: __init__

# 需要导入模块: from supriya.tools.requesttools.Request import Request [as 别名]
# 或者: from supriya.tools.requesttools.Request.Request import __init__ [as 别名]
 def __init__(
     self,
     node_id=None,
     **kwargs
     ):
     Request.__init__(self)
     self._node_id = node_id
     self._kwargs = kwargs
开发者ID:digideskio,项目名称:supriya,代码行数:10,代码来源:NodeSetRequest.py

示例4: __init__

# 需要导入模块: from supriya.tools.requesttools.Request import Request [as 别名]
# 或者: from supriya.tools.requesttools.Request.Request import __init__ [as 别名]
 def __init__(
     self,
     completion_message=None,
     synthdef_path=None,
     ):
     Request.__init__(self)
     self._completion_message = completion_message
     self._synthdef_path = os.path.abspath(synthdef_path)
开发者ID:digideskio,项目名称:supriya,代码行数:10,代码来源:SynthDefLoadRequest.py

示例5: __init__

# 需要导入模块: from supriya.tools.requesttools.Request import Request [as 别名]
# 或者: from supriya.tools.requesttools.Request.Request import __init__ [as 别名]
 def __init__(
     self,
     include_controls=False,
     node_id=None,
     ):
     Request.__init__(self)
     self._node_id = node_id
     self._include_controls = bool(include_controls)
开发者ID:digideskio,项目名称:supriya,代码行数:10,代码来源:GroupQueryTreeRequest.py

示例6: __init__

# 需要导入模块: from supriya.tools.requesttools.Request import Request [as 别名]
# 或者: from supriya.tools.requesttools.Request.Request import __init__ [as 别名]
 def __init__(
     self,
     buffer_id=None,
     completion_message=None
     ):
     Request.__init__(self)
     self._buffer_id = int(buffer_id)
     self._completion_message = self._coerce_completion_message_input(
         completion_message)
开发者ID:andrewyoung1991,项目名称:supriya,代码行数:11,代码来源:BufferZeroRequest.py

示例7: __init__

# 需要导入模块: from supriya.tools.requesttools.Request import Request [as 别名]
# 或者: from supriya.tools.requesttools.Request.Request import __init__ [as 别名]
 def __init__(
     self,
     node_ids=None
     ):
     Request.__init__(self)
     if not isinstance(node_ids, collections.Sequence):
         node_ids = (node_ids,)
     node_ids = tuple(int(_) for _ in node_ids)
     self._node_ids = node_ids
开发者ID:digideskio,项目名称:supriya,代码行数:11,代码来源:NodeFreeRequest.py

示例8: __init__

# 需要导入模块: from supriya.tools.requesttools.Request import Request [as 别名]
# 或者: from supriya.tools.requesttools.Request.Request import __init__ [as 别名]
 def __init__(
     self,
     add_action=None,
     node_id=None,
     target_node_id=None,
     ):
     from supriya.tools import servertools
     Request.__init__(self)
     self._add_action = servertools.AddAction.from_expr(add_action)
     self._node_id = node_id
     self._target_node_id = target_node_id
开发者ID:digideskio,项目名称:supriya,代码行数:13,代码来源:GroupNewRequest.py

示例9: __init__

# 需要导入模块: from supriya.tools.requesttools.Request import Request [as 别名]
# 或者: from supriya.tools.requesttools.Request.Request import __init__ [as 别名]
 def __init__(
     self,
     node_id=None,
     **kwargs
     ):
     Request.__init__(self)
     self._node_id = node_id
     self._kwargs = dict(
         (name, int(value))
         for name, value in kwargs.items()
         )
开发者ID:andrewyoung1991,项目名称:supriya,代码行数:13,代码来源:NodeMapToControlBusRequest.py

示例10: __init__

# 需要导入模块: from supriya.tools.requesttools.Request import Request [as 别名]
# 或者: from supriya.tools.requesttools.Request.Request import __init__ [as 别名]
 def __init__(
     self,
     buffer_id=None,
     index_count_value_triples=None,
     ):
     Request.__init__(self)
     self._buffer_id = int(buffer_id)
     triples = []
     for index, count, value in index_count_value_triples:
         triple = (int(index), int(count), float(value))
         triples.append(triple)
     triples = tuple(triples)
     self._index_count_value_triples = triples
开发者ID:digideskio,项目名称:supriya,代码行数:15,代码来源:BufferFillRequest.py

示例11: __init__

# 需要导入模块: from supriya.tools.requesttools.Request import Request [as 别名]
# 或者: from supriya.tools.requesttools.Request.Request import __init__ [as 别名]
 def __init__(self, index_count_value_triples=None):
     Request.__init__(self)
     if index_count_value_triples:
         triples = []
         for index, count, value in index_count_value_triples:
             index = int(index)
             count = int(count)
             value = float(value)
             assert 0 <= index
             assert 0 < count
             triple = (index, count, value)
             triples.append(triple)
         index_count_value_triples = tuple(triples)
     self._index_count_value_triples = index_count_value_triples
开发者ID:andrewyoung1991,项目名称:supriya,代码行数:16,代码来源:ControlBusFillRequest.py

示例12: __init__

# 需要导入模块: from supriya.tools.requesttools.Request import Request [as 别名]
# 或者: from supriya.tools.requesttools.Request.Request import __init__ [as 别名]
 def __init__(self, index_values_pairs=None):
     Request.__init__(self)
     if index_values_pairs:
         pairs = []
         for index, values in index_values_pairs:
             index = int(index)
             values = tuple(float(value) for value in values)
             assert 0 <= index
             assert values
             if not values:
                 continue
             pair = (index, values)
             pairs.append(pair)
         index_values_pairs = tuple(pairs)
     self._index_values_pairs = index_values_pairs
开发者ID:andrewyoung1991,项目名称:supriya,代码行数:17,代码来源:ControlBusSetContiguousRequest.py

示例13: __init__

# 需要导入模块: from supriya.tools.requesttools.Request import Request [as 别名]
# 或者: from supriya.tools.requesttools.Request.Request import __init__ [as 别名]
 def __init__(
     self,
     completion_message=None,
     synthdefs=None,
     ):
     from supriya.tools import synthdeftools
     Request.__init__(self)
     self._completion_message = completion_message
     if synthdefs:
         prototype = synthdeftools.SynthDef
         if isinstance(synthdefs, prototype):
             synthdefs = (synthdefs,)
         assert all(isinstance(x, prototype) for x in synthdefs)
         synthdefs = tuple(synthdefs)
     self._synthdefs = synthdefs
开发者ID:digideskio,项目名称:supriya,代码行数:17,代码来源:SynthDefReceiveRequest.py

示例14: __init__

# 需要导入模块: from supriya.tools.requesttools.Request import Request [as 别名]
# 或者: from supriya.tools.requesttools.Request.Request import __init__ [as 别名]
 def __init__(
     self,
     index_value_pairs=None,
     ):
     Request.__init__(self)
     if index_value_pairs:
         pairs = []
         for index, value in index_value_pairs:
             index = int(index)
             value = float(value)
             assert 0 <= index
             pair = (index, value)
             pairs.append(pair)
         index_value_pairs = tuple(pairs)
     self._index_value_pairs = index_value_pairs
开发者ID:andrewyoung1991,项目名称:supriya,代码行数:17,代码来源:ControlBusSetRequest.py

示例15: __init__

# 需要导入模块: from supriya.tools.requesttools.Request import Request [as 别名]
# 或者: from supriya.tools.requesttools.Request.Request import __init__ [as 别名]
 def __init__(
     self,
     buffer_id=None,
     index_value_pairs=None,
     ):
     Request.__init__(self)
     self._buffer_id = int(buffer_id)
     if index_value_pairs:
         pairs = []
         for index, value in index_value_pairs:
             index = int(index)
             value = float(value)
             pair = (index, value)
             pairs.append(pair)
         pairs = tuple(pairs)
     self._index_value_pairs = index_value_pairs
开发者ID:digideskio,项目名称:supriya,代码行数:18,代码来源:BufferSetRequest.py


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