Java Design Patterns, Part 2 of 7: Factory and Singleton Pattern
Interactive

Java Design Patterns, Part 2 of 7: Factory and Singleton Pattern

LearnNow Online
Updated Jul 20, 2020

Course description

Design patterns are proven solutions for solving problems without reinventing the wheel.Adding them to your high level toolkit will make you a better developer. In this course you'll become familiar with the Factory, Singleton and Command design patterns.

Each LearnNowOnline training course is made up of Modules (typically an hour in length). Within each module there are Topics (typically 15-30 minutes each) and Subtopics (typically 2-5 minutes each). There is a Post Exam for each Module that must be passed with a score of 70% or higher to successfully and fully complete the course.


Prerequisites

Core Java language is necessary for this course. if you do not have this please see: Java SE 9, Part 1 of 14: Install and Introduction Java SE 9, Part 2 of 14: IntelliJ and Operators Java SE 9, Part 3 of 14: classes and Objects Java SE 9, Part 4 of 14: Composition and Arrays Java SE 9, Part 5 of 14: Interfaces and Streams Java SE 9, Part 6 of 14: Swing and Flash Card Application Java SE 9, Part 7 of 14: Intro to Java FX Java SE 9, Part 8 of 14: Application Login Java SE 9, Part 9 of 14: Expressions, DB and Threads Java SE 9, Part 10 of 14: Project Setup and Login Java SE 9, Part 11 of 14: Errors and Listview Java SE 9, Part 12 of 14: Custom Lists and Updates Java SE 9, Part 13 of 14: Vaadin and HTTP Introduction Java SE 9, Part 14 of 14: Weather Application


Meet the expert

Paulo Dichone

Paulo Dichone graduated from Whitworth University with a B.S in Computer Science in 2009 and has worked building Android and iOS mobiles apps as well as web applications. Since 2014 he's been an online instructor teaching over 40,000 students from 170 countries in how to program Java and build Android Applications.

Video Runtime

97 Minutes

Time to complete

166 Minutes

Course Outline

Factory and Singleton Patterns

Factory Design Pattern (30:18)

  • Introduction (00:08)
  • Simple Factory (07:12)
  • Factory Pattern Part 1 (02:45)
  • Factory Pattern Part 1.1 (11:40)
  • Factory Pattern Part 1.2 (08:24)
  • Summary (00:08)

Singleton Design Pattern (26:33)

  • Introduction (00:08)
  • Singleton Pattern (03:25)
  • First Singleton Pattern (05:53)
  • Singleton Synchronized (07:04)
  • Eager Singleton Creation (03:43)
  • Double-Checked Locking Singleton (06:10)
  • Summary (00:08)

Command Design Pattern (23:44)

  • Introduction (00:08)
  • Command Pattern Intro (08:54)
  • Command Class and Gameboy Classes (05:48)
  • MarioUpCommand (08:45)
  • Summary (00:08)

Command Example (16:30)

  • Introduction (00:08)
  • Final Command Pattern (08:31)
  • Invoker (07:43)
  • Summary (00:08)
;