Clojure Cookbook Recipes for Functional Programming 13620

Паперова книга
13620
04.05
669

Все про “Clojure Cookbook Recipes for Functional Programming”

Від видавця

With more than 150 detailed recipes, this cookbook shows experienced Clojure developers how to solve a variety of programming tasks with this JVM language. The solutions cover everything from building dynamic websites and working with databases to network communication, cloud computing, and advanced testing strategies. And more than 60 of the world's best Clojurians contributed recipes. Each recipe includes code that you can use right away, along with a discussion on how and why the solution works, so you can adapt these patterns, approaches, and techniques to situations not specifically covered in this cookbook. Master built-in primitive and composite data structures Create, develop and publish libraries, using the tool Leiningen Interact with the local computer that's running your application Manage communication network protocols and libraries Use techniques for connecting to and using a variety of databases Build and maintain dynamic websites, using the Ring HTTP server library Tackle application tasks such as packaging, distributing, profiling, and logging Take on cloud computing and heavyweight distributed data crunching Dive into unit, integration, simulation, and property-based testing Clojure Cookbook is a collaborative project with contributions from some of the world's best Clojurians, whose backgrounds range from aerospace to social media, banking to robotics, AI research to e-commerce.

Зміст

Chapter 1 : Primitive Data
Introduction
Changing the Capitalization of a String
Cleaning Up Whitespace in a String
Building a String from Parts
Treating a String as a Sequence of Characters
Converting Between Characters and Integers
Formatting Strings
Searching a String by Pattern
Pulling Values Out of a String Using Regular Expressions
Performing Find and Replace on Strings
Splitting a String into Parts
Pluralizing Strings Based on a Quantity
Converting Between Strings, Symbols, and Keywords
Maintaining Accuracy with Extremely Large/Small Numbers
Working with Rational Numbers
Parsing Numbers
Truncating and Rounding Numbers
Performing Fuzzy Comparison
Performing Trigonometry
Inputting and Outputting Integers with Different Bases
Calculating Statistics on Collections of Numbers
Performing Bitwise Operations
Generating Random Numbers
Working with Currency
Generating Unique IDs
Obtaining the Current Date and Time
Representing Dates as Literals
Parsing Dates and Times Using clj-time
Formatting Dates Using clj-time
Comparing Dates
Calculating the Length of a Time Interval
Generating Ranges of Dates and Times
Generating Ranges of Dates and Times Using Java Native Types
Retrieving Dates Relative to One Another
Working with Time Zones
Converting a Unix Timestamp to a Date
Converting a Date to a Unix Timestamp
Chapter 2 : Composite Data
Introduction
Creating a List
Creating a List from an Existing Data Structure
"Adding" an Item to a List
"Removing" an Item from a List
Testing for a List
Creating a Vector
"Adding" an Item to a Vector
"Removing" an Item from a Vector
Getting the Value at an Index
Setting the Value at an Index
Creating a Set
Adding and Removing Items from Sets
Testing Set Membership
Using Set Operations
Creating a Map
Retrieving Values from a Map
Retrieving Multiple Keys from a Map Simultaneously
Setting Keys in a Map
Using Composite Values as Map Keys
Treating Maps as Sequences (and Vice Versa)
Applying Functions to Maps
Keeping Multiple Values for a Key
Combining Maps
Comparing and Sorting Values
Removing Duplicate Elements from a Collection
Determining if a Collection Holds One of Several Values
Implementing Custom Data Structures: Red-Black Trees—Part I
Implementing Custom Data Structures: Red-Black Trees—Part II
Chapter 3 : General Computing
Introduction
Running a Minimal Clojure REPL
Interactive Documentation
Exploring Namespaces
Trying a Library Without Explicit Dependencies
Running Clojure Programs
Running Programs from the Command Line
Parsing Command-Line Arguments
Creating Custom Project Templates
Building Functions with Polymorphic Behavior
Extending a Built-In Type
Decoupling Consumers and Producers with core.async
Making a Parser for Clojure Expressions Using core.match
Querying Hierarchical Graphs with core.logic
Playing a Nursery Rhyme
Chapter 4 : Local I/O
Introduction
Writing to STDOUT and STDERR
Reading a Single Keystroke from the Console
Executing System Commands
Accessing Resource Files
Copying Files
Deleting Files or Directories
Listing Files in a Directory
Memory Mapping a File
Reading and Writing Text Files
Using Temporary Files
Reading and Writing Files at Arbitrary Positions
Parallelizing File Processing
Parallelizing File Processing with Reducers
Reading and Writing Clojure Data
Using edn for Configuration Files
Emitting Records as edn Values
Handling Unknown Tagged Literals When Reading Clojure Data
Reading Properties from a File
Reading and Writing Binary Files
Reading and Writing CSV Data
Reading and Writing Compressed Files
Working with XML Data
Reading and Writing JSON Data
Generating PDF Files
Making a GUI Window with Scrollable Text
Chapter 5 : Network I/O and Web Services
Introduction
Making HTTP Requests
Performing Asynchronous HTTP Requests
Sending a Ping Request
Retrieving and Parsing RSS Data
Sending Email
Communicating over Queues Using RabbitMQ
Communicating with Embedded Devices via MQTT
Using ZeroMQ Concurrently
Creating a TCP Client
Creating a TCP Server
Sending and Receiving UDP Packets
Chapter 6 : Databases
Introduction
Connecting to an SQL Database
Connecting to an SQL Database with a Connection Pool
Manipulating an SQL Database
Simplifying SQL with Korma
Performing Full-Text Search with Lucene
Indexing Data with ElasticSearch
Working with Cassandra
Working with MongoDB
Working with Redis
Connecting to a Datomic Database
Defining a Schema for a Datomic Database
Writing Data to Datomic
Removing Data from a Datomic Database
Trying Datomic Transactions Without Committing Them
Traversing Datomic Indexes
Chapter 7 : Web Applications
Introduction
Introduction to Ring
Using Ring Middleware
Serving Static Files with Ring
Handling Form Data with Ring
Handling Cookies with Ring
Storing Sessions with Ring
Reading and Writing Request and Response Headers in Ring
Routing Requests with Compojure
Performing HTTP Redirects with Ring
Building a RESTful Application with Ліберейтор
Templating HTML with Enlive
Templating with Selmer
Templating with Hiccup
Rendering Markdown Documents
Building Applications with Luminus
Chapter 8 : Performance and Production
Introduction
AOT Compilation
Packaging a Project into a JAR File
Creating a WAR File
Running an Application as a Daemon
Alleviating Performance Problems with Type Hinting
Fast Math with Primitive Java Arrays
Simple Profiling with Timbre
Logging with Timbre
Releasing a Library to Clojars
Using Macros to Simplify API Deprecations
Chapter 9 : Distributed Computation
Introduction
Building an Activity Feed System with Storm
Data Processing with an Extract Transform Load (ETL) Pipeline
Aggregating Large Files
Testing Cascalog Workflows
Checkpointing Cascalog Jobs
Explaining a Cascalog Query
Running a Cascalog Job on Elastic MapReduce
Chapter 10 : Testing
Introduction
Unit Testing
Testing with Midje
Thoroughly Testing by Randomizing Inputs
Finding Values That Cause Failure
Running Browser-Based Tests
Tracing Code Execution
Avoiding Null-Pointer with Exceptions core.typed
Verifying Java Interop Using core.typed
Type Checking Higher-Order Functions with core.typed
Index
Colophon

