- Home
- About
- Testimonials
- Demos
- Download
- Documentation
- Blogs
- Forum
- Support

Packages: default System System.Caching System.Collections System.Data System.Data.ActiveRecord System.Data.ActiveRecord.Relations System.Data.ActiveRecord.Scaffold System.Data.ActiveReecord.Scaffold.InputBuilder System.Data.Commom.Sqlite System.Data.Common System.Data.Common.Mssql System.Data.Common.Mysql System.Data.Common.Oracle System.Data.Common.Pgsql System.Data.Common.Sqlite System.Data.DataGateway System.Data.SqlMap System.Data.SqlMap.Configuration System.Data.SqlMap.Statements System.Exceptions System.I18N System.IO System.Security System.Util System.Web System.Web.Services System.Web.UI System.Web.UI.ActiveControls System.Web.UI.WebControls System.Web.UI.WebControls.assets System.Xml Classes: TDiscriminator TInlineParameterMapParser TParameterMap TParameterProperty TResultMap TResultProperty TSimpleDynamicParser TSqlMapCacheKey TSqlMapCacheModel TSqlMapCacheTypes TSqlMapDelete TSqlMapInsert TSqlMapSelectKey TSqlMapStatement TSqlMapUpdate TSqlMapXmlConfigBuilder TSqlMapXmlConfiguration TSqlMapXmlMappingConfiguration TSubMap |
Keyword
# Class TSqlMapStatement
    TComponent
       |
       --TSqlMapStatement
