Package org.cast.isi.data

Examples of org.cast.isi.data.ISIPrompt


  @Override
  public boolean isVisible() {
    List<Response> responses = getResponses();
    if (responses.isEmpty())
      return false;
    ISIPrompt prompt = (ISIPrompt) responses.get(0).getPrompt();
    User user = targetUserModel.getObject();
    return !(prompt.isDelayFeedback() && needsReview(prompt, user));
  }
View Full Code Here


    if (collectionName != null)
      c.add(Restrictions.eq("collectionName", collectionName));
    else
      c.add(Restrictions.isNull("collectionName"));

    ISIPrompt p = (ISIPrompt) c.uniqueResult();

    // If it doesn't exist, create it
    if (p == null) {
      p = new ISIPrompt(type);
      if (ce != null)
        p.setContentElement(ce.getObject());
      if (targetUser != null)
        p.setTargetUser(targetUser.getObject());
      if (identifier != null)
        p.setIdentifier(identifier);
      if (collectionName != null) {
        p.setCollectionName(collectionName);
      }
      Databinder.getHibernateSession().save(p)
    }
   
    cwmService.flushChanges();
View Full Code Here

  private Prompt prompt;
 
  @SuppressWarnings({ "unchecked", "rawtypes" })
  @Before
  public void setUp() {
    prompt = new ISIPrompt(PromptType.RESPONSEAREA);
    response1 = makeResponse(prompt);
    response2 = makeResponse(prompt);
    setupInjectedServices();
    wicketTester = new CwmWicketTester(new GuiceInjectedTestApplication(injectionMap));
  }
View Full Code Here

TOP

Related Classes of org.cast.isi.data.ISIPrompt

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.