to get stuff out of a can you can do:
1. Pattern matching
having c a Can[String]
c match {
case Full(value) => //do something with the value
case _ =>
}
2. call open_!(if you're sure your can is not empty) or openOr
Br's,
Marius
On Oct 15, 3:22 am, "Charles F. Munat" <[EMAIL PROTECTED]> wrote:
> I must be very dense, but these cans are kicking my butt (kicking my
> can?). No matter what I do, I seem to end up with everything back in the
> can! I just... want... to get... the goodies... OUT!
>
> An example:
>
> How do I extract the URI of the current page from S.request?
>
> I am currently doing something immensely stupid and wrong like this:
>
> S.request.toList.head.location.toList.head.createDefaultLink.toList.head.text
>
> I *know* this is way wrong, but I'm not clever enough, apparently, to
> figure out the puzzle, despite reading through the Can code repeatedly.
> I figure the above works only because what I'm looking for is there,
> which sort of defeats the purpose of the cans...
>
> Can anyone help? This is driving me insane.
>
> Chas.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Lift" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/liftweb?hl=en
-~----------~----~----~----~------~----~------~--~---