#### Direct Known Sub-classes: TSqlMapSelect , TSqlMapInsert , TSqlMapUpdate , TSqlMapSelectKey TSqlMapStatement class corresponds to <statement> element. Mapped Statements can hold any SQL statement and can use Parameter Maps and Result Maps for input and output. The <statement> element is a general "catch all" element that can be used for any type of SQL statement. Generally it is a good idea to use one of the more specific statement-type elements. The more specific elements provided better error-checking and even more functionality. (For example, the insert statement can return a database-generated key.) Since: 3.1 Author: Wei Zhuo <weizho[at]gmail[dot]com>
Method Summary
protected mixed | createInstanceOf ( TSqlMapTypeHandlerRegistry $registry, string $type, array $row) Create a new instance of a given type.
ArrayAccess | createInstanceOfListClass ( TSqlMapTypeHandlerRegistry $registry)
mixed | createInstanceOfResultClass ( TSqlMapTypeHandlerRegistry $registry, array $row) Create a new instance of result class.
TSqlMapCacheModel | getCache ()
string | getCacheModel ()
string | getExtends ()
string | getID ()
string | getListClass ()
string | getParameterClass ()
string | getParameterMap ()
string | getResultClass ()
string | getResultMap ()
TStaticSql | getSqlText ()
void | initialize ( TSqlMapManager $manager)
TParameterMap | parameterMap ()
TResultMap | resultMap ()
void | setCache ( TSqlMapCacheModel $value)
void | setCacheModel ( string $value)
void | setExtends ( string $value)
void | setID ( string $value)
void | setInlineParameterMap ( TInlineParameterMap $map)
void | setListClass ( string $value) An ArrayAccess class can be specified to handle the type of objects in the collection.
void | setParameterClass ( string $value) If a ParameterMap property is not specified, you may specify a ParameterClass instead and use inline parameters.
void | setParameterMap ( string $value) A Parameter Map defines an ordered list of values that match up with the "?" placeholders of a standard, parameterized query statement.
void | setResultClass ( string $value) If a ResultMap is not specified, you may specify a
void | setResultMap ( string $value) A Result Map lets you control how data is extracted from the result of a query, and how the columns are mapped to object properties.
void | setSqlText ( TStaticSql $value)
Methods Inherited From TComponent
TComponent::addParsedObject(), TComponent::attachEventHandler(), TComponent::canGetProperty(), TComponent::canSetProperty(), TComponent::createdOnTemplate(), TComponent::detachEventHandler(), TComponent::evaluateExpression(), TComponent::evaluateStatements(), TComponent::getEventHandlers(), TComponent::getSubProperty(), TComponent::hasEvent(), TComponent::hasEventHandler(), TComponent::hasProperty(), TComponent::raiseEvent(), TComponent::setSubProperty(), TComponent::__get(), TComponent::__set()
Method Details
## createInstanceOf
protected mixed createInstanceOf | (TSqlMapTypeHandlerRegistry $registry , string $type , array $row )
Create a new instance of a given type.
Input
TSqlMapTypeHandlerRegistry | $registry | type handler registry
string | $type | result class name.
array | $row | result data.
Output
mixed | result object.
Exception
## createInstanceOfListClass
public ArrayAccess createInstanceOfListClass | (TSqlMapTypeHandlerRegistry $registry )
Input
TSqlMapTypeHandlerRegistry | $registry | type handler registry
Output
ArrayAccess | new instance of list class.
Exception
## createInstanceOfResultClass
public mixed createInstanceOfResultClass | (TSqlMapTypeHandlerRegistry $registry , array $row )
Create a new instance of result class.
Input
TSqlMapTypeHandlerRegistry | $registry | type handler registry
array | $row | result data.
Output
mixed | result object.
Exception
## getCache
public TSqlMapCacheModel getCache | ()
Output
TSqlMapCacheModel | cache implementation instance for this statement.
Exception
## getCacheModel
public string getCacheModel | ()
Output
string | cache mode name.
Exception
## getExtends
public string getExtends | ()
Output
string | another statement element name.
Exception
## getID
public string getID | ()
Output
string | name for this statement, unique to each sql map manager.
Exception
## getListClass
public string getListClass | ()
Output
string | name of a PHP class that implements ArrayAccess.
Exception
## getParameterClass
public string getParameterClass | ()
Output
string | parameter class name.
Exception
## getParameterMap
public string getParameterMap | ()
Output
string | name of a parameter map.
Exception
## getResultClass
public string getResultClass | ()
Output
string | result class name.
Exception
## getResultMap
public string getResultMap | ()
Output
string | result map name.
Exception
## getSqlText
public TStaticSql getSqlText | ()
Output
TStaticSql | sql text container.
Exception
## initialize
public void initialize | (TSqlMapManager $manager )
Input
TSqlMapManager | $manager | initialize the statement, sets the result and parameter maps.
Output
Exception
## parameterMap
public TParameterMap parameterMap | ()
Output
TParameterMap | the parameter map corresponding to the ParameterMap property.
Exception
## resultMap
public TResultMap resultMap | ()
Output
TResultMap | the result map corresponding to the ResultMap property.
Exception
## setCache
public void setCache | (TSqlMapCacheModel $value )
Input
TSqlMapCacheModel | $value | cache implementation instance for this statement.
Output
Exception
## setCacheModel
public void setCacheModel | (string $value )
Input
string | $value | cache mode name.
Output
Exception
## setExtends
public void setExtends | (string $value )
Input
string | $value | name of another statement element to extend.
Output
Exception
## setID
public void setID | (string $value )
Input
string | $value | name for this statement, which must be unique for each sql map manager.
Output
Exception
## setInlineParameterMap
public void setInlineParameterMap | (TInlineParameterMap $map )
Input
TInlineParameterMap | $map | parameter extracted from the sql text.
Output
Exception
## setListClass
public void setListClass | (string $value )
An ArrayAccess class can be specified to handle the type of objects in the collection.
Input
string | $value | name of a PHP class that implements ArrayAccess.
Output
Exception
## setParameterClass
public void setParameterClass | (string $value )
If a ParameterMap property is not specified, you may specify a ParameterClass instead and use inline parameters. The value of the parameterClass attribute can be any existing PHP class name.
Input
string | $value | parameter class name.
Output
Exception
## setParameterMap
public void setParameterMap | (string $value )
A Parameter Map defines an ordered list of values that match up with the "?" placeholders of a standard, parameterized query statement.
Input
string | $value | parameter map name.
Output
Exception
## setResultClass
public void setResultClass | (string $value )
If a ResultMap is not specified, you may specify a ResultClass instead. The value of the ResultClass property can be the name of a PHP class or primitives like integer, string, or array. The class specified will be automatically mapped to the columns in the result, based on the result metadata.
Input
string | $value | result class name.
Output
Exception
## setResultMap
public void setResultMap | (string $value )
A Result Map lets you control how data is extracted from the result of a query, and how the columns are mapped to object properties.
Input
string | $value | result map name.
Output
Exception
## setSqlText
public void setSqlText | (TStaticSql $value )
Input
TStaticSql | $value | sql text container.
Output
Exception