reklama - zainteresowany?

Head First C#. 5th Edition - Helion

Head First C#. 5th Edition
ebook
Autor: Andrew Stellman, Jennifer Greene
ISBN: 9781098141745
stron: 838, Format: ebook
Data wydania: 2024-07-09
Księgarnia: Helion

Cena książki: 245,65 zł (poprzednio: 285,64 zł)
Oszczędzasz: 14% (-39,99 zł)

Dodaj do koszyka Head First C#. 5th Edition

Tagi: C# - Programowanie

What will you learn from this book?

Create apps, games, and more using this engaging, highly visual introduction to C#, .NET, and Visual Studio. In the first chapter you'll dive right in, building a fully functional game using C# and .NET MAUI that can run on Windows, Mac, and even Android and iOS devices. You'll learn how to use classes and object-oriented programming, create 3D games in Unity, and query data with LINQ. And you'll do it all by solving puzzles, doing hands-on exercises, and building real-world applications. Interested in a development career? You'll learn important development techniques and ideas—many who learned to code with this book are now professional developers, team leads, coding streamers, and more. There's no experience required except the desire to learn. And this is the best place to start.

What's so special about this book?

If you've read a Head First book, you know what to expect: a visually rich format designed for the way your brain works. If you haven't, you're in for a treat. With this book, you'll learn C# through a multisensory experience that engages your mind—rather than a text-heavy approach that puts you to sleep.

Dodaj do koszyka Head First C#. 5th Edition

 

Osoby które kupowały "Head First C#. 5th Edition", wybierały także:

  • JÄ™zyk C. Kurs video. Praktyczne wprowadzenie do programowania
  • Wzorce projektowe dla programistów C#. Kurs video
  • C# 9.0 w piguÅ‚ce
  • Gray Hat C#. JÄ™zyk C# w kontroli i Å‚amaniu zabezpieczeÅ„
  • ASP.NET Core 6. Kurs video. Rozwijaj aplikacje webowe z Entity Framework Core

Dodaj do koszyka Head First C#. 5th Edition

Spis treści

