Class RPZoneDAO

java.lang.Object
marauroa.server.game.db.RPZoneDAO

public class RPZoneDAO extends Object
data access object for RPZones
Author:
miguel, hendrik
  • Field Details

    • factory

      protected RPObjectFactory factory
      factory for creating object instances
  • Constructor Details

    • RPZoneDAO

      protected RPZoneDAO(RPObjectFactory factory)
      creates a new RPZoneDAO
      Parameters:
      factory - factory for creating object instances
  • Method Details

    • loadRPZone

      public void loadRPZone(DBTransaction transaction, IRPZone zone) throws SQLException, IOException
      loads storable objects for the specified zone from the database
      Parameters:
      transaction - DBTransaction
      zone - IRPZone
      Throws:
      IOException - in case of an input/output error
      SQLException - in case of an database error
    • storeRPZone

      public void storeRPZone(DBTransaction transaction, IRPZone zone) throws IOException, SQLException
      saves storable objects for the specified zone to the database
      Parameters:
      transaction - DBTransaction
      zone - IRPZone
      Throws:
      IOException - in case of an input/output error
      SQLException - in case of an database error
    • storeRPZone

      public void storeRPZone(DBTransaction transaction, IRPZone zone, Iterable<RPObject> content) throws IOException, SQLException
      saves storable objects for the specified zone to the database
      Parameters:
      transaction - DBTransaction
      zone - IRPZone
      content - the RPObjects of that zone
      Throws:
      IOException - in case of an input/output error
      SQLException - in case of an database error
    • hasRPZone

      public boolean hasRPZone(DBTransaction transaction, IRPZone.ID zone) throws SQLException
      is the specified zone saved to the database
      Parameters:
      transaction - DBTransaction
      zone - id of zone
      Returns:
      true, if the zone exists; false otherwise
      Throws:
      SQLException - in case of an database error
    • loadRPZone

      public void loadRPZone(IRPZone zone) throws SQLException, IOException
      loads storable objects for the specified zone from the database
      Parameters:
      zone - IRPZone
      Throws:
      IOException - in case of an input/output error
      SQLException - in case of an database error
    • storeRPZone

      @Deprecated public void storeRPZone(IRPZone zone) throws IOException, SQLException
      Deprecated.
      saves storable objects for the specified zone to the database
      Parameters:
      zone - IRPZone
      Throws:
      IOException - in case of an input/output error
      SQLException - in case of an database error
    • hasRPZone

      @Deprecated public boolean hasRPZone(IRPZone.ID zone) throws SQLException
      Deprecated.
      is the specified zone saved to the database
      Parameters:
      zone - id of zone
      Returns:
      true, if the zone exists; false otherwise
      Throws:
      SQLException - in case of an database error