spoty-0.1.0.1: Spotify web API wrapper

Safe HaskellNone
LanguageHaskell2010

Utils.Spoty.Types

Description

Object declarations and lenses. Should not be imported by user code. Please view the official documentation.

Note that the distinction between full and simple objects is implemented as an optional Maybe field with details.

Synopsis

Documentation

type URL = Text Source

require :: FromJSON a => Text -> HashMap Text Value -> Parser (Maybe a) Source

Require that a field is present before parsing the corresponding value.

parseStrMap :: MonadPlus m => HashMap k Value -> (k -> Text -> a) -> m [a] Source

Parse a map of key-value entries, wrapped in the given constructor.

class HasType c e | c -> e where Source

Methods

type :: Lens' c e Source

class HasIdentifier c e | c -> e where Source

Methods

identifier :: Lens' c e Source

class HasHeight c e | c -> e where Source

Methods

height :: Lens' c e Source

Instances

class HasPath c e | c -> e where Source

Methods

path :: Lens' c e Source

Instances

class HasWidth c e | c -> e where Source

Methods

width :: Lens' c e Source

Instances

class HasHref c e | c -> e where Source

Methods

href :: Lens' c e Source

class HasItems c e | c -> e where Source

Methods

items :: Lens' c e Source

Instances

HasItems (Paging a) [a] 

class HasLimit c e | c -> e where Source

Methods

limit :: Lens' c e Source

Instances

class HasNext c e | c -> e where Source

Methods

next :: Lens' c e Source

Instances

class HasOffset c e | c -> e where Source

Methods

offset :: Lens' c e Source

Instances

class HasPrevious c e | c -> e where Source

Methods

previous :: Lens' c e Source

Instances

class HasTotal c e | c -> e where Source

Methods

total :: Lens' c e Source

Instances

_pagingItemsLens :: forall a a. Lens (Paging a) (Paging a) [a] [a] Source

class HasGenres c e | c -> e where Source

Methods

genres :: Lens' c e Source

class HasImages c e | c -> e where Source

Methods

images :: Lens' c e Source

class HasName c e | c -> e where Source

Methods

name :: Lens' c e Source

class HasArtists c e | c -> e where Source

Methods

artists :: Lens' c e Source

class HasDiscNumber c e | c -> e where Source

Methods

discNumber :: Lens' c e Source

class HasDurationMs c e | c -> e where Source

Methods

durationMs :: Lens' c e Source

class HasExplicit c e | c -> e where Source

Methods

explicit :: Lens' c e Source

class HasPreviewURL c e | c -> e where Source

Methods

previewURL :: Lens' c e Source

class HasNumber c e | c -> e where Source

Methods

number :: Lens' c e Source

Instances

class HasReleaseDate c e | c -> e where Source

Methods

releaseDate :: Lens' c e Source

class HasTracks c e | c -> e where Source

Methods

tracks :: Lens' c e Source

class HasExternalURLs c e | c -> e where Source

Methods

externalURLs :: Lens' c e Source