C# 클래스 Castle.MonoRail.ActiveRecordScaffold.AbstractScaffoldAction

Base abstract class for actions that relate to Scaffolding support. Provide the basic flow process
상속: IDynamicAction
파일 보기 프로젝트 열기: nats/castle-1.0.3-mono

보호된 프로퍼티들

프로퍼티 타입 설명
binder Castle.MonoRail.ActiveRecordSupport.ARDataBinder
builder Castle.Components.Binder.TreeBuilder
errors System.Collections.ArrayList
modelType System.Type
prop2Validation IDictionary
templateEngine ITemplateEngine

공개 메소드들

메소드 설명
AbstractScaffoldAction ( Type modelType, ITemplateEngine templateEngine, bool useModelName, bool useDefaultLayout ) : System

Initializes a new instance of the AbstractScaffoldAction class.

Execute ( Controller controller ) : void

Executes the basic flow which is Resolve the ActiveRecordModel Resolve the layout (if not is associated with the controller, defaults to "scaffold") Invokes PerformActionProcess which should perform the correct process for this action Resolves the template name that the developer might provide by using ComputeTemplateName If the template exists, renders it. Otherwise invokes RenderStandardHtml

보호된 메소드들

메소드 설명
AssertIsPost ( Controller controller ) : void
ComputeTemplateName ( Controller controller ) : string

Implementors should return the template name for the current action.

ObtainPKProperty ( ) : PropertyInfo

Gets the property that represents the Primary key for the current ActiveRecordModel

PerformActionProcess ( Controller controller ) : void

Implementors should perform the action for the scaffolding, like new or create.

RenderFromTemplate ( String templateName, Controller controller ) : void
RenderStandardHtml ( Controller controller ) : void

Only invoked if the programmer havent provided a custom template for the current action. Implementors should create a basic html to present.

SetUpHelpers ( Controller controller ) : void

비공개 메소드들

메소드 설명
GetARModel ( ) : ActiveRecordModel

메소드 상세

AbstractScaffoldAction() 공개 메소드

Initializes a new instance of the AbstractScaffoldAction class.
public AbstractScaffoldAction ( Type modelType, ITemplateEngine templateEngine, bool useModelName, bool useDefaultLayout ) : System
modelType System.Type Type of the model.
templateEngine ITemplateEngine The template engine.
useModelName bool Indicates that we should use the model name on urls
useDefaultLayout bool Whether we should use our layout.
리턴 System

AssertIsPost() 보호된 정적인 메소드

protected static AssertIsPost ( Controller controller ) : void
controller Castle.MonoRail.Framework.Controller
리턴 void

ComputeTemplateName() 보호된 추상적인 메소드

Implementors should return the template name for the current action.
protected abstract ComputeTemplateName ( Controller controller ) : string
controller Castle.MonoRail.Framework.Controller
리턴 string

Execute() 공개 메소드

Executes the basic flow which is Resolve the ActiveRecordModel Resolve the layout (if not is associated with the controller, defaults to "scaffold") Invokes PerformActionProcess which should perform the correct process for this action Resolves the template name that the developer might provide by using ComputeTemplateName If the template exists, renders it. Otherwise invokes RenderStandardHtml
public Execute ( Controller controller ) : void
controller Castle.MonoRail.Framework.Controller
리턴 void

ObtainPKProperty() 보호된 메소드

Gets the property that represents the Primary key for the current ActiveRecordModel
protected ObtainPKProperty ( ) : PropertyInfo
리턴 System.Reflection.PropertyInfo

PerformActionProcess() 보호된 메소드

Implementors should perform the action for the scaffolding, like new or create.
protected PerformActionProcess ( Controller controller ) : void
controller Castle.MonoRail.Framework.Controller
리턴 void

RenderFromTemplate() 보호된 메소드

protected RenderFromTemplate ( String templateName, Controller controller ) : void
templateName String
controller Castle.MonoRail.Framework.Controller
리턴 void

RenderStandardHtml() 보호된 추상적인 메소드

Only invoked if the programmer havent provided a custom template for the current action. Implementors should create a basic html to present.
protected abstract RenderStandardHtml ( Controller controller ) : void
controller Castle.MonoRail.Framework.Controller
리턴 void

SetUpHelpers() 보호된 정적인 메소드

protected static SetUpHelpers ( Controller controller ) : void
controller Castle.MonoRail.Framework.Controller
리턴 void

프로퍼티 상세

binder 보호되어 있는 프로퍼티

Binder that 'knows' ActiveRecord types
protected ARDataBinder,Castle.MonoRail.ActiveRecordSupport binder
리턴 Castle.MonoRail.ActiveRecordSupport.ARDataBinder

builder 보호되어 있는 프로퍼티

Constructs the data source for the binder
protected TreeBuilder,Castle.Components.Binder builder
리턴 Castle.Components.Binder.TreeBuilder

errors 보호되어 있는 프로퍼티

A list of errors that happened during this process
protected ArrayList,System.Collections errors
리턴 System.Collections.ArrayList

modelType 보호되어 있는 프로퍼티

Holds the AR type
protected Type,System modelType
리턴 System.Type

prop2Validation 보호되어 있는 프로퍼티

A map of PropertyInfo to validation failures
protected IDictionary prop2Validation
리턴 IDictionary

templateEngine 보호되어 있는 프로퍼티

Reference to the template engine instance
protected ITemplateEngine templateEngine
리턴 ITemplateEngine