Profile

Cover photo
Illegal Argument
94 followers|26,226 views
AboutPostsPhotosVideos

Stream

Illegal Argument
owner

Discussion  - 
 
_Episode 131: /tmp'orary disk space.
1
Add a comment...

Illegal Argument

Shared publicly  - 
 
Episode 130: Illegal? No - just an Obversable<Argument>.
Mark, Greg and Richard weekly discussion about topics relating to the Java/JVM space with an Auckland and New Zealand focus.
1
2
Illegal Argument's profile photoMark Derricutt's profile photo
Add a comment...

Illegal Argument
owner

Discussion  - 
 
 
Episode 129 -@Annotations As Architechture.

Long await....  it's already May and this is only the 2nd episode of the year...  wow.
4 comments on original post
2
Add a comment...

Illegal Argument

Shared publicly  - 
 
 
Episode 0b1111111 - The End is Nigh

The final episode of 2014 - it's been real ( or is that float, or double, damn type systems ).
1
Add a comment...

Illegal Argument
owner

Discussion  - 
1
Add a comment...

Illegal Argument
owner

Discussion  - 
 
Episode 123: It's easy as...
1
1
Brett Cooper's profile photoMark Derricutt's profile photoHamish Mackenzie's profile photoIllegal Argument's profile photo
8 comments
 
Yes, but it might be better to use a record, then you can make helper functions like these so that you can easily call functions that just need the database or just need ldap from inside a function that needs both...

    {-# LANGUAGE RecordWildCards #-}

    ...

    data Application = Application {
        ldapFoo :: LdapFoo,
        databaseFoo :: DatabaseFoo}

    liftLdap :: Reader LdapFoo a -> Reader Application a
    liftLdap f = do
        Application {..} <- ask
        return (runReader f ldapFoo)

    liftDatabase :: Reader DatabaseFoo a -> Reader Application a
    liftDatabase f = do
        Application {..} <- ask
        return (runReader f databaseFoo)

You could do the same with a tuple, but would need to update all the run functions each time you added something to the tuple.

If you are sure there is a natural order to the dependencies (you know you would never want LdapFoo without DatabaseFoo) then you could use ReaderT to make a monad stack instead.
Add a comment...
In their circles
2 people
Have them in circles
94 people
Vincent Ma's profile photo
Hugh McKee's profile photo
Manfred Moser's profile photo
Daniel Lewis's profile photo
Claudia Doppioslash's profile photo
Roger Barraud's profile photo
Scott McNew's profile photo
Richard Vowles's profile photo
José Dâmaso's profile photo

Communities

Illegal Argument
owner

Discussion  - 
 
 
Episode 130: Illegal? No - just an Obversable<Argument>.
Mark, Greg and Richard weekly discussion about topics relating to the Java/JVM space with an Auckland and New Zealand focus.
View original post
1
Add a comment...

Illegal Argument

Shared publicly  - 
 
Episode 129 -@Annotations As Architechture.

Long await....  it's already May and this is only the 2nd episode of the year...  wow.
2
1
Mx Uni's profile photoMark Derricutt's profile photoRobert Watkins's profile photoIllegal Argument's profile photo
4 comments
 
Who ever decided that tabs and spaces were meant to be significant - and different from each other - should suffer a death of a thousand indignities...

Other than that, makefiles were okay, I guess.
Add a comment...

Illegal Argument
owner

Discussion  - 
 
Episode 0b1111111 - The End is Nigh

The final episode of 2014 - it's been real ( or is that float, or double, damn type systems ).
1
3
Illegal Argument's profile photoMark Derricutt's profile photoFrank Hale's profile photo
2 comments
 
Must do something about the knocking noise emanating from one of the headset mic's - that noise is annoying as hell to listen to - both during recording and when listening :(
Add a comment...

Illegal Argument

Shared publicly  - 
1
Add a comment...
People
In their circles
2 people
Have them in circles
94 people
Vincent Ma's profile photo
Hugh McKee's profile photo
Manfred Moser's profile photo
Daniel Lewis's profile photo
Claudia Doppioslash's profile photo
Roger Barraud's profile photo
Scott McNew's profile photo
Richard Vowles's profile photo
José Dâmaso's profile photo
Communities
Story
Tagline
Illegal Argument is a JVM orientated technical podcast.