Download Impel

Version 0.7

Read the API

It’s simple

Download Impel Modules

Transparent Database Syncing

Read the FAQ

Yes, it runs on the iPhone

Class Impel.Criterion

An inner class that describes the different portions of the WHERE clause of an SQL query. The Impel.Criterion class should not be directly instantiated. Rather it should be instantiated through Impel.Criteria.getNewCriterion

Class Summary
Constructor Attributes Constructor Name and Description
 
Impel.Criterion(parent, peer_column, value, comparison)
An inner class that describes the different portions of the WHERE clause of an SQL query.
Field Summary
Field Attributes Field Name and Description
<static>  
Impel.Criterion.clauses
<static>  
Impel.Criterion.columns
The columns that a will be retrieved, or modified as part of any SQL statement that is constructed with this Impel.Criterion
<static>  
Impel.Criterion.length
The number of clauses that make up this Impel.Criterion
<static>  
Impel.Criterion.p
The parent Impel.Criteria to which this Impel.Criterion is attached
<static>  
Impel.Criterion.peer_tables
The tables that any SQL statement constructed with this Impel.Criterion will query
<static>  
Impel.Criterion.values
Method Summary
Method Attributes Method Name and Description
<static>  
Impel.Criterion.addAnd(criterion)
Add another Impel.Criterion to this Impel.Criterion object and join it with an AND conjunction
<static>  
Impel.Criterion.addOr(criterion)
Add another criterion to this criterion object and join it with an OR conjunction
<static>  
Impel.Criterion.getClause()
Retrieve the current list of clauses for this criterion
<static>  
Impel.Criterion.getColumns()
<static>  
Impel.Criterion.getDbug()
Retrieve a string representation of this Impel.Criterion object
<static>  
Impel.Criterion.getTables()
Retrieve a list of the tables that are inclued in this Impel.Criterion object
<static>  
Impel.Criterion.getValues()
Retrieve a list of the values that have been applied to this Impel.Criterion object
Class Detail
Impel.Criterion(parent, peer_column, value, comparison)
var c     = new Impel.Criteria();
var crit  = new Impel.Criterion(c,"CardPeer::name","Queen of Hearts",Impel.CritConstants.NOT_EQUAL);
Parameters:
{Impel.Criteria} parent
The Impel.Criteria object to which this Impel.Criterion object is attached
{String} peer_column
The Peer::column to which this Impel.Criterion object applies
{mixed} value
The value of the peer_column
{String} comparison Optional, Default: CritConfig.EQUAL
The relationship between the peer_column and the value
See:
Impel.Criteria#getNewCriterion
Field Detail
<static> {String} Impel.Criterion.clauses

<static> {String[]} Impel.Criterion.columns
The columns that a will be retrieved, or modified as part of any SQL statement that is constructed with this Impel.Criterion

<static> {Number} Impel.Criterion.length
The number of clauses that make up this Impel.Criterion

<static> {Impel.Criteria} Impel.Criterion.p
The parent Impel.Criteria to which this Impel.Criterion is attached

<static> {String[]} Impel.Criterion.peer_tables
The tables that any SQL statement constructed with this Impel.Criterion will query

<static> {String|Number[]} Impel.Criterion.values
Method Detail
<static> Impel.Criterion.addAnd(criterion)
Add another Impel.Criterion to this Impel.Criterion object and join it with an AND conjunction
Parameters:
{Impel.Criterion} criterion
A Impel.Criterion object to AND with this object

<static> Impel.Criterion.addOr(criterion)
Add another criterion to this criterion object and join it with an OR conjunction
Parameters:
{Impel.Criterion} criterion
A criterion object to OR with this object

<static> {String} Impel.Criterion.getClause()
Retrieve the current list of clauses for this criterion
Returns:
{String} The Impel.Criterion represented as the appropriate portions of an SQL WHERE clause

<static> {String[]} Impel.Criterion.getColumns()
Returns:
{String[]} The columns that will make up the SELECT portion of the SQL query for this Impel.Criterion

<static> {String} Impel.Criterion.getDbug()
Retrieve a string representation of this Impel.Criterion object
Returns:
{String}

<static> {String[]} Impel.Criterion.getTables()
Retrieve a list of the tables that are inclued in this Impel.Criterion object
Returns:
{String[]}

<static> {String|Number[]} Impel.Criterion.getValues()
Retrieve a list of the values that have been applied to this Impel.Criterion object
Returns:
{String|Number[]}

blog comments powered by Disqus

Impel takes the pain out of working with HTML5 asynchronous databases.

Statement callbacks? Transaction callbacks? One-to-many and many-to-many relationships? How the heck do I deal with all without my head exploding?

Use Impel; create an object then call object.save(); Now get a cup of coffee.

What’s an ORM

Object Relational Mapping is a programming technique that turns your database, in effect, into a virtual object database.

With an ORM you no longer need to worry about how to save a single object across multiple tables, you just call, "save" on the object.

 
Contact Us | © 2009 Caleb Crane | License