Package org.apache.wicket

Examples of org.apache.wicket.WicketRuntimeException


      {
        ret = getMethod.invoke(object, (Object[])null);
      }
      catch (InvocationTargetException ex)
      {
        throw new WicketRuntimeException("Error calling method: " + getMethod +
          " on object: " + object, ex.getCause());
      }
      catch (Exception ex)
      {
        throw new WicketRuntimeException("Error calling method: " + getMethod +
          " on object: " + object, ex);
      }
      return ret;
    }
View Full Code Here


        {
          setMethod.invoke(object, converted);
        }
        catch (InvocationTargetException ex)
        {
          throw new WicketRuntimeException("Error calling method: " + setMethod +
            " on object: " + object, ex.getCause());
        }
        catch (Exception ex)
        {
          throw new WicketRuntimeException("Error calling method: " + setMethod +
            " on object: " + object, ex);
        }
      }
      else if (field != null)
      {
        try
        {
          field.set(object, converted);
        }
        catch (Exception ex)
        {
          throw new WicketRuntimeException("Error setting field: " + field +
            " on object: " + object, ex);
        }
      }
      else
      {
        throw new WicketRuntimeException("no set method defined for value: " + value +
          " on object: " + object + " while respective getMethod being " +
          getMethod.getName());
      }
    }
View Full Code Here

      {
        return field.get(object);
      }
      catch (Exception ex)
      {
        throw new WicketRuntimeException("Error getting field value of field " + field +
          " from object " + object, ex);
      }
    }
View Full Code Here

      {
        field.set(object, value);
      }
      catch (Exception ex)
      {
        throw new WicketRuntimeException("Error setting field value of field " + field +
          " on object " + object + ", value " + value, ex);
      }
    }
View Full Code Here

          out.toByteArray()), replacedObjects, object.getClass().getClassLoader());
        return (T) ois.readObject();
      }
      catch (ClassNotFoundException | IOException e)
      {
        throw new WicketRuntimeException("Internal error cloning object", e);
      }
    }
  }
View Full Code Here

        }
      });
    }
    catch (IOException e1)
    {
      throw new WicketRuntimeException(e1);
    }
    if (copied[0] == false)
    {
      response.write(stream.toByteArray());
    }
View Full Code Here

        Class<?> c = WicketObjects.resolveClass(className);
        return (T) c.newInstance();
      }
      catch (Exception e)
      {
        throw new WicketRuntimeException("Unable to create " + className, e);
      }
    }
    return null;
  }
View Full Code Here

      {
        stream.write(data);
      }
      catch (IOException e)
      {
        throw new WicketRuntimeException(e);
      }
    }
View Full Code Here

      {
        stream.write(data, offset, length);
      }
      catch (Exception e)
      {
        throw new WicketRuntimeException(e);
      }
    }
View Full Code Here

    super.onBind();

    Component component = getComponent();
    if (!(component instanceof FormComponent))
    {
      throw new WicketRuntimeException("Behavior " + getClass().getName()
        + " can only be added to an instance of a FormComponent");
    }

    checkComponent((FormComponent<?>)component);
  }
View Full Code Here

TOP

Related Classes of org.apache.wicket.WicketRuntimeException

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.