Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

au.edu.educationau.belts.command.lesson.action
Class UpdateLessonAction  view UpdateLessonAction download UpdateLessonAction.java

java.lang.Object
  extended byau.edu.educationau.belts.command.AbstractCommand
      extended byau.edu.educationau.belts.command.container.AbstractContainerCommand
          extended byau.edu.educationau.belts.command.container.AbstractBeltsContainerCommand
              extended byau.edu.educationau.belts.command.AbstractIdCommand
                  extended byau.edu.educationau.belts.command.lesson.action.UpdateLessonAction
All Implemented Interfaces:
au.edu.educationau.belts.command.Action, au.edu.educationau.belts.command.Command, au.edu.educationau.belts.container.Containable, java.io.Serializable

public class UpdateLessonAction
extends au.edu.educationau.belts.command.AbstractIdCommand
implements au.edu.educationau.belts.command.Action

This class performs the action of updating a Lesson

Required Parameters:

id
the id of the lesson to update
name
the name of the lesson
description
the description of the lesson
instructions
the instructions for this lesson
owner
the owner for this lesson
author
the author for this lesson

Outcomes

OK
the lesson was created OK
ERROR
an error occurred during lesson creation
VALIDATION
a validation error occurred

The following errors may occur during lesson creation:

Duplicate Lesson
a lesson with that id already exists
Not Allowed to Create Lessons
the current user is not allowed to create lessons

Results

No results are returned from this action.

Version:
$Revision: 1.14.4.2 $ - $Date: 2003/07/25 00:29:46 $

Field Summary
private  java.lang.String _description
           
private  java.lang.String _instructions
           
private  java.lang.String _login
           
private  java.lang.String _name
           
private  java.lang.String _password
           
static java.lang.String DESCRIPTION
           
static java.lang.String INSTRUCTIONS
           
static java.lang.String LOGIN
           
static java.lang.String NAME
           
static java.lang.String PASSWORD
           
 
Fields inherited from class au.edu.educationau.belts.command.AbstractIdCommand
_id, ID
 
Fields inherited from class au.edu.educationau.belts.command.container.AbstractBeltsContainerCommand
_log
 
Fields inherited from class au.edu.educationau.belts.command.container.AbstractContainerCommand
 
Fields inherited from class au.edu.educationau.belts.command.AbstractCommand
_outcome, _result, ENTITY_NOT_FOUND_ERROR, SECURITY_ERROR, SYSTEM_ERROR, VALIDATION_ERROR
 
Constructor Summary
UpdateLessonAction()
           
 
Method Summary
 void execute()
          Execute the command.
 void setDescription(java.lang.String description)
          Sets the description.
 void setInstructions(java.lang.String instructions)
          Sets the instructions.
 void setLogin(java.lang.String login)
          Sets the login.
 void setName(java.lang.String name)
          Sets the name.
 void setPassword(java.lang.String password)
          Sets the password.
 boolean validate()
          Validate checks to ensure that the parameters required to execute the Command have been correctly set.
 
Methods inherited from class au.edu.educationau.belts.command.AbstractIdCommand
setId
 
Methods inherited from class au.edu.educationau.belts.command.container.AbstractBeltsContainerCommand
beltsContainer, currentUser, currentUserIsMemberOfSchool, currentUsersSchool, isManager, isPermitted, isTeacher, permitted
 
Methods inherited from class au.edu.educationau.belts.command.container.AbstractContainerCommand
container, dispatchEvent, hasContainer, prepare, release
 
Methods inherited from class au.edu.educationau.belts.command.AbstractCommand
addDuplicateEntityFoundError, addEmailFieldValidationError, addEntityNotFoundError, addError, addError, addError, addFieldValidationError, addIdValidationError, addSecurityError, addSystemError, addValidationError, addWarning, result
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface au.edu.educationau.belts.command.Command
result
 

Field Detail

NAME

public static final java.lang.String NAME
See Also:
Constant Field Values

_name

private java.lang.String _name

LOGIN

public static final java.lang.String LOGIN
See Also:
Constant Field Values

_login

private java.lang.String _login

PASSWORD

public static final java.lang.String PASSWORD
See Also:
Constant Field Values

_password

private java.lang.String _password

DESCRIPTION

public static final java.lang.String DESCRIPTION
See Also:
Constant Field Values

_description

private java.lang.String _description

INSTRUCTIONS

public static final java.lang.String INSTRUCTIONS
See Also:
Constant Field Values

_instructions

private java.lang.String _instructions
Constructor Detail

UpdateLessonAction

public UpdateLessonAction()
Method Detail

validate

public boolean validate()
Description copied from interface: au.edu.educationau.belts.command.Command

Validate checks to ensure that the parameters required to execute the Command have been correctly set.

WARNING - you should only check the Command objects internal structure, and not attempt to call external services as these may not be available to the object.

Specified by:
validate in interface au.edu.educationau.belts.command.Command

execute

public void execute()
Description copied from interface: au.edu.educationau.belts.command.Command

Execute the command. The dispatcher is responsible for ensuring that the commands validate method is called before the command is executed.

Specified by:
execute in interface au.edu.educationau.belts.command.Command

setName

public void setName(java.lang.String name)
Sets the name.


setDescription

public void setDescription(java.lang.String description)
Sets the description.


setInstructions

public void setInstructions(java.lang.String instructions)
Sets the instructions.


setLogin

public void setLogin(java.lang.String login)
Sets the login.


setPassword

public void setPassword(java.lang.String password)
Sets the password.