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


Python Observablefloat.__init__方法代码示例

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


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

示例1: __init__

# 需要导入模块: from marketsim.gen._out._observable import Observablefloat [as 别名]
# 或者: from marketsim.gen._out._observable.Observablefloat import __init__ [as 别名]
 def __init__(self, x = None):
     from marketsim.gen._out._observable import Observablefloat
     from marketsim.gen._out._constant import constant_Float as _constant_Float
     from marketsim import rtti
     Observablefloat.__init__(self)
     self.x = x if x is not None else _constant_Float(1.0)
     
     rtti.check_fields(self)
开发者ID:abensrhir,项目名称:marketsimulator,代码行数:10,代码来源:_Sqrt.py

示例2: __init__

# 需要导入模块: from marketsim.gen._out._observable import Observablefloat [as 别名]
# 或者: from marketsim.gen._out._observable.Observablefloat import __init__ [as 别名]
 def __init__(self, queue = None):
     from marketsim.gen._out._observable import Observablefloat
     from marketsim.gen._out.orderbook._asks import Asks_IOrderBook as _orderbook_Asks_IOrderBook
     from marketsim import rtti
     Observablefloat.__init__(self)
     self.queue = queue if queue is not None else _orderbook_Asks_IOrderBook()
     
     rtti.check_fields(self)
     _BestPrice_Impl.__init__(self)
开发者ID:abensrhir,项目名称:marketsimulator,代码行数:11,代码来源:_BestPrice.py

示例3: __init__

# 需要导入模块: from marketsim.gen._out._observable import Observablefloat [as 别名]
# 或者: from marketsim.gen._out._observable.Observablefloat import __init__ [as 别名]
 def __init__(self, trader = None):
     from marketsim.gen._out._observable import Observablefloat
     from marketsim.gen._out.trader._singleproxy import SingleProxy_ as _trader_SingleProxy_
     from marketsim import rtti
     Observablefloat.__init__(self)
     self.trader = trader if trader is not None else _trader_SingleProxy_()
     
     rtti.check_fields(self)
     Balance_Impl.__init__(self)
开发者ID:abensrhir,项目名称:marketsimulator,代码行数:11,代码来源:_Balance.py

示例4: __init__

# 需要导入模块: from marketsim.gen._out._observable import Observablefloat [as 别名]
# 或者: from marketsim.gen._out._observable.Observablefloat import __init__ [as 别名]
 def __init__(self, x = None):
     from marketsim.gen._out._observable import Observablefloat
     from marketsim.gen._out._const import const_Float as _const_Float
     from marketsim import event
     from marketsim import rtti
     Observablefloat.__init__(self)
     self.x = x if x is not None else _const_Float(1.0)
     event.subscribe(self.x, self.fire, self)
     rtti.check_fields(self)
     _Negate_Impl.__init__(self)
开发者ID:abensrhir,项目名称:marketsimulator,代码行数:12,代码来源:_Negate.py

示例5: __init__

# 需要导入模块: from marketsim.gen._out._observable import Observablefloat [as 别名]
# 或者: from marketsim.gen._out._observable.Observablefloat import __init__ [as 别名]
 def __init__(self, source = None):
     from marketsim.gen._out._observable import Observablefloat
     from marketsim.gen._out._const import const_Float as _const_Float
     from marketsim import event
     from marketsim import rtti
     Observablefloat.__init__(self)
     self.source = source if source is not None else _const_Float(1.0)
     event.subscribe(self.source, self.fire, self)
     rtti.check_fields(self)
     _BreaksAtChanges_Impl.__init__(self)
开发者ID:abensrhir,项目名称:marketsimulator,代码行数:12,代码来源:_BreaksAtChanges.py

示例6: __init__

# 需要导入模块: from marketsim.gen._out._observable import Observablefloat [as 别名]
# 或者: from marketsim.gen._out._observable.Observablefloat import __init__ [as 别名]
 def __init__(self, base = None, power = None):
     from marketsim.gen._out._observable import Observablefloat
     from marketsim.gen._out._constant import constant_Float as _constant_Float
     from marketsim import rtti
     Observablefloat.__init__(self)
     self.base = base if base is not None else _constant_Float(1.0)
     
     self.power = power if power is not None else _constant_Float(1.0)
     
     rtti.check_fields(self)
