Spring Framework StringArrayPropertyEditor - top ranked examples from Open Source projects

These code examples were ranked by Codota’s semantic indexing as the best open source examples for Spring Framework StringArrayPropertyEditor class.

This code example shows how to use the following methods:
	Map propertyEditors = modelEditor.getCacheModelPropertyEditors();
	assertEquals(1, propertyEditors.size());
	assertSame(StringArrayPropertyEditor.class, propertyEditors.get("cacheNames").getClass());
  } 
 
  public void testIsSerializableCacheElementRequired() { 
    assertFalse(facade.isSerializableCacheElementRequired());
  } 
 
  public void testOnFlushCache() { 
    setUpCache(); 
    cache.put(ENTRY_KEY, ENTRY_VALUE);
 
    GigaSpacesFlushingModel model = new GigaSpacesFlushingModel(
        new String[] { CACHE_NAME });
    facade.onFlushCache(model);
    assertValueIsNotInCache(); 
    tearDownCache(); 
  } 
 
5
CodeRank
Experience pair programming with AI  Get Codota for Java
This code example shows how to use the following methods:
	/** 
	 * @see org.springmodules.cache.provider.CacheProviderFacade#getFlushingModelEditor() 
	 */ 
	public PropertyEditor getFlushingModelEditor() {
		Map propertyEditors = new HashMap();
		propertyEditors.put("cacheNames", new StringArrayPropertyEditor());
 
		ReflectionCacheModelEditor editor = new ReflectionCacheModelEditor();
		editor.setCacheModelClass(CoherenceFlushingModel.class);
		editor.setCacheModelPropertyEditors(propertyEditors);
		return editor;
	} 
 
	/** 
	 * @see AbstractCacheProviderFacade#isSerializableCacheElementRequired() 
	 */ 
	protected boolean isSerializableCacheElementRequired() { 
		return false; 
	} 
 
