舉報

會員
Learning Scala Programming
ThisbookisforprogrammerswhochoosetogetagripoverScalatowriteconcurrent,scalable,andreactiveprograms.Nopriorexperiencewithanyprogramminglanguageisrequiredtolearntheconceptsexplainedinthisbook.Knowledgeofanyprogramminglanguagewouldhelpthereaderunderstandingconceptsfasterthough.
最新章節(jié)
- Leave a review - let other readers know what you think
- Other Books You May Enjoy
- Summary
- ScalaMock – a native library to mock objects
- Matchers
- Assertions
品牌:中圖公司
上架時間:2021-06-30 18:30:39
出版社:Packt Publishing
本書數(shù)字版權由中圖公司提供,并由其授權上海閱文信息技術有限公司制作發(fā)行
- Leave a review - let other readers know what you think 更新時間:2021-06-30 19:08:34
- Other Books You May Enjoy
- Summary
- ScalaMock – a native library to mock objects
- Matchers
- Assertions
- Testing in style using ScalaTest
- Setting up for testing
- ScalaTest
- Behavior driven development (BDD)
- Scenario
- Step 4 - repeat steps 1 to 3
- Step 3 - refactor the code to improve the quality
- Step 2 - write code to pass the failing test
- Step 1 - write a test that will fail
- The process of TDD
- The why and what of TDD
- Testing in Scala
- Summary
- Creating Observables
- React to RxScala
- Reactive extensions
- Reactive programming
- Programming with Reactive Extensions
- Summary
- Parallel collections
- Working with Promises
- Why not compose two or more Futures?
- What if Future computations go wrong?
- Working with Futures
- Asynchronous programming
- Executor and ExecutionContext
- Locks and synchronization
- Understanding processes and threads
- Building blocks of concurrency
- Concurrent programming
- Concurrent Programming in Scala
- Summary
- Testing actors
- Applying the supervision strategy
- Default supervision strategy
- OneForOne versus AllForOne strategy
- Supervising fault in our actors
- Actor communication via messages and its semantics
- The preStart and postStop hooks
- Stopping Actors
- The tell versus ask versus forward method
- Writing our first Actor
- Setting up the environment
- Hello world in Akka
- How the Actor life cycle works
- Selecting existing actorRefs via actorSelection
- Actor references and paths
- Props
- Understanding the Actor system
- What's up with the Actor Model?
- Why do we care about Akka?
- Introduction to Akka
- Summary
- Type-classes ahead!
- Looking for implicits
- Implicit conversions
- The implicitly method
- Implicit parameters
- Implicits - what and why
- Either left or right
- Using the Option way
- Exception handling – the old way
- Working with Implicits and Exceptions
- Summary
- Type-classes
- Abstract versus parameterized types
- Type bounds
- Abstract types
- When to use what type of variance relation
- Variance under inheritance
- Type erasure
- Container types
- Type parameter names
- Another way around - generic classes and traits
- Here comes type parameterization
- Why so serious about types?
- Advanced Functional Programming
- Summary
- Type parameterization
- Combinators
- Tail call optimization
- Lazy declaration
- Option type
- Matching a constructor
- Matching a constant
- Matching a variable
- Different ways we can pattern match
- Pattern matching
- For expressions
- Using Powerful Functional Constructs
- Summary
- Partially applied functions
- Converting a function with multiple parameters to curried form
- Currying
- Higher-order functions
- What are closures?
- Methods or functions?
- Functions versus methods
- Methods
- Function literals
- More on Functions
- Summary
- Sealed traits
- Visibility rules
- Importing packages
- Chaining package statements
- Nested package statements
- Multiple package statements in a file
- Package statements
- Packaging and importing
- Linearization
- Traits as stackable modifications
- Traits as composable mix-ins
- Traits as mix-ins
- Traits
- Default and parameterized constructors
- Misusing inheritance
- Dynamic binding in function invocation
- Restricting inheritance – final keyword
- Overriding data and behavior
- Subtyping versus subclassing
- Extending classes
- Class inheritance
- Composition and inheritance
- Next Steps in Object-Oriented Scala
- Summary
- Case classes
- Companion objects
- Objects as singletons
- The final classes
- Abstract classes and traits
- Abstract classes
- Classes
- Object-Oriented Scala Basics
- Summary
- Collection performance
- Choosing a collection
- Converting a Java collection into a Scala collection
- ParVector
- ParArray
- Parallel collections in Scala
- Rich operations performed on collections
- Array
- StringBuilder
- ListBuffer
- ArrayBuffer
- Ranges
- Immutable queue
- Immutable stack
- Vector
- Streams
- SortedSet
- Map
- List
- Commonly used collections in Scala
- Set
- Map
- Sequences
- Seq
- Iterable
- Traversable
- Hierarchy of collections in Scala
- Differences between the root and immutable collections
- Immutable and mutable collections
- Motivation
- Getting Familiar with Scala Collections
- Summary
- Partial functions
- Call by value
- Call by name
- Evaluation strategies
- Function literals
- Calling a function while passing named arguments
- Calling a function with a default parameter value
- Passing a variable number of arguments
- Calling a function
- Nesting of functions
- Function syntax
- Giving Meaning to Programs with Functions
- Summary
- Pattern matching
- The if else conditional expression
- Conditional statements
- The ideal way to write recursive functions
- Limitations of recursion
- Why recursion over iteration?
- Recursion
- The for yield expressions
- The for expressions
- The do while loop
- The while Loop
- The for loop
- Looping
- Shaping our Scala Program
- Summary
- The raw interpolator
- f Interpolator
- The s interpolator
- String Interpolators
- Wrapper classes
- Operator precedence
- Bitwise operators
- Logical operators
- Relational operators
- Arithmetic operators
- Operators in Scala
- Type inference
- Null and Nothing
- Boolean
- Unit
- AnyVal
- AnyRef
- AnyVal and AnyRef
- Any
- Scala's class hierarchy
- Data types
- Function literals
- Tuple literals
- Symbol literals
- String literals
- Character literals
- Boolean literals
- Floating point literals
- Integer literals
- Literals
- Vals and vars
- What is underneath a Scala program?
- Building Blocks of Scala
- Summary
- Running our first program
- Scala IDEs
- Scala REPL
- SBT installation
- Java installation
- Working with Scala
- Online support
- Extensive language
- Smart IDEs
- Now available for the frontend
- Asynchronous versus parallel versus concurrent programming
- Asynchronous code
- Concurrency made easy
- Type is the core
- Best of both worlds
- Super smart syntax
- Runs on JVM
- Scala advantages
- Scala is multi-paradigm
- Object-oriented versus functional paradigms
- A programming paradigm
- Introduction to Scala
- Getting Started with Scala Programming
- Reviews
- Get in touch
- Conventions used
- Download the example code files
- To get the most out of this book
- What this book covers
- Who this book is for
- Preface
- Packt is searching for authors like you
- About the reviewer
- About the author
- Contributors
- PacktPub.com
- Why subscribe?
- Packt Upsell
- Title Page
- coverpage
- coverpage
- Title Page
- Packt Upsell
- Why subscribe?
- PacktPub.com
- Contributors
- About the author
- About the reviewer
- Packt is searching for authors like you
- Preface
- Who this book is for
- What this book covers
- To get the most out of this book
- Download the example code files
- Conventions used
- Get in touch
- Reviews
- Getting Started with Scala Programming
- Introduction to Scala
- A programming paradigm
- Object-oriented versus functional paradigms
- Scala is multi-paradigm
- Scala advantages
- Runs on JVM
- Super smart syntax
- Best of both worlds
- Type is the core
- Concurrency made easy
- Asynchronous code
- Asynchronous versus parallel versus concurrent programming
- Now available for the frontend
- Smart IDEs
- Extensive language
- Online support
- Working with Scala
- Java installation
- SBT installation
- Scala REPL
- Scala IDEs
- Running our first program
- Summary
- Building Blocks of Scala
- What is underneath a Scala program?
- Vals and vars
- Literals
- Integer literals
- Floating point literals
- Boolean literals
- Character literals
- String literals
- Symbol literals
- Tuple literals
- Function literals
- Data types
- Scala's class hierarchy
- Any
- AnyVal and AnyRef
- AnyRef
- AnyVal
- Unit
- Boolean
- Null and Nothing
- Type inference
- Operators in Scala
- Arithmetic operators
- Relational operators
- Logical operators
- Bitwise operators
- Operator precedence
- Wrapper classes
- String Interpolators
- The s interpolator
- f Interpolator
- The raw interpolator
- Summary
- Shaping our Scala Program
- Looping
- The for loop
- The while Loop
- The do while loop
- The for expressions
- The for yield expressions
- Recursion
- Why recursion over iteration?
- Limitations of recursion
- The ideal way to write recursive functions
- Conditional statements
- The if else conditional expression
- Pattern matching
- Summary
- Giving Meaning to Programs with Functions
- Function syntax
- Nesting of functions
- Calling a function
- Passing a variable number of arguments
- Calling a function with a default parameter value
- Calling a function while passing named arguments
- Function literals
- Evaluation strategies
- Call by name
- Call by value
- Partial functions
- Summary
- Getting Familiar with Scala Collections
- Motivation
- Immutable and mutable collections
- Differences between the root and immutable collections
- Hierarchy of collections in Scala
- Traversable
- Iterable
- Seq
- Sequences
- Map
- Set
- Commonly used collections in Scala
- List
- Map
- SortedSet
- Streams
- Vector
- Immutable stack
- Immutable queue
- Ranges
- ArrayBuffer
- ListBuffer
- StringBuilder
- Array
- Rich operations performed on collections
- Parallel collections in Scala
- ParArray
- ParVector
- Converting a Java collection into a Scala collection
- Choosing a collection
- Collection performance
- Summary
- Object-Oriented Scala Basics
- Classes
- Abstract classes
- Abstract classes and traits
- The final classes
- Objects as singletons
- Companion objects
- Case classes
- Summary
- Next Steps in Object-Oriented Scala
- Composition and inheritance
- Class inheritance
- Extending classes
- Subtyping versus subclassing
- Overriding data and behavior
- Restricting inheritance – final keyword
- Dynamic binding in function invocation
- Misusing inheritance
- Default and parameterized constructors
- Traits
- Traits as mix-ins
- Traits as composable mix-ins
- Traits as stackable modifications
- Linearization
- Packaging and importing
- Package statements
- Multiple package statements in a file
- Nested package statements
- Chaining package statements
- Importing packages
- Visibility rules
- Sealed traits
- Summary
- More on Functions
- Function literals
- Methods
- Functions versus methods
- Methods or functions?
- What are closures?
- Higher-order functions
- Currying
- Converting a function with multiple parameters to curried form
- Partially applied functions
- Summary
- Using Powerful Functional Constructs
- For expressions
- Pattern matching
- Different ways we can pattern match
- Matching a variable
- Matching a constant
- Matching a constructor
- Option type
- Lazy declaration
- Tail call optimization
- Combinators
- Type parameterization
- Summary
- Advanced Functional Programming
- Why so serious about types?
- Here comes type parameterization
- Another way around - generic classes and traits
- Type parameter names
- Container types
- Type erasure
- Variance under inheritance
- When to use what type of variance relation
- Abstract types
- Type bounds
- Abstract versus parameterized types
- Type-classes
- Summary
- Working with Implicits and Exceptions
- Exception handling – the old way
- Using the Option way
- Either left or right
- Implicits - what and why
- Implicit parameters
- The implicitly method
- Implicit conversions
- Looking for implicits
- Type-classes ahead!
- Summary
- Introduction to Akka
- Why do we care about Akka?
- What's up with the Actor Model?
- Understanding the Actor system
- Props
- Actor references and paths
- Selecting existing actorRefs via actorSelection
- How the Actor life cycle works
- Hello world in Akka
- Setting up the environment
- Writing our first Actor
- The tell versus ask versus forward method
- Stopping Actors
- The preStart and postStop hooks
- Actor communication via messages and its semantics
- Supervising fault in our actors
- OneForOne versus AllForOne strategy
- Default supervision strategy
- Applying the supervision strategy
- Testing actors
- Summary
- Concurrent Programming in Scala
- Concurrent programming
- Building blocks of concurrency
- Understanding processes and threads
- Locks and synchronization
- Executor and ExecutionContext
- Asynchronous programming
- Working with Futures
- What if Future computations go wrong?
- Why not compose two or more Futures?
- Working with Promises
- Parallel collections
- Summary
- Programming with Reactive Extensions
- Reactive programming
- Reactive extensions
- React to RxScala
- Creating Observables
- Summary
- Testing in Scala
- The why and what of TDD
- The process of TDD
- Step 1 - write a test that will fail
- Step 2 - write code to pass the failing test
- Step 3 - refactor the code to improve the quality
- Step 4 - repeat steps 1 to 3
- Scenario
- Behavior driven development (BDD)
- ScalaTest
- Setting up for testing
- Testing in style using ScalaTest
- Assertions
- Matchers
- ScalaMock – a native library to mock objects
- Summary
- Other Books You May Enjoy
- Leave a review - let other readers know what you think 更新時間:2021-06-30 19:08:34