Dave Archer
Dave Archer

Reputation: 3060

In MVC file structure, what is Views/XXFolder/xxTemplateFile what is XXFolder known as?

I'm a bit confused about mvc terminology.

Using the question title as an example, a view corresponds to an action, which means xxTemplateFile would be considered to represent the view.

xxFolder does not represent an area. So could it be a View Collection? or View Container?

Cheers,

Upvotes: 0

Views: 699

Answers (1)

Jamie Dixon
Jamie Dixon

Reputation: 54001

This could reprisent the controller class and controller method for the related view. (or controller and action with the view being attached to the action).

Using your example: Views/XXFolder/xxTemplateFile could be used to indicate that your view, xxTemplateFile which is attached to a controller action of the same name, is inside the xxFolder class.

This would make sense if you consider how routed URLs tend to look {controller,action,id}

If this is simply the way you're organising your views then I'd be tempted to just refer to them as View folders or folders.

Upvotes: 1

Related Questions