Package bitel.billing.server.admin.resource.bean

# Class ResourceUseManager<T extends ResourceUse>

java.lang.Object
bitel.billing.server.admin.resource.bean.ResourceUseManager<T>

Direct Known Subclasses:
  `NumberResourceUseManager`

public abstract class ResourceUseManager<T extends ResourceUse> extends Object

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `protected Connection`
  `con`
  `protected int`
  `mid`
  `protected String`
  `tableName`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `ResourceUseManager(Connection con, int mid)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `closeResourceUse(int cid, Date date)`
  `void`
  `freeResources(int cid)`
  `List<T>`
  `getResourceUse(int resourceId)`
  `protected abstract T`
  `getResourceUseFromRs(ResultSet rs)`
  `protected abstract String`
  `getTableName()`
  `protected abstract void`
  `insertResourceUseList(int resourceId, List<T> resourceUseList)`
  `protected void`
  `loadStandartResourceUseFromRs(ResourceUse ruse, ResultSet rs)`
  `void`
  `updateResourceUse(int resourceId, List<T> useList)`
  `boolean`
  `wasResourceUsed(String resourceId)`

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

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

- ## Field Details

  - ### con

    protected Connection con

  - ### tableName

    protected String tableName

  - ### mid

    protected int mid

- ## Constructor Details

  - ### ResourceUseManager

    public ResourceUseManager(Connection con, int mid)

- ## Method Details

  - ### getResourceUse

    public List<T> getResourceUse(int resourceId)

  - ### updateResourceUse

    public void updateResourceUse(int resourceId, List<T> useList)

  - ### insertResourceUseList

    protected abstract void insertResourceUseList(int resourceId, List<T> resourceUseList) throws Exception
    Throws:
      `Exception`

  - ### wasResourceUsed

    public boolean wasResourceUsed(String resourceId)

  - ### loadStandartResourceUseFromRs

    protected void loadStandartResourceUseFromRs(ResourceUse ruse, ResultSet rs) throws Exception
    Throws:
      `Exception`

  - ### getResourceUseFromRs

    protected abstract T getResourceUseFromRs(ResultSet rs)

  - ### getTableName

    protected abstract String getTableName()

  - ### freeResources

    public void freeResources(int cid)

  - ### closeResourceUse

    public void closeResourceUse(int cid, Date date)