# Package org.apache.torque

package org.apache.torque
Torque is an object-relational mapper for Java. In other words, Torque lets you access and manipulate data in a relational database using java objects. Unlike most other object-relational mappers, Torque does not use reflection to access user-provided classes, but it generates the necessary classes (including the Data Objects) from an XML schema describing the database layout (which can either be written by hand or generated from an existing database). The XML schema can also be used to generate and execute a SQL script which creates all the tables in the database.

- Related Packages
  Package
  Description
  org.apache.torque.adapter
  Adapters between Torque and various databases.
  org.apache.torque.avalon
  Avalon component implementation.
  org.apache.torque.criteria
  This package contains Torque's Criteria classes.
  org.apache.torque.dsfactory
  Torque's API for creation of various javax.sql.DataSource implementations.
  org.apache.torque.manager
  A manager/factory API for use with Torque-generated data beans.
  org.apache.torque.map
  Description of the schema layout.
  org.apache.torque.oid
  The ID broker, an API to provide persistent object identifiers, as described by Scott Ambler's paper on "Enterprise-Ready Object IDs".
  org.apache.torque.om
  API for the classic Torque-generated object model.
  org.apache.torque.sql
  This package contains classes which are mainly used in the SQL generation process.
  org.apache.torque.util
  Misc. utility classes.
- Class
  Description
  Column
  The metadata of a column (or pseudocolumn) in a database.
  ColumnImpl
  An implementation of the column interface.
  ConstraintViolationException
  This exception is thrown if a database operation violates a database constraint, e.g. a foreign key constraint, a unique constraint or a not-null constraint.
  Database
  Bundles all information about a database.
  DeadlockException
  This exception is thrown if the database detects a deadlock.
  NoRowsException
  This exception indicates that no rows were returned but at least one should have been returned.
  OptimisticLockingFailedException
  This exception is thrown if the database detects that a row in a table with optimistic locking was updated by another process.
  TooManyRowsException
  This exception indicates that more rows were returned than expected.
  Torque
  A static facade wrapper around the Torque implementation (which is in `TorqueInstance`).
  TorqueException
  The base class of all checked exceptions thrown by Torque.
  TorqueInstance
  The core of Torque's implementation.
  TorqueRuntimeException
  This is the base class of all non-checked exceptions in Torque.