Microsoft.Xna.Framework.Content
Class ContentManager

java.lang.Object
  extended by Microsoft.Xna.Framework.Content.ContentManager
All Implemented Interfaces:
IDisposable

public class ContentManager
extends java.lang.Object
implements IDisposable

The ContentManager is the run-time component which loads managed objects from the binary files produced by the design time content pipeline. It also manages the lifespan of the loaded objects, disposing the content manager will also dispose any assets which are themselves IDisposable.

Author:
Halofreak1990

Constructor Summary
ContentManager(IServiceProvider serviceProvider)
           
ContentManager(IServiceProvider serviceProvider, java.lang.String rootDirectory)
           
 
Method Summary
 void Dispose()
          Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
protected  void Dispose(boolean disposing)
           
 java.lang.String getRootDirectory()
           
 IServiceProvider getServiceProvider()
           
<T> T
Load(java.lang.String assetName)
           
 void setRootDirectory(java.lang.String value)
           
 void Unload()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ContentManager

public ContentManager(IServiceProvider serviceProvider)
Parameters:
serviceProvider -
Throws:
ArgumentNullException

ContentManager

public ContentManager(IServiceProvider serviceProvider,
                      java.lang.String rootDirectory)
Parameters:
serviceProvider -
rootDirectory -
Throws:
ArgumentNullException
Method Detail

getRootDirectory

public java.lang.String getRootDirectory()

setRootDirectory

public void setRootDirectory(java.lang.String value)

getServiceProvider

public IServiceProvider getServiceProvider()

Dispose

public void Dispose()
Description copied from interface: IDisposable
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

Specified by:
Dispose in interface IDisposable

Dispose

protected void Dispose(boolean disposing)

Load

public <T> T Load(java.lang.String assetName)
Type Parameters:
T -
Parameters:
assetName -
Returns:
Throws:
ArgumentNullException
ObjectDisposedException

Unload

public void Unload()
Throws:
ObjectDisposedException