Package com.aesthete.swingobjects.fw.common

Examples of com.aesthete.swingobjects.fw.common.SwingObjectsException


            break;
          }
        }
      }
    } catch (Exception e) {
      throw new SwingObjectsException("error.severe.SF001", ErrorSeverity.SEVERE, null, e, ExcelHelper.class);
    }
  }
View Full Code Here


      email.send();
    }catch(SwingObjectsException e) {
      throw e;
    }catch(EmailException e) {
      if(e.getCause() instanceof AuthenticationFailedException) {
        throw new SwingObjectsException("error.email.authfailed", ErrorSeverity.ERROR, null, EmailHelper.class);
      }
      throw new SwingObjectsException("error.common.emailnotsent", ErrorSeverity.SEVERE, null, e, EmailHelper.class);
    } catch (Exception e) {
      throw new SwingObjectsException("error.common.emailnotsent", ErrorSeverity.SEVERE, null, e, EmailHelper.class);
    }
  }
View Full Code Here

        } else {
          email.addCc(emailDto.getCc().trim());
        }
      }
    }catch(EmailException e) {
      throw new SwingObjectsException("error.common.email.checkto", ErrorSeverity.ERROR, null, EmailHelper.class);
    }

    email.setSubject(emailDto.getSubj()==null?"":emailDto.getSubj());
  }
View Full Code Here

        }else if(start) {
          builder.append(line+"\n");
        }
      }
    } catch (Exception e) {
      throw new SwingObjectsException("error.severe.SF001", ErrorSeverity.SEVERE, null, e, CommonUtilities.class);
    } finally {
      try {
        try {
          if (buffer != null) {
            buffer.close();
          }
        } finally {
          if (reader != null) {
            reader.close();
          }
        }
      } catch (Exception e) {
        throw new SwingObjectsException("error.severe.SF001", ErrorSeverity.SEVERE, null, e, CommonUtilities.class);
      }
    }
    return builder.toString();
  }
View Full Code Here

        WaitDialog.setWaitDialogGif(props.getWaitDialogGif());
      }
    } catch (SwingObjectsException e) {
      throw e;
    } catch (Exception e) {
      throw new SwingObjectsException("error.severe.SF001", ErrorSeverity.SEVERE, null, e, SwingObjectsInit.class);
    }
  }
View Full Code Here

            for (int i = 0; i < frameArray.length; i++) {
                Frame frame = frameArray[i];
                frameConfigMap.put(frame.getId(),frame);
            }
        }catch(Exception e){
            throw new SwingObjectsException("error.severe.SF001",ErrorSeverity.SEVERE,
                    "Error while parsing frames.xml", e,FrameFactory.class);
        }
    }
View Full Code Here

                  Frame frame=frameConfigMap.get(frameFactory.toString());
                    comp = (Component)getInstance(frame.getFrameClass(),objs);
                    comp.setName(frameSetId);
                    frameSetMap.put(frameFactory, comp);
                } catch (Exception ex) {
                    new SwingObjectsException("error.severe.SF001",ErrorSeverity.SEVERE,"Exception while getting frame "+frameFactory,(Exception)ex.getCause(),FrameFactory.class);
                    logger.error("Unable to obtain frame.. so exiting!",ex);
                    System.exit(1);
                }
            }
            return comp;
View Full Code Here

            for (int i = 0; i < actions.length; i++) {
                ActionEntry actionEntry = actions[i];
                swingConfigMap.put(String.valueOf(actionEntry.getId()), actionEntry);
            }
        }catch(Exception e){
            throw new SwingObjectsException("error.severe.SF001",ErrorSeverity.SEVERE,
                    "Error while parsing swing-config.xml",e,SwingActionFactory.class);
        }
    }
View Full Code Here

            MethodUtils.invokeMethod(obj, modelClassMethod, null);
        } catch(InvocationTargetException e){
            if(e.getCause() instanceof SwingObjectsException){
                throw (SwingObjectsException)e.getCause();
            }else{
                throw new SwingObjectsException("error.severe.SF001",ErrorSeverity.SEVERE,
                        "Runtime exception in model - Error caught while trying to invoke method "+modelClassMethod+" on "+obj,
                        (Exception)e.getCause(), SwingActionFactory.class);
            }
        } catch(Exception e){
                throw new SwingObjectsException("error.severe.SF001",ErrorSeverity.SEVERE,
                        "Error caught while trying to invoke method "+modelClassMethod+" on "+obj,
                        e, SwingActionFactory.class);
        }
    }
View Full Code Here

    try {
      source = new FileInputStream(fromFile).getChannel();
      destination = new FileOutputStream(toFile).getChannel();
      destination.transferFrom(source, 0, source.size());
    }catch(Exception e){
      throw new SwingObjectsException("error.severe.SF001", ErrorSeverity.SEVERE,
          null,e, FileHelper.class);
    }finally {
      try {
        try {
          if(source != null) {
            source.close();
          }
        } finally {
          if(destination != null) {
            destination.close();
          }
        }
      } catch (Exception e) {
        throw new SwingObjectsException("error.severe.SF001", ErrorSeverity.SEVERE, null, e, FileHelper.class);
      }
    }
  }
View Full Code Here

TOP

Related Classes of com.aesthete.swingobjects.fw.common.SwingObjectsException

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.