Package javax.jdo

Examples of javax.jdo.JDOFatalException


            resultStream = new PrintStream(new FileOutputStream(file));
            for (Iterator it = supportedOptions.iterator(); it.hasNext();) {
                resultStream.println((String)it.next());
            }
        } catch (FileNotFoundException e) {
            throw new JDOFatalException(
                "dumpSupportedOptions: cannot create file " + file.getName(), e);
        } finally {
            if (resultStream != null)
                resultStream.close();
        }
View Full Code Here


                    oos.writeObject(obj);
                    ois = new ObjectInputStream(new ByteArrayInputStream(
                            byteArrayOutputStream.toByteArray()));
                    result = ois.readObject();
                } catch (IOException e) {
                    throw new JDOFatalException(e.getMessage(), e);
                } catch (ClassNotFoundException e) {
                    throw new JDOFatalException(e.getMessage(), e);
                } finally {
                    try {
                        if (oos != null) {
                            oos.close();
                        }
                        if (ois != null) {
                            ois.close();
                        }
                    } catch (IOException e) {
                        throw new JDOFatalException(e.getMessage(), e);
                    }
                }
                break;  
               
            default:
View Full Code Here

            Throwable throwable = (Throwable)entry.getValue();
            String message = "Uncaught exception " + throwable + " in thread " + thread;
            if( throwable instanceof AssertionFailedError )
                fail(ASSERTION_FAILED, message);
            else
                throw new JDOFatalException(message, throwable);
        }
       
    }
View Full Code Here

                verifyProperties(pmf, loadProperties(validPropertiesFile));
                context.bind(jndiName, pmf);
            }
            return JDOHelper.getPersistenceManagerFactory(jndiName, context);
        } catch (NamingException e) {
            throw new JDOFatalException("Caught NamingException trying to bind " +
                    e.getMessage(), e);
        } finally {
            if (context != null) {
                try {
                    context.unbind(jndiName);
View Full Code Here

            ObjectOutputStream oos = null;
            try {
                oos = new ObjectOutputStream(new ByteArrayOutputStream());
                oos.writeObject(obj);
            } catch (IOException e) {
                throw new JDOFatalException(e.getMessage(), e);
            } finally {
                if (oos != null) {
                    try {
                        oos.close();
                    } catch (IOException e) {
                        throw new JDOFatalException(e.getMessage(), e);
                    }
                }
            }
            break;     
        }
        case SERIALIZEDATASTORE:
        case SERIALIZEOPTIMISTIC:
        {
            ObjectOutputStream oos = null;
            try {
                oos = new ObjectOutputStream(new ByteArrayOutputStream());
                oos.writeObject(obj);
            } catch (IOException e) {
                throw new JDOFatalException(e.getMessage(), e);
            } finally {
                if (oos != null) {
                    try {
                        oos.close();
                    } catch (IOException e) {
                        throw new JDOFatalException(e.getMessage(), e);
                    }
                }
            }
            break;     
        }
View Full Code Here

        Throwable t1Problem = group.getUncaughtException(T1);
        if (t1Problem != null) {
            if (t1Problem instanceof AssertionFailedError)
                throw (AssertionFailedError)t1Problem;
            else
                throw new JDOFatalException( "Thread "+T1.getName()+" results in exception ", t1Problem );
        }
        Throwable t2Problem = group.getUncaughtException(T2);
        if (t2Problem != null) {
            if (t2Problem instanceof AssertionFailedError)
                throw (AssertionFailedError)t2Problem;
            else
                throw new JDOFatalException( "Thread "+T2.getName()+" results in exception ", t2Problem );
        }

        if (debug) logger.debug ("END RefreshAllWithArraySideEffects");
    }
View Full Code Here

        Throwable t1Problem = group.getUncaughtException(T1);
        if (t1Problem != null) {
            if (t1Problem instanceof AssertionFailedError)
                throw (AssertionFailedError)t1Problem;
            else
                throw new JDOFatalException( "Thread "+T1.getName()+" results in exception ", t1Problem );
        }
        Throwable t2Problem = group.getUncaughtException(T2);
        if (t2Problem != null) {
            if (t2Problem instanceof AssertionFailedError)
                throw (AssertionFailedError)t2Problem;
            else
                throw new JDOFatalException( "Thread "+T2.getName()+" results in exception ", t2Problem );
        }

        if (debug) logger.debug("END RefreshAllWithCollectionSideEffects");
    }
View Full Code Here

        Throwable t1Problem = group.getUncaughtException(T1);
        if (t1Problem != null) {
            if (t1Problem instanceof AssertionFailedError)
                throw (AssertionFailedError)t1Problem;
            else
                throw new JDOFatalException( "Thread "+T1.getName()+" results in exception ", t1Problem );
        }
        Throwable t2Problem = group.getUncaughtException(T2);
        if (t2Problem != null) {
            if (t2Problem instanceof AssertionFailedError)
                throw (AssertionFailedError)t2Problem;
            else
                throw new JDOFatalException( "Thread "+T2.getName()+" results in exception ", t2Problem );
        }

        if (debug) logger.debug ("END RefreshSideEffects");
    }
View Full Code Here

        Throwable t1Problem = group.getUncaughtException(T1);
        if (t1Problem != null) {
            if (t1Problem instanceof AssertionFailedError)
                throw (AssertionFailedError)t1Problem;
            else
                throw new JDOFatalException( "Thread "+T1.getName()+" results in exception ", t1Problem );
        }
        Throwable t2Problem = group.getUncaughtException(T2);
        if (t2Problem != null) {
            if (t2Problem instanceof AssertionFailedError)
                throw (AssertionFailedError)t2Problem;
            else
                throw new JDOFatalException( "Thread "+T2.getName()+" results in exception ", t2Problem );
        }
       
        if (debug) logger.debug ("END RefreshAllNoParameterSideEffects");
    }
View Full Code Here

    /** */
    public TestResult start(String[] args) {
        Test suite = null;
        if ((args == null) || args.length == 0) {
            String conf = System.getProperty("jdo.tck.cfg");
            throw new JDOFatalException(
                "Missing JDO TCK test classes for configuration '" + conf +
                "'. Please check the property 'jdo.tck.classes'.");
        }
        else if (args.length == 1) {
            suite = getTest(args[0]);
View Full Code Here

TOP

Related Classes of javax.jdo.JDOFatalException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.