org.codehaus.wadi.impl
Class DiscStore

java.lang.Object
  extended byorg.codehaus.wadi.impl.DiscStore
All Implemented Interfaces:
Config, DiscMotableConfig, Store, StoreMotableConfig

public class DiscStore
extends Object
implements Store, DiscMotableConfig


Nested Class Summary
 
Nested classes inherited from class org.codehaus.wadi.Store
Store.Putter
 
Field Summary
protected  DirectByteBufferCache _cache
           
protected  File _dir
           
protected  Log _log
           
protected  boolean _reusingStore
           
protected  Streamer _streamer
           
protected  boolean _useNIO
           
 
Constructor Summary
DiscStore(Streamer streamer, File dir, boolean useNIO, boolean reusingStore)
           
 
Method Summary
 void clean()
           
 StoreMotable create()
           
 String getDescription()
           
 File getDirectory()
           
 boolean getReusingStore()
           
 String getStartInfo()
           
 String getSuffix()
           
 boolean getUseNIO()
           
 void load(Store.Putter putter, boolean accessOnLoad)
           
 void put(ByteBuffer buffer)
           
 ByteBuffer take(int size)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_log

protected final Log _log

_streamer

protected final Streamer _streamer

_dir

protected final File _dir

_useNIO

protected final boolean _useNIO

_cache

protected final DirectByteBufferCache _cache

_reusingStore

protected final boolean _reusingStore
Constructor Detail

DiscStore

public DiscStore(Streamer streamer,
                 File dir,
                 boolean useNIO,
                 boolean reusingStore)
          throws Exception
Method Detail

clean

public void clean()
Specified by:
clean in interface Store

load

public void load(Store.Putter putter,
                 boolean accessOnLoad)
Specified by:
load in interface Store

create

public StoreMotable create()
Specified by:
create in interface Store

getStartInfo

public String getStartInfo()
Specified by:
getStartInfo in interface Store

getDescription

public String getDescription()
Specified by:
getDescription in interface Store

getDirectory

public File getDirectory()
Specified by:
getDirectory in interface DiscMotableConfig

getSuffix

public String getSuffix()
Specified by:
getSuffix in interface DiscMotableConfig

getUseNIO

public boolean getUseNIO()
Specified by:
getUseNIO in interface StoreMotableConfig

take

public ByteBuffer take(int size)
Specified by:
take in interface DiscMotableConfig

put

public void put(ByteBuffer buffer)
Specified by:
put in interface DiscMotableConfig

getReusingStore

public boolean getReusingStore()
Specified by:
getReusingStore in interface DiscMotableConfig


Copyright © 2004-2008 Core Developers Network Ltd.. All Rights Reserved.