5
CodeRank
Experience pair programming with AI  Get Codota for Java
This code example shows how to use the following methods:
 
	public void testGetFlushingModelEditor() { 
		PropertyEditor editor = facade.getFlushingModelEditor();
 
		assertNotNull(editor);
		assertEquals(ReflectionCacheModelEditor.class, editor.getClass());
 
		ReflectionCacheModelEditor modelEditor = (ReflectionCacheModelEditor) editor;
		assertEquals(CoherenceFlushingModel.class, modelEditor.getCacheModelClass());
		Map propertyEditors = modelEditor.getCacheModelPropertyEditors();
		assertEquals(1, propertyEditors.size());
		assertSame(StringArrayPropertyEditor.class, propertyEditors.get("cacheNames").getClass());
	} 
 
	public void testIsSerializableCacheElementRequired() { 
		assertFalse(facade.isSerializableCacheElementRequired());
	} 
 
	public void testOnFlushCache() { 
		setUpCache(); 
5
CodeRank
Experience pair programming with AI  Get Codota for Java
This code example shows how to use the following methods:
	/** 
	 * @see org.springmodules.cache.provider.CacheProviderFacade#getFlushingModelEditor() 
	 */ 
	public PropertyEditor getFlushingModelEditor() {
		Map propertyEditors = new HashMap();
		propertyEditors.put("cacheNames", new StringArrayPropertyEditor());
 
		ReflectionCacheModelEditor editor = new ReflectionCacheModelEditor();
		editor.setCacheModelClass(JbossCacheFlushingModel.class);
		editor.setCacheModelPropertyEditors(propertyEditors);
		return editor;
	} 
 
	/** 
	 * Sets the JBossCache cache manager to use. 
	 * 
	 * @param newCacheManager the new cache manager 
	 */ 
	public void setCacheManager(TreeCache newCacheManager) {
		cacheManager = newCacheManager;
5
CodeRank
Experience pair programming with AI  Get Codota for Java
This code example shows how to use the following methods:
	/** 
	 * @see org.springmodules.cache.provider.CacheProviderFacade#getFlushingModelEditor() 
	 */ 
	public PropertyEditor getFlushingModelEditor() {
		Map propertyEditors = new HashMap();
		propertyEditors.put("cacheNames", new StringArrayPropertyEditor());
 
		ReflectionCacheModelEditor editor = new ReflectionCacheModelEditor();
		editor.setCacheModelClass(OsCacheFlushingModel.class);
		editor.setCacheModelPropertyEditors(propertyEditors);
		return editor;
	} 
 
	/** 
	 * Sets the OSCache cache manager to use. 
	 * 
	 * @param newCacheManager the new cache manager 
	 */ 
	public void setCacheManager(GeneralCacheAdministrator newCacheManager) {
		cacheManager = newCacheManager;
5
CodeRank
Experience pair programming with AI  Get Codota for Java
This code example shows how to use the following methods:
	/** 
	 * @see org.springmodules.cache.provider.CacheProviderFacade#getFlushingModelEditor() 
	 */ 
	public PropertyEditor getFlushingModelEditor() {
		Map propertyEditors = new HashMap();
		propertyEditors.put("cacheNames", new StringArrayPropertyEditor());
 
		ReflectionCacheModelEditor editor = new ReflectionCacheModelEditor();
		editor.setCacheModelClass(GigaSpacesFlushingModel.class);
		editor.setCacheModelPropertyEditors(propertyEditors);
		return editor;
	} 
 
	/** 
	 * Returns a GigaSpaces cache from the cache manager. 
	 * 
	 * @param model the model containing the name of the cache to retrieve 
	 * @return the cache retrieved from the cache manager 
	 * @throws CacheNotFoundException if the cache does not exist 
	 * @throws CacheAccessException   wrapping any unexpected exception thrown by the cache 
5
CodeRank
Experience pair programming with AI  Get Codota for Java
This code example shows how to use the following methods:
 
		ReflectionCacheModelEditor modelEditor = (ReflectionCacheModelEditor) editor;
		assertEquals(JbossCacheCachingModel.class, modelEditor.getCacheModelClass());
		assertNull(modelEditor.getCacheModelPropertyEditors());
	} 
 
	public void testGetFlushingModelEditor() { 
		PropertyEditor editor = cacheFacade.getFlushingModelEditor();
 
		assertNotNull(editor);
		assertEquals(ReflectionCacheModelEditor.class, editor.getClass());
 
		ReflectionCacheModelEditor modelEditor = (ReflectionCacheModelEditor) editor;
		assertEquals(JbossCacheFlushingModel.class, modelEditor
				.getCacheModelClass()); 
		Map propertyEditors = modelEditor.getCacheModelPropertyEditors();
		assertEquals(1, propertyEditors.size());
		assertSame(StringArrayPropertyEditor.class, propertyEditors.get("cacheNames").getClass());
	} 
 
5
CodeRank
Experience pair programming with AI  Get Codota for Java
This code example shows how to use the following methods:
	/** 
	 * @see org.springmodules.cache.provider.CacheProviderFacade#getFlushingModelEditor() 
	 */ 
	public PropertyEditor getFlushingModelEditor() {
		Map propertyEditors = new HashMap();
		propertyEditors.put("cacheNames", new StringArrayPropertyEditor());
 
		ReflectionCacheModelEditor editor = new ReflectionCacheModelEditor();
		editor.setCacheModelClass(EhCacheFlushingModel.class);
		editor.setCacheModelPropertyEditors(propertyEditors);
		return editor;
	} 
 
	/** 
	 * Sets the EHCache cache manager to use. 
	 * 
	 * @param newCacheManager the new cache manager 
	 */ 
	public void setCacheManager(CacheManager newCacheManager) {
		cacheManager = newCacheManager;
5
CodeRank
Experience pair programming with AI  Get Codota for Java
This code example shows how to use the following methods:
	public EhCacheFacadeTests(String name) {
		super(name);
	} 
 
	/** 
	 * Verifies that the method 
	 * <code>{@link EhCacheFacade#modelValidator()}</code> returns an an 
	 * instance of <code>{@link EhCacheModelValidator}</code> not equal to 
	 * <code>null</code>. 
	 */ 
	public void testGetCacheModelValidator() { 
		CacheModelValidator validator = cacheFacade.modelValidator();
		assertNotNull(validator);
		assertEquals(EhCacheModelValidator.class, validator.getClass());
	} 
 
	public void testGetCacheWhenCacheAccessThrowsException() { 
		setUpCache(); 
 
		// we can't mock the cache manager since it doesn't have a public 
4
CodeRank
Experience pair programming with AI  Get Codota for Java