Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

org.objectstyle.cayenne.access.util
Class ResultDescriptor  view ResultDescriptor download ResultDescriptor.java

java.lang.Object
  extended byorg.objectstyle.cayenne.access.util.ResultDescriptor

public class ResultDescriptor
extends java.lang.Object

Contains information about the ResultSet used to process fetched rows. ResultDescriptor is initialized by calling various "add*" methods, after that it must be indexed by calling "index".


Nested Class Summary
(package private) static class ResultDescriptor.ProcedureParameterWrapper
           
 
Field Summary
protected  org.objectstyle.cayenne.access.types.ExtendedType[] converters
           
protected  java.util.List dbAttributes
           
private static int[] emptyInt
           
protected  int[] idIndexes
           
protected  java.util.List javaTypes
           
protected  int[] jdbcTypes
           
private static org.apache.log4j.Logger logObj
           
protected  java.lang.String[] names
           
protected  int[] outParamIndexes
           
protected  org.objectstyle.cayenne.map.ObjEntity rootEntity
           
protected  org.objectstyle.cayenne.access.types.ExtendedTypeMap typesMapping
           
 
Constructor Summary
ResultDescriptor(org.objectstyle.cayenne.access.types.ExtendedTypeMap typesMapping)
           
ResultDescriptor(org.objectstyle.cayenne.access.types.ExtendedTypeMap typesMapping, org.objectstyle.cayenne.map.ObjEntity rootEntity)
           
 
Method Summary
 void addColumns(java.util.Collection dbAttributes)
           
 void addDbAttribute(org.objectstyle.cayenne.map.DbAttribute attr)
           
 void addJavaType(java.lang.String javaType)
           
 void addJavaTypes(java.util.Collection javaTypes)
           
static ResultDescriptor createDescriptor(org.objectstyle.cayenne.map.Procedure procedure, org.objectstyle.cayenne.access.types.ExtendedTypeMap typeConverters)
          Creates and returns a ResultDescriptor for the stored procedure parameters.
static ResultDescriptor createDescriptor(java.sql.ResultSet resultSet, org.objectstyle.cayenne.access.types.ExtendedTypeMap typeConverters)
          Creates and returns a ResultDescritor based on ResultSet metadata.
 org.objectstyle.cayenne.access.types.ExtendedType[] getConverters()
           
 int[] getIdIndexes()
           
 int[] getJdbcTypes()
           
 java.lang.String[] getNames()
           
 int[] getOutParamIndexes()
           
 int getResultWidth()
          Returns a count of columns in the result.
 void index()
           
protected  void initConvertersFromJavaTypes()
           
protected  void initConvertersFromMapping()
           
protected  void initDefaultConverters()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

logObj

private static org.apache.log4j.Logger logObj

emptyInt

private static final int[] emptyInt

names

protected java.lang.String[] names

jdbcTypes

protected int[] jdbcTypes

converters

protected org.objectstyle.cayenne.access.types.ExtendedType[] converters

idIndexes

protected int[] idIndexes

outParamIndexes

protected int[] outParamIndexes

dbAttributes

protected java.util.List dbAttributes

javaTypes

protected java.util.List javaTypes

typesMapping

protected org.objectstyle.cayenne.access.types.ExtendedTypeMap typesMapping

rootEntity

protected org.objectstyle.cayenne.map.ObjEntity rootEntity
Constructor Detail

ResultDescriptor

public ResultDescriptor(org.objectstyle.cayenne.access.types.ExtendedTypeMap typesMapping)

ResultDescriptor

public ResultDescriptor(org.objectstyle.cayenne.access.types.ExtendedTypeMap typesMapping,
                        org.objectstyle.cayenne.map.ObjEntity rootEntity)
Method Detail

createDescriptor

public static ResultDescriptor createDescriptor(java.sql.ResultSet resultSet,
                                                org.objectstyle.cayenne.access.types.ExtendedTypeMap typeConverters)
Creates and returns a ResultDescritor based on ResultSet metadata.


createDescriptor

public static ResultDescriptor createDescriptor(org.objectstyle.cayenne.map.Procedure procedure,
                                                org.objectstyle.cayenne.access.types.ExtendedTypeMap typeConverters)
Creates and returns a ResultDescriptor for the stored procedure parameters.


addColumns

public void addColumns(java.util.Collection dbAttributes)

addDbAttribute

public void addDbAttribute(org.objectstyle.cayenne.map.DbAttribute attr)

addJavaTypes

public void addJavaTypes(java.util.Collection javaTypes)

addJavaType

public void addJavaType(java.lang.String javaType)

index

public void index()

initConvertersFromJavaTypes

protected void initConvertersFromJavaTypes()

initDefaultConverters

protected void initDefaultConverters()

initConvertersFromMapping

protected void initConvertersFromMapping()

getConverters

public org.objectstyle.cayenne.access.types.ExtendedType[] getConverters()

getIdIndexes

public int[] getIdIndexes()

getJdbcTypes

public int[] getJdbcTypes()

getNames

public java.lang.String[] getNames()

getResultWidth

public int getResultWidth()
Returns a count of columns in the result.


getOutParamIndexes

public int[] getOutParamIndexes()