001/* 002 * Shredzone Commons 003 * 004 * Copyright (C) 2012 Richard "Shred" Körber 005 * http://commons.shredzone.org 006 * 007 * This program is free software: you can redistribute it and/or modify 008 * it under the terms of the GNU Library General Public License as 009 * published by the Free Software Foundation, either version 3 of the 010 * License, or (at your option) any later version. 011 * 012 * This program is distributed in the hope that it will be useful, 013 * but WITHOUT ANY WARRANTY; without even the implied warranty of 014 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 015 * GNU General Public License for more details. 016 * 017 * You should have received a copy of the GNU Library General Public License 018 * along with this program. If not, see <http://www.gnu.org/licenses/>. 019 */ 020 021package org.shredzone.commons.view.exception; 022 023import javax.annotation.ParametersAreNonnullByDefault; 024 025import org.shredzone.commons.view.ViewContext; 026 027/** 028 * This exception is thrown when an error happened because {@link ViewContext} was unable 029 * to return the requested data. 030 * 031 * @author Richard "Shred" Körber 032 */ 033@ParametersAreNonnullByDefault 034public class ViewContextException extends ViewException { 035 private static final long serialVersionUID = -1796171034784340995L; 036 037 /** 038 * Creates a new {@link ViewContextException}. 039 */ 040 public ViewContextException() { 041 super(); 042 } 043 044 /** 045 * Creates a new {@link ViewContextException}. 046 * 047 * @param msg 048 * Reason for the failure 049 */ 050 public ViewContextException(String msg) { 051 super(msg); 052 } 053 054 /** 055 * Creates a new {@link ViewContextException}. 056 * 057 * @param cause 058 * Exception that caused the failure 059 */ 060 public ViewContextException(Throwable cause) { 061 super(cause); 062 } 063 064 /** 065 * Creates a new {@link ViewContextException}. 066 * 067 * @param msg 068 * Reason for the failure 069 * @param cause 070 * Exception that caused the failure 071 */ 072 public ViewContextException(String msg, Throwable cause) { 073 super(msg, cause); 074 } 075 076}