org.gvsig.tools.dispose
Interface DisposableManager

All Known Implementing Classes:
DefaultDisposableManager

public interface DisposableManager

Manages the use and dispose of Disposable objects.

Author:
2009- César Ordiñana - gvSIG team

Method Summary
 boolean bind(Disposable disposable)
          Registers a disposable as being in use.
 int getBoundDisposableCount()
          Returns the number of Disposable objects pending to be released.
 Set getBoundDisposables()
          Returns a Set of Disposable objects currently bound.
 boolean release(Disposable disposable)
          Marks a disposable as not being used anymore.
 void releaseAll()
          Releases all bound Disposables.
 

Method Detail

bind

boolean bind(Disposable disposable)
Registers a disposable as being in use.

Parameters:
disposable - to bind
Returns:
true if the disposable was not already bound

release

boolean release(Disposable disposable)
Marks a disposable as not being used anymore.

Parameters:
disposable - to release
Returns:
true if the disposable has been finally released

releaseAll

void releaseAll()
                throws BaseException
Releases all bound Disposables.

Throws:
BaseException - if there is an error disposing any of the bound disposables

getBoundDisposableCount

int getBoundDisposableCount()
Returns the number of Disposable objects pending to be released.

Returns:
the number of Disposable objects pending to be released

getBoundDisposables

Set getBoundDisposables()
Returns a Set of Disposable objects currently bound.

Returns:


Copyright © 2004-2011 gvSIG. All Rights Reserved.