开发者ID:abensrhir,项目名称:marketsimulator,代码行数:12,代码来源:_Pow.py

示例7: __init__

# 需要导入模块: from marketsim.gen._out._observable import Observablefloat [as 别名]
# 或者: from marketsim.gen._out._observable.Observablefloat import __init__ [as 别名]
 def __init__(self, trader = None):
     from marketsim.gen._out.trader._singleproxy import SingleProxy_ as _trader_SingleProxy_
     from marketsim import _
     from marketsim import rtti
     from marketsim import event
     from marketsim.gen._out._observable import Observablefloat
     Observablefloat.__init__(self)
     self.trader = trader if trader is not None else _trader_SingleProxy_()
     rtti.check_fields(self)
     self.impl = self.getImpl()
     event.subscribe(self.impl, _(self).fire, self)
开发者ID:abensrhir,项目名称:marketsimulator,代码行数:13,代码来源:_RoughPnL.py

示例8: __init__

# 需要导入模块: from marketsim.gen._out._observable import Observablefloat [as 别名]
# 或者: from marketsim.gen._out._observable.Observablefloat import __init__ [as 别名]
 def __init__(self, x = None):
     from marketsim import _
     from marketsim import rtti
     from marketsim import event
     from marketsim.gen._out._observable import Observablefloat
     from marketsim.gen._out._test.in1.in2._intobs import IntObs_ as __test_in1_in2_IntObs_
     Observablefloat.__init__(self)
     self.x = x if x is not None else __test_in1_in2_IntObs_()
     rtti.check_fields(self)
     self.impl = self.getImpl()
     event.subscribe(self.impl, _(self).fire, self)
开发者ID:abensrhir,项目名称:marketsimulator,代码行数:13,代码来源:_o.py

示例9: __init__

# 需要导入模块: from marketsim.gen._out._observable import Observablefloat [as 别名]
# 或者: from marketsim.gen._out._observable.Observablefloat import __init__ [as 别名]
 def __init__(self, book = None):
     from marketsim import _
     from marketsim import rtti
     from marketsim.gen._out.orderbook._oftrader import OfTrader_IAccount as _orderbook_OfTrader_IAccount
     from marketsim import event
     from marketsim.gen._out._observable import Observablefloat
     Observablefloat.__init__(self)
     self.book = book if book is not None else _orderbook_OfTrader_IAccount()
     rtti.check_fields(self)
     self.impl = self.getImpl()
     event.subscribe(self.impl, _(self).fire, self)
开发者ID:abensrhir,项目名称:marketsimulator,代码行数:13,代码来源:_Price.py

示例10: __init__

# 需要导入模块: from marketsim.gen._out._observable import Observablefloat [as 别名]
# 或者: from marketsim.gen._out._observable.Observablefloat import __init__ [as 别名]
 def __init__(self, x = None, elsePart = None):
     from marketsim import _
     from marketsim import rtti
     from marketsim.gen._out._const import const_Float as _const_Float
     from marketsim import event
     from marketsim.gen._out._observable import Observablefloat
     Observablefloat.__init__(self)
     self.x = x if x is not None else _const_Float(1.0)
     self.elsePart = elsePart if elsePart is not None else _const_Float(1.0)
     rtti.check_fields(self)
     self.impl = self.getImpl()
     event.subscribe(self.impl, _(self).fire, self)
开发者ID:abensrhir,项目名称:marketsimulator,代码行数:14,代码来源:_IfDefined.py

示例11: __init__

# 需要导入模块: from marketsim.gen._out._observable import Observablefloat [as 别名]
# 或者: from marketsim.gen._out._observable.Observablefloat import __init__ [as 别名]
 def __init__(self, source = None, timeframe = None):
     from marketsim import _
     from marketsim import rtti
     from marketsim.gen._out._const import const_Float as _const_Float
     from marketsim import event
     from marketsim.gen._out._observable import Observablefloat
     Observablefloat.__init__(self)
     self.source = source if source is not None else _const_Float(1.0)
     self.timeframe = timeframe if timeframe is not None else 10.0
     rtti.check_fields(self)
     self.impl = self.getImpl()
     event.subscribe(self.impl, _(self).fire, self)
