Package javax.ejb

Examples of javax.ejb.EJBException.initCause()


     
      throw exn;
    }
    else {
      RuntimeException exn = new EJBException();
      exn.initCause(e);
     
      throw exn;
    }
  }
View Full Code Here


        }

        if( t != null ) {
            if( t instanceof java.rmi.RemoteException ) {
                EJBException ejbEx = new EJBException();
                ejbEx.initCause(t);
                throw ejbEx;
            } else {
                throw t;
            }
        }
View Full Code Here

            timedObjectPrimaryKey_  = blob.getTimedObjectPrimaryKey(cl);
            info_ = blob.getInfo(cl);
            blobLoaded_ = true;
        } catch(Exception e) {
            EJBException ejbEx = new EJBException();
            ejbEx.initCause(e);
            throw ejbEx;
        }
    }

    public void setEntityContext(EntityContext context) {
View Full Code Here

        try {
            timerId = timerService_.createTimer
                (containerId_, getTimedObjectPrimaryKey(), duration, 0, info);
        } catch(CreateException ce) {           
            EJBException ejbEx = new EJBException();
            ejbEx.initCause(ce);
            throw ejbEx;           
        }

        return new TimerWrapper(timerId, timerService_);
    }
View Full Code Here

            timerId = timerService_.createTimer
                (containerId_, getTimedObjectPrimaryKey(), initialDuration,
                 intervalDuration, info);
        } catch(CreateException ce) {
            EJBException ejbEx = new EJBException();
            ejbEx.initCause(ce);
            throw ejbEx;                      
        }

        return new TimerWrapper(timerId, timerService_);
    }
View Full Code Here

            timerId = timerService_.createTimer(containerId_,
                                                getTimedObjectPrimaryKey(),
                                                expiration, 0, info);
        } catch(CreateException ce) {
            EJBException ejbEx = new EJBException();
            ejbEx.initCause(ce);
            throw ejbEx;          
        }

        return new TimerWrapper(timerId, timerService_);
    }
View Full Code Here

            timerId = timerService_.createTimer(containerId_,
                getTimedObjectPrimaryKey(), initialExpiration,
                intervalDuration, info);
        } catch(CreateException e) {
            EJBException ejbEx = new EJBException();
            ejbEx.initCause(e);
            throw ejbEx;                      
        }

        return new TimerWrapper(timerId, timerService_);
    }
View Full Code Here

            try {
                timerIds = timerService_.getTimerIds
                    (containerId_,  getTimedObjectPrimaryKey());
            } catch(FinderException fe) {
                EJBException ejbEx = new EJBException();
                ejbEx.initCause(fe);
                throw ejbEx;                        
            }
        }
                                                       
        Collection timerWrappers = new HashSet();
View Full Code Here

                }
            } else if (inv.exception instanceof Exception) {
                throw inv.exception;
            } else {
                EJBException ejbEx = new EJBException();
                ejbEx.initCause(inv.exception);
                throw ejbEx;
            }
        }
        return returnValue;
        } finally {
View Full Code Here

    /**
     * Create EJBException using the exception that is passed in
     */
    private EJBException createEJBException( Exception ex ) {
        EJBException ejbEx = new EJBException();
        ejbEx.initCause(ex);
        return ejbEx;
    }

    /**
     * Provide a count of timers owned by each server
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.