KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > mule > impl > space > VMSpaceFactory


1 /*
2  * $Id: VMSpaceFactory.java 3865 2006-11-09 17:11:08Z Lajos $
3  * --------------------------------------------------------------------------------------
4  * Copyright (c) MuleSource, Inc. All rights reserved. http://www.mulesource.com
5  *
6  * The software in this package is published under the terms of the MuleSource MPL
7  * license, a copy of which has been included with this distribution in the
8  * LICENSE.txt file.
9  */

10
11 package org.mule.impl.space;
12
13 import org.mule.util.queue.MemoryPersistenceStrategy;
14
15 /**
16  * An in-memory space that is not persistent. Useful for testing or where the space
17  * information is not mission critical.
18  */

19 public class VMSpaceFactory extends DefaultSpaceFactory
20 {
21
22     public VMSpaceFactory()
23     {
24         super();
25     }
26
27     public VMSpaceFactory(boolean enableMonitorEvents)
28     {
29         super(enableMonitorEvents);
30         setPersistenceStrategy(new MemoryPersistenceStrategy());
31     }
32
33     public VMSpaceFactory(boolean enableMonitorEvents, int capacity)
34     {
35         super(enableMonitorEvents, capacity);
36         setPersistenceStrategy(new MemoryPersistenceStrategy());
37     }
38
39     public VMSpaceFactory(boolean enableMonitorEvents, boolean enableCaching)
40     {
41         super(enableMonitorEvents);
42         setPersistenceStrategy(new MemoryPersistenceStrategy());
43         setEnableCaching(enableCaching);
44     }
45
46     public VMSpaceFactory(boolean enableMonitorEvents, int capacity, boolean enableCaching)
47     {
48         super(enableMonitorEvents, capacity);
49         setPersistenceStrategy(new MemoryPersistenceStrategy());
50         setEnableCaching(enableCaching);
51     }
52
53 }
54
Popular Tags