Package de.iritgo.aktera.model

Examples of de.iritgo.aktera.model.ModelException


      {
        add(new OutputMessage((Output) oneElement));
      }
      else
      {
        throw new ModelException("Element " + oneElement.getName() + " is of an unknown type: "
                + oneElement.getClass().getName() + "'");
      }
    }

    /* Attributes must be either ResponseElements, or basic Java types */
    String oneAttribName = null;
    Object oneAttribValue = null;

    for (Iterator ia = res.getAttributes().keySet().iterator(); ia.hasNext();)
    {
      oneAttribName = (String) ia.next();
      oneAttribValue = res.getAttribute(oneAttribName);

      if (oneAttribValue instanceof Command)
      {
        setAttribute(oneAttribName, new CommandMessage((Command) oneAttribValue));
      }
      else if (oneAttribValue instanceof Input)
      {
        setAttribute(oneAttribName, new InputMessage((Input) oneAttribValue));
      }
      else if (oneAttribValue instanceof Output)
      {
        setAttribute(oneAttribName, new OutputMessage((Output) oneAttribValue));
      }
      else if (oneAttribValue.getClass().getName().startsWith("java.lang"))
      {
        setAttribute(oneAttribName, oneAttribValue);
      }
      else if (oneAttribValue.getClass().getName().startsWith("java.util"))
      {
        setAttribute(oneAttribName, oneAttribValue);
      }
      else
      {
        throw new ModelException("Attribute '" + oneAttribName + "' of Class '"
                + oneAttribValue.getClass().getName() + "' is not allowed as a ModelResponse attribute");
      }
    }

    Map errs = res.getErrors();
View Full Code Here


          fixedDomain = defaultDomain;
        }
      }
      catch (ConfigurationException x)
      {
        throw new ModelException(x);
      }
    }

    Input loginName = res.createInput("loginName");
View Full Code Here

                }
              }
            }
            catch (PersistenceException x)
            {
              throw new ModelException(x);
            }
          }

          res.addOutput("sessionDisplayName", (String) userEnv.getAttribute("sessionDisplayName"));
          res.addOutput("sessionFirstName", (String) userEnv.getAttribute("sessionFirstName"));
          res.addOutput("sessionLastName", (String) userEnv.getAttribute("sessionLastName"));
          res.addOutput("sessionLoginName", (String) userEnv.getLoginName());

          Output lang = res.createOutput("sessionLanguage");

          lang.setContent(userEnv.getAttribute("sessionLanguage"));
          res.add(lang);
        }
        else
        {
          Output lang = res.createOutput("sessionLanguage");

          lang.setContent(Locale.GERMAN);
          res.add(lang);
        }
      }
      catch (AuthorizationException x)
      {
        throw new ModelException(x);
      }
    }

    return res;
  }
View Full Code Here

        return res;
      }
    }
    else
    {
      throw new ModelException("[Import] Unknown import mode '" + params.mode + "'");
    }
  }
View Full Code Here

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

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

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

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

    if (bean != null)
    {
      return bean;
    }

    throw new ModelException("Unable to find persistent or bean '" + name + "' in persistent descriptor '" + id
            + "'");
  }
View Full Code Here

    if (persistent != null)
    {
      return persistent;
    }

    throw new ModelException("Unable to find persistent '" + name + "' in persistent descriptor '" + 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.