Tabnine Logo
org.eclipse.persistence.exceptions
Code IndexAdd Tabnine to your IDE (free)

How to use org.eclipse.persistence.exceptions

Best Java code snippets using org.eclipse.persistence.exceptions (Showing top 20 results out of 315)

origin: com.haulmont.thirdparty/eclipselink

private void handleXMLMarshalException(XMLMarshalException xmlException) throws IOException {
  if(xmlException.getErrorCode() == XMLMarshalException.NO_DESCRIPTOR_WITH_MATCHING_ROOT_ELEMENT || xmlException.getErrorCode() == XMLMarshalException.DESCRIPTOR_NOT_FOUND_IN_PROJECT){
    throw SDOException.globalPropertyNotFound();
  } else if (xmlException.getCause() instanceof IOException) {
    throw (IOException) xmlException.getCause();
  } else{
    throw xmlException;
  }
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

public static DatabaseException sqlException(SQLException exception, Call call, Accessor accessor, AbstractSession session, boolean isCommunicationFailure) {
  DatabaseException databaseException = new DatabaseException(exception);
  databaseException.setErrorCode(SQL_EXCEPTION);
  databaseException.setAccessor(accessor);
  databaseException.setCall(call);
  databaseException.setCommunicationFailure(isCommunicationFailure);
  return databaseException;
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * INTERNAL:
 * Require for cloning, the part must be cloned.
 */
public Object buildBackupCloneForPartObject(Object attributeValue, Object clone, Object backup, UnitOfWorkImpl unitOfWork) {
  throw DescriptorException.invalidMappingOperation(this, "buildBackupCloneForPartObject");
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * INTERNAL:
 * New parameter added to doesConform for feature 2612601
 * @param objectIsUnregistered true if object possibly not a clone, but is being
 * conformed against the unit of work cache; if object is not in the UOW cache
 * but some of its attributes are, use the registered versions of
 * object's attributes for the purposes of this method.
 */
public boolean doesConform(Object object, AbstractSession session, AbstractRecord translationRow, int valueHolderPolicy, boolean objectIsUnregistered) throws QueryException {
  throw QueryException.cannotConformExpression();
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * INTERNAL:
 * Prepare and execute the batch query and store the
 * results for each source object in a map keyed by the
 * mappings source keys of the source objects.
 */
protected void executeBatchQuery(DatabaseQuery query, CacheKey parentCacheKey, Map referenceObjectsByKey, AbstractSession session, AbstractRecord row) {
  throw QueryException.batchReadingNotSupported(this, query);
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * INTERNAL:
 * Used to allow object level comparisons.
 */
public Expression buildObjectJoinExpression(Expression base, Object value, AbstractSession session) {
  throw QueryException.unsupportedMappingForObjectComparison(this, base);
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * PUBLIC:
 * Returns the integrityChecker.IntegrityChecker holds all the ClassDescriptor Exceptions.
 */
@Override
public IntegrityChecker getIntegrityChecker() {
  // BUG# 2700595 - Lazily create an IntegrityChecker if one has not already been created.
  if (integrityChecker == null) {
    integrityChecker = new IntegrityChecker();
  }
  return integrityChecker;
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * PUBLIC:
 * This method is used for catching all the Descriptor Exceptions
 */
public void catchExceptions() {
  setShouldCatchExceptions(true);
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * PUBLIC:
 * This method is used to check the database tables.
 */
public void checkDatabase() {
  setShouldCheckDatabase(true);
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * INTERNAL:
 * TopLink exceptions should only be thrown by TopLink.
 */
protected SessionLoaderException(String message, Throwable internalException) {
  super(message);
  setInternalException(internalException);
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * INTERNAL:
 * Extract and return the appropriate value from the
 * specified remote value holder.
 */
public Object getValueFromRemoteValueHolder(RemoteValueHolder remoteValueHolder) {
  throw DescriptorException.invalidIndirectionPolicyOperation(this, "getValueFromRemoteValueHolder");
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * ADVANCED: Return an expression representing a field in a data-level query.
 * This is used internally in EclipseLink, or to construct queries involving
 * fields and/or tables that are not mapped.
 * <p> Example:
 * <blockquote><pre>
 *  builder.getField(aField).greaterThan(100);
 * </pre></blockquote>
 */
public Expression getField(DatabaseField field) {
  throw QueryException.illegalUseOfGetField(field);
}
origin: org.eclipse.persistence/org.eclipse.persistence.sdo

private void handleXMLMarshalException(XMLMarshalException xmlException) throws IOException {
  if(xmlException.getErrorCode() == XMLMarshalException.NO_DESCRIPTOR_WITH_MATCHING_ROOT_ELEMENT || xmlException.getErrorCode() == XMLMarshalException.DESCRIPTOR_NOT_FOUND_IN_PROJECT){
    throw SDOException.globalPropertyNotFound();
  } else if (xmlException.getCause() instanceof IOException) {
    throw (IOException) xmlException.getCause();
  } else{
    throw xmlException;
  }
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * INTERNAL:
 * Builder the unit of work value holder.
 * @param buildDirectlyFromRow indicates that we are building the clone directly
 * from a row as opposed to building the original from the row, putting it in
 * the shared cache, and then cloning the original.
 */
public DatabaseValueHolder createCloneValueHolder(ValueHolderInterface attributeValue, Object original, Object clone, AbstractRecord row, AbstractSession cloningSession, boolean buildDirectlyFromRow) {
  throw DescriptorException.invalidMappingOperation(this, "createUnitOfWorkValueHolder");
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * INTERNAL:
 * Return the value for in memory comparison.
 * This is only valid for valueable expressions.
 * New parameter added for feature 2612601
 * @param isObjectUnregistered true if object possibly not a clone, but is being
 * conformed against the unit of work cache.
 */
public Object valueFromObject(Object object, AbstractSession session, AbstractRecord translationRow, int valueHolderPolicy, boolean isObjectUnregistered) {
  throw QueryException.cannotConformExpression();
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * INTERNAL:
 * Extract the source primary key value from the target row.
 * Used for batch reading, most following same order and fields as in the mapping.
 * The method should be overridden by classes that support batch reading.
 */
protected Object extractKeyFromTargetRow(AbstractRecord row, AbstractSession session) {
  throw QueryException.batchReadingNotSupported(this, null);
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * ADVANCED:
 * This method is used to add an object to a collection once the changeSet is applied.
 * The referenceKey parameter should only be used for direct Maps.
 */
public void simpleAddToCollectionChangeRecord(Object referenceKey, Object changeSetToAdd, ObjectChangeSet changeSet, AbstractSession session) throws DescriptorException {
  throw DescriptorException.invalidMappingOperation(this, "simpleAddToCollectionChangeRecord");
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * INTERNAL:
 * Add or removes a new value and its change set to the collection change record based on the event passed in.  This is used by
 * attribute change tracking.
 */
public void updateCollectionChangeRecord(org.eclipse.persistence.descriptors.changetracking.CollectionChangeEvent event, ObjectChangeSet objectChangeSet, UnitOfWorkImpl uow) throws DescriptorException {
  throw DescriptorException.invalidMappingOperation(this, "updateCollectionChangeRecord");
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
* INTERNAL:
* Clone the attribute from the clone and assign it to the backup.
*/
public void buildBackupClone(Object clone, Object backup, UnitOfWorkImpl unitOfWork) {
  throw DescriptorException.invalidMappingOperation(this, "buildBackupClone");
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
* INTERNAL:
* Merge changes from the source to the target object.
*/
@Override
public void mergeChangesIntoObject(Object target, ChangeRecord changeRecord, Object source, MergeManager mergeManager, AbstractSession targetSession) {
  throw DescriptorException.invalidMappingOperation(this, "mergeChangesIntoObject");
}
org.eclipse.persistence.exceptions

Most used classes

  • ValidationException
    Purpose: This exception is used if incorrect state or method arguments are detected in a general Top
  • DescriptorException
    Purpose: This exception is used for any problem that is detected with a descriptor or mapping.
  • RemoteCommandManagerException
    Instances of this exception are raised if a problem is detected in the RemoteCommandManager (RCM) fe
  • XMLMarshalException
    Purpose: XMLMarshalExceptions are raised when issues are encountered during XMLMarshaller or XMLUnma
  • DatabaseException
    Purpose: Wrapper for any database exception that occurred through EclipseLink.
  • DBWSException,
  • DynamicException,
  • EclipseLinkException,
  • EntityManagerSetupException,
  • IntegrityChecker,
  • JAXBException,
  • QueryException,
  • SDOException,
  • SessionLoaderException,
  • StaticWeaveException,
  • ExceptionMessageGenerator,
  • BeanValidationException,
  • CommunicationException,
  • ConcurrencyException
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now