LEONARDI Application Composer - 8.9.0.40 by W4 S.A.

leon.peer.sql.postgresql
Class LyPostgresqlRequestEncoder

java.lang.Object
  extended by leon.peer.LyRequestEncoder
      extended by leon.peer.LyBlobRequestEncoder
          extended by leon.peer.sql.LySqlRequestEncoder
              extended by leon.peer.sql.postgresql.LyPostgresqlRequestEncoder
All Implemented Interfaces:
LyJoinRequestEncoder

public class LyPostgresqlRequestEncoder
extends LySqlRequestEncoder

This class is used to send requests to a SQL database connection and to receive its answers. This is a specialization for postgresql database .

See Also:
LyRequestEncoder, LySqlConnection, LyPostgresqlDataProvider

Field Summary
static java.lang.String __VERSION
           
 
Fields inherited from class leon.peer.sql.LySqlRequestEncoder
CHAR_QUOTE, DOMAIN_FILTER_RELATION, STRING_QUOTE, STRING_TWO_QUOTES
 
Fields inherited from class leon.peer.LyBlobRequestEncoder
MAX_BLOB_BUFFER
 
Constructor Summary
LyPostgresqlRequestEncoder(LyDataProvider provider, LyDataSource dataSource, java.lang.String valueSep)
           
 
Method Summary
 java.lang.String encodeLimitCondition(int limit)
          encode the limit condition.
 java.lang.String getSQLFormatDate(java.lang.String quotedId, LyDateFieldInfo fieldInfo)
          String force formating date for order by using FORMAT(quotedId, 'YYYY-MM-DD HH:MM:SS') but syntax is specific depending on database vendor.
 void setResponse(LyResponse response)
          Set the request encoder response.
 boolean supportCaseSensitive()
          Returns a boolean that indicates if case sensitive is supported.
 
Methods inherited from class leon.peer.sql.LySqlRequestEncoder
buildObject, clearChildRequestInfo, completeSelectedFields, completeSelectedFields, createObject, deleteObject, deleteObjects, getFilters, getObject, getObjects, getObjects, getRequestInfo, getSize, getSize, getTableAliasForSelfTargetRelationClass, setChildRequestInfo, setObject, setObjects, setTrim
 
Methods inherited from class leon.peer.LyBlobRequestEncoder
getBlobContent
 
Methods inherited from class leon.peer.LyRequestEncoder
getClassBinding, getDataClass, getProvider, getResponse, isSynchronous, loadObject, setClassBinding, setDataClass, toString, toString, toString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

__VERSION

public static final java.lang.String __VERSION
See Also:
Constant Field Values
Constructor Detail

LyPostgresqlRequestEncoder

public LyPostgresqlRequestEncoder(LyDataProvider provider,
                                  LyDataSource dataSource,
                                  java.lang.String valueSep)
Parameters:
provider -
dataSource -
valueSep -
Method Detail

supportCaseSensitive

public boolean supportCaseSensitive()
Returns a boolean that indicates if case sensitive is supported.

Overrides:
supportCaseSensitive in class LySqlRequestEncoder
Returns:
True if supported, false otherwise.

encodeLimitCondition

public java.lang.String encodeLimitCondition(int limit)
Description copied from class: LySqlRequestEncoder
encode the limit condition.

Overrides:
encodeLimitCondition in class LySqlRequestEncoder
Parameters:
limit - max numbut of rows fetched

setResponse

public void setResponse(LyResponse response)
Set the request encoder response. Inherited method of LyRequestEncoder to set properties to the response.

Overrides:
setResponse in class LySqlRequestEncoder
Parameters:
the - response

getSQLFormatDate

public java.lang.String getSQLFormatDate(java.lang.String quotedId,
                                         LyDateFieldInfo fieldInfo)
String force formating date for order by using FORMAT(quotedId, 'YYYY-MM-DD HH:MM:SS') but syntax is specific depending on database vendor. If not overridden this method does nothing and returns the quotedId to keep backward compatibility.

Overrides:
getSQLFormatDate in class LySqlRequestEncoder
Parameters:
quotedId - id of the date field (using aliases, table names and quotes if needed)
peerField - peer field related to this column
Returns:
the sort criteria to use in the SQL request

(c) January 2013 - W4 S.A.

Website: W4 S.A., contact us: support@w4global.com