Programming C# 5.0 – Excellent how-to guide for experienced developers ready to learn C# – #bookreview

Programming C# 5.0
Ian Griffiths
(O’Reilly, paperbackKindle)

Ian Griffiths’ new book is for “experienced developers,” not for beginners hoping to learn the basics of programming while also learning C#. The focus is “Building Windows 8, Web, and Desktop Applications for the .NET 4.5 Framework.”

Earlier editions in the Programming C# series have “explained some basic concepts such as classes, polymorphism, and collections,” Griffiths notes. But C# also keeps growing in power and size, which means the page counts of its how-to manuals must keep growing, too, to cover “everything.”

The paperback version of Programming C# 5.0 weighs in at 861 pages and more than three pounds. So Griffiths’ choice to sharpen the book’s focus is a smart one. Beginners can learn the basics of programming in other books and other ways before digging into this edition. And experienced developers will find that the author’s explanations and code examples now have space to go “into rather more detail” than would have been possible if chapters explaining the basics of programming had been packed in, as well.

If you have done some programming and know a class from an array, this book can be your well-structured guide to learning C#. The “basics” are gone, but you still are shown how to create a “Hello World” program—primarily so you can see how new C# projects are created in Visual Studio, Microsoft’s development environment.

C# has been around since 2000 and “can be used for many kinds of applications, including websites, desktop applications, games, phone apps, and command-line utilities,” Griffiths says.

“The most significant new feature in C# 5.0,” he emphasizes, “is support for asynchronous programming.” He notes that “.NET has always offered asynchronous APIs (i.e., ones that do not wait for the operation they perform to finish before returning). Asynchrony is particularly important with input/output(I/O) operations, which can take a long time and often don’t require any active involvement from the CPU except at the start and end of an operation. Simple, synchronous APIs that do not return until the operation completes can be inefficient. They tie up a thread while waiting, which can cause suboptimal performance in servers, and they’re also unhelpful in client-side code, where they can make a user interface unresponsive.”

In the past, however, “the more efficient and flexible asynchronous APIs” have been “considerably harder to use than their synchronous counterparts. But now,” Griffiths points out, “if an asynchronous API conforms to a certain pattern, you can write C# code that looks almost as simple as the synchronous alternative would.”

If you are an experienced programmer hoping to add C# to your language skills, Ian Griffiths’ new book covers much of what you need to know, including how to use XAML (pronounced “zammel”) “to create  applications of the [touch-screen] style introduced by Windows 8” but also applications for desktop computers and Windows Phone.

Yes, Microsoft created C#, but there are other ways to run it, too, Griffiths adds.

