List of usage examples for java.lang Object Object
@HotSpotIntrinsicCandidate
public Object()
From source file:gov.nih.nci.cabig.ctms.web.WebTestCase.java
@Override protected void setUp() throws Exception { super.setUp(); mockRegistry = new MockRegistry(); servletContext = new MockServletContext(); request = new MockHttpServletRequest(servletContext); response = new MockHttpServletResponse(); errors = new BindException(new Object(), "command"); }
From source file:org.openmrs.web.controller.patient.TribeFormController.java
/** * This is called prior to displaying a form for the first time. It tells Spring the * form/command object to load into the request * //w ww . j a va2s. com * @see org.springframework.web.servlet.mvc.AbstractFormController#formBackingObject(javax.servlet.http.HttpServletRequest) */ protected Object formBackingObject(HttpServletRequest request) throws ServletException { return new Object(); }
From source file:com.bsb.cms.commons.utils.URLUtils.java
public static String getTemplatePath() { if (templateDir == null) { URL url = new Object() { }.getClass().getResource("/template"); String classpath = (new File(url.getFile())).getParentFile().getAbsolutePath(); templateDir = classpath + "/template/"; }//from ww w .j a v a 2s . co m return templateDir; }
From source file:com.github.jinahya.codec.commons.RareEncoderProxyTest.java
@Test public void testAsEncoder() throws EncoderException { final Encoder encoder = (Encoder) RareEncoderProxy.newInstance(); try {// w ww. ja va 2 s . c o m encoder.encode(null); Assert.fail("passed: <Object>encode(null)"); } catch (final NullPointerException npe) { //expected } final Object expected = new Object(); final Object actual = encoder.encode(expected); Assert.assertEquals(actual, expected); }
From source file:com.hm.SSI.dubbo.DubboProvider.java
@Test public void testDubboProvider() throws Exception { System.in.read();/*w w w . j a v a2s . c o m*/ try { //new ClassPathXmlApplicationContext("application-RmiService.xml"); Object lock = new Object(); synchronized (lock) { lock.wait(); } } catch (BeansException e) { // TODO Auto-generated catch block e.printStackTrace(); } catch (InterruptedException e) { // TODO Auto-generated catch block e.printStackTrace(); } }
From source file:com.qrmedia.commons.collections.PairUtilsTest.java
@Test public void toPairAcceptsNullFirstObject() { assertNull(PairUtils.toPair(null, new Object()).getFirstObject()); }
From source file:com.yoncabt.abys.core.util.EBRConf.java
private EBRConf() { reloadLock = new Object(); reload(); }
From source file:io.helixservice.feature.restservice.marshal.JacksonMarshallerUnitTest.java
@Test public void testResponseData() throws JsonProcessingException { Object marshaledObject = new Object(); ObjectMapper objectMapper = mock(ObjectMapper.class); when(objectMapper.writeValueAsString(marshaledObject)).thenReturn("{ json body }"); JacksonMarshaller subject = new JacksonMarshaller(objectMapper); Message message = subject.marshal(marshaledObject); assertEquals("{ json body }", new String(message.getBody())); assertEquals("application/json", message.getContentType()); }
From source file:it.jugpadova.controllers.HomeController.java
@RequestMapping public ModelAndView welcome(HttpServletRequest req, HttpServletResponse res) { Map params = new HashMap(); params.put("something", new Object()); FlashHelper.setRedirectError(req, "flash.TestError"); FlashHelper.setRedirectNotice(req, "flash.TestNotice"); return new ModelAndView("welcome", params); }
From source file:nl.mok.mastersofcode.spectatorclient.controllers.RoundController.java
@RequestMapping(method = RequestMethod.GET, value = "/{id}") public ModelAndView testDashboard(final HttpServletRequest request, @PathVariable int id) { ModelAndView mav = new ModelAndView(); mav.addObject("page", new Object() { public String uri = "/spec/round"; public String redirect = request.getRequestURL().toString(); });/*w w w. java 2 s .c om*/ Round round = DataController.getRoundById(id).get(); mav.addObject("round", round); mav.addObject("teams", DataController.getCompetitionById(round.getCompetition()).get().getTeams()); mav.addObject("currentCompetition", DataController.getCurrentCompetition()); mav.addObject("currentRound", DataController.getCurrentRound()); mav.addObject("newsitems", newsitems); mav.setViewName("round.twig"); return mav; }