Hoogle Search

Within LTS Haskell 24.52 (ghc-9.10.3)

Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.

  1. quoteForCommandLine :: String -> String

    hledger-lib Hledger.Utils.String

    Try to single- and backslash-quote a string as needed to make it usable as an argument on a (sh/bash) shell command line. At least, well enough to handle common currency symbols, like $. Probably broken in many ways.

    >>> quoteForCommandLine "a"
    "a"
    
    >>> quoteForCommandLine "\""
    "'\"'"
    
    >>> quoteForCommandLine "$"
    "'\\$'"
    

  2. encodedFormBody :: [(ByteString, ByteString)] -> OutputStream Builder -> IO ()

    http-streams Network.Http.Client

    Specify name/value pairs to be sent to the server in the manner used by web browsers when submitting a form via a POST request. Parameters will be URL encoded per RFC 2396 and combined into a single string which will be sent as the body of your request. You use this partially applied:

    let nvs = [("name","Kermit"),
    ("type","frog")]
    ("role","stagehand")]
    
    sendRequest c q (encodedFormBody nvs)
    
    Note that it's going to be up to you to call setContentType with a value of "application/x-www-form-urlencoded" when building the Request object; the postForm convenience (which uses this encodedFormBody function) takes care of this for you, obviously.

  3. multipartFormBody :: Boundary -> [Part] -> OutputStream Builder -> IO ()

    http-streams Network.Http.Client

    Build a list of parts into an upload body. You use this partially applied:

    boundary <- randomBoundary
    
    let q = buildRequest1 $ do
    http POST "/api/v1/upload"
    setContentMultipart boundary
    
    let parts =
    [ simplePart "metadata" Nothing metadata
    , filePart "submission" (Just "audio/wav") filepath
    ]
    
    sendRequest c q (multipartFormBody boundary parts)
    
    You must have called setContentMultipart when forming the request or the request body you are sending will be invalid and (obviously) you must pass in that same Boundary value when calling this function.

  4. postForm :: URL -> [(ByteString, ByteString)] -> (Response -> InputStream ByteString -> IO β) -> IO β

    http-streams Network.Http.Client

    Send form data to a server via an HTTP POST request. This is the usual use case; most services expect the body to be MIME type application/x-www-form-urlencoded as this is what conventional web browsers send on form submission. If you want to POST to a URL with an arbitrary Content-Type, use post.

  5. parseParamsFor :: forall (b :: Type -> Type) p . (HasParams a, HasParams b, ProtectionIndicator p) => Proxy b -> Maybe Object -> Maybe Object -> Parser (a p)

    jose Crypto.JOSE.Header

    No documentation available.

  6. waitForAnimationFrame :: JSM Double

    jsaddle Language.Javascript.JSaddle.Monad

    On GHCJS this is waitForAnimationFrame. On GHC it will delay the execution of the current batch of asynchronous command when they are sent to JavaScript. It will not delay the Haskell code execution. The time returned will be based on the Haskell clock (not the JavaScript clock).

  7. waitForAnimationFrame :: JSM Double

    jsaddle Language.Javascript.JSaddle.Run

    On GHCJS this is waitForAnimationFrame. On GHC it will delay the execution of the current batch of asynchronous command when they are sent to JavaScript. It will not delay the Haskell code execution. The time returned will be based on the Haskell clock (not the JavaScript clock).

  8. newtype JSObjectForSend

    jsaddle Language.Javascript.JSaddle.Types

    Wrapper used when sending a Object to the JavaScript context

  9. JSObjectForSend :: JSValueForSend -> JSObjectForSend

    jsaddle Language.Javascript.JSaddle.Types

    No documentation available.

  10. newtype JSStringForSend

    jsaddle Language.Javascript.JSaddle.Types

    Wrapper used when sending a JString to the JavaScript context

Page 650 of many | Previous | Next