Examples of Skill


Examples of org.apache.struts2.showcase.model.Skill

    if (skills != null) {
      for (Object val : skills) {
        if (val instanceof Skill) {
          list.add(((Skill) val).getDescription());
        } else {
          Skill skill = skillDao.getSkill((String) val);
          list.add(skill.getDescription());
        }
      }
    }
    return list;
  }
View Full Code Here

Examples of org.apache.struts2.showcase.model.Skill

   * This method is called to allow the action to prepare itself.
   *
   * @throws Exception thrown if a system level exception occurs.
   */
  public void prepare() throws Exception {
    Skill preFetched = (Skill) fetch(getSkillName(), getCurrentSkill());
    if (preFetched != null) {
      setCurrentSkill(preFetched);
    }
  }
View Full Code Here

Examples of org.apache.struts2.showcase.model.Skill

     * creating new objects as necessary
     *
     */
    public JsfEmployeeAction() {
        Employee e = new Employee();
        e.setMainSkill(new Skill());
        setCurrentEmployee(e);
    }
View Full Code Here

Examples of org.apache.struts2.showcase.model.Skill

     * Converting the Skill object list into a map
     */
    public Map<String, String> getAvailableSkills() {
        Map<String, String> map = new HashMap<String, String>();
        for (Object val : skillDao.findAll()) {
            Skill skill = (Skill) val;
            map.put(skill.getDescription(), skill.getName());
        }
        return map;
    }
View Full Code Here

Examples of org.apache.struts2.showcase.model.Skill

        if (skills != null) {
            for (Object val : skills) {
                if (val instanceof Skill) {
                    list.add(((Skill) val).getDescription());
                } else {
                    Skill skill = skillDao.getSkill((String) val);
                    list.add(skill.getDescription());
                }
            }
        }
        return list;
    }
View Full Code Here

Examples of org.apache.struts2.showcase.model.Skill

     * This method is called to allow the action to prepare itself.
     *
     * @throws Exception thrown if a system level exception occurs.
     */
    public void prepare() throws Exception {
        Skill preFetched = (Skill) fetch(getSkillName(), getCurrentSkill());
        if (preFetched != null) {
            setCurrentSkill(preFetched);
        }
    }
View Full Code Here

Examples of org.apache.struts2.showcase.model.Skill

    public Employee setSkills(Employee employee, List skillNames) {
        if (employee!= null && skillNames != null) {
            employee.setOtherSkills(new ArrayList());
            for (int i = 0, j = skillNames.size(); i < j; i++) {
                Skill skill = (Skill) skillDao.get((String) skillNames.get(i));
                employee.getOtherSkills().add(skill);
            }
        }
        return employee;
    }
View Full Code Here

Examples of org.apache.struts2.showcase.model.Skill

   * Creating a default employee and main skill, since the JSF EL can't handle
   * creating new objects as necessary
   */
  public JsfEmployeeAction() {
    Employee e = new Employee();
    e.setMainSkill(new Skill());
    setCurrentEmployee(e);
  }
View Full Code Here

Examples of org.apache.struts2.showcase.model.Skill

   * Converting the Skill object list into a map
   */
  public Map<String, String> getAvailableSkills() {
    Map<String, String> map = new HashMap<String, String>();
    for (Object val : skillDao.findAll()) {
      Skill skill = (Skill) val;
      map.put(skill.getDescription(), skill.getName());
    }
    return map;
  }
View Full Code Here

Examples of org.apache.struts2.showcase.model.Skill

    if (skills != null) {
      for (Object val : skills) {
        if (val instanceof Skill) {
          list.add(((Skill) val).getDescription());
        } else {
          Skill skill = skillDao.getSkill((String) val);
          list.add(skill.getDescription());
        }
      }
    }
    return list;
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.