View Source FlEx.Router.Methods (fl_ex v0.1.2)

This module helps to handle the http method macros

This module it's just for internal use, it's not necessary implement

Summary

Functions

Adds the path to the route list under the http method call

Adds the path to the route list under the http method call

Adds the path to the route list under the http method call

Adds the path to the route list under the http method call

Adds the path to the route list under the http method call

Adds the path as prefix and the defined plugs for all the scoped routes

Functions

Link to this macro

delete(path, module, function \\ [], pipeline \\ nil)

View Source (macro)

Adds the path to the route list under the http method call

Example:

  get "/your_scoped_page", FlExExample.ExampleController, :function_name
  post "/your_scoped_page", FlExExample.ExampleController, :function_name
  put "/your_scoped_page", FlExExample.ExampleController, :function_name
  patch "/your_scoped_page", FlExExample.ExampleController, :function_name
  delete "/your_scoped_page", FlExExample.ExampleController, :function_name
Link to this macro

get(path, module, function \\ [], pipeline \\ nil)

View Source (macro)

Adds the path to the route list under the http method call

Example:

  get "/your_scoped_page", FlExExample.ExampleController, :function_name
  post "/your_scoped_page", FlExExample.ExampleController, :function_name
  put "/your_scoped_page", FlExExample.ExampleController, :function_name
  patch "/your_scoped_page", FlExExample.ExampleController, :function_name
  delete "/your_scoped_page", FlExExample.ExampleController, :function_name
Link to this macro

patch(path, module, function \\ [], pipeline \\ nil)

View Source (macro)

Adds the path to the route list under the http method call

Example:

  get "/your_scoped_page", FlExExample.ExampleController, :function_name
  post "/your_scoped_page", FlExExample.ExampleController, :function_name
  put "/your_scoped_page", FlExExample.ExampleController, :function_name
  patch "/your_scoped_page", FlExExample.ExampleController, :function_name
  delete "/your_scoped_page", FlExExample.ExampleController, :function_name
Link to this macro

post(path, module, function \\ [], pipeline \\ nil)

View Source (macro)

Adds the path to the route list under the http method call

Example:

  get "/your_scoped_page", FlExExample.ExampleController, :function_name
  post "/your_scoped_page", FlExExample.ExampleController, :function_name
  put "/your_scoped_page", FlExExample.ExampleController, :function_name
  patch "/your_scoped_page", FlExExample.ExampleController, :function_name
  delete "/your_scoped_page", FlExExample.ExampleController, :function_name
Link to this macro

put(path, module, function \\ [], pipeline \\ nil)

View Source (macro)

Adds the path to the route list under the http method call

Example:

  get "/your_scoped_page", FlExExample.ExampleController, :function_name
  post "/your_scoped_page", FlExExample.ExampleController, :function_name
  put "/your_scoped_page", FlExExample.ExampleController, :function_name
  patch "/your_scoped_page", FlExExample.ExampleController, :function_name
  delete "/your_scoped_page", FlExExample.ExampleController, :function_name
Link to this macro

scope(path, arg2)

View Source (macro)

Adds the path as prefix and the defined plugs for all the scoped routes

Example:

  scope "/api/v1" do
    plug FlEx.Plug.Logger

    get "/your_scoped_page", FlExExample.ExampleController, :function_name
  end