Package java.util

Examples of java.util.Map


  @Test
  public void testException() throws Exception
  {

    View view = createStrictMock(View.class);
    Map model = createStrictMock(Map.class);
    ActionContext context = createStrictMock(ActionContext.class);
    HttpServletRequest request = createStrictMock(HttpServletRequest.class);
    HttpServletResponse response = createStrictMock(HttpServletResponse.class);

    SpringRenderingViewAdapter va = new SpringRenderingViewAdapter(view, model);
View Full Code Here


    CreateAction createAction = getCreateAction(actionCreator);
    ServletActionContext actionContext = getActionContext();
    ActionConfig actionConfig = newMock(ActionConfig.class);
    ModuleConfig moduleConfig = newMock(ModuleConfig.class);
    ActionServlet servlet = newMock(ActionServlet.class);
    Map applicationScope = newMock(Map.class);
    Map actions = new HashMap();
    Action action = new Action();
   
    expect(actionConfig.getModuleConfig()).andReturn(moduleConfig);
    expect(moduleConfig.getPrefix()).andReturn("prefix");
    expect(actionContext.getApplicationScope()).andReturn(applicationScope);
    expect(applicationScope.get("actionsprefix")).andReturn(actions);
    expect(actionCreator.createAction(String.class)).andReturn(action);
    expect(actionContext.getActionServlet()).andReturn(servlet);

    replayMocks();
    createAction.getAction(actionContext, "java.lang.String", actionConfig);
    verifyMocks();
   
    assertEquals(1, actions.size());
  }
View Full Code Here

        }
        return result;
    }

    public Map<Event, Assignment> createTransformerMap(Collection<Event> input) {
        Map map = FastMap.newInstance();

        for (Event ev : input) {
            map.put(ev, new Assignment(ev, ev.getStart()));
        }
        return map;
    }
View Full Code Here

    EndpointReference endpoint = EndpointFactory.convert(qName, element);
    return endpoint;
  }

  public Map<?,?> getConfigLookup(EndpointReference epr) {
    Map result = null;

    if(epr instanceof MutableEndpoint)
    {
      result = ((MutableEndpoint)epr).toMap();
    }
View Full Code Here

    BindableBean form = new BindableBean();
    Collection collection = new ArrayList();
    collection.add(new DomainClass(1));
    collection.add(new DomainClass(3));
    collection.add(new DomainClass(4));
    Map map = handler.getPropertyAsMap(collection);
    form.setLookupMap(map);

    TargetBean targetBean = new TargetBean();
    form.setTargetBean(targetBean);
    targetBean.setDomainClass(new DomainClass(4));
View Full Code Here

  @Test
  public void testEmptyMapBindOutwards()
  {

    BindableBean form = new BindableBean();
    Map map = handler.getPropertyAsMap(new HashMap());
    form.setLookupMap(map);

    TargetBean targetBean = new TargetBean();
    form.setTargetBean(targetBean);
    targetBean.setDomainClass(new DomainClass(4));
View Full Code Here

    BindableBean form = new BindableBean();
    Collection collection = new ArrayList();
    collection.add(new DomainClass(1));
    collection.add(new DomainClass(3));
    collection.add(new DomainClass(4));
    Map map = handler.getPropertyAsMap(collection);
    form.setLookupMap(map);

    TargetBean targetBean = new TargetBean();
    // form.setTargetBean(targetBean);
    targetBean.setDomainClass(new DomainClass(4));
View Full Code Here

    BindableBean form = new BindableBean();
    Collection collection = new ArrayList();
    collection.add(new DomainClass(1));
    collection.add(new DomainClass(3));
    collection.add(new DomainClass(4));
    Map map = handler.getPropertyAsMap(collection);
    form.setLookupMap(map);

    TargetBean targetBean = new TargetBean();
    form.setTargetBean(targetBean);
View Full Code Here

    BindableBean form = new BindableBean();
    Collection collection = new ArrayList();
    collection.add(new DomainClass(1));
    collection.add(new DomainClass(3));
    collection.add(new DomainClass(4));
    Map map = handler.getPropertyAsMap(collection);
    form.setLookupMap(map);

    TargetBean targetBean = new TargetBean();
    // form.setTargetBean(targetBean);
View Full Code Here

    BindableBean form = new BindableBean();
    Collection collection = new ArrayList();
    collection.add(new DomainClass(1));
    collection.add(new DomainClass(3));
    collection.add(new DomainClass(4));
    Map map = handler.getPropertyAsMap(collection);
    form.setLookupMap(map);

    TargetBean targetBean = new TargetBean();
    form.setTargetBean(targetBean);
View Full Code Here

TOP

Related Classes of java.util.Map

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.