ZMObject
└─ZMView
└─ZMForwardView
public class ZMForwardView
extends ZMView
| Method Summary | |
|---|---|
| void | Create a new forward view. |
| string | asUrl(mixed request, mixed template, string type, string filename, request The) {@inheritDoc} |
| boolean | exists(mixed request, mixed template, string type, string filename, request The) {@inheritDoc} |
| string | fetch(mixed request, string template, mixed type, request The) {@inheritDoc} |
| string | {@inheritDoc} |
| string | Get the request id of the redirect. |
| ZMViewUtils | {@inheritDoc} |
| boolean | {@inheritDoc} |
| string | path(mixed template, string type, string filename) {@inheritDoc} |
| void | setRequestId(string requestId) Set the request id of the redirect. |
| Methods inherited from org.zenmagick.mvc.view\ZMView | |
|---|---|
| __construct, asUrl, exists, fetch, generate, getContentType, getEncoding, getTemplate, getVar, getVars, getViewId, getViewUtils, isValid, path, setTemplate, setVar, setVars, setViewId | |
| Methods inherited from org.zenmagick.core\ZMObject | |
|---|---|
| __construct, attachMethod, get, getAttachedMethods, getProperties, getPropertyNames, set, singleton | |
public void __construct()
Create a new forward view.
public string asUrl(mixed request, mixed template, string type, string filename, request The)
Resolve the given (relative) templates filename into a url.
ZMView::TEMPLATE and ZMView::RESOURCE; default is ZMVIew::TEMPLATE.public boolean exists(mixed request, mixed template, string type, string filename, request The)
Check if the given templates file exists.
ZMView::TEMPLATE and ZMView::RESOURCE; default is ZMVIew::TEMPLATE.true if the file exists, false if not.public string fetch(mixed request, string template, mixed type, request The)
Fetch/generate the contents of the given template.
public string generate(ZMRequest request)
Shortcut to generate the contents for the currenty set template.
The template extension is taken from the 'zenmagick.mvc.templates.ext'
public string getRequestId()
Get the request id of the redirect.
If not set, this will default to the template name (compatibility mode).
public ZMViewUtils getViewUtils()
Get view utils.
ZMViewUtils or null.public boolean isValid(ZMRequest request)
Check if this view is valid.
This is optional and it is up to the specific subclass to implement as appropriate.
true if the view is valid.public string path(mixed template, string type, string filename)
Resolve the given templates filename to a fully qualified filename.
ZMView::TEMPLATE and ZMView::RESOURCE; default is ZMVIew::TEMPLATE.null.public void setRequestId(string requestId)
Set the request id of the redirect.
Forward view.
This will forward the request to the given controller without a redirect.