开发者ID:abensrhir,项目名称:marketsimulator,代码行数:14,代码来源:_DownMovements.py

示例12: __init__

# 需要导入模块: from marketsim.gen._out._observable import Observablefloat [as 别名]
# 或者: from marketsim.gen._out._observable.Observablefloat import __init__ [as 别名]
 def __init__(self, book = None, depth = None):
     from marketsim.gen._out._observable import Observablefloat
     from marketsim.gen._out.orderbook._oftrader import OfTrader_IAccount as _orderbook_OfTrader_IAccount
     from marketsim.gen._out._constant import constant_Float as _constant_Float
     from marketsim import rtti
     Observablefloat.__init__(self)
     self.book = book if book is not None else _orderbook_OfTrader_IAccount()
     
     self.depth = depth if depth is not None else _constant_Float(1.0)
     
     rtti.check_fields(self)
     CumulativePrice_Impl.__init__(self)
开发者ID:abensrhir,项目名称:marketsimulator,代码行数:14,代码来源:_CumulativePrice.py

示例13: __init__

# 需要导入模块: from marketsim.gen._out._observable import Observablefloat [as 别名]
# 或者: from marketsim.gen._out._observable.Observablefloat import __init__ [as 别名]
 def __init__(self, ticker = None, start = None, end = None):
     from marketsim.gen._out._observable import Observablefloat
     from marketsim import rtti
     Observablefloat.__init__(self)
     self.ticker = ticker if ticker is not None else "^GSPC"
     
     self.start = start if start is not None else "2001-1-1"
     
     self.end = end if end is not None else "2010-1-1"
     
     rtti.check_fields(self)
     Quote_Impl.__init__(self)
开发者ID:abensrhir,项目名称:marketsimulator,代码行数:14,代码来源:_Quote.py

示例14: __init__

# 需要导入模块: from marketsim.gen._out._observable import Observablefloat [as 别名]
# 或者: from marketsim.gen._out._observable.Observablefloat import __init__ [as 别名]
 def __init__(self, queue = None, defaultValue = None):
     from marketsim import _
     from marketsim import rtti
     from marketsim.gen._out._const import const_Float as _const_Float
     from marketsim import event
     from marketsim.gen._out._observable import Observablefloat
     from marketsim.gen._out.orderbook._asks import Asks_IOrderBook as _orderbook_Asks_IOrderBook
     Observablefloat.__init__(self)
     self.queue = queue if queue is not None else _orderbook_Asks_IOrderBook()
     self.defaultValue = defaultValue if defaultValue is not None else _const_Float(100.0)
     rtti.check_fields(self)
     self.impl = self.getImpl()
     event.subscribe(self.impl, _(self).fire, self)
开发者ID:abensrhir,项目名称:marketsimulator,代码行数:15,代码来源:_SafeSidePrice.py

示例15: __init__

# 需要导入模块: from marketsim.gen._out._observable import Observablefloat [as 别名]
# 或者: from marketsim.gen._out._observable.Observablefloat import __init__ [as 别名]
 def __init__(self, source = None, epsilon = None):
     from marketsim import rtti
     from marketsim.gen._out._constant import constant_Float as _constant_Float
     from marketsim.gen._out._const import const_Float as _const_Float
     from marketsim import event
     from marketsim.gen._out._observable import Observablefloat
     Observablefloat.__init__(self)
     self.source = source if source is not None else _const_Float(1.0)
     event.subscribe(self.source, self.fire, self)
     self.epsilon = epsilon if epsilon is not None else _constant_Float(0.01)
     
     rtti.check_fields(self)
     MaxEpsilon_Impl.__init__(self)
开发者ID:abensrhir,项目名称:marketsimulator,代码行数:15,代码来源:_MaxEpsilon.py


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