Package ru.bitel.bgbilling.modules.tv.server.runtime

# Class TvApplication

java.lang.Object
ru.bitel.bgbilling.modules.tv.server.runtime.TvApplication

All Implemented Interfaces:
  `ru.bitel.bgbilling.kernel.application.server.CommandListener`, `ru.bitel.bgbilling.kernel.application.server.Lifecycle`, `ru.bitel.common.worker.ThreadContextFactory<ru.bitel.bgbilling.kernel.container.managed.ServerContext>`

public abstract class TvApplication extends Object implements ru.bitel.bgbilling.kernel.application.server.CommandListener, ru.bitel.common.worker.ThreadContextFactory<ru.bitel.bgbilling.kernel.container.managed.ServerContext>, ru.bitel.bgbilling.kernel.application.server.Lifecycle

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `final int`
  `applicationId`
  `static final int`
  `CHECK_TARIFF_PRICE_DISABLE`
  `static final int`
  `CHECK_TARIFF_PRICE_ENABLE`
  `static final int`
  `CHECK_TARIFF_PRICE_ENABLE_WITHOUT_TIME`
  `static final int`
  `CHECK_TARIFF_PRICE_STRICT`
  `static final int`
  `CHECK_TARIFF_PRICE_STRICT_WITHOUT_TIME`
  `final int`
  `checkTariffPrice`
  Нужно ли выдавать ошибку, если цена не найдена
  `Set<Integer>`
  `childrenDeviceIds`
  Все устройства-дети
  `final ru.bitel.bgbilling.kernel.contract.runtime.ContractRuntimeMap`
  `contractRuntimeMap`
  `final ru.bitel.bgbilling.kernel.contract.balance.server.ConvergenceBalanceManager`
  `convergenceBalanceManager`
  `protected final Date`
  `dateFrom`
  `final TvDeviceRuntimeMap`
  `deviceMap`
  Мап устройств
  `static final int`
  `EMPTY_ROOT_DEVICE_ID`
  `final Date`
  `initialDate`
  `final int`
  `moduleId`
  `ProductSpecRuntimeMap`
  `productSpecRuntimeMap`
  `final boolean`
  `realtime`
  `final int`
  `rootDeviceId`
  `protected final ScheduledExecutorService`
  `scheduledExecutorService`
  `ServiceSpecRuntimeMap`
  `serviceSpecRuntimeMap`
  `final Setup`
  `setup`
  `final TvAccountRuntimeMap`
  `tvAccountRuntimeMap`
  `TvAccountSpecRuntimeMap`
  `tvAccountSpecRuntimeMap`
  Динамически обновляемый справочник типов сервисов
  `final ru.bitel.bgbilling.modules.tv.server.tariff.TvTariffContext`
  `tvTariffContext`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `TvApplication(boolean realtime, Setup setup, int applicationId, int moduleId, boolean loadSaScripts)`
  `TvApplication(boolean realtime, Setup setup, int applicationId, int moduleId, boolean loadSaScripts, int rootDeviceId, Date dateFrom)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `AuthResult`
  `authorization(ConnectionSet connectionSet, TvAccountRuntime tvAccountRuntime, Date now, BigDecimal accountDelta)`
  `String`
  `executeCommand(String cmd, String param)`
  `String`
  `getCommandsHelp()`
  `ru.bitel.bgbilling.kernel.contract.runtime.ContractRuntimeMap`
  `getContractRuntimeMap()`
  `ProductSpecRuntimeMap`
  `getProductSpecRuntimeMap()`
  `TvAccountRuntimeMap`
  `getTvAccountRuntimeMap()`
  `TvAccountSpecRuntimeMap`
  `getTvAccountSpecRuntimeMap()`
  `TvDeviceRuntimeMap`
  `getTvDeviceRuntimeMap()`
  `void`
  `load()`
  `ru.bitel.bgbilling.kernel.container.managed.ServerContext`
  `newThreadContext()`
  `void`
  `start()`
  `void`
  `stop()`
  `Set<Integer>`
  `tvAccountOptionSet(ConnectionSet connectionSet, TvAccountRuntime tvAccountRuntime, Date now)`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Field Details

  - ### scheduledExecutorService

    protected final ScheduledExecutorService scheduledExecutorService

  - ### realtime

    public final boolean realtime

  - ### initialDate

    public final Date initialDate

  - ### setup

    public final Setup setup

  - ### applicationId

    public final int applicationId

  - ### moduleId

    public final int moduleId

  - ### rootDeviceId

    public final int rootDeviceId

  - ### tvTariffContext

    public final ru.bitel.bgbilling.modules.tv.server.tariff.TvTariffContext tvTariffContext

  - ### contractRuntimeMap

    public final ru.bitel.bgbilling.kernel.contract.runtime.ContractRuntimeMap contractRuntimeMap

  - ### tvAccountRuntimeMap

    public final TvAccountRuntimeMap tvAccountRuntimeMap

  - ### tvAccountSpecRuntimeMap

    public TvAccountSpecRuntimeMap tvAccountSpecRuntimeMap
    Динамически обновляемый справочник типов сервисов

  - ### serviceSpecRuntimeMap

    public ServiceSpecRuntimeMap serviceSpecRuntimeMap

  - ### productSpecRuntimeMap

    public ProductSpecRuntimeMap productSpecRuntimeMap

  - ### childrenDeviceIds

    public volatile Set<Integer> childrenDeviceIds
    Все устройства-дети

  - ### deviceMap

    public final TvDeviceRuntimeMap deviceMap
    Мап устройств

  - ### convergenceBalanceManager

    public final ru.bitel.bgbilling.kernel.contract.balance.server.ConvergenceBalanceManager convergenceBalanceManager

  - ### EMPTY_ROOT_DEVICE_ID

    public static final int EMPTY_ROOT_DEVICE_ID
    See Also:
      - Constant Field Values

  - ### dateFrom

    protected final Date dateFrom

  - ### CHECK_TARIFF_PRICE_DISABLE

    public static final int CHECK_TARIFF_PRICE_DISABLE
    See Also:
      - Constant Field Values

  - ### CHECK_TARIFF_PRICE_ENABLE

    public static final int CHECK_TARIFF_PRICE_ENABLE
    See Also:
      - Constant Field Values

  - ### CHECK_TARIFF_PRICE_STRICT

    public static final int CHECK_TARIFF_PRICE_STRICT
    See Also:
      - Constant Field Values

  - ### CHECK_TARIFF_PRICE_ENABLE_WITHOUT_TIME

    public static final int CHECK_TARIFF_PRICE_ENABLE_WITHOUT_TIME
    See Also:
      - Constant Field Values

  - ### CHECK_TARIFF_PRICE_STRICT_WITHOUT_TIME

    public static final int CHECK_TARIFF_PRICE_STRICT_WITHOUT_TIME
    See Also:
      - Constant Field Values

  - ### checkTariffPrice

    public final int checkTariffPrice
    Нужно ли выдавать ошибку, если цена не найдена

- ## Constructor Details

  - ### TvApplication

    public TvApplication(boolean realtime, Setup setup, int applicationId, int moduleId, boolean loadSaScripts) throws Exception
    Throws:
      `Exception`

  - ### TvApplication

    public TvApplication(boolean realtime, Setup setup, int applicationId, int moduleId, boolean loadSaScripts, int rootDeviceId, Date dateFrom) throws Exception
    Throws:
      `Exception`

- ## Method Details

  - ### start

    public void start() throws Exception
    Specified by:
      `start` in interface `ru.bitel.bgbilling.kernel.application.server.Lifecycle`
    Throws:
      `Exception`

  - ### load

    public void load()

  - ### stop

    public void stop() throws Exception
    Specified by:
      `stop` in interface `ru.bitel.bgbilling.kernel.application.server.Lifecycle`
    Throws:
      `Exception`

  - ### newThreadContext

    public ru.bitel.bgbilling.kernel.container.managed.ServerContext newThreadContext()
    Specified by:
      `newThreadContext` in interface `ru.bitel.common.worker.ThreadContextFactory<ru.bitel.bgbilling.kernel.container.managed.ServerContext>`

  - ### getCommandsHelp

    public String getCommandsHelp()
    Specified by:
      `getCommandsHelp` in interface `ru.bitel.bgbilling.kernel.application.server.CommandListener`

  - ### executeCommand

    public String executeCommand(String cmd, String param)
    Specified by:
      `executeCommand` in interface `ru.bitel.bgbilling.kernel.application.server.CommandListener`

  - ### tvAccountOptionSet

    public Set<Integer> tvAccountOptionSet(ConnectionSet connectionSet, TvAccountRuntime tvAccountRuntime, Date now) throws Exception
    Throws:
      `Exception`

  - ### authorization

    public AuthResult authorization(ConnectionSet connectionSet, TvAccountRuntime tvAccountRuntime, Date now, BigDecimal accountDelta) throws Exception
    Throws:
      `Exception`

  - ### getContractRuntimeMap

    public ru.bitel.bgbilling.kernel.contract.runtime.ContractRuntimeMap getContractRuntimeMap()

  - ### getTvAccountRuntimeMap

    public TvAccountRuntimeMap getTvAccountRuntimeMap()

  - ### getTvAccountSpecRuntimeMap

    public TvAccountSpecRuntimeMap getTvAccountSpecRuntimeMap()

  - ### getProductSpecRuntimeMap

    public ProductSpecRuntimeMap getProductSpecRuntimeMap()

  - ### getTvDeviceRuntimeMap

    public TvDeviceRuntimeMap getTvDeviceRuntimeMap()