“The open source Mono project (http://www.mono-project.com/) provides tools for building C# applications that run on Linux, Mac OS X, iOS, and Android.”

Si Dunn

For more information:  paperback – Kindle

Adobe Edge Animate Preview 7: The Missing Manual – #bookreview #html5 #animation

Adobe Edge Animate Preview 7: The Missing Manual
Chris Grover
(O’Reilly,
paperbackKindle)

Chris Glover’s well-written new book shows you how to build animated HTML 5 graphics for the iPhone, the iPad, and the Web, using familiar Adobe features. By the sixth page of the first chapter, you are using the software to create your first animation.

The only problem is,Adobe released the 1.0 commercial version of its Edge Animate product on Sept. 24, 2012, very soon after this Preview 7 book was published.

And, for a limited time, Adobe was offering Edge Animate 1.0 free with a new membership in Adobe’s Creative Cloud.

Prior to the 1.0 release, seven Preview versions of Adobe Edge Animate were released as free downloads, and user feedback was gathered so the product could be enhanced and expanded.

Preview 7 was released about five weeks prior to the appearance of new 1.0 commercial version. And this book was created to fill a gap that was expected to remain open longer.

Here’s the good news – three items of good news, actually.

First, this book can help you get started with the 1.0 commercial version of Adobe Edge Animate. Second, O’Reilly will soon bring out an Adobe Edge Animate “Missing Manual” that covers the new commercial release. And, third, sources at O’Reilly tell me that readers who purchase this Preview 7 edition of Chris Grover’s book will get access to “the e-book version of Adobe Edge Animate the 1.0 version and all of its updates.”

Adobe Edge Animate Preview 7: The Missing Manual has nine chapters organized into four parts:

Part One:Working with the Stage

  • Chapter 1: Introducing Adobe Edge Animate
  • Chapter 2: Creating and Animating Art
  • Chapter 3: Adding and Formatting Text

Part Two: Animation with Edge Animate

  • Chapter 4: Learning Timeline and Transition Techniques
  • Chapter 5: Triggering Actions
  • Chapter 6: Working Smart with Symbols

Part Three: Edge Animate with HTML 5 and JavaScript

  • Chapter 7: Working with Basic HTML and CSS
  • Chapter 8: Controlling Your Animations with JavaScript and jQuery
  • Chapter 9: Helpful JavaScript Tricks

Part Four: Appendixes

  • Appendix A: Installation and Help
  • Appendix B: Menu by Menu
  • Where keystrokes are appropriate, Chris Grover lists both and does not make you have to translate between systems, as some how-to manuals do.

“Animate works almost precisely the same in its Macintosh and Windows versions,” he assures. “Every button in every dialog box is exactly the same; the software response to ever command is identical. In this book, the illustrations have been given even-handed treatment, rotating between the two operating systems where Animate is at home (Windows 7 and Mac OS X).”

 

Si Dunn

For more information: (O’Reilly, paperback, Kindle)

Version Control with Git, 2nd Ed. – Bring order to software development’s collaborative chaos – #bookreview #programming

Version Control with Git, 2nd Edition
Jon Loeliger and Matthew McCullough
(O’Reilly, paperbackKindle)

When I first took a job in software development, individual programmers controlled code versions themselves, and they jealously guarded their releases with back-ups on multiple diskettes – 5.25” diskettes. The real floppies. (Yep, I’m so old I actually worked with a few 8-inch floppies, too.)

It’s a different world now. Code for one project often is developed, modified, tested and controlled by groups of people, sometimes big groups. And many of those who work with the project’s code are scattered all over the planet.

Thus, maintaining version control and keeping good backups are major management challenges for software developers today. There’s no more going home after work with 10 big floppies in your briefcase as a hedge against your office burning down overnight.

Git is a popular, if somewhat difficult, tool for tracking, branching, merging, and managing code revisions. The authors of Version Control with Git favor the term “version control system (VCS)” for this and other software packages that perform similar functions. (“Source code manager (SCM)” is another popular label.)

In their updated and expanded 2nd edition, here is how they sum up the imperative for strong version control:

“No cautious, creative person starts a project nowadays without a back-up strategy. Because data is ephemeral and be lost easily—through an errant code change or catastrophic disk crash, say— it is wise to maintain a living archive of all work. For text and code projects, the back-up strategy typically includes version control, or tracking and managing revisions. Each developer can make several revisions per day, and the ever-increasing corpus serves simultaneously as repository, project narrative, communication medium, and team and project management tool. Given its pivotal role, version control is most effective when tailored to the working habits and goals of the project team.”

Whether you do or do not yet have experience with a version control system, you can glean important information and numerous useful tips from this book’s 21 chapters and 434 pages. Version Control with Git covers a lot of vital ground in a well-organized how-to fashion, with plenty of code samples and related illustrations.

One example out of its many key lessons: “As the developer of content for a project using Git, you should create your own private copy, or clone, of the repository to do your development. This development repository should serve as your own work area where you can make changes without fear of colliding with, interrupting, or otherwise interfering with another developer.”

In another key lesson, they show how to use git stash, “the mechanism for capturing your work in progress, allowing you to save it and return to it later when convenient….the stash is a quick convenience mechanism that allows a complete and thorough capturing of your index and working directory in one simple command. It leaves your repository clean, uncluttered, and ready for an alternate development direction. Another single command restores that index and working directory state completely, allowing you to resume where you left off.”

In a software development environment where everything is a crisis and priorities change hourly on what should have been finished yesterday, git stash save and git stash pop may become two of your favorite commands.

The book describes installing versions of Git for Linux and Microsoft Windows, and for running within Cygwin. It also can be run on Mac OS X and Solaris systems. Meanwhile, most of the book’s chapters focus on using the Git command line tool. But the new 2nd edition also devotes a chapter to what many Git users consider the most vital tool that has emerged from the big online community that now surrounds Git: GitHub.com.

Developers often clone a repository from GitHub. Several types of public and private repositories also can be created there. And so-called “social coding” is available. Indeed, many open source projects are hosted on GitHub, and some of them attract people who simply watch the coding, while others do coding in personal “forks” that may or not prove helpful to those more officially involved in the project. Yet another popular use of GitHub is finding useful code examples in particular programming languages.

Whether Git is in your working future or it’s already here, or if you’re still wondering if it can help you, definitely check out Version Control with Git.

Si Dunn

Build Awesome Command-Line Applications in Ruby – #programming #bookreview

Build Awesome Command-Line Applications in Ruby
David Bryant Copeland
(Pragmatic Bookshelf,
paperback)

The word “awesome” now is grossly overused in contemporary culture. And I hate it in book titles.

That being said, Build Awesome Command-Line Applications in Ruby is an excellent how-to guide, particularly if you have a little bit of UNIX and some basic Ruby programming in your background.

The book is “aimed at both developers and system administrators who have some familiarity with Ruby and who find themselves automating things on the command line (or wish they could),” David Bryant Copeland writes. And he adds: “Writing command-line apps in Ruby is also a great way to really learn Ruby and become a better programmer, since you can apply it directly to your day-to-day tasks.”

Mac and Linux users will have the easiest time with this book’s code examples. Things get a little bit more complicated for Windows users, especially those with no UNIX experience and not much programming background, either. The author, fortunately, lays out some workarounds.

For example, on UNIX systems, the first line of code commonly is called the shebang. In a piece of Ruby code, the shebang might look something like this: #!/usr/bin/ruby. (That example tells where the Ruby interpreter is installed.) But, at a Windows command prompt, if Ruby has been installed correctly and is in the path, the # character simply will be interpreted as the start of a comment line, and the rest of the shebang will be ignored when code is run directly, such as: ruby hello_world.rb.

In this book, David Bryant Copeland’s focus definitely is code. “There is a lot of code,” he says, “and we’ll do our best to take each new bit of it step by step.” As the book progresses, two command-line applications are developed, enhanced, and improved. One is a database-backup app, and the other is a command suite, “an app that provides a set of commands, each representing a different function of a related concept.”

This is not a Ruby primer, so get some experience in that language first before tackling this book. But if you are now reasonably comfortable with Ruby coding on a graphical user interface (GUI) and want some new challenges, consider moving to the command line and use this excellent book as your guide.

The requirements are minimal: a free Ruby download and a text editor or a UNIX-like shell. But the payoff is very good.

In his 10 chapters, the author discusses and illustrates “every detail of command-line application development, from user input, program output, and code organization to code handling, testing, and distribution” while the two example applications are created, tested, and enhanced.

There is plenty to learn, and Build Awesome Command-Line Applications in Ruby does a fine job of  leading you through the process in short-chapter steps.

Si Dunn

Learn the Kinect API – New Microsoft ‘Start Here!’ guide shows how – #bookreview

Learn the Kinect™ API
Rob Miles
(Microsoft Press, paperback, Kindle)

The Kinect sensor  is a popular peripheral for Microsoft’s XBox 360 video game systems and Windows PCs. The device contains a video camera, a directional microphone system, and a depth sensor.

Software developers are using the device “to advance the field of computer interaction in all kinds of exciting ways,” the author notes. “It is now possible to create programs that use the Kinect sensor to create a computer interface with the ability to recognize users and understand their intentions using a ‘natural’ user interface consisting of gestures and spoken commands. In addition, the device’s capabilities have a huge range of possible applications, from burglar alarms to robot controllers.”

If you want to learn how to program with the Kinect application programming interface (API), this new book in the popular Microsoft “Start Here!” series can get you moving along the right path toward becoming a developer.

But there are three key assumptions that may slow your start. You are expected to “have a reasonable understanding of .NET development using the C# programming language.” And: “You should be familiar with the Visual Studio 2010 development environment and object-oriented programming development.”

Also, “if you are a C++ developer who wishes to learn how to interact with the Kinect sensor from unmanaged C++ programs, you will find that the code samples supplied will not [emphasis added] provide this information.” All of the code samples are written in C#.

Rob Miles, a programming professor at the United Kingdom’s University of Hull, has organized his well-written, 250-page book into four parts:

  • Part I: Getting Started – Provides an overview of the Kinect and how to hook it up and get it working with your PC.
  • Part II: Using the Kinect Sensor – Covers sensor initialization and introduces each of Kinect’s data sources –video, depth, and sound – and how to use them in programs.
  • Part III: Creating Advanced User Interfaces – Illustrates how the Kinect SDK performs body tracking and how programs can use this information. Also shows how Kinect data can be combined to create augmented-reality applications.
  • Part IV: Kinect in the Real World – Focuses on how the Kinect can interact with external devices, such as MIDI devices and robots.

Learn the Kinect™ API offers several ideas for how you can use the Kinect’s video, sound, and depth-response capabilities in your own programs. One example is using the Kinect’s directional microphone feature so that a spoken password “only works when you say it in one part of [a] room, or you could have different [spoken] passwords for different parts of the room,” Miles points out.

It’s a bit of understatement to say that Rob Miles enjoys working with the Kinect device. “I’ve had,” he writes, “more wow moments with this little sensor bar than I’ve had with much more expensive toys that I’ve played with over time.”

Si Dunn

Understanding IPv6, 3rd Edition – Welcome to the new, improved & BIGGER Internet – #bookreview #microsoft #windows

Understanding IPv6, 3rd Edition
Joseph Davies
(Microsoft Press, paperback, list price $49.99; Kindle edition, list price $39.99)

The Internet can now expand into a much bigger realm than was possible before the worldwide launch of IPv6 (Internet Protocol version 6) on June 6, 2012.

The web most of us use has long relied on IPv4, the circa-1981 Internet Protocol built around 32-bit addresses. This scheme can accommodate approximately 4.3 billion unique addresses worldwide. On a planet where (1) the population now has surpassed 7 billion and (2) many of us now have multiple devices connected to the Web, Internet Protocol version 4 recently has been in dire danger of running out of unique addresses.

IPv6 will fix that problem and offer several important new enhancements, as long as we don’t find ways to expand the Internet to parallel universes or to the people on a few trillion distant planets. IPv6 uses a 128-bit addressing scheme that can accommodate more than 340 trillion trillion trillion unique addresses. So go ahead. Get online with that second iPad, third smart phone or fourth laptop.

IPv4 and IPv6 are now running in a dual stack that supports both addressing schemes. The transition from IPv4 to IPv6 is not seamless, however. A lot of work remains to be done by major Internet service providers (ISPs), web companies, hardware manufacturers, network equipment providers and many others to enable IPv6 on their products and services.

Joseph Davies, author of Understanding IPv6, has been writing about IPv6 since 1999. His new 674-page third edition provides both a detailed overview of IPv6 and a detailed focus on how to implement it, within a limited range of Windows products.

“There are,” he notes, “different versions of the Microsoft IPv6 protocol for Windows….I have chosen to confine the discussion to the IPv6 implementation in Windows Server 2012, Windows Server 2008 R2, Windows Server 2008, Windows 8, Windows 7, and Windows Vista.”

This well-written and well-organized book is not for beginners. Its intended audience includes:

  • Windows networking consultants and planners
  • Microsoft Windows network administrators
  • Microsoft Certified Systems Engineers (MCSEs) and Microsoft Certified Trainers (MCTs)
  • General technical staff
  • Information technology students

Davies and Microsoft offer downloadable companion content for this book: Microsoft Network Monitor 3.4 (a network sniffer for capturing and viewing frames); and PowerPoint 2007 training slides that can be used along with the book to teach IPv6.

If you need a guide to best practices for using IPv6 in a Windows network, definitely consider getting Understanding IPv6, 3rd Edition.

Si Dunn

Introducing Windows Server 2012 – A guide to what’s coming in a much-anticipated release – #bookreview #microsoft

Introducing Windows Server® 2012
Mitch Tulloch with the Microsoft Server Team
(Microsoft Press, paperback, list price $14.99; Kindle edition,
list price $0.00)

 The anticipated release date for the new version of Microsoft Server®  is sometime between the third quarter of 2012 and early 2013. And this book’s introduction hails it as “probably the most significant release of the Windows Server platform ever.”

Windows Server® 2012, it states, will offer “an innovative new user interface, powerful new management tools, enhanced Windows PowerShell support, and hundreds of new features in the areas of networking, storage and virtualization.”

There also will be major emphasis on cloud computing. The product has been “designed for the cloud from the ground up and provides a foundation for building both public and private cloud solutions,” the book declares.

Introducing Windows Server® 2012 is “based on beta,” according to the cover disclaimer. And, according to the author, the book  “represents a ‘first look’ based on the public beta release of Windows Server 2012 and is intended to help IT professionals familiarize themselves with the capabilities of the new platform.”

The 235-page book is divided into five chapters:

  • Chapter 1 presents “The business need for Windows Server® 2012.” Not surprisingly, the main focus is on cloud computing and multi-server platforms.
  • Chapter 2’s focus is “Foundation for building your private cloud” and how the new product can provide “a solid foundation for building dynamic, highly scalable, multi-tenant cloud environments.”
  • Chapter 3 looks at the Windows Server® 2012 features and capabilities that can create a “[h]ighly available, easy-to-manage multi-server platform.”
  • Chapter 4 discusses how you can use the product to “[d]eploy web applications on premises and in the cloud,” with its “scalable and elastic web platform” and “[s]upport for open standards.”
  • Chapter 5 focuses on Windows Server® 2012 features and capabilities that are key to “[e]nabling the modern workstyle.” The author states: “Today’s business users want things simple. They want to be able to access their desktop applications, and data virtually anywhere, from any device, and have the full Windows experience. And from an IT perspective, this must be done securely and in ways that can ensure compliance at all times.”

Since this book is a “first look” written prior to the ready-to-manufacture (RTM) date, some of its screenshots, feature descriptions and stated capabilities may differ somewhat from the product that will be released.

But this overview can be a useful – and inexpensive — guide to have handy while considering whether to move to, or upgrade to, Windows Server® 2012.

Si Dunn