net.datacrow.core.modules
Class ContainerModule

java.lang.Object
  extended by net.datacrow.core.modules.DcModule
      extended by net.datacrow.core.modules.DcParentModule
          extended by net.datacrow.core.modules.ContainerModule
All Implemented Interfaces:
java.lang.Comparable<DcModule>

public class ContainerModule
extends DcParentModule

The container module hold any kind of item as long as the item belongs to a container managed module. Container managed items are represented by the item module.

Author:
Robert Jan van der Waals
See Also:
ItemModule

Field Summary
 
Fields inherited from class net.datacrow.core.modules.DcModule
_TYPE_ASSOCIATE_MODULE, _TYPE_EXTERNALREFERENCE_MODULE, _TYPE_MAPPING_MODULE, _TYPE_MEDIA_MODULE, _TYPE_MODULE, _TYPE_PROPERTY_MODULE, _TYPE_TEMPLATE_MODULE, insertView, searchView
 
Constructor Summary
ContainerModule(int index, boolean topModule, java.lang.String name, java.lang.String description, java.lang.String objectName, java.lang.String objectNamePlural, java.lang.String tableName, java.lang.String tableShortName)
          Creates a new instance.
ContainerModule(XmlModule module)
          Creates this module based on an XML module definition.
 
Method Summary
 DcObject createItem()
          Creates a new instance of an item belonging to this module.
 boolean equals(java.lang.Object o)
           
 int getDefaultSortFieldIdx()
          Retrieves the index of the field on which is sorted by default.
 int[] getSupportedViews()
           
protected  void initializeUI()
          Initializes the various views.
 boolean isContainerManaged()
          Indicates if the module is managed by (can belong to) a container.
 boolean isSelectableInUI()
          Indicates whether this module be selected from the module bar.
 boolean isServingMultipleModules()
          Indicates if this module is used by multiple modules.
 
Methods inherited from class net.datacrow.core.modules.DcParentModule
isParentModule, isTopModule
 
Methods inherited from class net.datacrow.core.modules.DcModule
addField, addValueEnhancer, applySettings, canBeLend, compareTo, delete, deliversOnlineService, getChartPanel, getChild, getCurrentInsertView, getCurrentSearchView, getDefaultData, getDescription, getDisplayFieldIdx, getDisplayIndex, getField, getField, getFieldCount, getFieldDefinitions, getFieldIndices, getFields, getFileField, getFileRenamerDialog, getFilterForm, getIcon16, getIcon16Filename, getIcon32, getIcon32Filename, getIconField, getImporter, getImporterClass, getIndex, getInsertView, getItem, getItemForm, getItemPluralResourceKey, getItemResourceKey, getKeyStroke, getLabel, getMenuBar, getMinimalFields, getModuleResourceKey, getName, getNameFieldIdx, getObjectName, getObjectNamePlural, getOnlineServices, getParent, getParentReferenceFieldIndex, getPersistentField, getPropertyModule, getQuickView, getQuickViewFieldDefinitions, getSearchView, getSetting, getSettings, getSynchronizer, getSystemDisplayFieldIdx, getSystemField, getSystemObjectName, getSystemObjectNamePlural, getTableName, getTableShortName, getTemplateModule, getType, getViews, getWebFieldDefinitions, getXmlModule, hasActualReferenceTo, hasDependingModules, hashCode, hasInsertView, hasReferenceTo, hasReports, hasSearchView, initializeFields, initializeMultiReferenceFields, initializeSettings, initializeSystemFields, isAbstract, isChildModule, isCustomFieldsAllowed, isCustomModule, isDefaultDataLoaded, isEditingAllowed, isEnabled, isEnabled, isFileBacked, isHasImages, isHasReferences, isNew, isSearchViewInitialized, isValid, release, removeEnhancers, setChild, setDefaultDataLoaded, setIcon16, setIcon32, setNew, setServingMultipleModules, setSetting, setValid, setXmlModule, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ContainerModule

public ContainerModule(int index,
                       boolean topModule,
                       java.lang.String name,
                       java.lang.String description,
                       java.lang.String objectName,
                       java.lang.String objectNamePlural,
                       java.lang.String tableName,
                       java.lang.String tableShortName)
Creates a new instance.

Parameters:
index - The module index.
topModule - Indicates if the module is a top module. Top modules are allowed to be displayed in the module bar and can be enabled or disabled.
name - The internal unique name of the module.
description - The module description
objectName - The name of the items belonging to this module.
objectNamePlural - The plural name of the items belonging to this module.
tableName - The database table name for this module.
tableShortName - The database table short name for this module.

ContainerModule

public ContainerModule(XmlModule module)
Creates this module based on an XML module definition.

Parameters:
module -
Method Detail

isServingMultipleModules

public boolean isServingMultipleModules()
Description copied from class: DcModule
Indicates if this module is used by multiple modules.

Overrides:
isServingMultipleModules in class DcModule

getSupportedViews

public int[] getSupportedViews()
Overrides:
getSupportedViews in class DcModule

isContainerManaged

public boolean isContainerManaged()
Description copied from class: DcModule
Indicates if the module is managed by (can belong to) a container.

Overrides:
isContainerManaged in class DcModule
See Also:
ContainerModule, Container

initializeUI

protected void initializeUI()
Initializes the various views.

Overrides:
initializeUI in class DcModule

isSelectableInUI

public boolean isSelectableInUI()
Indicates whether this module be selected from the module bar.

Overrides:
isSelectableInUI in class DcModule

getDefaultSortFieldIdx

public int getDefaultSortFieldIdx()
Description copied from class: DcModule
Retrieves the index of the field on which is sorted by default. Return 1 if this field exists or else the defined default index.

Overrides:
getDefaultSortFieldIdx in class DcModule

createItem

public DcObject createItem()
Creates a new instance of an item belonging to this module.

Overrides:
createItem in class DcModule

equals

public boolean equals(java.lang.Object o)
Overrides:
equals in class DcParentModule