Keel 2.1RC2

org.keel.apps.crud.models
Class PromptAdd

java.lang.Object
  extended byorg.keel.services.model.StandardModel
      extended byorg.keel.services.model.StandardLogEnabledModel
          extended byorg.keel.services.model.SecurableStandardLogEnabledModel
              extended byorg.keel.apps.crud.models.CrudBase
                  extended byorg.keel.apps.crud.models.GetBase
                      extended byorg.keel.apps.crud.models.PromptAdd
All Implemented Interfaces:
Configurable, LogEnabled, Model, Securable, ThreadSafe

public class PromptAdd
extends GetBase
implements ThreadSafe, Securable

Prompt the user to enter a new record for the specified persistent. Altered by Santanu Dutt to make this model implement the Securable lifecycle interface for authorization.

Version:
$Revision: 1.8 $ $Date: 2003/10/04 17:48:10 $
Author:
Michael Nash

Field Summary
private  AuthorizationManager am
           
private  java.util.Map fixedFields
           
 
Fields inherited from class org.keel.apps.crud.models.CrudBase
ADD, CRUD, DELETE, LIST, noPaging, prefix, PROMPT, PROMPT_ADD, PROMPT_QUERY, PROMPT_UPDATE, QUERY, SELECT_PERSISTENT, suffix, UPDATE
 
Fields inherited from class org.keel.services.model.StandardLogEnabledModel
log
 
Fields inherited from class org.keel.services.model.StandardModel
configuration
 
Fields inherited from interface org.keel.services.model.Model
ROLE
 
Constructor Summary
PromptAdd()
           
 
Method Summary
protected  void autoField(ModelRequest req, ModelResponse res, java.lang.String oneFieldName)
          Automatically handle a single field on the form
 ModelResponse execute(ModelRequest req)
          Prompt the user for a new record
 AuthorizationManager getAuthorizationManager()
           
 java.util.Set getOperations()
           
 void setAuthorizationManager(AuthorizationManager newManager)
          Provide the service with a security manager.
 
Methods inherited from class org.keel.apps.crud.models.GetBase
showForm
 
Methods inherited from class org.keel.apps.crud.models.CrudBase
addCriteria, addParameters, countRecords, decode, getCurrentPage, getEndRecord, getFixedFields, getMasterDetail, getPageNumber, getPersistent, getPersistentName, getPrefixes, getSortFieldsParam, getStartRecord, isShowNext, isShowPrev, saveSettings, setCurrentPage, setEndRecord, setShowNext, setShowPrev, setStartRecord, showEditLink, showOptions, showUserName
 
Methods inherited from class org.keel.services.model.StandardLogEnabledModel
enableLogging
 
Methods inherited from class org.keel.services.model.StandardModel
configure, getConfiguration
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

am

private AuthorizationManager am

fixedFields

private java.util.Map fixedFields
Constructor Detail

PromptAdd

public PromptAdd()
Method Detail

autoField

protected void autoField(ModelRequest req,
                         ModelResponse res,
                         java.lang.String oneFieldName)
                  throws PersistenceException,
                         ModelException
Automatically handle a single field on the form

Specified by:
autoField in class GetBase
Parameters:
oneFieldName - The name of the field
Throws:
PersistenceException - If a problem occurs getting field info from the persistent object
ModelException

execute

public ModelResponse execute(ModelRequest req)
                      throws ModelException
Prompt the user for a new record

Specified by:
execute in interface Model
Overrides:
execute in class CrudBase
Throws:
ModelException - If an internal model processing error occurs

setAuthorizationManager

public void setAuthorizationManager(AuthorizationManager newManager)
Description copied from interface: Securable
Provide the service with a security manager. This security manager is used whenever a service needs to determine if the current principal is allowed to perform the requested operation. All instances of the same Securable service will have the same authorizations - if you need per- instance authorization, see InstanceSecurable.

Specified by:
setAuthorizationManager in interface Securable
Overrides:
setAuthorizationManager in class SecurableStandardLogEnabledModel

getOperations

public java.util.Set getOperations()

getAuthorizationManager

public AuthorizationManager getAuthorizationManager()
Specified by:
getAuthorizationManager in interface Securable
Overrides:
getAuthorizationManager in class SecurableStandardLogEnabledModel
See Also:
Securable.getAuthorizationManager()

Keel 2.1RC2

Please see keelframework.org for information about new Keel releases.