code stringlengths 73 34.1k | label stringclasses 1
value |
|---|---|
public void addNotBetween(Object attribute, Object value1, Object value2)
{
// PAW
// addSelectionCriteria(ValueCriteria.buildNotBeweenCriteria(attribute, value1, value2, getAlias()));
addSelectionCriteria(ValueCriteria.buildNotBeweenCriteria(attribute, value1, value2, getUserAlias(attribute)));
... | java |
public void addIn(Object attribute, Query subQuery)
{
// PAW
// addSelectionCriteria(ValueCriteria.buildInCriteria(attribute, subQuery, getAlias()));
addSelectionCriteria(ValueCriteria.buildInCriteria(attribute, subQuery, getUserAlias(attribute)));
} | java |
public void addNotIn(String attribute, Query subQuery)
{
// PAW
// addSelectionCriteria(ValueCriteria.buildNotInCriteria(attribute, subQuery, getAlias()));
addSelectionCriteria(ValueCriteria.buildNotInCriteria(attribute, subQuery, getUserAlias(attribute)));
} | java |
List getGroupby()
{
List result = _getGroupby();
Iterator iter = getCriteria().iterator();
Object crit;
while (iter.hasNext())
{
crit = iter.next();
if (crit instanceof Criteria)
{
result.addAll(((Criteria) crit)... | java |
public void addGroupBy(String[] fieldNames)
{
for (int i = 0; i < fieldNames.length; i++)
{
addGroupBy(fieldNames[i]);
}
} | java |
private static int getSqlInLimit()
{
try
{
PersistenceBrokerConfiguration config = (PersistenceBrokerConfiguration) PersistenceBrokerFactory
.getConfigurator().getConfigurationFor(null);
return config.getSqlInLimit();
}
catch (Confi... | java |
private UserAlias getUserAlias(Object attribute)
{
if (m_userAlias != null)
{
return m_userAlias;
}
if (!(attribute instanceof String))
{
return null;
}
if (m_alias == null)
{
return null;
}
if (m_aliasPath == null)
{
boolean allPathsAliased = true;
return new User... | java |
public void setAlias(String alias)
{
if (alias == null || alias.trim().equals(""))
{
m_alias = null;
}
else
{
m_alias = alias;
}
// propagate to SelectionCriteria,not to Criteria
for (int i = 0; i < m_criteria.size(); i++)
{
if (!(m_criteria.elementAt(i) instanceof Criteria))
... | java |
public void setAlias(UserAlias userAlias)
{
m_alias = userAlias.getName();
// propagate to SelectionCriteria,not to Criteria
for (int i = 0; i < m_criteria.size(); i++)
{
if (!(m_criteria.elementAt(i) instanceof Criteria))
{
((SelectionCriteria) m_criteria.elementAt(i)).setAlias(userAlias);... | java |
public Map getPathClasses()
{
if (m_pathClasses.isEmpty())
{
if (m_parentCriteria == null)
{
if (m_query == null)
{
return m_pathClasses;
}
else
{
return m_query.getPathClasses();
}
}
else
{
return m_parentCriteria.getPathClasses();
}
}
... | java |
public void beforeBatch(PreparedStatement stmt) throws PlatformException
{
// Check for Oracle batching support
final Method methodSetExecuteBatch;
final Method methodSendBatch;
methodSetExecuteBatch = ClassHelper.getMethod(stmt, "setExecuteBatch", PARAM_TYPE_INTEGER);
... | java |
public void addBatch(PreparedStatement stmt) throws PlatformException
{
// Check for Oracle batching support
final boolean statementBatchingSupported = m_batchStatementsInProgress.containsKey(stmt);
if (statementBatchingSupported)
{
try
{
... | java |
public int[] executeBatch(PreparedStatement stmt) throws PlatformException
{
// Check for Oracle batching support
final Method methodSendBatch = (Method) m_batchStatementsInProgress.remove(stmt);
final boolean statementBatchingSupported = methodSendBatch != null;
int[] retval ... | java |
public BeanDefinition toInternal(BeanDefinitionInfo beanDefinitionInfo) {
if (beanDefinitionInfo instanceof GenericBeanDefinitionInfo) {
GenericBeanDefinitionInfo genericInfo = (GenericBeanDefinitionInfo) beanDefinitionInfo;
GenericBeanDefinition def = new GenericBeanDefinition();
def.setBeanClassName(generi... | java |
public BeanDefinitionInfo toDto(BeanDefinition beanDefinition) {
if (beanDefinition instanceof GenericBeanDefinition) {
GenericBeanDefinitionInfo info = new GenericBeanDefinitionInfo();
info.setClassName(beanDefinition.getBeanClassName());
if (beanDefinition.getPropertyValues() != null) {
Map<String, Be... | java |
private void validate(Object object) {
Set<ConstraintViolation<Object>> viols = validator.validate(object);
for (ConstraintViolation<Object> constraintViolation : viols) {
if (Null.class.isAssignableFrom(constraintViolation.getConstraintDescriptor().getAnnotation().getClass())) {
Object o = constraintViolati... | java |
protected void initializeJdbcConnection(Connection con, JdbcConnectionDescriptor jcd)
throws LookupException
{
try
{
PlatformFactory.getPlatformFor(jcd).initializeJdbcConnection(jcd, con);
}
catch (PlatformException e)
{
throw new ... | java |
protected Connection newConnectionFromDataSource(JdbcConnectionDescriptor jcd)
throws LookupException
{
Connection retval = null;
// use JNDI lookup
DataSource ds = jcd.getDataSource();
if (ds == null)
{
// [tomdz] Would it suffice to store t... | java |
protected Connection newConnectionFromDriverManager(JdbcConnectionDescriptor jcd)
throws LookupException
{
Connection retval = null;
// use JDBC DriverManager
final String driver = jcd.getDriver();
final String url = getDbURL(jcd);
try
{
... | java |
private void prepareModel(DescriptorRepository model)
{
TreeMap result = new TreeMap();
for (Iterator it = model.getDescriptorTable().values().iterator(); it.hasNext();)
{
ClassDescriptor classDesc = (ClassDescriptor)it.next();
if (classDesc.getFullTableName... | java |
@Override
protected final void subAppend(final LoggingEvent event) {
if (event instanceof ScheduledFileRollEvent) {
// the scheduled append() call has been made by a different thread
synchronized (this) {
if (this.closed) {
// just consume the event
return;
}
this.rollFile(event);
}
... | java |
public void updateIntegerBelief(String name, int value) {
introspector.storeBeliefValue(this, name, getIntegerBelief(name) + value);
} | java |
public int getIntegerBelief(String name){
Object belief = introspector.getBeliefBase(this).get(name);
int count = 0;
if (belief!=null) {
count = (Integer) belief;
}
return (Integer) count;
} | java |
@Programmatic
public <T> List<T> fromExcel(
final Blob excelBlob,
final Class<T> cls,
final String sheetName) throws ExcelService.Exception {
return fromExcel(excelBlob, new WorksheetSpec(cls, sheetName));
} | java |
public TransactionImpl getCurrentTransaction()
{
TransactionImpl tx = tx_table.get(Thread.currentThread());
if(tx == null)
{
throw new TransactionNotInProgressException("Calling method needed transaction, but no transaction found for current thread :-(");
}
... | java |
public String getDefaultTableName()
{
String name = getName();
int lastDotPos = name.lastIndexOf('.');
int lastDollarPos = name.lastIndexOf('$');
return lastDollarPos > lastDotPos ? name.substring(lastDollarPos + 1) : name.substring(lastDotPos + 1);
} | java |
private void sortFields()
{
HashMap fields = new HashMap();
ArrayList fieldsWithId = new ArrayList();
ArrayList fieldsWithoutId = new ArrayList();
FieldDescriptorDef fieldDef;
for (Iterator it = getFields(); it.hasNext(); )
... | java |
public void checkConstraints(String checkLevel) throws ConstraintException
{
// now checking constraints
FieldDescriptorConstraints fieldConstraints = new FieldDescriptorConstraints();
ReferenceDescriptorConstraints refConstraints = new ReferenceDescriptorConstraints();
... | java |
private boolean contains(ArrayList defs, DefBase obj)
{
for (Iterator it = defs.iterator(); it.hasNext();)
{
if (obj.getName().equals(((DefBase)it.next()).getName()))
{
return true;
}
}
return false;
} | java |
private FieldDescriptorDef cloneField(FieldDescriptorDef fieldDef, String prefix)
{
FieldDescriptorDef copyFieldDef = new FieldDescriptorDef(fieldDef, prefix);
copyFieldDef.setOwner(this);
// we remove properties that are only relevant to the class the features are declared in
... | java |
private ReferenceDescriptorDef cloneReference(ReferenceDescriptorDef refDef, String prefix)
{
ReferenceDescriptorDef copyRefDef = new ReferenceDescriptorDef(refDef, prefix);
copyRefDef.setOwner(this);
// we remove properties that are only relevant to the class the features are declared... | java |
private CollectionDescriptorDef cloneCollection(CollectionDescriptorDef collDef, String prefix)
{
CollectionDescriptorDef copyCollDef = new CollectionDescriptorDef(collDef, prefix);
copyCollDef.setOwner(this);
// we remove properties that are only relevant to the class the features are... | java |
public Iterator getAllBaseTypes()
{
ArrayList baseTypes = new ArrayList();
baseTypes.addAll(_directBaseTypes.values());
for (int idx = baseTypes.size() - 1; idx >= 0; idx--)
{
ClassDescriptorDef curClassDef = (ClassDescriptorDef)baseTypes.get(idx);
... | java |
public Iterator getAllExtentClasses()
{
ArrayList subTypes = new ArrayList();
subTypes.addAll(_extents);
for (int idx = 0; idx < subTypes.size(); idx++)
{
ClassDescriptorDef curClassDef = (ClassDescriptorDef)subTypes.get(idx);
for (Iterator it = c... | java |
public FieldDescriptorDef getField(String name)
{
FieldDescriptorDef fieldDef = null;
for (Iterator it = _fields.iterator(); it.hasNext(); )
{
fieldDef = (FieldDescriptorDef)it.next();
if (fieldDef.getName().equals(name))
{
return... | java |
public ArrayList getFields(String fieldNames) throws NoSuchFieldException
{
ArrayList result = new ArrayList();
FieldDescriptorDef fieldDef;
String name;
for (CommaListIterator it = new CommaListIterator(fieldNames); it.hasNext();)
{
... | java |
public ArrayList getPrimaryKeys()
{
ArrayList result = new ArrayList();
FieldDescriptorDef fieldDef;
for (Iterator it = getFields(); it.hasNext();)
{
fieldDef = (FieldDescriptorDef)it.next();
if (fieldDef.getBooleanProperty(PropertyHelper.OJB... | java |
public ReferenceDescriptorDef getReference(String name)
{
ReferenceDescriptorDef refDef;
for (Iterator it = _references.iterator(); it.hasNext(); )
{
refDef = (ReferenceDescriptorDef)it.next();
if (refDef.getName().equals(name))
{
... | java |
public CollectionDescriptorDef getCollection(String name)
{
CollectionDescriptorDef collDef = null;
for (Iterator it = _collections.iterator(); it.hasNext(); )
{
collDef = (CollectionDescriptorDef)it.next();
if (collDef.getName().equals(name))
{
... | java |
public NestedDef getNested(String name)
{
NestedDef nestedDef = null;
for (Iterator it = _nested.iterator(); it.hasNext(); )
{
nestedDef = (NestedDef)it.next();
if (nestedDef.getName().equals(name))
{
return nestedDef;
... | java |
public IndexDescriptorDef getIndexDescriptor(String name)
{
IndexDescriptorDef indexDef = null;
for (Iterator it = _indexDescriptors.iterator(); it.hasNext(); )
{
indexDef = (IndexDescriptorDef)it.next();
if (indexDef.getName().equals(name))
{
... | java |
public void addProcedure(ProcedureDef procDef)
{
procDef.setOwner(this);
_procedures.put(procDef.getName(), procDef);
} | java |
public void addProcedureArgument(ProcedureArgumentDef argDef)
{
argDef.setOwner(this);
_procedureArguments.put(argDef.getName(), argDef);
} | java |
public void processClass(String template, Properties attributes) throws XDocletException
{
if (!_model.hasClass(getCurrentClass().getQualifiedName()))
{
// we only want to output the log message once
LogHelper.debug(true, OjbTagsHandler.class, "processClass", "Type "+get... | java |
public void forAllClassDefinitions(String template, Properties attributes) throws XDocletException
{
for (Iterator it = _model.getClasses(); it.hasNext(); )
{
_curClassDef = (ClassDescriptorDef)it.next();
generate(template);
}
_curClassDef = null;
... | java |
public void originalClass(String template, Properties attributes) throws XDocletException
{
pushCurrentClass(_curClassDef.getOriginalClass());
generate(template);
popCurrentClass();
} | java |
public String addExtent(Properties attributes) throws XDocletException
{
String name = attributes.getProperty(ATTRIBUTE_NAME);
if (!_model.hasClass(name))
{
throw new XDocletException(Translator.getString(XDocletModulesOjbMessages.class,
... | java |
public void forAllExtents(String template, Properties attributes) throws XDocletException
{
for (Iterator it = _curClassDef.getExtentClasses(); it.hasNext(); )
{
_curExtent = (ClassDescriptorDef)it.next();
generate(template);
}
_curExtent = null;
} | java |
public String processIndexDescriptor(Properties attributes) throws XDocletException
{
String name = attributes.getProperty(ATTRIBUTE_NAME);
IndexDescriptorDef indexDef = _curClassDef.getIndexDescriptor(name);
String attrName;
if (indexDef ==... | java |
public void forAllIndexDescriptorDefinitions(String template, Properties attributes) throws XDocletException
{
for (Iterator it = _curClassDef.getIndexDescriptors(); it.hasNext(); )
{
_curIndexDescriptorDef = (IndexDescriptorDef)it.next();
generate(template);
}
... | java |
public void forAllIndexDescriptorColumns(String template, Properties attributes) throws XDocletException
{
String fields = _curIndexDescriptorDef.getProperty(PropertyHelper.OJB_PROPERTY_FIELDS);
FieldDescriptorDef fieldDef;
String name;
for (CommaListIt... | java |
public String processObjectCache(Properties attributes) throws XDocletException
{
ObjectCacheDef objCacheDef = _curClassDef.setObjectCache(attributes.getProperty(ATTRIBUTE_CLASS));
String attrName;
attributes.remove(ATTRIBUTE_CLASS);
for (Enumeration attrNames = attrib... | java |
public void forObjectCache(String template, Properties attributes) throws XDocletException
{
_curObjectCacheDef = _curClassDef.getObjectCache();
if (_curObjectCacheDef != null)
{
generate(template);
_curObjectCacheDef = null;
}
} | java |
public String processProcedure(Properties attributes) throws XDocletException
{
String type = attributes.getProperty(ATTRIBUTE_TYPE);
ProcedureDef procDef = _curClassDef.getProcedure(type);
String attrName;
if (procDef == null)
{
procDe... | java |
public void forAllProcedures(String template, Properties attributes) throws XDocletException
{
for (Iterator it = _curClassDef.getProcedures(); it.hasNext(); )
{
_curProcedureDef = (ProcedureDef)it.next();
generate(template);
}
_curProcedureDef = null;
... | java |
public String processProcedureArgument(Properties attributes) throws XDocletException
{
String id = attributes.getProperty(ATTRIBUTE_NAME);
ProcedureArgumentDef argDef = _curClassDef.getProcedureArgument(id);
String attrName;
if (argDef ... | java |
public void forAllProcedureArguments(String template, Properties attributes) throws XDocletException
{
String argNameList = _curProcedureDef.getProperty(PropertyHelper.OJB_PROPERTY_ARGUMENTS);
for (CommaListIterator it = new CommaListIterator(argNameList); it.hasNext();)
{
... | java |
public void processAnonymousField(Properties attributes) throws XDocletException
{
if (!attributes.containsKey(ATTRIBUTE_NAME))
{
throw new XDocletException(Translator.getString(XDocletModulesOjbMessages.class,
XDocletModulesOjbMessages.PARAMET... | java |
public void processField(String template, Properties attributes) throws XDocletException
{
String name = OjbMemberTagsHandler.getMemberName();
String defaultType = getDefaultJdbcTypeForCurrentMember();
String defaultConversion = getD... | java |
public void processAnonymousReference(Properties attributes) throws XDocletException
{
ReferenceDescriptorDef refDef = _curClassDef.getReference("super");
String attrName;
if (refDef == null)
{
refDef = new ReferenceDescriptorDef("super");
... | java |
public void processReference(String template, Properties attributes) throws XDocletException
{
String name = OjbMemberTagsHandler.getMemberName();
XClass type = OjbMemberTagsHandler.getMemberType();
int dim = OjbMemberTagsHandler.... | java |
public void forAllReferenceDefinitions(String template, Properties attributes) throws XDocletException
{
for (Iterator it = _curClassDef.getReferences(); it.hasNext(); )
{
_curReferenceDef = (ReferenceDescriptorDef)it.next();
// first we check whether it is an inherited ... | java |
public void processCollection(String template, Properties attributes) throws XDocletException
{
String name = OjbMemberTagsHandler.getMemberName();
CollectionDescriptorDef collDef = _curClassDef.getCollection(name);
String attrName;
if (col... | java |
public void forAllCollectionDefinitions(String template, Properties attributes) throws XDocletException
{
for (Iterator it = _curClassDef.getCollections(); it.hasNext(); )
{
_curCollectionDef = (CollectionDescriptorDef)it.next();
if (!isFeatureIgnored(LEVEL_COLLECTION) &... | java |
public String processNested(Properties attributes) throws XDocletException
{
String name = OjbMemberTagsHandler.getMemberName();
XClass type = OjbMemberTagsHandler.getMemberType();
int dim = OjbMemberTagsHandler.getMemberDimension();
NestedDef nestedD... | java |
public String createTorqueSchema(Properties attributes) throws XDocletException
{
String dbName = (String)getDocletContext().getConfigParam(CONFIG_PARAM_DATABASENAME);
_torqueModel = new TorqueModelDef(dbName, _model);
return "";
} | java |
public void forAllTables(String template, Properties attributes) throws XDocletException
{
for (Iterator it = _torqueModel.getTables(); it.hasNext(); )
{
_curTableDef = (TableDef)it.next();
generate(template);
}
_curTableDef = null;
} | java |
public void forAllColumns(String template, Properties attributes) throws XDocletException
{
for (Iterator it = _curTableDef.getColumns(); it.hasNext(); )
{
_curColumnDef = (ColumnDef)it.next();
generate(template);
}
_curColumnDef = null;
} | java |
public void forAllForeignkeys(String template, Properties attributes) throws XDocletException
{
for (Iterator it = _curTableDef.getForeignkeys(); it.hasNext(); )
{
_curForeignkeyDef = (ForeignkeyDef)it.next();
generate(template);
}
_curForeignkeyDef = n... | java |
public void forAllForeignkeyColumnPairs(String template, Properties attributes) throws XDocletException
{
for (int idx = 0; idx < _curForeignkeyDef.getNumColumnPairs(); idx++)
{
_curPairLeft = _curForeignkeyDef.getLocalColumn(idx);
_curPairRight = _curForeignkeyDef.getR... | java |
public void forAllIndices(String template, Properties attributes) throws XDocletException
{
boolean processUnique = TypeConversionUtil.stringToBoolean(attributes.getProperty(ATTRIBUTE_UNIQUE), false);
// first the default index
_curIndexDef = _curTableDef.getIndex(null);
if ((... | java |
public void forAllIndexColumns(String template, Properties attributes) throws XDocletException
{
for (Iterator it = _curIndexDef.getColumns(); it.hasNext(); )
{
_curColumnDef = _curTableDef.getColumn((String)it.next());
generate(template);
}
_curColumnD... | java |
public String name(Properties attributes) throws XDocletException
{
return getDefForLevel(attributes.getProperty(ATTRIBUTE_LEVEL)).getName();
} | java |
public void ifHasName(String template, Properties attributes) throws XDocletException
{
String name = getDefForLevel(attributes.getProperty(ATTRIBUTE_LEVEL)).getName();
if ((name != null) && (name.length() > 0))
{
generate(template);
}
} | java |
public void ifHasProperty(String template, Properties attributes) throws XDocletException
{
String value = getPropertyValue(attributes.getProperty(ATTRIBUTE_LEVEL), attributes.getProperty(ATTRIBUTE_NAME));
if (value != null)
{
generate(template);
}
} | java |
public String propertyValue(Properties attributes) throws XDocletException
{
String value = getPropertyValue(attributes.getProperty(ATTRIBUTE_LEVEL), attributes.getProperty(ATTRIBUTE_NAME));
if (value == null)
{
value = attributes.getProperty(ATTRIBUTE_DEFAULT);
}... | java |
public void ifPropertyValueEquals(String template, Properties attributes) throws XDocletException
{
String value = getPropertyValue(attributes.getProperty(ATTRIBUTE_LEVEL), attributes.getProperty(ATTRIBUTE_NAME));
String expected = attributes.getProperty(ATTRIBUTE_VALUE);
if (value ... | java |
public void forAllValuePairs(String template, Properties attributes) throws XDocletException
{
String name = attributes.getProperty(ATTRIBUTE_NAME, "attributes");
String defaultValue = attributes.getProperty(ATTRIBUTE_DEFAULT_RIGHT, "");
String attributePairs = getPropertyVal... | java |
private ClassDescriptorDef ensureClassDef(XClass original)
{
String name = original.getQualifiedName();
ClassDescriptorDef classDef = _model.getClass(name);
if (classDef == null)
{
classDef = new ClassDescriptorDef(original);
_model.ad... | java |
private void addDirectSubTypes(XClass type, ArrayList subTypes)
{
if (type.isInterface())
{
if (type.getExtendingInterfaces() != null)
{
subTypes.addAll(type.getExtendingInterfaces());
}
// we have to traverse the implementing c... | java |
private String searchForPersistentSubType(XClass type)
{
ArrayList queue = new ArrayList();
XClass subType;
queue.add(type);
while (!queue.isEmpty())
{
subType = (XClass)queue.get(0);
queue.remove(0);
if (_model.hasClass(subTy... | java |
private DefBase getDefForLevel(String level)
{
if (LEVEL_CLASS.equals(level))
{
return _curClassDef;
}
else if (LEVEL_FIELD.equals(level))
{
return _curFieldDef;
}
else if (LEVEL_REFERENCE.equals(level))
{
... | java |
private String getPropertyValue(String level, String name)
{
return getDefForLevel(level).getProperty(name);
} | java |
final void compress(final File backupFile,
final AppenderRollingProperties properties) {
if (this.isCompressed(backupFile)) {
LogLog.debug("Backup log file " + backupFile.getName()
+ " is already compressed");
return; // try not to do unnecessary work
}
final long lastModified = ... | java |
public static PersistenceBroker createPersistenceBroker(String jcdAlias,
String user,
String password) throws PBFactoryException
{
return PersistenceBrokerFactoryFactory.instance().
... | java |
public void setRegistrationConfig(RegistrationConfig registrationConfig) {
this.registrationConfig = registrationConfig;
if (registrationConfig.getDefaultConfig()!=null) {
for (String key : registrationConfig.getDefaultConfig().keySet()) {
dynamicConfig.put(key, registration... | java |
public void characters(char ch[], int start, int length)
{
if (m_CurrentString == null)
m_CurrentString = new String(ch, start, length);
else
m_CurrentString += new String(ch, start, length);
} | java |
public synchronized boolean hasNext()
{
try
{
if (!isHasCalledCheck())
{
setHasCalledCheck(true);
setHasNext(getRsAndStmt().m_rs.next());
if (!getHasNext())
{
autoReleaseDbResources(... | java |
public synchronized Object next() throws NoSuchElementException
{
try
{
if (!isHasCalledCheck())
{
hasNext();
}
setHasCalledCheck(false);
if (getHasNext())
{
Object obj = getObjectFromR... | java |
private Collection getOwnerObjects()
{
Collection owners = new Vector();
while (hasNext())
{
owners.add(next());
}
return owners;
} | java |
private void prefetchRelationships(Query query)
{
List prefetchedRel;
Collection owners;
String relName;
RelationshipPrefetcher[] prefetchers;
if (query == null || query.getPrefetchedRelationships() == null || query.getPrefetchedRelationships().isEmpty())
{
... | java |
protected Object getProxyFromResultSet() throws PersistenceBrokerException
{
// 1. get Identity of current row:
Identity oid = getIdentityFromResultSet();
// 2. return a Proxy instance:
return getBroker().createProxy(getItemProxyClass(), oid);
} | java |
protected int countedSize() throws PersistenceBrokerException
{
Query countQuery = getBroker().serviceBrokerHelper().getCountQuery(getQueryObject().getQuery());
ResultSetAndStatement rsStmt;
ClassDescriptor cld = getQueryObject().getClassDescriptor();
int count = 0;
/... | java |
public boolean absolute(int row) throws PersistenceBrokerException
{
boolean retval;
if (supportsAdvancedJDBCCursorControl())
{
retval = absoluteAdvanced(row);
}
else
{
retval = absoluteBasic(row);
}
return retval;
... | java |
private boolean absoluteBasic(int row)
{
boolean retval = false;
if (row > m_current_row)
{
try
{
while (m_current_row < row && getRsAndStmt().m_rs.next())
{
m_current_row++;
}
... | java |
private boolean absoluteAdvanced(int row)
{
boolean retval = false;
try
{
if (getRsAndStmt().m_rs != null)
{
if (row == 0)
{
getRsAndStmt().m_rs.beforeFirst();
}
e... | java |
private String safeToString(Object obj)
{
String toString = null;
if (obj != null)
{
try
{
toString = obj.toString();
}
catch (Throwable ex)
{
toString = "BAD toString() impl for " + obj.getClass().getName();
}
}
return toString;
} | java |
public void setRowReader(String newReaderClassName)
{
try
{
m_rowReader =
(RowReader) ClassHelper.newInstance(
newReaderClassName,
ClassDescriptor.class,
this);
}
catch (Exception e)
... | java |
public void setClassOfObject(Class c)
{
m_Class = c;
isAbstract = Modifier.isAbstract(m_Class.getModifiers());
// TODO : Shouldn't the HashMap in DescriptorRepository be updated as well?
} | java |
public void addFieldDescriptor(FieldDescriptor fld)
{
fld.setClassDescriptor(this); // BRJ
if (m_FieldDescriptions == null)
{
m_FieldDescriptions = new FieldDescriptor[1];
m_FieldDescriptions[0] = fld;
}
else
{
int size = ... | java |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.