cpw.mods.fml.common
Interface ModContainer

All Known Implementing Classes:
DummyModContainer, FMLDummyContainer, FMLModContainer, ForgeDummyContainer, InjectedModContainer, ModLoaderModContainer

public interface ModContainer

The container that wraps around mods in the system.

The philosophy is that individual mod implementation technologies should not impact the actual loading and management of mod code. This interface provides a mechanism by which we can wrap actual mod code so that the loader and other facilities can treat mods at arms length.

Author:
cpw

Method Summary
 void bindMetadata(MetadataCollection mc)
          Attach this mod to it's metadata from the supplied metadata collection
 List<ArtifactVersion> getDependants()
          A list of modids that should be loaded after this one.
 List<ArtifactVersion> getDependencies()
          A list of modids that should be loaded prior to this one.
 String getDisplayVersion()
           
 ModMetadata getMetadata()
          The metadata for this mod
 Object getMod()
          Get the actual mod object
 String getModId()
          The globally unique modid for this mod
 String getName()
          A human readable name
 ArtifactVersion getProcessedVersion()
           
 Set<ArtifactVersion> getRequirements()
          A list of the modids that this mod requires loaded prior to loading
 String getSortingRules()
          A representative string encapsulating the sorting preferences for this mod
 File getSource()
          The location on the file system which this mod came from
 String getVersion()
          A human readable version identifier
 boolean isImmutable()
           
 boolean isNetworkMod()
           
 boolean matches(Object mod)
          Does this mod match the supplied mod
 boolean registerBus(com.google.common.eventbus.EventBus bus, LoadController controller)
          Register the event bus for the mod and the controller for error handling Returns if this bus was successfully registered - disabled mods and other mods that don't need real events should return false and avoid further processing
 void setEnabledState(boolean enabled)
          Set the enabled/disabled state of this mod
 

Method Detail

getModId

String getModId()
The globally unique modid for this mod

Returns:

getName

String getName()
A human readable name

Returns:

getVersion

String getVersion()
A human readable version identifier

Returns:

getSource

File getSource()
The location on the file system which this mod came from

Returns:

getMetadata

ModMetadata getMetadata()
The metadata for this mod

Returns:

bindMetadata

void bindMetadata(MetadataCollection mc)
Attach this mod to it's metadata from the supplied metadata collection

Parameters:
mc -

setEnabledState

void setEnabledState(boolean enabled)
Set the enabled/disabled state of this mod

Parameters:
enabled -

getRequirements

Set<ArtifactVersion> getRequirements()
A list of the modids that this mod requires loaded prior to loading

Returns:

getDependencies

List<ArtifactVersion> getDependencies()
A list of modids that should be loaded prior to this one. The special value * indicates to load before any other mod.

Returns:

getDependants

List<ArtifactVersion> getDependants()
A list of modids that should be loaded after this one. The special value * indicates to load after any other mod.

Returns:

getSortingRules

String getSortingRules()
A representative string encapsulating the sorting preferences for this mod

Returns:

registerBus

boolean registerBus(com.google.common.eventbus.EventBus bus,
                    LoadController controller)
Register the event bus for the mod and the controller for error handling Returns if this bus was successfully registered - disabled mods and other mods that don't need real events should return false and avoid further processing

Parameters:
bus -
controller -
Returns:

matches

boolean matches(Object mod)
Does this mod match the supplied mod

Parameters:
mod -
Returns:

getMod

Object getMod()
Get the actual mod object

Returns:

getProcessedVersion

ArtifactVersion getProcessedVersion()

isImmutable

boolean isImmutable()

isNetworkMod

boolean isNetworkMod()

getDisplayVersion

String getDisplayVersion()