Package de.iritgo.aktera.model

Examples of de.iritgo.aktera.model.ModelException


      return res;
    }
    catch (ConfigurationException x)
    {
      throw new ModelException(x);
    }
  }
View Full Code Here


      if (listingOutput != null)
      {
        return (ListingDescriptor) listingOutput.getContent();
      }

      throw new ModelException("[Listing] Unable to find listing model '" + modelName + "'");
    }
    catch (Exception x)
    {
      throw new ModelException("Listing: Unable to create listing from model " + modelName + " (" + x + ")");
    }
  }
View Full Code Here

        sortColumn = sortConfig.getValue(sortConfig.getAttribute("name", null));
      }

      if (listing.getColumn(sortColumn) == null)
      {
        throw new ModelException("Unknown column '" + sortColumn + "' in sort tag for listing '"
                + config.getAttribute("id") + "'");
      }

      listing.setSortColumn(sortColumn, sortOrder);
    }
View Full Code Here

      return starter;
    }
    catch (Exception x)
    {
      throw new ModelException("Exception loading starter (" + x + ")");
    }
  }
View Full Code Here

      return starter.execute(request);
    }
    catch (Exception x)
    {
      x.printStackTrace(System.err);
      throw new ModelException(x);
    }
  }
View Full Code Here

    {
      serverSocket = new ServerSocket(myConfig.getAttributeAsInteger("port"));
    }
    catch (Exception e)
    {
      throw new ModelException("Unable to instantiate ServerSocket on configured port", e);
    }
  }
View Full Code Here

  public KeelResponse execute(KeelRequest request) throws ModelException
  {
    if (getContainer() == null)
    {
      throw new ModelException("Initialization failed - container is null");
    }

    ModelRequest req = null;

    try
    {
      Object o = getContainer().getService(ModelRequest.ROLE);

      if (o == null)
      {
        getLogger().error("Service returned was null");
      }

      req = (ModelRequest) o;
    }
    catch (Exception se)
    {
      getLogger().error("Service Exception:", se);
      throw new ModelException("Service Exception getting request", se);
    }

    try
    {
      req.copyFrom(request);
    }
    catch (Exception ee)
    {
      getLogger().error("Error copying ModelRequestMessage to ModelRequest", ee);
    }

    //Set the context to that provided in the original request
    if (req instanceof KeelContextualizable)
    {
      try
      {
        ((KeelContextualizable) req).setKeelContext(getContext(req));
      }
      catch (ContextException e)
      {
        throw new ModelException("Unable to set keel context on ModelRequest", e);
      }
    }

    getLogger().debug("Executing model " + req.getModel());
View Full Code Here

  public KeelResponse execute(KeelRequest request) throws ModelException
  {
    if (getContainer() == null)
    {
      throw new ModelException("Initialization failed - container is null");
    }

    ModelRequest req = null;

    try
    {
      Object o = getContainer().getService(ModelRequest.ROLE);

      if (o == null)
      {
        getLogger().error("Service returned was null");
      }

      req = (ModelRequest) o;
    }
    catch (Exception se)
    {
      getLogger().error("Service Exception:", se);
      throw new ModelException("Service Exception getting request", se);
    }

    try
    {
      req.copyFrom(request);
    }
    catch (Exception ee)
    {
      getLogger().error("Error copying ModelRequestMessage to ModelRequest", ee);
    }

    // Set the context to that provided in the original request
    if (req instanceof KeelContextualizable)
    {
      try
      {
        ((KeelContextualizable) req).setKeelContext(getContext(req));
      }
      catch (ContextException e)
      {
        throw new ModelException("Unable to set keel context on ModelRequest", e);
      }
    }

    getLogger().debug("Executing model " + req.getModel());
View Full Code Here

   */
  public void addError(String errorName, String errorMessage)
  {
    assert errorName != null;

    ModelException ne = new ModelException("Application Error");

    ne.fillInStackTrace();

    Throwable existing = (Throwable) throwables.get(errorName);

    if ((existing != null) && (! existing.equals(ne)))
    {
View Full Code Here

    {
      readConfig(req);
    }
    catch (ConfigurationException x)
    {
      throw new ModelException(x);
    }

    Object id = req.getParameter(keyName);

    if (StringTools.isTrimEmpty(id))
View Full Code Here

TOP

Related Classes of de.iritgo.aktera.model.ModelException

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.