Associate key and value Access Pattern

Preview unavailable

You must log in or sign up to view this lesson.

LoginSign up

B03 Clojure Language Basics

Buy nowLearn more

Variables and scope

  • Global Scope
  • Let and Function Argument Scope
  • Dynamic Scope1
  • Scope problems diagnosed

Namespaces

  • Clojure Namespace Declarations
  • Navigating Namespaces at the REPL

Syntax

  • for comprehensions
  • Clojure Function Syntax6

Collections

  • Introduction to Clojure's Collections
  • Data structures
  • Vector collection
  • HashMap collection
  • Set collection2
  • List collection
  • Queue collection
  • Sorted Map collection
  • Sorted Set collection
  • Access patterns
  • Sequential Access Pattern1
  • Remembering Duplicates Access Pattern
  • Lookup by key Access Pattern
  • Associate key and value Access Pattern
  • Dissociate a key and value Access Pattern
  • Count the elements Access Pattern
  • Equality Comparison Access Pattern
  • Removing an item from a set Access Pattern
  • Splitting a sequence Access Pattern
  • Containment Check Access Pattern
  • First-in, first-out Access Pattern
  • Last-in, First-out Access Pattern
  • Usage patterns
  • Entity Usage Pattern10
  • Index Usage Pattern
  • Tuple Usage Pattern
  • Multi-comparison Usage Pattern
  • Transients
  • Usage in an Atom
  • Hybrid Collections
  • Hybrid Types3
  • Vectors and Lists in syntax
  • Lazy sequences
  • Collections vs sequences

Lazy sequences

  • What are lazy sequences?
  • Gotcha: Effects and chunking
  • Gotcha: *print-length*
  • Gotcha: holding onto the head
  • Gotcha: length checks
  • The Benefits of Laziness2

Destructuring

  • Introduction
  • Sequences
  • Maps Part 1
  • Maps Part 21
  • Keyword Arguments
  • Where to Destructure
  • Nested Destructuring
  • Destructuring Examples

Concurrency

  • Delay
  • Promise
  • Future
  • Deref
  • Keeping state consistent with Atoms
  • Sharing state among many threads: Atoms
  • Ref
  • Vars
  • Agents
  • Locking
  • Core Async
  • Threads
  • ExecutorService
  • ForkJoin
  • Reducers

Protocols

  • What Problems do Clojure Protocols Solve?
  • How to define protocols
  • Protocols for Easy Type Conversion
  • Defining a DSL with Protocols1
  • Building a Component Clone