
Set up the Java JDK by ensuring Java 8 or 9 is installed, verify with the Java compiler, and use Oracle Technical Network downloads or Linux PPA if needed.
Please download the zip file attached to this lecture, then follow the video to unpack it and import it into IntelliJ IDEA
This lecture explains invariance in generic types and introduces covariance with a food bowl example, showing how plus F makes a fruit bowl usable as a food bowl.
Explore how types can be members of a class, using abstract types, upper bounds, and a type projection to define and access internal and external types like food and apple.
Explains infix type notation for two-parameter types in Scala, showing the equivalence between infix and square-bracket forms and how parentheses affect scope.
Explore the Scala type system's implicit instances and type classes, then a simple retry pattern using nonfatal, by-name bindings and an explicit retry type.
Register and use implicit parameters in Scala by marking values as implicit, enabling compiler lookup by type for features like retry parameters and execution context in futures.
Implement a json writer type class in Scala by adding an implicit string writer that quotes strings via interpolation, then extend with a double writer using toString without quotes.
Learn to derive a JSON writer for lists of any type using implicit type classes and context bounds, reducing boilerplate and enabling seamless composition when the items have a writer.
Scala Advanced, Part 1
The Escalate Software Scala Advanced course is intended for experienced Scala developers looking to improve their skills, particularly for library and API design and development. It covers topics needed to be effective in producing high quality, correct, powerful and flexible Scala libraries that are still easy to use by others.
Part 1 provides in depth and thorough knowledge of the Scala type system, an important precursor to any library development. We start off with a look at the dangers, and safe use, of mutable shared state in Scala, covering properties and caching. From there we delve into the Scala type system including:
Generics
Co- and Contra-Variance
Upper and Lower Bounds
Type Inference
Type Parameters and Type Members
Path Dependent Types
Refinement Types
Structural Types
Recursive Types
F-bounded Polymorphism
The final two modules then move on to the secondary Implicits type system that augments the regular Scala type system, covering:
Simple Implicit Parameters
Type Classes
Implicit classes, objects and methods
Type Class Composition
Implicit Constraints
=:= and <:<
Implicit Class and Type Tags
Implicit Conversions
extends AnyVal
And more.
After completing this course you will understand the Scala type system in a way that lets you construct your own well designed APIs, reason about type abstraction and calculus, apply implicit constraints and augment the language rules, and much more.
Parts 2 and 3 (available separately) cover topics like best practices, idioms, patterns, advanced functional programming, asynchronous programming, parser-combinators, macros, performance profiling and optimization, and much more. These parts rely on information presented during this advanced part 1 course.