Object/Trait

net.liftweb.sitemap

Loc

Related Docs: trait Loc | package sitemap

Permalink

object Loc

The Loc companion object, complete with a nice constructor

Linear Supertypes
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. Loc
  2. AnyRef
  3. Any
  1. Hide All
  2. Show all
Visibility
  1. Public
  2. All

Type Members

  1. type AnyLocParam = LocParam[Any]

    Permalink

    A type alias for LocParam instances that are applicable to any Loc

  2. case class CalcParamStateless[-T](f: (Box[T]) ⇒ Boolean) extends LocParam[T] with Product with Serializable

    Permalink

    A function that calculates the statelessness of the Loc for the given request with the parameterized type passed into the function

  3. case class CalcStateless(f: () ⇒ Boolean) extends AnyLocParam with Product with Serializable

    Permalink

    A function that calculates the statelessness of the Loc for the given request

  4. case class CalcValue[T](func: () ⇒ Box[T]) extends LocParam[T] with Product with Serializable

    Permalink

    Calculate the value for the Loc.

    Calculate the value for the Loc. This is useful for parameterized menus. It allows you to calculate the value of the Loc.

  5. case class DataLoc[T](name: String, link: Link[T], text: LinkText[T], defaultValue: Box[T], xparams: LocParam[T]*) extends Loc[T] with Product with Serializable

    Permalink
  6. trait DispatchLocSnippets extends LocSnippets

    Permalink

    A subclass of LocSnippets with a built in dispatch method (no need to implement isDefinedAt or apply...

    A subclass of LocSnippets with a built in dispatch method (no need to implement isDefinedAt or apply... just def dispatch: PartialFunction[String, NodeSeq => NodeSeq].

    See also

    ValueSnippets.apply

    ValueSnippets

  7. case class EarlyResponse(func: () ⇒ Box[LiftResponse]) extends AnyLocParam with Product with Serializable

    Permalink

    Allows you to generate an early response for the location rather than going through the whole Lift XHTML rendering pipeline

  8. type FailMsg = () ⇒ LiftResponse

    Permalink
  9. case class HttpAuthProtected(role: (Req) ⇒ Box[Role]) extends AnyLocParam with Product with Serializable

    Permalink

    Indicates that the path denominated by Loc requires HTTP authentication and only a user assigned to this role or to a role that is child-of this role can access it.

  10. case class If(test: () ⇒ Boolean, failMsg: FailMsg) extends AnyLocParam with Product with Serializable

    Permalink

    If the test returns True, the page can be accessed, otherwise, the result of FailMsg will be sent as a response to the browser.

    If the test returns True, the page can be accessed, otherwise, the result of FailMsg will be sent as a response to the browser. If the Loc cannot be accessed, it will not be displayed in menus.

    test

    -- the function that tests access to the page

    failMsg

    -- what to return the the browser (e.g., 304, etc.) if the page is accessed.

  11. case class IfValue[T](test: (Box[T]) ⇒ Boolean, failMsg: FailMsg) extends LocParam[T] with Product with Serializable

    Permalink
  12. class Link[-T] extends PartialFunction[Req, Box[Boolean]]

    Permalink

    This defines the Link to the Loc.

  13. case class LinkText[-T](text: (T) ⇒ NodeSeq) extends Product with Serializable

    Permalink

    A function that can be used to calculate the link text from the current value encapsulated by the Loc.

  14. case class LocGroup(group: String*) extends AnyLocParam with Product with Serializable

    Permalink

    If the Loc is in a group (or groups) like "legal" "community" etc.

    If the Loc is in a group (or groups) like "legal" "community" etc. the groups can be specified and recalled at the top level

  15. trait LocInfo[X] extends AnyLocParam

    Permalink

    An extension point for adding arbitrary lazy values to a Loc.

  16. trait LocParam[-T] extends AnyRef

    Permalink

    Algebraic data type for parameters that modify handling of a Loc in a SiteMap

  17. case class LocQueryParameters[T](f: (Box[T]) ⇒ List[(String, String)]) extends LocParam[T] with Product with Serializable

    Permalink

    Calculate additional query parameters to add as a query string to the Loc

  18. trait LocSnippets extends PartialFunction[String, (NodeSeq) ⇒ NodeSeq] with ValueSnippets[Any] with AnyLocParam

    Permalink

    Allows you to create a handler for many snippets that are associated with a Loc, but agnostic to the Loc's value.

    Allows you to create a handler for many snippets that are associated with a Loc, but agnostic to the Loc's value.

    See also

    ValueSnippets.apply

    ValueSnippets

  19. case class MenuCssClass(cssClass: StringFunc) extends AnyLocParam with Product with Serializable

    Permalink

    MenuCssClass is used to add css to the Menu node.

    MenuCssClass is used to add css to the Menu node. The css allows for replacing menu with an icon and other super-fun and helpful things. cssClass is a StringFunc which can either be a String constant or a Function that returns a String. Thus, you can compute the css based on the current state or you can have a constant. Syntactically you can use either:

    MenuCssClass("foobar")
    MenuCssClass(() => calculateCssForMyMenuItem())
    

  20. case class QueryParameters(f: () ⇒ List[(String, String)]) extends AnyLocParam with Product with Serializable

    Permalink

    Calculate additional query parameters to add as a query string to the Loc

  21. class Snippet extends ValueSnippets[Any] with AnyLocParam

    Permalink

    A single snippet that's associated with a Loc, but is not directly aware of the Loc value.

    A single snippet that's associated with a Loc, but is not directly aware of the Loc value.

    See also

    ValueSnippets

  22. case class Template(template: () ⇒ NodeSeq) extends AnyLocParam with Product with Serializable

    Permalink

    Allows a user to specify a template based upon a function from the current value encapsulated in the Loc

  23. case class TemplateBox(template: () ⇒ Box[NodeSeq]) extends AnyLocParam with Product with Serializable

    Permalink

    Allows a user to specify a template based upon a function from the current value encapsulated in the Loc.

    Allows a user to specify a template based upon a function from the current value encapsulated in the Loc. Allow the return of Box[NodeSeq] so that it's more friendly to Templates.

  24. case class Test(test: (Req) ⇒ Boolean) extends AnyLocParam with Product with Serializable

    Permalink

    Tests to see if the request actually matches the requirements for access to the page.

    Tests to see if the request actually matches the requirements for access to the page. For example, if a parameter is missing from the request, this is a good way to restrict access to the page.

  25. case class TestAccess(func: () ⇒ Box[LiftResponse]) extends AnyLocParam with Product with Serializable

    Permalink

    Allows extra access testing for a given menu location such that you can generically return a response during access control testing

  26. case class TestValueAccess[T](func: (Box[T]) ⇒ Box[LiftResponse]) extends LocParam[T] with Product with Serializable

    Permalink
  27. case class Title[T](title: (T) ⇒ NodeSeq) extends LocParam[T] with Product with Serializable

    Permalink

    This LocParam may be used to specify a function that calculates a title for the page based upon the current value encapsulated by this Loc.

  28. case class Unless(test: () ⇒ Boolean, failMsg: FailMsg) extends AnyLocParam with Product with Serializable

    Permalink

    Unless the test returns True, the page can be accessed, otherwise, the result of FailMsg will be sent as a response to the browser.

    Unless the test returns True, the page can be accessed, otherwise, the result of FailMsg will be sent as a response to the browser. If the Loc cannot be accessed, it will not be displayed in menus.

    test

    -- the function that tests access to the page

    failMsg

    -- what to return the the browser (e.g., 304, etc.) if the page is accessed.

  29. case class UnlessValue[T](test: (Box[T]) ⇒ Boolean, failMsg: FailMsg) extends LocParam[T] with Product with Serializable

    Permalink
  30. case class UseParentParams() extends AnyLocParam with Product with Serializable

    Permalink

    If this is a submenu, use the parent Loc's params

  31. trait UserLocParam[-T] extends LocParam[T]

    Permalink

    Extension point for user-defined LocParam instances.

  32. case class Value[T](value: T) extends LocParam[T] with Product with Serializable

    Permalink

    The value of Loc

  33. trait ValueSnippets[A] extends LocParam[A]

    Permalink

    The common interface for LocParams that provide snippet functions, which can be aware of the Loc value.

    The common interface for LocParams that provide snippet functions, which can be aware of the Loc value.

    A

    The type with which the Loc is parameterized.

  34. case class ValueTemplate[T](template: (Box[T]) ⇒ NodeSeq) extends LocParam[T] with Product with Serializable

    Permalink
  35. case class ValueTemplateBox[T](template: (Box[T]) ⇒ Box[NodeSeq]) extends LocParam[T] with Product with Serializable

    Permalink

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. object ExtLink

    Permalink
  5. object Hidden extends AnyLocParam with Product with Serializable

    Permalink

    If this parameter is included, the item will not be visible in the menu, but will still be accessable.

  6. object HideIfNoKids extends AnyLocParam with Product with Serializable

    Permalink

    If the Loc has no children, hide the Loc itself

  7. object Link

    Permalink
  8. object LinkText extends Serializable

    Permalink

    The companion object to LinkText that contains some helpful implicit conversion

  9. object MatchWithoutCurrentValue extends AnyLocParam with Product with Serializable

    Permalink

    If this parameter is included, the Loc will continue to execute even if currentValue is not defined.

    If this parameter is included, the Loc will continue to execute even if currentValue is not defined.

    By default, Lift will determine that a Loc does not match a given request if its currentValue comes up Empty, and as a result will return an HTTP 404. For situations where this is not the desired, "Not Found" behavior, you can add the MatchWithoutCurrentValue LocParam to a Loc, then use the IfValue LocParam to define what should happen when the currentValue is Empty.

    For example, given some class Thing, you could do the following to trigger a redirect when a Thing with a particular ID isn't found.

    Menu.param[Thing]("Thing", "Thing", Thing.find(_), _.id) >>
      MatchWithoutCurrentValue >>
      IfValue(_.isDefined, () => RedirectResponse("/page/to/redirect/to"))
  10. object PlaceHolder extends AnyLocParam with Product with Serializable

    Permalink

    The Loc does not represent a menu itself, but is the parent menu for children (implies HideIfNoKids)

  11. object Snippet

    Permalink
  12. object Stateless extends AnyLocParam with Product with Serializable

    Permalink

    Is the Loc a stateless Loc...

    Is the Loc a stateless Loc... it will be served in stateless mode

  13. object ValueSnippets

    Permalink
  14. def apply(name: String, link: Link[Unit], text: LinkText[Unit], params: List[LocParam[Unit]]): Loc[Unit]

    Permalink
  15. def apply(name: String, link: Link[Unit], text: LinkText[Unit], params: LocParam[Unit]*): Loc[Unit]

    Permalink

    Create a Loc (Location) instance

    Create a Loc (Location) instance

    name

    -- the name of the location. This must be unique across your entire sitemap. It's used to look up a menu item in order to create a link to the menu on a page.

    link

    -- the Link to the page

    text

    -- the text to display when the link is displayed

    params

    -- access test, title calculation, etc.

  16. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  17. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  18. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  19. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  20. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  21. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  22. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  23. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  24. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  25. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  26. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  27. implicit def redirectToFailMsg(in: ⇒ RedirectResponse): FailMsg

    Permalink
  28. implicit def strFuncToFailMsg(in: () ⇒ String): FailMsg

    Permalink
  29. implicit def strToFailMsg(in: ⇒ String): FailMsg

    Permalink
  30. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  31. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  32. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  33. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  34. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from AnyRef

Inherited from Any

Ungrouped