z_dispatcher (zotonic_core v1.0.0-rc.10)
Link to this section Summary
Functions
Make the url an absolute url
Convert process state when code is changed
A list of dispatch rule arguments that shouldn't be considered with redirects. Used by controller_file_id and controller_redirect
Fetch the dispatchlist for the site.
Drop the portnumber from the hostname
Create the url for the dispatch rule with name and arguments Args.
Handling all non call/cast messages
Fetch the preferred hostname for this site
Fetch the preferred hostname, including port, for this site
Fetch the preferred hostname for SSL, including port, for this site
Initiates the server, loads the dispatch list into the webmachine dispatcher
Reload all dispatch lists. Finds new dispatch lists and adds them to the dispatcher
Starts the dispatch server
This function is called by a gen_server when it is about to terminate. It should be the opposite of Module:init/1 and do any necessary cleaning up. When it returns, the gen_server terminates with Reason. The return value is ignored.
Update the dispatch list but don't reload it yet. Used when flushing all sites, see z:flush/0
Construct an uri from a named dispatch, assuming no parameters. Use html escape.
Construct an uri from a named dispatch and the parameters. Use html escape.
Construct an uri from a named dispatch and the parameters
Link to this section Functions
Link to this function
abs_url(Url, Context)
Link to this function
code_change(OldVsn, State, Extra)
Link to this function
dispatcher_args()
Link to this function
dispatchinfo(Context)
-spec dispatchinfo(z:context() | pid() | atom()) -> {ok, {atom(), binary() | string(), binary() | string(), list(), boolean(), list()}} | {error, noproc}.
Link to this function
drop_port(Hostname)
-spec drop_port(undefined | none | string() | binary()) -> undefined | binary().
Link to this function
handle_call(_, From, State)
Link to this function
handle_cast(Msg, State)
Link to this function
handle_info(Info, State)
Link to this function
hostname(Context)
-spec hostname(z:context()) -> binary() | undefined.
Link to this function
hostname_port(Context)
-spec hostname_port(z:context()) -> binary() | undefined.
Link to this function
hostname_ssl_port(Context)
-spec hostname_ssl_port(z:context()) -> binary() | undefined.
Link to this function
init(Site)
Link to this function
reload(Context)
Link to this function
reload(_, Context)
Link to this function
start_link(Site)
Link to this function
terminate(Reason, State)
Link to this function
update(Context)
Link to this function
url_for(Name, Context)
Link to this function
url_for(Name, Args, Context)
Link to this function