org.olat.repository
Class DetailsForm

java.lang.Object
  extended by org.olat.core.gui.components.Component
      extended by org.olat.core.gui.components.form.Form
          extended by org.olat.repository.DetailsForm

public class DetailsForm
extends Form

Initial Date: 08.07.2003

Author:
Mike Stock Comment:

Field Summary
static int MAX_DISPLAYNAME
           
 
Fields inherited from class org.olat.core.gui.components.form.Form
CANCEL_IDENTIFICATION, ELEM_BUTTON_COMMAND_ID, EVNT_FORM_CANCELLED, EVNT_VALIDATION_NOK, EVNT_VALIDATION_OK, SUBMIT_IDENTIFICATION
 
Constructor Summary
DetailsForm(java.lang.String name, Translator translator, RepositoryEntry entry, java.lang.String typeName, boolean enableAuthorView, boolean doDisplayOnly)
          The details form is initialized with data collected from entry and typeName.
 
Method Summary
 java.lang.String getAuthor()
           
 java.lang.String getDescription()
           
 java.lang.String getDisplayName()
           
 java.lang.String getResourceName()
           
 java.lang.String getType()
           
 RepositoryEntry getUpdatedEntry()
          Get an updated repository entry with data from this form.
 void init()
          Initialize form data based on repository entry.
 void setEntry(RepositoryEntry newEntry)
          Set entry and re-initialize the form based on data of this entry.
 void updateEntry(RepositoryEntry repositoryEntry)
          Update the given repository entry with data available from this form.
 boolean validate()
           
 
Methods inherited from class org.olat.core.gui.components.form.Form
addFormElement, addSubmitKey, addSubmitKey, addVisibilityDependsOnSelectionRule, getCheckBoxElement, getDateElement, getElementCount, getFormElement, getHTMLRendererSingleton, getIntegerElement, getMultipleSelectionElement, getNameIterator, getPasswordElement, getRadioButtonElement, getSelectedSubmitKey, getSingleSelectionElement, getTextAreaElement, getTextElement, getVisibilityDependsOnSelectionRules, getWikiMarkupTextAreaElement, hasMandatoryFields, hasWikiMarkupFields, isDisplayOnly, isValid, removeCancelButton, removeFormElements, setAllFormElements, setCancelButton, setCancelKey, setDisplayOnly, setSubmitKey, validate
 
Methods inherited from class org.olat.core.gui.components.Component
addListener, debuginfoGetListeners, dispatchRequest, getAndClearLatestFiredEvent, getComponentName, getDispatchID, getExtendedDebugInfo, getLatestDispatchedController, getListenerInfo, getParent, getSpanAsDomReplaceable, getTimestamp, getTranslator, isDirty, isDirtyForUser, isDomReplaceable, isEnabled, isVisible, setDirty, setDomReplaceable, setEnabled, setSpanAsDomReplaceable, setVisible, toString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

MAX_DISPLAYNAME

public static final int MAX_DISPLAYNAME
See Also:
Constant Field Values
Constructor Detail

DetailsForm

public DetailsForm(java.lang.String name,
                   Translator translator,
                   RepositoryEntry entry,
                   java.lang.String typeName,
                   boolean enableAuthorView,
                   boolean doDisplayOnly)
The details form is initialized with data collected from entry and typeName. Handler is looked-up by the given handlerName and not by the entry's resourceableType. This is to allow for an entry with no resourceable to initialize correctly (c.f. RepositoryAdd workflow). The typeName may be null.

Parameters:
name -
t -
entry -
typeName -
enableAuthorView -
doDisplayOnly -
Method Detail

init

public void init()
Initialize form data based on repository entry.


validate

public boolean validate()
Specified by:
validate in class Form
Returns:
true: form validates, false: form contains invalid data
See Also:
org.olat.core.gui.components.Form#validate(org.olat.core.gui.UserRequest)

getResourceName

public java.lang.String getResourceName()
Returns:
Resource name filed.

getDisplayName

public java.lang.String getDisplayName()
Returns:
Display name field.

getAuthor

public java.lang.String getAuthor()
Returns:
Author field.

getType

public java.lang.String getType()
Returns:
Typoe field.

getDescription

public java.lang.String getDescription()
Returns:
Descritpion field.

setEntry

public void setEntry(RepositoryEntry newEntry)
Set entry and re-initialize the form based on data of this entry.

Parameters:
newEntry -

updateEntry

public void updateEntry(RepositoryEntry repositoryEntry)
Update the given repository entry with data available from this form.

Parameters:
repositoryEntry -

getUpdatedEntry

public RepositoryEntry getUpdatedEntry()
Get an updated repository entry with data from this form.

Returns:
Updated repository entry.