Анотація

Clojure Cookbook Recipes for Functional Programming

Рецензії

0

Всі характеристики

Товар входить до категорії

  • Самовивіз з відділень поштових операторів від 45 ₴ - 80 ₴
  • Доставка поштовими сервісами - тарифи перевізника
Схожі товари
Hands-on Rust: Effective Learning through 2D Game Development and Play. 1st Ed.
244804
Herbert Wolverson
1'700 ₴
Powerful Command-Line Applications in Go. Build Fast and Maintainable Tools. 1st Ed.
244806
Ricardo Gerardi
1'800 ₴
Introducing Microsoft Quantum Computing for Developers. Using the Quantum Development Kit and Q#. 1st Ed.
244686
Johnny Hooyberghs
1'900 ₴
Learn JavaFX 17. Building User Experience and Interfaces with Java. 2nd Ed.
244696
Kishori Sharan, Peter Sp?th
2'100 ₴
Practical Rust Projects: Build Serverless, AI, Machine Learning, Embedded, Game, and Web Applications 2nd ed. Edition
255276
Shing LyuAndrew Rzeznik
2'100 ₴
Go for Java Programmers: Learn the Google Go Programming Language. 1st Ed.
244681
Barry Feigenbaum, Ph.D.
2'200 ₴
Pro Jakarta Persistence in Jakarta EE 10. An In-Depth Guide to Persistence in Enterprise Java Development. 4th Ed.
244722
Lukas Jungmann, Mike Keith
2'200 ₴
iOS 15 Programming Fundamentals with Swift: Swift, Xcode, and Cocoa Basics. 1st Ed.
244758
Matt Neuberg
2'200 ₴
Pro Go. The Complete Guide to Programming Reliable and Efficient Software Using Golang. 1st Ed.
244721
Adam Freeman
2'500 ₴
Head First Swift. A Learner's Guide to Programming with Swift. 1st Ed.
244755
Paris Buttfield-Addison, Jon Manning
2'500 ₴