Você não pode selecionar mais de 25 tópicos Os tópicos devem começar com uma letra ou um número, podem incluir traços ('-') e podem ter até 35 caracteres.

SystemMessageException.java 1.8KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. /*
  2. * Copyright 2000-2018 Vaadin Ltd.
  3. *
  4. * Licensed under the Apache License, Version 2.0 (the "License"); you may not
  5. * use this file except in compliance with the License. You may obtain a copy of
  6. * the License at
  7. *
  8. * http://www.apache.org/licenses/LICENSE-2.0
  9. *
  10. * Unless required by applicable law or agreed to in writing, software
  11. * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
  12. * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
  13. * License for the specific language governing permissions and limitations under
  14. * the License.
  15. */
  16. package com.vaadin.server;
  17. @SuppressWarnings("serial")
  18. public class SystemMessageException extends RuntimeException {
  19. /**
  20. * Cause of the method exception
  21. */
  22. private Throwable cause;
  23. /**
  24. * Constructs a new <code>SystemMessageException</code> with the specified
  25. * detail message.
  26. *
  27. * @param msg
  28. * the detail message.
  29. */
  30. public SystemMessageException(String msg) {
  31. super(msg);
  32. }
  33. /**
  34. * Constructs a new <code>SystemMessageException</code> with the specified
  35. * detail message and cause.
  36. *
  37. * @param msg
  38. * the detail message.
  39. * @param cause
  40. * the cause of the exception.
  41. */
  42. public SystemMessageException(String msg, Throwable cause) {
  43. super(msg, cause);
  44. }
  45. /**
  46. * Constructs a new <code>SystemMessageException</code> from another
  47. * exception.
  48. *
  49. * @param cause
  50. * the cause of the exception.
  51. */
  52. public SystemMessageException(Throwable cause) {
  53. this.cause = cause;
  54. }
  55. /**
  56. * @see java.lang.Throwable#getCause()
  57. */
  58. @Override
  59. public Throwable getCause() {
  60. return cause;
  61. }
  62. }