Head First C#. 5th Edition eBook -- spis treści

  • Related books from OReilly
    • Other books in OReillys Head First series
  • Table of Contents (the real thing)
  •  
  • How to use this Book Intro
    • Who is this book for?
      • Who should probably back away from this book?
    • We know what youre thinking
    • We know what your brain is thinking
    • Metacognition: thinking about thinking
    • Heres what WE did:
    • Heres what YOU can do to bend your brain into submission
    • README.md
    • The technical review team
    • Shoulders of giants
    • Acknowledgments
      • ...and a few more folks who have been so incredibly supportive over the years
  • 1. Start Building Apps with C# Build something great...fast!
    • Learn C#...and learn to become a great developer
      • ...with a learning system thats effective and fun
    • Write code and explore C# with Visual Studio
      • Visual Studio is your free gateway to C#
    • Install Visual Studio Community Edition
    • Run Visual Studio
    • Create and run your first C# project in Visual Studio
    • You can use Visual Studio Code with Head First C#
    • Install the C# extensions
      • Change the C# debug console setting
    • Create and run your first project in Visual Studio Code
    • Set up Visual Studio Code for the next project
      • First open a folder, then add a project
      • The Command Palette
      • Install .NET MAUI before reading the rest of this chapter
      • If youre using Linux, youll need an Android device for the .NET MAUI projects
    • Lets build a game!
    • Break up large projects into smaller parts
    • Heres how youll build your game
    • Create a .NET MAUI project in Visual Studio
    • Create a .NET MAUI project in Visual Studio Code
    • Run your new .NET MAUI app
      • Stop your MAUI app
    • MAUI apps work on all of your devices
    • Heres the page that youll build
    • Start editing your XAML code
    • Add the XAML for a Button and a Label
    • Use a FlexLayout to make a grid of animal buttons
    • Write C# code to add the animals to the buttons
    • Start editing the PlayAgainButton event handler method
      • Add a C# statement to the event handler method
    • Add more statements to your event handler
    • Add animals to your buttons
    • Run your app!
      • Here are just a few things Git can do for you
    • Visual Studio makes it easy to use Git
    • Add C# code to handle mouse clicks
    • Enter the code for the event handler
    • Run your app and find all the pairs
      • Uh-ohtheres a bug in your code
      • When you find a bug, you need to sleuth it out
    • Finish the game by adding a timer
    • Add a timer to your games code
    • Finish the code for your game
      • Add a field to hold the time elapsed
      • Finish your TimerTick method
    • Even better ifs...
  • 2. Variables, Statements, and Methods Dive into C# code
    • Take a closer look at the files in your console app
      • A statement performs one single action
    • Statements are the building blocks for your apps
    • Statements live inside methods
      • Methods do something
      • Methods help you organize your code
    • Your methods use variables to work with data
      • Declare your variables
      • Variables vary
      • You need to assign values to variables before you use them
      • A few useful types
    • Generate a new method to work with variables
    • Add code that uses operators to your method
    • Use the debugger to watch your variables change
    • Use code snippets to help write loops
    • Use operators to work with variables
    • if statements make decisions
      • if/else statements also do something if a condition isnt true
    • Loops perform an action over and over
      • while loops keep looping statements while a condition is true
      • do/while loops run the statements then check the condition
      • for loops run a statement after each loop
    • Some useful things to keep in mind about C# code
    • Controls drive the mechanics of your user interfaces
      • Meet some of the controls youll use in this book
    • Other controls youll use in this book
    • Build a .NET MAUI app to experiment with controls
    • Create a new app to experiment with controls
    • Explore your new MAUI app and figure out how it works
    • Add an Entry control to your app
    • Add properties to your Entry control
    • Make your Entry control update a Label control
    • Combine horizontal and vertical stack layouts
      • Youll nest one Layout inside another
    • Add a Picker control to display a list of choices
  • Unity Lab #1 Explore C# with Unity
    • Unity is a powerful tool for game design
    • Download Unity Hub
    • Use Unity Hub to create a new project
      • Work with your project in the Unity editor
    • Take control of the Unity layout
      • Choose the Wide layout to match our screenshots
      • Set up Unity to work with Visual Studio
    • Your scene is a 3D environment
    • Unity games are made with GameObjects
    • Use the Move Gizmo to move your GameObjects
    • The Inspector shows your GameObjects components
    • Add a material to your Sphere GameObject
    • Rotate your sphere
      • Move the Scene view camera with the View Tool and Scene Gizmo
      • Get creative!
  • 3. Namespaces and Classes Organizing your code
    • Classes help you organize your code
    • If code is useful, classes can help you reuse it
    • Some methods take parameters and return a value
    • Visual Studio helps you explore parameters and return values
    • Lets build an app that picks random cards
    • Youll use an array to store the cards
    • Create an app with a Main method
      • Create your PickRandomCards app without top-level statements
    • Add a class called CardPicker to your app
    • Use Quick Actions to remove unnecessary using lines
    • Convert between namespace styles
    • Use the new keyword to create an array of strings
      • Heres the code for your finished CardPicker class
    • Anas working on her next game
    • Anas game is evolving...
      • ...so how can Ana make things easier for herself?
    • Build a paper prototype for a classic game
    • Build a MAUI version of your random card app
      • Make your app accessible!
    • Make your MAUI app pick random cards
    • Reuse your CardPicker class
    • Add a using directive to use code in another namespace
    • Anas prototypes look great...
      • ...but what if she wants more than one enemy?
    • Ana can use objects to solve her problem
    • You use a class to build an object
      • An object gets its methods from its class
    • When you create a new object from a class, its called an instance of that class
    • A better solution for Ana...brought to you by objects
      • Theory and practice
    • An instance uses fields to keep track of things
      • Methods are what an object does. Fields are what an object knows.
    • Thanks for the memory
    • Whats on your apps mind
    • Sometimes code can be difficult to read
      • Extremely compact code can be especially problematic
    • Most code doesnt come with a manual
    • Use intuitive class and method names
    • Build a class to work with some guys
    • Theres an easier way to initialize objects with C#
    • Use the C# Interactive window or csi to run C# code
  • 4. Data, Types, Objects, and References Managing your apps data
    • Owen could use our help!
      • Storytelling, fantasy, and mechanics
    • Character sheets store different types of data on paper
    • A variables type determines what kind of data it can store
    • C# has several types for storing integers
    • Types for storing really HUGE and really tiny numbers
    • Lets talk about strings
    • A literal is a value written directly into your code
      • Use suffixes to give your literals types
    • A variable is like a data to-go cup
      • Use the Convert class to explore bits and bytes
    • Other types come in different sizes too
    • 10 pounds of data in a 5-pound bag
    • Casting lets you copy values that C# cant automatically convert to another type
      • So what happened?
      • When you cast a value thats too big, C# adjusts it to fit its new container
    • C# does some conversions automatically
    • When you call a method, the arguments need to be compatible with the types of the parameters
    • Owen is constantly improving his game...
      • ...but the trial and error can be time-consuming
    • Lets help Owen experiment with ability scores
    • Fix the compiler error by adding a cast
      • Add a cast to get the AbilityScoreCalculator class to compile...
      • ...but theres still a bug!
      • Now we can finally fix Owens bugand get the REAL Sharpen answer
    • Use reference variables to access your objects
    • References are like sticky notes for your objects
    • If there arent any more references, your object gets garbage-collected
    • Multiple references and their side effects
    • Two references mean TWO variables that can change the same objects data
    • Objects use references to talk to each other
    • Arrays hold multiple values
      • Use each element in an array like its a normal variable
    • Arrays can contain reference variables
    • null means a reference points to nothing
      • Console.ReadLine returns a null when there are no lines available
    • Use the string? type when a string might be null
      • int.TryParse takes a string? parameter
    • Welcome to Sloppy Joes Budget House o Discount Sandwiches!
    • Sloppy Joes menu app uses a Grid layout
    • Grid controls
      • Use Grid properties to put a control in a cell
    • Define the rows and columns for a Grid
    • Create the Sloppy Joes menu app and set up the grid
      • Heres the XAML for the app
    • The C# code for the main page
    • Can we make the app more accessible?
      • Set the main header so the screen reader narrates it
      • Try setting the item1 labels SemanticProperties.Description instead
    • Use the SetValue method to change a controls semantic properties
  • Unity Lab #2 Write C# Code for Unity
    • C# scripts add behavior to your GameObjects
    • Add a C# script to your GameObject
    • Write C# code to rotate your sphere
    • Add a breakpoint and debug your game
      • Use a hit count to skip frames
    • Use the debugger to understand Time.deltaTime
    • Add a cylinder to show where the Y axis is
    • Add fields to your class for the rotation angle and speed
    • Use Debug.DrawRay to explore how 3D vectors work
      • Use Unity to visualize vectors in 3D
    • Run the game to see the ray in the Scene view
      • Add a duration to the ray so it leaves a trail
    • Rotate your ball around a point in the scene
    • Use Unity to take a closer look at rotation and vectors
    • Get creative!
  • 5. Encapsulation How objects keep their Secrets
    • Lets help Owen roll for damage
    • Create a console app to calculate damage
    • Design a MAUI version of the damage calculator app
      • How your damage calculator app will work
    • Tabletop talk (or maybe...dice discussion?)
    • Lets try to fix that bug
      • Oops! Its still not working
    • Use Debug.WriteLine to print diagnostic information
    • Its easy to accidentally misuse your objects
    • Encapsulation means keeping some data in a class private
      • When in doubt, make it private
    • Use encapsulation to control access to your classs methods and fields
    • But is the RealName field REALLY protected?
    • Private fields and methods can only be accessed from instances of the same class
    • Why encapsulation? Think of an object as an opaque box...
      • Encapsulation makes your classes...
    • Lets use encapsulation to improve the SwordDamage class
      • Is every member of the SwordDamage class public?
      • Are fields or methods being misused?
      • Is there calculation required after setting a field?
      • So what fields and methods really need to be public?
    • Encapsulation keeps your data safe
      • Lets use encapsulation in a class
    • Write a console app to test the PaintballGun class
      • Our class is well-encapsulated, but...
    • Properties make encapsulation easier
      • Replace the GetBalls and SetBalls methods with a property
    • Modify your top-level statements to use the Balls property
      • Debug your PaintballGun class to understand how the property works
    • Auto-implemented properties simplify your code
      • Use the prop snippet to create an auto-implemented property
    • Use a private setter to create a read-only property
      • Make the BallsLoaded setter private
    • What if we want to change the magazine size?
      • But theres a problem...how do we initialize MagazineSize?
    • Use a constructor with parameters to initialize properties
    • Specify arguments when you use the new keyword
    • Initialize fields and properties inline or in the constructor
    • Make the screen reader announce each roll
    • A few useful facts about methods and properties
  • 6. Inheritance Your Objects Family Tree
    • Calculate damage for MORE weapons
    • Use a switch statement to match several candidates
    • One more thing...can we calculate damage for a dagger? And a mace? And a staff? and...
    • When your classes use inheritance, you only need to write your code once
    • Build up your class model by starting general and getting more specific
    • How would you design a zoo simulator?
    • Different animals have different behaviors
    • Every subclass extends its base class
      • C# always calls the most specific method
    • Any place where you can use a base class, you can use one of its subclasses instead
    • Use a colon to extend a base class
    • We know that inheritance adds the base class fields, properties, and methods to the subclass...
      • ...but some birds dont fly!
    • A subclass can override methods to change or replace members it inherited
    • Some members are only implemented in a subclass
    • Use the debugger to understand how overriding works
    • Build an app to explore virtual and override
    • A subclass can hide methods in the base class
      • Hiding methods vs. overriding methods
      • Use the new keyword when youre hiding methods
      • Use different references to call hidden methods
    • Use the override and virtual keywords to inherit behavior
    • A subclass can access its base class using the base keyword
    • When a base class has a constructor, your subclass needs to call it
    • A subclass and base class can have different constructors
    • Its time to finish the job for Owen
      • Use the debugger to really understand how these classes work
    • A class should do one thing
    • Build a beehive management system
    • How the Beehive Management System app works
    • The page uses a grid to lay out the controls for the UI
      • The Bee Jobs box uses a Border with a VerticalStackLayout
    • The Beehive Management System class model
    • All bees in the system extend the Bee class
    • All the constants are in their own static class
    • The worker bees extend the Bee class
    • The Queen class: how she manages the worker bees
    • Heres the code-behind for MainPage.xaml.cs
    • Feedback drives your beehive management game
      • Workers and honey are in a feedback loop
    • The Beehive Management System is turn-based... now lets convert it to real-time
    • Some classes should never be instantiated
    • An abstract class is an intentionally incomplete class
      • Lets plan a trip to another planet
    • Like we said, some classes should never be instantiated
      • Solution: use an abstract class
    • An abstract method doesnt have a body
    • Abstract properties work just like abstract methods
    • The Deadly Diamond of Death
  • Unity Lab #3 GameObject Instances
    • Lets build a game in Unity!
    • Create a new material inside the Materials folder
    • Spawn a billiard ball at a random point in the scene
    • Use the debugger to understand Random.value
    • Turn your GameObject into a prefab
    • Create a script to control the game
    • Attach the GameController script to the Main Camera
    • Press Play to run your code
      • Watch the live instances in the Hierarchy window
    • Use the Inspector to work with GameObject instances
    • Use physics to keep balls from overlapping
    • Get creative!
  • 7. Interfaces, Casting, and is Making classes keep their Promises
    • The beehive is under attack!
      • HiveDefender needs a DefendHive method because enemies can attack at any time
    • We could use casting to call the DefendHive method
      • but what if we add more Bee subclasses that can defend?
    • An interface defines methods and properties that a class must implement
      • but theres no limit to the number of interfaces a class can implement
    • Interfaces let unrelated classes do the same job
    • Get a little practice using interfaces
    • Fireside Chats
    • You cant instantiate an interface, but you can reference an interface
      • If you try to instantiate an interface, your code wont build
      • Use the interface to reference an object you already have
    • Pool Puzzle
    • Pool Puzzle Solution
    • Interface references are ordinary object references
    • The RoboBee 4000 can do a worker bees job without using valuable honey
    • The IWorkers Job property is a hack
    • Use is to check the type of an object
    • Use is to access methods in a subclass
    • What if we want different animals to swim or hunt in packs?
    • Use interfaces to work with classes that do the same job
      • Use the is keyword to check if the Animal is a swimmer or pack hunter
    • Safely navigate your class hierarchy with is
    • C# has another tool for safe type conversion: the as keyword
    • Use upcasting and downcasting to move up and down a class hierarchy
    • A quick example of upcasting
    • Upcasting turns your CoffeeMaker into an Appliance
    • Downcasting turns your Appliance back into a CoffeeMaker
    • Upcasting and downcasting work with interfaces too
    • Interfaces can inherit from other interfaces
    • Interfaces can have static members
    • Default implementations give bodies to interface methods
    • Add a ScareAdults method with a default implementation
    • Data binding updates MAUI controls automatically
    • Add data binding to the default MAUI app
    • Make Moods implement the INotifyPropertyChanged interface
    • Use the PropertyChanged event to make data binding work
    • Polymorphism means that one object can take many different forms
      • Keep your eyes open for polymorphism!
      • The four core principles of object-oriented programming
  • 8. Enums and Collections Organizing your data
    • If a constructor just sets fields, use a primary constructor instead
    • A primary constructor can extend a base constructor
      • Overloaded constructors use this to call the primary constructor
    • Strings dont always work for storing categories of data
    • Enums let you work with a set of valid values
      • An enum defines a new type
    • Enums let you represent numbers with names
    • We could use an array to create a deck of cards
      • but what if you wanted to do more?
    • Arrays can be annoying to work with
    • Lists make it easy to store collections ofanything
    • Lists are more flexible than arrays
    • Lets build an app to store shoes
    • Generic collections can store any type
      • Generic lists are declared using <angle brackets>
    • You can use collection expressions to create Lists
    • Lets create a List of Ducks
      • Use a collection expression to create a List of Ducks
    • Sorting lists can be tricky
      • Lists know how to sort themselves
    • IComparable<Duck> helps your List sort its Ducks
      • An objects CompareTo method compares it to another object
    • Use IComparer to tell your List how to sort
      • Add an IComparer to your project
    • Create an instance of your comparer object
      • Multiple IComparer implementations, multiple ways to sort your objects
    • Comparers can do complex comparisons
    • Overriding a ToString method lets an object describe itself
      • Override the ToString method to see your Ducks in the IDE
    • Update your foreach loops to let your Ducks and Cards write themselves to the console
      • Add a ToString method to your Card object too
    • You can upcast an entire list using IEnumerable<T>
    • Use a Dictionary to store keys and values
      • How to use a Dictionary
    • The Dictionary functionality rundown
      • Your key and value can be different types
    • Write an app that uses a Dictionary
      • Use a collection initializer to create the Dictionary
    • And yet MORE collection types
      • Generic .NET collections implement IEnumerable
    • A queue is FIFOfirst in, first out
    • A stack is LIFOlast in, first out
    • CollectionView is a MAUI control built for displaying collections
    • ObservableCollection is a collection made for data binding
    • Add your Card class to the project
    • Use XAML to instantiate your objects for data binding
    • Modify your app to use a resource Dictionary
    • Modify the event handlers to use the resource Dictionary
    • Use what youve learned to build an app with two decks
  • Unity Lab #4 User Interfaces
    • Add a score that goes up when the player clicks a ball
    • Add two different modes to your game
    • Add game mode to your game
    • Add a UI to your game
      • Use the 2D view to work with the Canvas
    • Set up the Text that will display the score in the UI
    • Add a Button that calls a method to start the game
    • Make the Play Again button and Score Text work
    • Finish the code for the game
    • Get creative!
  • 9. LINQ and Lambdas Get Control of your data
    • Jimmys a Captain Amazing superfan...
    • ...but his collections all over the place
    • Use LINQ to query your collections
    • LINQ works with any sequence
      • LINQ methods enumerate your sequencesjust like foreach loops
    • LINQs query syntax
      • LINQ queries are built from clauses
    • LINQ works with objects
    • Use a LINQ query to finish the app for Jimmy
    • The var keyword lets C# figure out variable types for you
      • When you use var, C# figures out the variables type automatically
    • LINQ is versatile
    • LINQ queries arent run until you access their results
    • Use a group query to separate your sequence into groups
    • Use join queries to merge data from two sequences
    • Use the new keyword to create anonymous types
    • Unit tests help you make sure your code works
      • Add a second project to your solution for the unit tests
    • Start writing your first test method
      • Run the unit test
    • Give your unit tests access to the classes theyre testing
      • Add a project reference so the unit tests can access the classes they need to test
    • One project can only access public classes in another project
      • Make your JimmyLinq classes and enums public
    • Use the Arrange-Act-Assert pattern to write an effective test
      • Use Assert.AreEqual to check that a calculated value matches an expected value
    • Finish your first unit test
    • Write a unit test for the GetReviews method
    • Write unit tests to handle edge cases and weird data
    • Use the => operator to create lambda expressions
    • Refactor a clown with lambdas
    • Use the ?: operator to make your lambdas make choices
    • LINQ queries are made up of methods
      • You can use lambda expressions with methods that take a Func parameter
    • LINQ declarative syntax can be refactored into chained methods
    • Use the => operator to create switch expressions
    • Explore the Enumerable class
      • Enumerable.Empty creates an empty sequence of any type
      • Enumerable.Repeat repeats a value a specific number of times
      • So what exactly is an IEnumerable<T>?
    • Create an enumerable sequence by hand
    • Use yield return to create your own sequences
      • Use the debugger to explore yield return
    • Use yield return to refactor ManualSportSequence
      • Add an indexer to BetterSportSequence
    • Collectioncross
    • Collectioncross solution
  • 10. Reading and Writing Files Save the last byte for me
    • .NET uses streams to read and write data
    • Different streams read and write different things
      • Things you can do with a stream:
    • A FileStream reads and writes bytes in a file
    • Write text to a file in three simple steps
    • The Swindler launches another diabolical plan
      • StreamWriter.WriteLine works just like Console.WriteLine
    • StreamWriter Magnets
    • StreamWriter Magnets Solution
    • Use a StreamReader to read a file
    • Data can go through more than one stream
    • Use the static File and Directory classes to work with files and directories
      • Things you can do with the static File class:
      • Things you can do with the static Directory class:
    • IDisposable makes sure objects are closed properly
      • Use the IDE to explore IDisposable
    • Avoid filesystem errors with using statements
      • Use multiple using statements for multiple objects
    • Use a MemoryStream to stream data to memory
      • Use Encoding.UTF8.GetString to convert byte arrays to strings
    • What happens to an object when its serialized?
    • But what exactly IS an objects state? What needs to be saved?
    • When an object is serialized, all of the objects it refers to get serialized too
    • Use JsonSerializer to serialize your objects
    • JSON only includes data, not specific C# types
    • Next up: well take a deep dive into our data
    • C# strings are encoded with Unicode
    • Visual Studio works really well with Unicode
    • .NET uses Unicode to store characters and text
    • C# can use byte arrays to move data around
    • Use a BinaryWriter to write binary data
    • Use BinaryReader to read the data back in
    • A hex dump lets you see the bytes in your files
      • How to make a hex dump of some plain text
    • Use StreamReader to build a hex dumper
    • Use Stream.Read to read bytes from a stream
    • Modify your hex dumper to read directly from the stream
    • Run your app from the command line
      • Use the args variable to access command-line arguments
    • Pass command-line arguments to an app run in the IDE
  • Unity Lab #5 Raycasting
    • Create a new Unity project and start to set up the scene
    • Set up the camera
    • Create a GameObject for the player
    • Introducing Unitys navigation system
    • Install the AI Navigation package
    • Things youll do with navigation
    • Set up the NavMesh
      • Fix the carved-out hole in your NavMesh
    • Make your player automatically navigate the play area
  • 11. Captain Amazing the Death of the Object
    • The life and death of an object
    • Use the GC class (with caution) to force garbage collection
    • Your last chance to DO something... your objects finalizer
    • When EXACTLY does a finalizer run?
      • You can SUGGEST to .NET that its time to collect the garbage
    • Finalizers cant depend on other objects
      • Dont use finalizers for serialization
    • A struct looks like an object...
      • ...but isnt an object
    • Values get copied; references get assigned
    • Structs are value types; objects are reference types
      • Heres what happened...
    • The stack vs. the heap: more on memory
    • Use out parameters to make a method return more than one value
    • Pass by reference using the ref modifier
    • Use optional parameters to set default values
    • A null reference doesnt refer to any object
    • Non-nullable reference types help you avoid NREs
      • Use encapsulation to prevent your property from ever being null
    • Nullable value types can be null...and handled safely
    • The null-coalescing operator ?? checks for nulls automatically
      • ?? checks for null and returns an alternative
      • ??= assigns a value to a variable only if its null
    • Captain Amazing...not so much
    • Records give your objects value equality automatically
    • Dont modify recordscopy them
      • Use the with keyword to create a modified copy of your Duck
    • Extension methods add new behavior to EXISTING classes
    • Extending a fundamental type: string
  • 12. Exception Handling Putting out fires gets old
    • Your hex dumper reads a filename from the command line
      • But what happens if you give HexDump an invalid filename?
    • When your program throws an exception, the CLR generates an Exception object
    • All Exception objects inherit from System.Exception
    • There are some files you just cant dump
    • What happens when a method you want to call is risky?
    • Handle exceptions with try and catch
    • Use the debugger to follow the try/catch flow
    • If you have code that ALWAYS needs to run, use a finally block
    • Catch-all exceptions handle System.Exception
      • Avoid catch-all exception with multiple catch blocks
    • Pool Puzzle
    • Pool Puzzle Solution
    • Use the right exception for the situation
      • Catch custom exceptions that extend System.Exception
    • Exception Magnets
    • Exception Magnets Solution
    • Exception filters help you create precise handlers
    • The worst catch block EVER: catch-all plus comments
      • You should handle your exceptions, not bury them
    • Temporary solutions are OK (temporarily)
    • Use NuGet to add a logging library to your app
      • Packages add DLLs with classes
    • Add logging to your ExceptionExperiment app
  • Unity Lab #6 Scene Navigation
    • Lets pick up where the last Unity Lab left off
    • Add a platform to your scene
    • Use bake options to make the platform walkable
    • Include the stairs and ramp in the NavMesh
    • Make the player navigate around the obstacles
      • Fix the moving obstacle
    • Get creative!
    • Thank you for reading our book!
      • But wait, theres more! Your journeys just begun...
      • Check out these essential (and amazing!) books written by our friends and colleagues, also published by
  • Index

Dodaj do koszyka Head First C#. 5th Edition

Code, Publish & WebDesing by CATALIST.com.pl



(c) 2005-2024 CATALIST agencja interaktywna, znaki firmowe należą do wydawnictwa Helion S.A.