Search found 500 matches

Author Message

Программист

Post Yesterday 15:55

[Quote]

Разработка приложений на С++ с использованием Boost
Год издания: 2020
Автор: Полухин Антон
Издательство: ДMK
ISBN: 978-5-97060-868-5
Язык: Русский
Формат: PDF
Качество: Издательский макет или текст (eBook)
Интерактивное оглавление: Да
Количество страниц: 346
Описание: Если вы хотите воспользоваться преимуществами Boost и языка C++ и не путаться, какую библиотеку в какой ситуации использовать, тогда эта книга для вас!
Начиная с основ, вы перейдете к изучению того, как библиотеки Boost упрощают разработку приложений. Увидите, какую работу можно выполнить во время компиляции и на что способны контейнеры Boost. Научитесь разрабатывать качественные, быстрые и портативные приложения. От манипулирования изображениями до графов, каталогов, таймеров, файлов и работы в сети - каждый найдет для себя интересную тему. Напишите программу один раз и используйте ее в операционных системах Linux, Windows, macOS и Android. Обратите внимание, что знания, полученные в ходе прочтения этой книги, не устареют, поскольку все больше и больше библиотек Boost становятся частью стандарта C++.
Эта книга предназначена для разработчиков, стремящихся улучшить свои знания о Boost, и тех, кто хочет упростить процесс разработки приложений. Предполагается, что читатель знаком с C++ и имеет базовые знания стандартной библиотеки.

Примеры страниц

Оглавление

Предисловие от издательства 20
Об авторе 21
О рецензентах 22
Вступительное слово автора 23
Вступительное слово от сообщества С++ 24
Предисловие 25
Глава 1. Приступаем к написанию приложения 29
Глава 2. Управление ресурсами 65
Глава 3. Преобразование и приведение 91
Глава 4. Уловки времени компиляции 115
Глава 5. Многопоточность 137
Глава 6. Манипулирование задачами 167
Глава 7. Манипулирование строками 205
Глава 8. Метапрограммирование 225
Глава 9. Контейнеры 253
Глава 10. Сбор информации о платформе и компиляторе 283
Глава 11. Работа с системой 299
Глава 12. Касаясь верхушки айсберга 325
Предметный указатель 344

Программист

Post 23-Jan-2021 16:00

[Quote]

Спортивное программирование
Год издания: 2020
Автор: Халим С., Халим Ф.
Издательство: ДМК
ISBN: 978-5-97060-758-9
Язык: Русский
Формат: PDF
Качество: Издательский макет или текст (eBook)
Интерактивное оглавление: Да
Количество страниц: 604
Описание: Книга содержит задачи по программированию, аналогичные тем, которые используются на соревнованиях мирового уровня (в частности, ACM ICPC и IOI). Помимо задач разного типа приводятся общие рекомендации для подготовки к соревнованиям, касающиеся классификации заданий, анализа алгоритмов и пр. Кроме стандартных тем (структуры данных и библиотеки, графы, математика, вычислительная геометрия) авторы затрагивают и малораспространенные - им посвящена отдельная глава.
В конце каждой главы приводятся краткие решения заданий, не помеченных звездочкой, или даются подсказки к ним. Задания сложного уровня (помеченные звездочкой) требуют самостоятельной проработки.
Издание адресовано читателям, которые готовятся к соревнованиям по программированию или просто любят решать задачи по информатике. Для изучения материала требуются элементарные знания из области методологии программирования и знакомство хотя бы с одним из двух языков программирования -C/C++ или Java.

Примеры страниц

Оглавление

Вступление 11
Предисловие 13
От издательства 27
Об авторах этой книги 28
Список сокращений 30
Глава 1. Введение 32
Глава 2. Структуры данных и библиотеки 76
Глава 3. Некоторые способы решения задач 124
Глава 4. Графы 197
Глава 5. Математика 293
Глава 6. Обработка строк 349
Глава 7. (Вычислительная) Геометрия 398
Глава 8. Более сложные темы 436
Глава 9. Малораспространенные темы 487
Приложение А. uHunt 562
Приложение В. Благодарности 567
Список используемой литературы 569
Предметный указатель 574

Программист

Post 21-Jan-2021 10:10

[Quote]

Простой Python
Год издания: 2021
Автор: Любанович Б.
Издательство: Питер
ISBN: 978-5-4461-1639-3
Язык: Русский
Формат: PDF/ePub
d: Бестселлеры O’Reilly
Качество: Издательский макет или текст (eBook)
Интерактивное оглавление: Да
Количество страниц: 592
Описание: Простой Python» познакомит вас с одним из самых популярных языков программирования. Книга идеально подойдет как начинающим, так и опытным программистам, желающим добавить Python к списку освоенных языков.
Любому программисту нужно знать не только язык, но и его возможности. Вы начнете с основ Python и его стандартной библиотеки. Узнаете, как находить, загружать, устанавливать и использовать сторонние пакеты. Изучите лучшие практики тестирования, отладки, повторного использования кода и получите полезные советы по разработке. Примеры кода и упражнения помогут в создании приложений для различных целей.
Что изменилось?
- Абсолютно новые 100 страниц (там есть котики).
- Глав стало большое, но они стали короче.
- Появилась глава, посвященная типам данных, переменным и именам.
- Добавился рассказ о новых возможностях Python, таких как f-строки.
- Обновилась информация о сторонних библиотеках.
- Новые примеры кода.
- Дан обзор библиотеки asyncio.
- Рассмотрен новый стек технологий: контейнеры, облачные технологии, data science и машинное обучение.
Что осталось неизменным?
- Примеры c утками и плохими стихотворениями. Они навечно с нами.

Примеры страниц

1

Оглавление

Введение 26
Благодарности 33
Об авторе 34
Часть I. Основы Python
Глава 1. Python: с чем его едят 36
Глава 2. Данные: типы, значения, переменные и имена 55
Глава 3. Числа 67
Глава 4. Выбираем с помощью оператора if 82
Глава 5. Текстовые строки 91
Глава 6. Создаем циклы с помощью ключевых слов while и for 113
Глава 7. Кортежи и списки 119
Глава 8. Словари и множества 144
Глава 9. Функции 166
Глава 10. Ой-ой-ой: объекты и классы 194
Глава 11. Модули, пакеты и программы 224
Часть II. Python на практике
Глава 12. Обрабатываем данные 242
Глава 13. Календари и часы 271
Глава 14. Файлы и каталоги 283
Глава 15. Данные во времени: процессы и конкурентность 302
Глава 16. Данные в коробке: надежные хранилища 327
Глава 17. Данные в пространстве: сети 368
Глава 18. Распутываем Всемирную паутину 400
Глава 19. Быть питонщиком 431
Глава 20. Пи-Арт 474
Глава 21. За работой 487
Глава 22. Python в науке 503
Приложения
Приложение А. Аппаратное и программное обеспечение для начинающих программистов 520
Приложение Б. Установка Python 3 530
Приложение В. Нечто совершенно иное: async 538
Приложение Г. Ответы к упражнениям 544
Приложение Д. Вспомогательные таблицы 587
Эпилог 591

Программист

Post 16-Jan-2021 19:25

[Quote]

C# 9 and .NET 5 - Modern Cross-Platform Development (5th edition) / C# 9 и .NET 5 - Современная кроссплатформенная разработка (5-е издание)
Год издания: 2020
Автор: Price Mark J. / Прайс Марк Дж.
Издательство: Packt
ISBN: 9781800568105
Язык: Английский
Формат: PDF/epub
Качество: Издательский макет или текст (eBook)
Интерактивное оглавление: Да
Количество страниц: 822
Описание: In C# 9 and .NET 5 – Modern Cross-Platform Development, Fifth Edition, expert teacher Mark J. Price gives you everything you need to start programming C# applications.
This latest edition uses the popular Visual Studio Code editor to work across all major operating systems. It is fully updated and expanded with a new chapter on the Microsoft Blazor framework.
The book’s first part teaches the fundamentals of C#, including object-oriented programming and new C# 9 features such as top-level programs, target-typed new object instantiation, and immutable types using the record keyword. Part 2 covers the .NET APIs, for performing tasks like managing and querying data, monitoring and improving performance, and working with the file system, async streams, serialization, and encryption. Part 3 provides examples of cross-platform apps you can build and deploy, such as websites and services using ASP.NET Core or mobile apps using Xamarin.Forms.
By the end of the book, you will have acquired the understanding and skills you need to use C# 9 and .NET 5 to create websites, services, and mobile apps.
What you will learn
- Build your own types with object-oriented programming
- Query and manipulate data using LINQ
- Build websites and services using ASP.NET Core 5
- Create intelligent apps using machine learning
- Use Entity Framework Core and work with relational databases
- Discover Windows app development using the Universal Windows Platform and XAML
- Build rich web experiences using the Blazor framework
- Build mobile applications for iOS and Android using Xamarin.Forms
Who this book is for
This book is best for C# and .NET beginners, or programmers who have worked with C# in the past but feel left behind by the changes in the past few years. This book doesn't expect you to have any C# or .NET experience; however, you should have a general understanding of programming.
Students and professionals with a science, technology, engineering, or mathematics (STEM) background can certainly benefit from this book.

Примеры страниц

Оглавление

Hello, C#! Welcome, .NET Core!
Speaking C#
Controlling Flow and Converting Types
Writing, Debugging, and Testing Functions
Building Your Own Types with Object-Oriented Programming
Implementing Interfaces and Inheriting Classes
Understanding and Packaging .NET Types
Working with Common .NET Types
Working with Files, Streams, and Serialization
Protecting Your Data and Applications
Working with Databases Using Entity Framework Core
Querying and Manipulating Data with LINQ
Improving Performance and Scalability with Multitasking
Introducing Practical Applications of C# and .NET
Building Websites Using ASP.NET Core Razor Pages
Building Websites Using the Model-View-Controller Pattern
Building Websites Using a Content Management System
Building and Consuming Web Services
Building Intelligent Apps Using Machine Learning
Building Web User Interfaces Using Blazor
Building Cross-Platform Mobile Apps Using Xamarin.Forms
Code: https://github.com/markjprice/cs9dotnet5/archive/master.zip

Программист

Post 16-Jan-2021 18:15

[Quote]

Pro Cryptography and Cryptanalysis with C++20: Creating and Programming Advanced Algorithms / Профессиональные криптография и криптоанализ с C++20: создание и программирование продвинутых алгоритмов
Год издания: 2021
Автор: Mihailescu M.I., Nita S.L. / Михайлеску М.Ю., Нита С.Л.
Издательство: Apress
ISBN: 978-1-4842-6586-4
Язык: Английский
Формат: PDF/epub
Качество: Издательский макет или текст (eBook)
Интерактивное оглавление: Да
Количество страниц: 470
Описание: Develop strong skills and a passion for writing cryptography algorithms and security schemes/modules using C++ 20 and its new features. You will find the right methods of writing advanced cryptographic algorithms (such as, elliptic curve cryptography algorithms, lattice-based cryptography, searchable encryption, and homomorphic encryption), examine internal cryptographic mechanisms, and discover common ways in which the algorithms could be implemented and used correctly in practice.
The authors avoid the complexities of the mathematical background by explaining its mathematical basis in terms that a programmer can easily understand. They show how “bad” cryptography creeps in during implementation and what “good” cryptography should look like. They do so by showing and comparing the advantages and disadvantages based on processing time, execution time, and reliability.
What You Will Learn:
  • Understand where and why cryptography is used and how it gets misused
  • Discover what modern cryptography algorithms and methods are used for
  • Design and implement advanced cryptographic mechanisms
  • See how C++20 and its new features are impacting the future of implementing cryptographic algorithms
  • Practice the basics of public key cryptography, including ECDSA signatures and more
  • Find out how most of the algorithms can be broken
Who This Book Is For:
Professional programmers, developers, and software engineers who are developing cryptography algorithms and security schemes/modules in C++. Prior C++ programming and IDE experience and some basic experience of cryptography concepts (symmetric and asymmetric) highly recommended.

Примеры страниц

Оглавление

Part I: Foundations
Chapter 1: Getting Started in Cryptography and Cryptanalysis
Chapter 2: Cryptography Fundamentals
Chapter 3: Mathematical Background and Its Applicability
Chapter 4: Large Integer Arithmetic
Chapter 5: Floating-Point Arithmetic
Chapter 6: New Features in C++20
Chapter 7: Secure Coding Guidelines
Chapter 8: Cryptography Libraries in C/C++20
Part II: Pro Cryptography
Chapter 9: Elliptic-Curve Cryptography
Chapter 10: Lattice-Based Cryptography
Chapter 11: Searchable Encryption
Chapter 12: Homomorphic Encryption
Chapter 13: Ring Learning with Errors Cryptography
Chapter 14: Chaos-Based Cryptography
Chapter 15: Big Data Cryptography
Chapter 16: Cloud Computing Cryptography
Part III: Pro Cryptanalysis
Chapter 17: Getting Started with Cryptanalysis
Chapter 18: Cryptanalysis Attacks and Techniques
Chapter 19: Linear and Differential Cryptanalysis
Chapter 20: Integral Cryptanalysis
Chapter 21: Brute Force and Buffer Overflow Attacks
Chapter 22: Text Characterization
Chapter 23: Implementation and Practical Approach of Cryptanalysis Methods

Программист

Post 15-Jan-2021 15:55

[Quote]

Artificial Intelligence. A Modern Approach. Second edition / Искусственный интеллект. Современный подход. Второе издание
Год издания: 2007
Автор: Stuart J. Russel, Peter Norvig / Стюарт Рассел, Питер Норвиг
Переводчик: Птицына К.
Издательство: Издательский дом ‘‘Вильямс’’
ISBN: 978-5-8459-0887-2
Язык: Русский
Формат: PDF
Качество: Издательский макет или текст (eBook)
Интерактивное оглавление: Нет
Количество страниц: 1408
Описание:
В книге представлены все современные достижения и изложены идеи, которые были сформулированы в исследованиях, проводившихся в течение последних пятидесяти лет, а также собраны на протяжении двух тысячелетий в областях знаний, ставших стимулом к развитию искусственного интеллекта как науки проектирования рациональных агентов. Теоретическое описание иллюстрируется многочисленными алгоритмами, реализации которых в виде готовых программ на нескольких языках программирования находятся на сопровождающем книгу Web-узле. Книга предназначена для использования в базовом университетском курсе или в последовательности курсов по специальности. Применима в качестве основного справочника для аспирантов, специализирующихся в области искусственного интеллекта, а также будет небезынтересна профессионалам, желающим выйти за пределы избранной ими специальности. Благодаря кристальной ясности и наглядности изложения вполне может быть отнесена к лучшим образцам научно-популярной литературы.
Искусственный интеллект - вопрос, которому посвящена книга Стюарта Рассела и Питера Норвига "AIMA" ("Artificial Intelligence: A Modern Approach") - «Искусственный интеллект: современный подход». Стержневой темой "AIMA" является идея интеллектуального агента (intelligent agent). На страницах этого издания излагаются:
• основы математической логики,
• теории вероятностей, теории непрерывных функций,
• раскрывается суть таких понятий, как "восприятие", "рассуждение", "обучение" и "действие".
Стюарт Рассел и Питер Норвиг определяют искусственный интеллект как науку об агентах, получающих из своей среды результаты актов восприятия и выполняющих соответствующие действия. Авторы рассматривают разнообразные способы представления функций, реализуемых агентами, среди которых
• продукционные системы,
• реактивные агенты,
• условные планировщики в реальном масштабе времени,
• нейронные сети и системы, действующие на основе теории решений.
Помимо сугубо теоретической части, в "AIMA" представлено множество примеров алгоритмов, версии которых, реализованные на различных языках программирования.
Питер Норвиг, один из соавторов книги, является директором подразделения компании Google.
Известный эксперт делится накопленным опытом, дает профессиональные советы и помогает всем заинтересованным читателям совершить путешествие в поисках электронного Грааля, имя которому - искусственный интеллект.
AIMA написана понятным и доступным языком и является прекрасным пособием для студентов университетов, учащихся специализированных курсов, аспирантов, программистов, изучающих искусственный интеллект. Кроме того, книга будет весьма полезна для разработчиков интеллектуального ПО и профессионалов, желающих расширить рамки избранной ими специальности.
Stuart Russell / Стюарт Рассел - Human Compatible: Artificial Intelligence and the Problem of Control / Совместимость. Как контролировать искусственный интеллект [2021, EPUB, RUS]

Примеры страниц

Мои остальные раздачи - [url=tracker.php?rid=43141996]https://rutracker.org/forum/tracker.php?rid=43141996[/url]

Программист

Post 13-Jan-2021 18:15

[Quote]

Pivotal Certified Professional Core Spring 5 Developer Exam, 2nd edition
Год издания: 2020
Автор: Cosmina Iuliana
Издательство: Apress
ISBN: 978-1-4842-5136-2
Язык: Английский
Формат: PDF/epub
Качество: Издательский макет или текст (eBook)
Интерактивное оглавление: Да
Количество страниц: 1014
Описание: Pass the Pivotal Certified Professional exam for Core Spring, based on the latest Spring Framework 5, using source code examples, study summaries, and mock exams. This book now includes WebFlux, reactive programming, and more found in Spring 5. You'll find a descriptive overview of certification-related Spring modules and a single example application demonstrating the use of all required Spring modules.
Furthermore, in Pivotal Certified Professional Core Spring 5 Developer Exam, Second Edition, each chapter contains a brief study summary and question set, and the book’s free downloadable source code package includes one mock exam (50 questions – like a real exam). After using this study guide, you will be ready to take and pass the Pivotal Certified Professional exam.
When you become Pivotal Certified, you will have one of the most valuable credentials in Java. Pivotal certification helps you advance your skills and your career, and get the maximum benefit from Spring. Passing the exam demonstrates your understanding of Spring and validates your familiarity with: container-basics, aspect oriented programming (AOP), data access and transactions, Spring Security, Spring Boot, microservices, and Spring model-view-controller (MVC). Good luck!
What You Will Learn:
• Understand the core principles of Spring Framework 5
• Use dependency injection
• Work with aspects in Spring and do AOP (aspect oriented programming)
• Control transactional behavior and work with SQL and NoSQL databases
• Create and secure web applications based on Spring MVC
• Get to know the format of the exam and the type of questions in it
• Create Spring microservices applications
Who This Book Is For:
Spring developers who have taken the Pivotal Core Spring class are eligible to take the Pivotal Certified Professional exam.

Примеры страниц

Оглавление

Chapter 1: Book Overview
Chapter 2: Spring Bean Lifecycle and Configuration
Chapter 3: Testing Spring Applications
Chapter 4: Aspect-Oriented Programming with Spring
Chapter 5: Data Access
Chapter 6: Spring Web
Chapter 7: Spring Security
Chapter 8: Spring REST
Chapter 9: Monitoring Spring Applications
Chapter 10: Spring and Kotlin
Chapter 11: Microservices with Spring Cloud
Chapter 12: Building Reactive Applications Using Spring
Code: https://github.com/Apress/pivotal-certified-pro-spring-dev-exam-02/archive/master.zip

Программист

Post 09-Jan-2021 22:55

[Quote]

Write Great Code (in 3 volumes) / Пиши отличный код (в 3-х томах)
Год издания: 2020
Автор: Hyde Randell / Хайд Ранделл
Издательство: No Starch Press
ISBN: 978-1-71850-036-5, 978-1-59327-855-7, 978-1-59327-981-3
Язык: Английский
Формат: PDF/epub
Качество: Издательский макет или текст (eBook)
Интерактивное оглавление: Да
Количество страниц: 476, 660, 376
Описание: Understanding the Machine, the first volume in the landmark Write Great Code series by Randall Hyde, explains the underlying mechanics of how a computer works.
This, the first volume in Randall Hyde's Write Great Code series, dives into machine organization without the extra overhead of learning assembly language programming. Written for high-level language programmers, Understanding the Machine fills in the low-level details of machine organization that are often left out of computer science and engineering courses.
Learn:
• How the machine represents numbers, strings, and high-level data structures, so you'll know the inherent cost of using them.
• How to organize your data, so the machine can access it efficiently.
• How the CPU operates, so you can write code that works the way the machine does.
• How I/O devices operate, so you can maximize your application's performance when accessing those devices.
• How to best use the memory hierarchy to produce the fastest possible programs.
NEW IN THIS EDITION, COVERAGE OF:
• Programming languages like Swift and Java
• Code generation on modern 64-bit CPUs
• ARM processors on mobile phones and tablets
• Newer peripheral devices
• Larger memory systems and large-scale SSDs
Great code is efficient code. But before you can write truly efficient code, you must understand how computer systems execute programs and how abstractions in programming languages map to the machine's low-level hardware. After all, compilers don't write the best machine code; programmers do. This book gives you the foundation upon which all great software is built.
-
Explains how compilers translate high-level language source code (like code written in Python) into low-level machine code (code that the computer can understand) to help readers understand how to produce the best low-level, computer readable machine code.
In the beginning, most software was written in assembly, the CPU's low-level language, in order to achieve acceptable performance on relatively slow hardware. Early programmers were sparing in their use of high-level language code, knowing that a high-level language compiler would generate crummy, low-level machine code for their software. Today, however, many programmers write in high-level languages like Python, C/C++/C#, Java, Swift. The result is often sloppy, inefficient code.
But you don't need to give up the productivity and portability of high-level languages in order to produce more efficient software.
In this second volume of the Write Great Code series, you'll learn:
  • How to analyze the output of a compiler to verify that your code does, indeed, generate good machine code
  • The types of machine code statements that compilers typically generate for common control structures, so you can choose the best statements when writing HLL code
  • Just enough 80x86 and PowerPC assembly language to read compiler output
  • How compilers convert various constant and variable objects into machine data, and how to use these objects to write faster and shorter programs
New to this edition, coverage of:
  • Programming languages like Swift and Java
  • Code generation on modern 64-bit CPUs
  • ARM processors on mobile phones and tablets
  • Stack-based architectures like the Java Virtual Machine
  • Modern language systems like the Microsoft Common Language Runtime
With an understanding of how compilers work, you'll be able to write source code that they can translate into elegant machine code. That understanding starts right here, with Write Great Code, Volume 2: Thinking Low-Level, Writing High-Level.


-
Re-engineer your approach to programming. This third volume in the Write Great Code series will help you create readable and maintainable code that will generate awe from fellow programmers.
The field of software engineering may value team productivity over individual growth, but legendary computer scientist Randall Hyde wants to make promising programmers into masters of their craft. To that end, Engineering Software,the latest volume in Hyde's highly regarded Write Great Code series, offers his signature in-depth coverage of everything from development methodologies and strategic productivity to object-oriented design requirements and system documentation.
You'll learn:
• Why following the software craftsmanship model can lead you to do your best work
• How to utilize traceability to enforce consistency within your documentation
• The steps for creating your own UML requirements with use-case analysis
• How to leverage the IEEE documentation standards to create better software
This advanced apprenticeship in the skills, attitudes, and ethics of quality software development reveals the right way to apply engineering principles to programming. Hyde will teach you the rules, and show you when to break them. Along the way, he offers illuminating insights into best practices while empowering you to invent new ones.
Brimming with resources and packed with examples, Engineering Software is your go-to guide for writing code that will set you apart from your peers.

Примеры страниц

Оглавление

Volume 1:
Chapter 1: What You Need to Know to Write Great Code . . . . . . . . . . . . . . . . . . . . . . 1
Chapter 2: Numeric Representation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
Chapter 3: Binary Arithmetic and Bit Operations . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37
Chapter 4: Floating-Point Representation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61
Chapter 5: Character Representation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 95
Chapter 6: Memory Organization and Access . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 131
Chapter 7: Composite Data Types and Memory Objects . . . . . . . . . . . . . . . . . . . . . . 159
Chapter 8: Boolean Logic and Digital Design . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 217
Chapter 9: CPU Architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 251
Chapter 10: Instruction Set Architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 283
Chapter 11: Memory Architecture and Organization . . . . . . . . . . . . . . . . . . . . . . . . 319
Chapter 12: Input and Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 349
Chapter 13: Computer Peripheral Buses . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 367
Chapter 14: Mass Storage Devices and Filesystems . . . . . . . . . . . . . . . . . . . . . . . . . 381
Chapter 15: Miscellaneous Input and Output Devices . . . . . . . . . . . . . . . . . . . . . . . . 413
Afterword: Thinking Low-Level, Writing High-Level . . . . . . . . . . . . . . . . . . . . . . . . . . 425
Appendix A: ASCII Character Set . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 427
Glossary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 431
Index . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 443
-
Volume 2:
Chapter 1: Thinking Low-Level, Writing High-Level . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
Chapter 2: Shouldn’t You Learn Assembly Language? . . . . . . . . . . . . . . . . . . . . . . . . . . 9
Chapter 3: 80x86 Assembly for the HLL Programmer . . . . . . . . . . . . . . . . . . . . . . . . . 17
Chapter 4: Compiler Operation and Code Generation . . . . . . . . . . . . . . . . . . . . . . . . 47
Chapter 5: Tools for Analyzing Compiler Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99
Chapter 6: Constants and High-Level Languages . . . . . . . . . . . . . . . . . . . . . . . . . . . 145
Chapter 7: Variables in a High-Level Language . . . . . . . . . . . . . . . . . . . . . . . . . . . . 173
Chapter 8: Array Data Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 225
Chapter 9: Pointer Data Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 267
Chapter 10: String Data Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 293
Chapter 11: Record, Union, and Class Data Types . . . . . . . . . . . . . . . . . . . . . . . . . 331
Chapter 12: Arithmetic and Logical Expressions . . . . . . . . . . . . . . . . . . . . . . . . . . . 385
Chapter 13: Control Structures and Programmatic Decisions . . . . . . . . . . . . . . . . . . . 451
Chapter 14: Iterative Control Structures . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 503
Chapter 15: Functions and Procedures . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 535
Afterword: Engineering Software . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 599
Glossary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 601
Online Appendixes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 607
Index . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 609
-
Volume 3:
PART I: PERSONAL SOFTWARE ENGINEERING
Chapter 1: Software Development Metaphors
Chapter 2: Productivity
Chapter 3: Software Development Models
PART II: UML
Chapter 4: An Introduction to UML and Use Cases
Chapter 5: UML Activity Diagrams
Chapter 6: UML Class Diagrams
Chapter 7: UML Interaction Diagrams
Chapter 8: Miscellaneous UML Diagrams
PART III: DOCUMENTATION
Chapter 9: System Documentation
Chapter 10: Requirements Documentation
Chapter 11: Software Design Description Documentation
Chapter 12: Software Test Documentation
Afterword: Designing Great Code
Glossary
Index

Список книг

Write Great Code, Volume 1: Understanding the Machine, 2nd edition (pdf, epub)
Write Great Code, Volume 2: Thinking Low-Level, Writing High-Level, 2nd edition (pdf, epub)
Write Great Code, Volume 3: Engineering Software (epub)

Программист

Post 09-Jan-2021 20:35

[Quote]

C++ Concurrency in Action, 2nd edition / С++. Практика многопоточного программирования, 2-е издание
Год издания: 2020
Автор: Williams A. / Уильямс Э.
Издательство: Питер
ISBN: 978-5-4461-0831-2
Язык: Русский
Формат: PDF
Качество: Издательский макет или текст (eBook)
Интерактивное оглавление: Да
Количество страниц: 640
Описание: Язык С++ выбирают, когда надо создать по-настоящему молниеносные приложения. А качественная конкурентная обработка сделает их еще быстрее. Новые возможности С++17 позволяют использовать всю мощь многопоточного программирования, чтобы с легкостью решать задачи графической обработки, машинного обучения и др.
Энтони Уильямс, эксперт конкурентной обработки, рассматривает примеры и описывает практические задачи, а также делится секретами, которые пригодятся всем, в том числе и самым опытным разработчикам. Теперь вам доступны все аспекты конкурентной обработки на C++17 - от создания новых потоков до проектирования полнофункциональных многопоточных алгоритмов и структур данных.
В книге
• Полный обзор возможностей С++17.
• Запуск и управление потоками.
• Синхронизация конкурентных операций.
• Разработка конкурентного кода.
• Отладка многопоточных приложений.
Книга подойдет для разработчиков среднего уровня, пользующихся C и C++. Опыт конкурентного программирования не требуется.
Энтони Уильямс с 2001 года входит в состав экспертного совета BSI C++ и является автором библиотеки just::thread Pro для С++11.
«Эта понятная, емкая, ценная книга должна быть на столе у каждого программиста C++».
Роб Грин, Университет Боулинг-Грин
«Подробное описание всех возможностей конкурентности в C ++».
Маурицио Томаси, Миланский университет
«Крайне рекомендуется программистам, желающим расширить свои знания о новейшем стандарте C++».
Фредерик Флайоль, 4Pro Web C++
«В этом руководстве вы найдете примеры для повседневного использования в ваших проектах; книга поможет вам прокачаться в C++ от Падавана до Джедая».
Юра Шикин, IVI Technologies

Примеры страниц

Оглавление

Предисловие
Благодарности
О книге
Об авторе
Об иллюстрации на обложке
От издательства
Глава 1. Здравствуй, мир конкурентности в C++!
Глава 2. Управление потоками
Глава 3. Совместное использование данных несколькими потоками
Глава 4. Синхронизация конкурентных операций
Глава 5. Модель памяти C++ и операции над атомарными типами
Глава 6. Разработка конкурентных структур данных с блокировками
Глава 7. Разработка конкурентных структур данных без блокировок
Глава 8. Разработка конкурентного кода
Глава 9. Усовершенствованное управление потоками
Глава 10. Алгоритмы параллельных вычислений
Глава 11. Тестирование и отладка многопоточных приложений
Приложения
Приложение А. Краткий справочник по некоторым функциям языка C++11
Приложение Б. Краткое сравнение библиотек для написания конкурентных программ
Приложение В. Среда передачи сообщений и полный пример программы
управления банкоматом
Приложение Г. Справочник по C++ Thread Library

Программист

Post 01-Jan-2021 22:55

[Quote]

マンガでわかる. 機械学習 / Занимательная манга. Машинное обучение
Год издания: 2020
Автор: 荒木雅弘, 渡まかな / Араки Масахиро, Ватари Макана
Переводчик: Слащева А.
Издательство: ДМК Пресс
ISBN: 978-5-97060-830-2
Серия: Образовательная манга
Язык: Русский
Формат: PDF
Качество: Издательский макет или текст (eBook)
Интерактивное оглавление: Да
Количество страниц: 215
Описание:
Сотруднику городской администрации Киёхара Кадзума поручено задание, которое без машинного обучения не выполнить. Под руководством своей давней знакомой Мияно Саяка он осваивает премудрости работы с искусственным интеллектом - от самых азов до глубокого обучения.
Вместе с героями манги читатели узнают о том, что такое регрессия и как проводить классификацию, ознакомятся с принципами оценки тестовых данных и особенностями работы нейронных сетей. В заключительной части излагаются методы обучения без учителя.
Манга предназначена для тех, кто начинает знакомство с машинным обучением и освоил математику на уровне первых курсов университета.

Примеры страниц

Мои остальные раздачи - [url=tracker.php?rid=43141996]https://rutracker.org/forum/tracker.php?rid=43141996[/url]

Программист

Post 31-Dec-2020 16:05

[Quote]

Applied Predictive Modeling / Предиктивное моделирование на практике
Год издания: 2019
Автор: Max Kuhn, Kjell Johnson / Макс Кун, Кьелл Джонсон
Издательство: Питер
ISBN: 978-5-4461-1039-1
Серия: Для профессионалов
Язык: Русский
Формат: DjVu
Качество: Отсканированные страницы + слой распознанного текста
Интерактивное оглавление: Да
Количество страниц: 640
Описание:
«Предиктивное моделирование на практике» охватывает все аспекты прогнозирования, начиная с ключевых этапов предварительной обработки данных, разбиения данных и основных принципов настройки модели. Все этапы моделирования рассматриваются на практических примерах из реальной жизни, в каждой главе дается подробный код на языке R.
Эта книга может использоваться как введение в предиктивные модели и руководство по их применению. Читатели, не обладающие математической подготовкой, оценят интуитивно понятные объяснения конкретных методов, а внимание, уделяемое решению актуальных задач с реальными данными, поможет специалистам, желающим повысить свою квалификацию.
Авторы постарались избежать сложных формул, для усвоения основного материала достаточно понимания основных статистических концепций, таких как корреляция и линейный регрессионный анализ, но для изучения углубленных тем понадобится математическая подготовка.
Для работы с книгой нужно иметь базовые знания о языке R.

Примеры страниц

Мои остальные раздачи - [url=tracker.php?rid=43141996]https://rutracker.org/forum/tracker.php?rid=43141996[/url]

Программист

Post 31-Dec-2020 16:05

[Quote]

Core Java (2 volumes), 11th edition / Базовая Java (в 2-ух томах), 11-е издание
Год издания: 2019
Автор: Horstmann Cay S. / Хорстман Кей С.
Издательство: Pearson
ISBN: 9780135166307, 9780135166314
Язык: Английский
Формат: PDF
Качество: Издательский макет или текст (eBook)
Интерактивное оглавление: Да
Количество страниц: 1019, 959
Описание: The #1 Java Guide for Serious Programmers: Fully Updated for Java SE 9, 10 & 11
For serious programmers, Core Java, Volume I—Fundamentals, Eleventh Edition, is the definitive guide to writing robust, maintainable code. Whether you’re using Java SE 9, 10, or 11, it will help you achieve a deep and practical understanding of the language and API, and its hundreds of realistic examples reveal the most powerful and effective ways to get the job done.
Cay Horstmann’s updated examples reflect Java’s long-awaited modularization, showing how to write code that’s easier to manage and evolve. You’ll learn how to use JShell’s new Read-Eval-Print Loop (REPL) for more rapid and exploratory development, and apply key improvements to the Process API, contended locking, logging, and compilation.
In this first of two volumes, Horstmann offers in-depth coverage of fundamental Java and UI programming, including objects, generics, collections, lambda expressions, Swing design, concurrency, and functional programming. If you’re an experienced programmer moving to Java SE 9, 10, or 11, there’s no better source for expert insight, solutions, and code.
- Master foundational techniques, idioms, and best practices for writing superior Java code
- Leverage the power of interfaces, lambda expressions, and inner classes
- Harden programs through effective exception handling and debugging
- Write safer, more reusable code with generic programming
- Improve performance and efficiency with Java’s standard collections
- Build cross-platform GUIs with the Swing toolkit
- Fully utilize multicore processors with Java’s improved concurrency
-
Core Java has long been recognized as the leading, no-nonsense tutorial and reference for experienced programmers who want to write robust Java code for real-world applications. Now, Core Java, Volume II—Advanced Features, Eleventh Edition, has been updated for Java 11, with up-to-date coverage of advanced UI and enterprise programming, networking, security, and Java’s powerful new module system.
Cay S. Horstmann explores sophisticated new language and library features with the depth and completeness that readers expect from Core Java. He demonstrates how to use these features to build professional-quality applications, using thoroughly tested examples that reflect modern Java style and best practices, including modularization. Horstmann’s examples are carefully crafted for easy understanding and maximum practical value, so you can consistently use them to jump-start your own code.
- Master advanced techniques, idioms, and best practices for writing superior Java code
- Take full advantage of modern Java I/O APIs, object serialization, and regular expressions
- Efficiently connect to network services, implement network clients and servers, and harvest web data
- Query databases and manage database connections with the latest version of JDBC
- Simplify all aspects of date and time programming with the Java Date and Time API
- Write internationalized programs that localize dates, times, numbers, text, and GUIs
- Process code in three powerful ways: the scripting API, compiler API, and annotation processing
- Learn how to migrate legacy code to the Java Platform Module System
- Leverage the modern Java security features most valuable to application programmers
- Program advanced client-side user interfaces, and generate images on the server
- Use JNI to interoperate with native C code

Примеры страниц

Оглавление

Volume I—Fundamentals:
Preface .......................................................................................................... xix
Acknowledgments ......................................................................................... xxv
Chapter 1: An Introduction to Java ............................................................... 1
1.1 Java as a Programming Platform ......................................................... 1
1.2 The Java “White Paper” Buzzwords .................................................... 2
1.2.1 Simple ....................................................................................... 3
1.2.2 Object-Oriented ....................................................................... 4
1.2.3 Distributed ............................................................................... 4
1.2.4 Robust ....................................................................................... 4
1.2.5 Secure ....................................................................................... 5
1.2.6 Architecture-Neutral ................................................................ 6
1.2.7 Portable .................................................................................... 6
1.2.8 Interpreted ................................................................................ 7
1.2.9 High-Performance ................................................................... 7
1.2.10 Multithreaded .......................................................................... 8
1.2.11 Dynamic ................................................................................... 8
1.3 Java Applets and the Internet ............................................................. 9
1.4 A Short History of Java ...................................................................... 10
1.5 Common Misconceptions about Java ............................................... 13
Chapter 2: The Java Programming Environment ....................................... 17
2.1 Installing the Java Development Kit ................................................. 18
2.1.1 Downloading the JDK ........................................................... 18
2.1.2 Setting up the JDK ................................................................ 20
2.1.3 Installing Source Files and Documentation ........................ 22
2.2 Using the Command-Line Tools ....................................................... 23
2.3 Using an Integrated Development Environment ............................. 29
2.4 JShell .................................................................................................... 32
Chapter 3: Fundamental Programming Structures in Java ...................... 37
3.1 A Simple Java Program ...................................................................... 38
3.2 Comments ............................................................................................ 41
3.3 Data Types ........................................................................................... 42
3.3.1 Integer Types ......................................................................... 43
3.3.2 Floating-Point Types ............................................................. 44
3.3.3 The char Type .......................................................................... 46
3.3.4 Unicode and the char Type ................................................... 47
3.3.5 The boolean Type ..................................................................... 48
3.4 Variables and Constants .................................................................... 48
3.4.1 Declaring Variables ............................................................... 48
3.4.2 Initializing Variables ............................................................. 50
3.4.3 Constants ................................................................................ 51
3.4.4 Enumerated Types ................................................................. 52
3.5 Operators ............................................................................................. 52
3.5.1 Arithmetic Operators ............................................................ 52
3.5.2 Mathematical Functions and Constants .............................. 54
3.5.3 Conversions between Numeric Types ................................ 56
3.5.4 Casts ........................................................................................ 57
3.5.5 Combining Assignment with Operators ............................. 58
3.5.6 Increment and Decrement Operators ................................. 58
3.5.7 Relational and boolean Operators .......................................... 59
3.5.8 Bitwise Operators .................................................................. 60
3.5.9 Parentheses and Operator Hierarchy .................................. 61
3.6 Strings .................................................................................................. 62
3.6.1 Substrings ............................................................................... 62
3.6.2 Concatenation ........................................................................ 63
3.6.3 Strings Are Immutable .......................................................... 63
3.6.4 Testing Strings for Equality .................................................. 65
3.6.5 Empty and Null Strings ......................................................... 66
3.6.6 Code Points and Code Units ............................................... 66
3.6.7 The String API ......................................................................... 68
3.6.8 Reading the Online API Documentation ............................ 71
3.6.9 Building Strings ..................................................................... 74
3.7 Input and Output ................................................................................ 75
3.7.1 Reading Input ........................................................................ 75
3.7.2 Formatting Output ................................................................. 78
3.7.3 File Input and Output ........................................................... 83
3.8 Control Flow ........................................................................................ 86
3.8.1 Block Scope ............................................................................ 86
3.8.2 Conditional Statements ......................................................... 87
3.8.3 Loops ...................................................................................... 91
3.8.4 Determinate Loops ................................................................ 95
3.8.5 Multiple Selections The switch Statement ............................ 99
3.8.6 Statements That Break Control Flow ................................ 102
3.9 Big Numbers ...................................................................................... 105
3.10 Arrays ................................................................................................. 108
3.10.1 Declaring Arrays .................................................................. 108
3.10.2 Accessing Array Elements .................................................. 109
3.10.3 The “for each” Loop ............................................................ 110
3.10.4 Array Copying ...................................................................... 111
3.10.5 Command-Line Parameters ................................................ 112
3.10.6 Array Sorting ........................................................................ 113
3.10.7 Multidimensional Arrays .................................................... 116
3.10.8 Ragged Arrays ...................................................................... 120
Chapter 4: Objects and Classes ................................................................ 125
4.1 Introduction to Object-Oriented Programming ............................. 126
4.1.1 Classes .................................................................................. 127
4.1.2 Objects .................................................................................. 128
4.1.3 Identifying Classes ............................................................... 129
4.1.4 Relationships between Classes .......................................... 129
4.2 Using Predefined Classes ................................................................. 131
4.2.1 Objects and Object Variables ............................................. 132
4.2.2 The LocalDate Class of the Java Library ............................... 135
4.2.3 Mutator and Accessor Methods ......................................... 138
4.3 Defining Your Own Classes ............................................................ 141
4.3.1 An Employee Class ................................................................... 142
4.3.2 Use of Multiple Source Files .............................................. 145
4.3.3 Dissecting the Employee Class ................................................ 146
4.3.4 First Steps with Constructors ............................................. 146
4.3.5 Declaring Local Variables with var ..................................... 148
4.3.6 Working with null References ............................................. 148
4.3.7 Implicit and Explicit Parameters ........................................ 150
4.3.8 Benefits of Encapsulation .................................................... 151
4.3.9 Class-Based Access Privileges ............................................ 154
4.3.10 Private Methods ................................................................... 155
4.3.11 Final Instance Fields ............................................................ 155
4.4 Static Fields and Methods ................................................................ 156
4.4.1 Static Fields .......................................................................... 156
4.4.2 Static Constants ................................................................... 157
4.4.3 Static Methods ..................................................................... 158
4.4.4 Factory Methods .................................................................. 159
4.4.5 The main Method ................................................................... 160
4.5 Method Parameters ........................................................................... 163
4.6 Object Construction .......................................................................... 170
4.6.1 Overloading .......................................................................... 170
4.6.2 Default Field Initialization .................................................. 171
4.6.3 The Constructor with No Arguments ................................ 172
4.6.4 Explicit Field Initialization .................................................. 173
4.6.5 Parameter Names ................................................................ 174
4.6.6 Calling Another Constructor .............................................. 175
4.6.7 Initialization Blocks ............................................................. 175
4.6.8 Object Destruction and the finalize Method ..................... 180
4.7 Packages ............................................................................................. 180
4.7.1 Package Names .................................................................... 181
4.7.2 Class Importation ................................................................ 181
4.7.3 Static Imports ....................................................................... 183
4.7.4 Addition of a Class into a Package ................................... 184
4.7.5 Package Access .................................................................... 187
4.7.6 The Class Path ..................................................................... 189
4.7.7 Setting the Class Path ......................................................... 191
4.8 JAR Files ............................................................................................. 192
4.8.1 Creating JAR files ................................................................ 192
4.8.2 The Manifest ........................................................................ 193
4.8.3 Executable JAR Files ............................................................ 194
4.8.4 Multi-Release JAR Files ....................................................... 195
4.8.5 A Note about Command-Line Options ............................. 197
4.9 Documentation Comments .............................................................. 198
4.9.1 Comment Insertion ............................................................. 199
4.9.2 Class Comments .................................................................. 199
4.9.3 Method Comments .............................................................. 200
4.9.4 Field Comments ................................................................... 201
4.9.5 General Comments .............................................................. 201
4.9.6 Package Comments ............................................................. 202
4.9.7 Comment Extraction ........................................................... 203
4.10 Class Design Hints ............................................................................ 204
Chapter 5: Inheritance ................................................................................ 207
5.1 Classes, Superclasses, and Subclasses ............................................ 208
5.1.1 Defining Subclasses ............................................................. 208
5.1.2 Overriding Methods ............................................................ 210
5.1.3 Subclass Constructors ......................................................... 211
5.1.4 Inheritance Hierarchies ....................................................... 216
5.1.5 Polymorphism ...................................................................... 217
5.1.6 Understanding Method Calls ............................................. 218
5.1.7 Preventing Inheritance: Final Classes and Methods ....... 221
5.1.8 Casting .................................................................................. 223
5.1.9 Abstract Classes ................................................................... 225
5.1.10 Protected Access .................................................................. 231
5.2 Object: The Cosmic Superclass .......................................................... 232
5.2.1 Variables of Type Object ....................................................... 232
5.2.2 The equals Method ................................................................ 233
5.2.3 Equality Testing and Inheritance ....................................... 234
5.2.4 The hashCode Method ............................................................. 238
5.2.5 The toString Method ............................................................. 241
5.3 Generic Array Lists ........................................................................... 248
5.3.1 Declaring Array Lists ........................................................... 248
5.3.2 Accessing Array List Elements ........................................... 251
5.3.3 Compatibility between Typed and Raw Array Lists ........ 255
5.4 Object Wrappers and Autoboxing .................................................. 256
5.5 Methods with a Variable Number of Parameters .......................... 260
5.6 Enumeration Classes ........................................................................ 261
5.7 Reflection ........................................................................................... 264
5.7.1 The Class Class ...................................................................... 264
5.7.2 A Primer on Declaring Exceptions .................................... 267
5.7.3 Resources .............................................................................. 268
5.7.4 Using Reflection to Analyze the Capabilities of Classes 271
5.7.5 Using Reflection to Analyze Objects at Runtime ............ 277
5.7.6 Using Reflection to Write Generic Array Code ............... 283
5.7.7 Invoking Arbitrary Methods and Constructors ................ 286
5.8 Design Hints for Inheritance ........................................................... 290
Chapter 6: Interfaces, Lambda Expressions, and Inner Classes ........... 295
6.1 Interfaces ............................................................................................ 296
6.1.1 The Interface Concept ......................................................... 296
6.1.2 Properties of Interfaces ....................................................... 303
6.1.3 Interfaces and Abstract Classes ......................................... 305
6.1.4 Static and Private Methods ................................................. 306
6.1.5 Default Methods .................................................................. 307
6.1.6 Resolving Default Method Conflicts ................................. 308
6.1.7 Interfaces and Callbacks ..................................................... 310
6.1.8 The Comparator Interface ......................................................... 313
6.1.9 Object Cloning ..................................................................... 314
6.2 Lambda Expressions ......................................................................... 322
6.2.1 Why Lambdas? ..................................................................... 322
6.2.2 The Syntax of Lambda Expressions ................................... 323
6.2.3 Functional Interfaces ........................................................... 326
6.2.4 Method References .............................................................. 328
6.2.5 Constructor References ....................................................... 332
6.2.6 Variable Scope ..................................................................... 333
6.2.7 Processing Lambda Expressions ........................................ 335
6.2.8 More about Comparators ................................................... 339
6.3 Inner Classes ..................................................................................... 340
6.3.1 Use of an Inner Class to Access Object State .................. 341
6.3.2 Special Syntax Rules for Inner Classes ............................. 345
6.3.3 Are Inner Classes Useful? Actually Necessary? Secure? 346
6.3.4 Local Inner Classes .............................................................. 349
6.3.5 Accessing Variables from Outer Methods ........................ 350
6.3.6 Anonymous Inner Classes .................................................. 352
6.3.7 Static Inner Classes ............................................................. 356
6.4 Service Loaders ................................................................................. 360
6.5 Proxies ................................................................................................ 362
6.5.1 When to Use Proxies .......................................................... 363
6.5.2 Creating Proxy Objects ....................................................... 363
6.5.3 Properties of Proxy Classes ................................................ 368
Chapter 7: Exceptions, Assertions, and Logging .................................... 371
7.1 Dealing with Errors ........................................................................... 372
7.1.1 The Classification of Exceptions ........................................ 373
7.1.2 Declaring Checked Exceptions ........................................... 375
7.1.3 How to Throw an Exception .............................................. 378
7.1.4 Creating Exception Classes ................................................ 380
7.2 Catching Exceptions ......................................................................... 381
7.2.1 Catching an Exception ........................................................ 381
7.2.2 Catching Multiple Exceptions ............................................ 383
7.2.3 Rethrowing and Chaining Exceptions ............................... 384
7.2.4 The finally Clause ................................................................ 386
7.2.5 The try-with-Resources Statement ..................................... 389
7.2.6 Analyzing Stack Trace Elements ........................................ 391
7.3 Tips for Using Exceptions ................................................................ 396
7.4 Using Assertions ............................................................................... 399
7.4.1 The Assertion Concept ....................................................... 399
7.4.2 Assertion Enabling and Disabling ..................................... 400
7.4.3 Using Assertions for Parameter Checking ........................ 401
7.4.4 Using Assertions for Documenting Assumptions ............ 402
7.5 Logging ............................................................................................... 403
7.5.1 Basic Logging ....................................................................... 404
7.5.2 Advanced Logging ............................................................... 405
7.5.3 Changing the Log Manager Configuration ....................... 407
7.5.4 Localization .......................................................................... 409
7.5.5 Handlers ............................................................................... 410
7.5.6 Filters .................................................................................... 414
7.5.7 Formatters ............................................................................. 415
7.5.8 A Logging Recipe ................................................................ 415
7.6 Debugging Tips ................................................................................. 425
Chapter 8: Generic Programming ............................................................. 431
8.1 Why Generic Programming? ............................................................ 432
8.1.1 The Advantage of Type Parameters .................................. 432
8.1.2 Who Wants to Be a Generic Programmer? ...................... 433
8.2 Defining a Simple Generic Class .................................................... 434
8.3 Generic Methods ............................................................................... 437
8.4 Bounds for Type Variables ............................................................... 438
8.5 Generic Code and the Virtual Machine ......................................... 441
8.5.1 Type Erasure ........................................................................ 441
8.5.2 Translating Generic Expressions ........................................ 442
8.5.3 Translating Generic Methods ............................................. 443
8.5.4 Calling Legacy Code ........................................................... 445
8.6 Restrictions and Limitations ............................................................ 447
8.6.1Type Parameters Cannot Be Instantiated with Primitive Types ..................................................................................... 447
8.6.2 Runtime Type Inquiry Only Works with Raw Types ...... 447
8.6.3 You Cannot Create Arrays of Parameterized Types ...... 448
8.6.4 Varargs Warnings ................................................................ 448
8.6.5 You Cannot Instantiate Type Variables ............................ 450
8.6.6 You Cannot Construct a Generic Array ............................ 451
8.6.7 Type Variables Are Not Valid in Static Contexts of Generic Classes .................................................................... 452
8.6.8 You Cannot Throw or Catch Instances of a Generic Class ...................................................................................... 453
8.6.9 You Can Defeat Checked Exception Checking ................ 454
8.6.10 Beware of Clashes after Erasure ........................................ 455
8.7 Inheritance Rules for Generic Types .............................................. 457
8.8 Wildcard Types ................................................................................. 459
8.8.1 The Wildcard Concept ........................................................ 459
8.8.2 Supertype Bounds for Wildcards ....................................... 461
8.8.3 Unbounded Wildcards ........................................................ 464
8.8.4 Wildcard Capture ................................................................ 465
8.9 Reflection and Generics ................................................................... 467
8.9.1 The Generic Class Class ....................................................... 467
8.9.2 Using Class Parameters for Type Matching ................... 469
8.9.3 Generic Type Information in the Virtual Machine .......... 469
8.9.4 Type Literals ......................................................................... 473
Chapter 9: Collections ................................................................................ 481
9.1 The Java Collections Framework ..................................................... 482
9.1.1 Separating Collection Interfaces and Implementation .... 482
9.1.2 The Collection Interface ......................................................... 485
9.1.3 Iterators ................................................................................. 485
9.1.4 Generic Utility Methods ...................................................... 489
9.2 Interfaces in the Collections Framework ........................................ 492
9.3 Concrete Collections ........................................................................ 494
9.3.1 Linked Lists .......................................................................... 496
9.3.2 Array Lists ............................................................................ 507
9.3.3 Hash Sets .............................................................................. 507
9.3.4 Tree Sets ............................................................................... 511
9.3.5 Queues and Deques ............................................................ 516
9.3.6 Priority Queues .................................................................... 518
9.4 Maps ................................................................................................... 519
9.4.1 Basic Map Operations ......................................................... 519
9.4.2 Updating Map Entries ......................................................... 523
9.4.3 Map Views ............................................................................ 525
9.4.4 Weak Hash Maps ................................................................. 526
9.4.5 Linked Hash Sets and Maps ............................................... 527
9.4.6 Enumeration Sets and Maps ............................................... 529
9.4.7 Identity Hash Maps ............................................................. 530
9.5 Views and Wrappers ......................................................................... 532
9.5.1 Small Collections ................................................................. 532
9.5.2 Subranges ............................................................................. 534
9.5.3 Unmodifiable Views ............................................................ 535
9.5.4 Synchronized Views ............................................................ 536
9.5.5 Checked Views .................................................................... 536
9.5.6 A Note on Optional Operations ........................................ 537
9.6 Algorithms ......................................................................................... 541
9.6.1 Why Generic Algorithms? .................................................. 541
9.6.2 Sorting and Shuffling .......................................................... 543
9.6.3 Binary Search ....................................................................... 546
9.6.4 Simple Algorithms ............................................................... 547
9.6.5 Bulk Operations ................................................................... 549
9.6.6 Converting between Collections and Arrays .................... 550
9.6.7 Writing Your Own Algorithms .......................................... 551
9.7 Legacy Collections ............................................................................ 552
9.7.1 The Hashtable Class ................................................................ 553
9.7.2 Enumerations ....................................................................... 553
9.7.3 Property Maps ...................................................................... 555
9.7.4 Stacks .................................................................................... 558
9.7.5 Bit Sets .................................................................................. 559
Chapter 10: Graphical User Interface Programming ............................... 565
10.1 A History of Java User Interface Toolkits ...................................... 565
10.2 Displaying Frames ............................................................................. 567
10.2.1 Creating a Frame ................................................................. 568
10.2.2 Frame Properties .................................................................. 570
10.3 Displaying Information in a Component ....................................... 574
10.3.1 Working with 2D Shapes .................................................... 579
10.3.2 Using Color .......................................................................... 587
10.3.3 Using Fonts .......................................................................... 589
10.3.4 Displaying Images ............................................................... 597
10.4 Event Handling .................................................................................. 598
10.4.1 Basic Event Handling Concepts ......................................... 598
10.4.2 Example: Handling a Button Click .................................... 600
10.4.3 Specifying Listeners Concisely ........................................... 604
10.4.4 Adapter Classes ................................................................... 605
10.4.5 Actions .................................................................................. 608
10.4.6 Mouse Events ....................................................................... 614
10.4.7 The AWT Event Hierarchy ................................................. 620
10.5 The Preferences API ......................................................................... 624
Chapter 11: User Interface Components with Swing .............................. 631
11.1 Swing and the Model-View-Controller Design Pattern ................ 632
11.2 Introduction to Layout Management .............................................. 636
11.2.1 Layout Managers ................................................................. 637
11.2.2 Border Layout ...................................................................... 639
11.2.3 Grid Layout .......................................................................... 642
11.3 Text Input .......................................................................................... 643
11.3.1 Text Fields ............................................................................ 643
11.3.2 Labels and Labeling Components ..................................... 645
11.3.3 Password Fields ................................................................... 647
11.3.4 Text Areas ............................................................................ 647
11.3.5 Scroll Panes .......................................................................... 648
11.4 Choice Components ......................................................................... 651
11.4.1 Checkboxes .......................................................................... 651
11.4.2 Radio Buttons ....................................................................... 654
11.4.3 Borders .................................................................................. 658
11.4.4 Combo Boxes ....................................................................... 661
11.4.5 Sliders ................................................................................... 665
11.5 Menus ................................................................................................. 671
11.5.1 Menu Building ..................................................................... 672
11.5.2 Icons in Menu Items ........................................................... 675
11.5.3 Checkbox and Radio Button Menu Items ......................... 676
11.5.4 Pop-Up Menus ..................................................................... 677
11.5.5 Keyboard Mnemonics and Accelerators ........................... 679
11.5.6 Enabling and Disabling Menu Items ................................. 682
11.5.7 Toolbars ................................................................................ 687
11.5.8 Tooltips ................................................................................. 689
11.6 Sophisticated Layout Management ................................................. 690
11.6.1 The Grid Bag Layout ........................................................... 691
11.6.1.1 The gridx, gridy, gridwidth, and gridheight Parameters ........................................................... 693
11.6.1.2 Weight Fields ....................................................... 694
11.6.1.3 The fill and anchor Parameters ........................... 694
11.6.1.4 Padding ................................................................ 694
11.6.1.5 Alternative Method to Specify the gridx, gridy, gridwidth, and gridheight Parameters ..................... 695
11.6.1.6 A Grid Bag Layout Recipe ................................. 695
11.6.1.7 A Helper Class to Tame the Grid Bag Constraints ........................................................... 696
11.6.2 Custom Layout Managers ................................................... 702
11.7 Dialog Boxes ...................................................................................... 706
11.7.1 Option Dialogs ..................................................................... 707
11.7.2 Creating Dialogs .................................................................. 712
11.7.3 Data Exchange ..................................................................... 716
11.7.4 File Dialogs ........................................................................... 723
Chapter 12: Concurrency ........................................................................... 733
12.1 What Are Threads? ........................................................................... 734
12.2 Thread States ..................................................................................... 739
12.2.1 New Threads ........................................................................ 740
12.2.2 Runnable Threads ................................................................ 740
12.2.3 Blocked and Waiting Threads ............................................ 741
12.2.4 Terminated Threads ............................................................ 742
12.3 Thread Properties .............................................................................. 743
12.3.1 Interrupting Threads ........................................................... 743
12.3.2 Daemon Threads ................................................................. 746
12.3.3 Thread Names ...................................................................... 747
12.3.4 Handlers for Uncaught Exceptions .................................... 747
12.3.5 Thread Priorities .................................................................. 749
12.4 Synchronization ................................................................................. 750
12.4.1 An Example of a Race Condition ...................................... 750
12.4.2 The Race Condition Explained .......................................... 752
12.4.3 Lock Objects ........................................................................ 755
12.4.4 Condition Objects ............................................................... 758
12.4.5 The synchronized Keyword ...................................................... 764
12.4.6 Synchronized Blocks ........................................................... 768
12.4.7 The Monitor Concept .......................................................... 770
12.4.8 Volatile Fields ....................................................................... 771
12.4.9 Final Variables ..................................................................... 772
12.4.10 Atomics ................................................................................. 773
12.4.11 Deadlocks ............................................................................. 775
12.4.12 Thread-Local Variables ....................................................... 778
12.4.13 Why the stop and suspend Methods Are Deprecated .......... 779
12.5 Thread-Safe Collections ................................................................... 781
12.5.1 Blocking Queues .................................................................. 781
12.5.2 Efficient Maps, Sets, and Queues ...................................... 789
12.5.3 Atomic Update of Map Entries .......................................... 790
12.5.4 Bulk Operations on Concurrent Hash Maps .................... 794
12.5.5 Concurrent Set Views ......................................................... 796
12.5.6 Copy on Write Arrays ......................................................... 797
12.5.7 Parallel Array Algorithms ................................................... 797
12.5.8 Older Thread-Safe Collections ........................................... 799
12.6 Tasks and Thread Pools ................................................................... 800
12.6.1 Callables and Futures .......................................................... 800
12.6.2 Executors .............................................................................. 802
12.6.3 Controlling Groups of Tasks .............................................. 806
12.6.4 The Fork-Join Framework ................................................... 811
12.7 Asynchronous Computations ........................................................... 814
12.7.1 Completable Futures ........................................................... 815
12.7.2 Composing Completable Futures ...................................... 817
12.7.3 Long-Running Tasks in User Interface Callbacks ............ 823
12.8 Processes ............................................................................................ 831
12.8.1 Building a Process ............................................................... 832
12.8.2 Running a Process ............................................................... 834
12.8.3 Process Handles ................................................................... 835
Appendix ...................................................................................................... 839
Index ............................................................................................................. 843
-
Volume II—Advanced Features:
Preface ........................................................................................................... xv
Acknowledgments ......................................................................................... xxi
Chapter 1: Streams ........................................................................................ 1
1.1 From Iterating to Stream Operations ................................................. 2
1.2 Stream Creation ................................................................................... 5
1.3 The filter, map, and flatMap Methods ................................................... 11
1.4 Extracting Substreams and Combining Streams ............................. 12
1.5 Other Stream Transformations ......................................................... 14
1.6 Simple Reductions .............................................................................. 15
1.7 The Optional Type ............................................................................. 16
1.7.1 Getting an Optional Value .................................................. 17
1.7.2 Consuming an Optional Value ............................................ 17
1.7.3 Pipelining Optional Values .................................................. 18
1.7.4 How Not to Work with Optional Values ........................... 19
1.7.5 Creating Optional Values .................................................... 20
1.7.6 Composing Optional Value Functions with flatMap ........... 21
1.7.7 Turning an Optional into a Stream .................................... 22
1.8 Collecting Results ............................................................................... 25
1.9 Collecting into Maps .......................................................................... 30
1.10 Grouping and Partitioning ................................................................ 34
1.11 Downstream Collectors ..................................................................... 36
1.12 Reduction Operations ........................................................................ 41
1.13 Primitive Type Streams ..................................................................... 43
1.14 Parallel Streams .................................................................................. 48
Chapter 2: Input and Output ........................................................................ 55
2.1 Input/Output Streams ........................................................................ 56
2.1.1 Reading and Writing Bytes .................................................. 56
2.1.2 The Complete Stream Zoo ................................................. 59
2.1.3 Combining Input/Output Stream Filters ............................ 63
2.1.4 Text Input and Output ......................................................... 68
2.1.5 How to Write Text Output .................................................. 68
2.1.6 How to Read Text Input ...................................................... 70
2.1.7 Saving Objects in Text Format ............................................ 72
2.1.8 Character Encodings ............................................................. 75
2.2 Reading and Writing Binary Data .................................................... 78
2.2.1 The DataInput and DataOutput interfaces ................................... 78
2.2.2 Random-Access Files ............................................................ 80
2.2.3 ZIP Archives .......................................................................... 85
2.3 Object Input/Output Streams and Serialization ............................. 88
2.3.1 Saving and Loading Serializable Objects ........................... 88
2.3.2 Understanding the Object Serialization File Format .................................................................................... 93
2.3.3 Modifying the Default Serialization Mechanism ............. 100
2.3.4 Serializing Singletons and Typesafe Enumerations ........ 102
2.3.5 Versioning ............................................................................ 103
2.3.6 Using Serialization for Cloning ......................................... 106
2.4 Working with Files ........................................................................... 109
2.4.1 Paths ..................................................................................... 109
2.4.2 Reading and Writing Files ................................................. 112
2.4.3 Creating Files and Directories ........................................... 113
2.4.4 Copying, Moving, and Deleting Files ............................... 114
2.4.5 Getting File Information ..................................................... 116
2.4.6 Visiting Directory Entries ................................................... 118
2.4.7 Using Directory Streams .................................................... 120
2.4.8 ZIP File Systems .................................................................. 123
2.5 Memory-Mapped Files ..................................................................... 124
2.5.1 Memory-Mapped File Performance .................................. 125
2.5.2 The Buffer Data Structure .................................................. 132
2.6 File Locking ....................................................................................... 134
2.7 Regular Expressions ......................................................................... 137
2.7.1 The Regular Expression Syntax ......................................... 137
2.7.2 Matching a String ............................................................... 142
2.7.3 Finding Multiple Matches .................................................. 145
2.7.4 Splitting along Delimiters .................................................. 147
2.7.5 Replacing Matches .............................................................. 148
Chapter 3: XML ........................................................................................... 153
3.1 Introducing XML .............................................................................. 154
3.2 The Structure of an XML Document ............................................. 156
3.3 Parsing an XML Document ............................................................. 159
3.4 Validating XML Documents ............................................................ 169
3.4.1 Document Type Definitions .............................................. 171
3.4.2 XML Schema ....................................................................... 179
3.4.3 A Practical Example ............................................................ 182
3.5 Locating Information with XPath ................................................... 188
3.6 Using Namespaces ........................................................................... 193
3.7 Streaming Parsers ............................................................................. 196
3.7.1 Using the SAX Parser ......................................................... 197
3.7.2 Using the StAX Parser ........................................................ 202
3.8 Generating XML Documents .......................................................... 206
3.8.1 Documents without Namespaces ...................................... 206
3.8.2 Documents with Namespaces ........................................... 207
3.8.3 Writing Documents ............................................................. 208
3.8.4 Writing an XML Document with StAX ............................ 210
3.8.5 An Example: Generating an SVG File .............................. 215
3.9 XSL Transformations ........................................................................ 216
Chapter 4: Networking ............................................................................... 227
4.1 Connecting to a Server .................................................................... 227
4.1.1 Using Telnet ........................................................................ 227
4.1.2 Connecting to a Server with Java ..................................... 230
4.1.3 Socket Timeouts .................................................................. 232
4.1.4 Internet Addresses .............................................................. 234
4.2 Implementing Servers ...................................................................... 236
4.2.1 Server Sockets ..................................................................... 236
4.2.2 Serving Multiple Clients .................................................... 239
4.2.3 Half-Close ............................................................................ 243
4.2.4 Interruptible Sockets ........................................................... 244
4.3 Getting Web Data ............................................................................ 251
4.3.1 URLs and URIs .................................................................... 251
4.3.2 Using a URLConnection to Retrieve Information .................... 254
4.3.3 Posting Form Data .............................................................. 261
4.4 The HTTP Client .............................................................................. 271
4.5 Sending E-Mail ................................................................................. 278
Chapter 5: Database Programming .......................................................... 283
5.1 The Design of JDBC ......................................................................... 284
5.1.1 JDBC Driver Types ............................................................. 285
5.1.2 Typical Uses of JDBC ......................................................... 286
5.2 The Structured Query Language .................................................... 287
5.3 JDBC Configuration ......................................................................... 293
5.3.1 Database URLs .................................................................... 294
5.3.2 Driver JAR Files .................................................................. 294
5.3.3 Starting the Database ......................................................... 294
5.3.4 Registering the Driver Class .............................................. 295
5.3.5 Connecting to the Database .............................................. 296
5.4 Working with JDBC Statements ..................................................... 299
5.4.1 Executing SQL Statements ................................................. 299
5.4.2 Managing Connections, Statements, and Result Sets ..... 303
5.4.3 Analyzing SQL Exceptions ................................................. 304
5.4.4 Populating a Database ....................................................... 306
5.5 Query Execution ............................................................................... 310
5.5.1 Prepared Statements ........................................................... 311
5.5.2 Reading and Writing LOBs ................................................ 317
5.5.3 SQL Escapes ........................................................................ 319
5.5.4 Multiple Results .................................................................. 321
5.5.5 Retrieving Autogenerated Keys ......................................... 322
5.6 Scrollable and Updatable Result Sets ............................................ 322
5.6.1 Scrollable Result Sets ......................................................... 323
5.6.2 Updatable Result Sets ......................................................... 325
5.7 Row Sets ............................................................................................ 329
5.7.1 Constructing Row Sets ....................................................... 330
5.7.2 Cached Row Sets ................................................................ 330
5.8 Metadata ............................................................................................ 334
5.9 Transactions ...................................................................................... 344
5.9.1 Programming Transactions with JDBC ............................. 344
5.9.2 Save Points .......................................................................... 345
5.9.3 Batch Updates ..................................................................... 345
5.9.4 Advanced SQL Types ......................................................... 348
5.10 Connection Management in Web and Enterprise Applications .. 349
Chapter 6: The Date and Time API ............................................................ 353
6.1 The Time Line .................................................................................. 354
6.2 Local Dates ....................................................................................... 358
6.3 Date Adjusters .................................................................................. 364
6.4 Local Time ........................................................................................ 365
6.5 Zoned Time ...................................................................................... 367
6.6 Formatting and Parsing ................................................................... 371
6.7 Interoperating with Legacy Code ................................................... 376
Chapter 7: Internationalization .................................................................. 379
7.1 Locales ............................................................................................... 380
7.1.1 Why Locales? ....................................................................... 380
7.1.2 Specifying Locales ............................................................... 381
7.1.3 The Default Locale ............................................................. 384
7.1.4 Display Names .................................................................... 384
7.2 Number Formats ............................................................................... 387
7.2.1 Formatting Numeric Values ............................................... 387
7.2.2 Currencies ............................................................................ 393
7.3 Date and Time .................................................................................. 394
7.4 Collation and Normalization .......................................................... 402
7.5 Message Formatting ......................................................................... 409
7.5.1 Formatting Numbers and Dates ........................................ 409
7.5.2 Choice Formats ................................................................... 411
7.6 Text Input and Output ..................................................................... 413
7.6.1 Text Files .............................................................................. 414
7.6.2 Line Endings ........................................................................ 414
7.6.3 The Console ........................................................................ 414
7.6.4 Log Files ............................................................................... 415
7.6.5 The UTF-8 Byte Order Mark .............................................. 415
7.6.6 Character Encoding of Source Files .................................. 416
7.7 Resource Bundles ............................................................................. 417
7.7.1 Locating Resource Bundles ................................................ 417
7.7.2 Property Files ...................................................................... 418
7.7.3 Bundle Classes .................................................................... 419
7.8 A Complete Example ....................................................................... 421
Chapter 8: Scripting, Compiling, and Annotation Processing ................ 439
8.1 Scripting for the Java Platform ....................................................... 440
8.1.1 Getting a Scripting Engine ................................................. 440
8.1.2 Script Evaluation and Bindings ......................................... 441
8.1.3 Redirecting Input and Output ........................................... 444
8.1.4 Calling Scripting Functions and Methods ........................ 444
8.1.5 Compiling a Script .............................................................. 446
8.1.6 An Example: Scripting GUI Events ................................... 447
8.2 The Compiler API ............................................................................ 452
8.2.1 Invoking the Compiler ....................................................... 453
8.2.2 Launching a Compilation Task ......................................... 453
8.2.3 Capturing Diagnostics ........................................................ 454
8.2.4 Reading Source Files from Memory ................................. 454
8.2.5 Writing Byte Codes to Memory ........................................ 455
8.2.6 An Example: Dynamic Java Code Generation ................ 457
8.3 Using Annotations ............................................................................ 463
8.3.1 An Introduction into Annotations .................................... 464
8.3.2 An Example: Annotating Event Handlers ........................ 465
8.4 Annotation Syntax ............................................................................ 471
8.4.1 Annotation Interfaces ......................................................... 471
8.4.2 Annotations ......................................................................... 473
8.4.3 Annotating Declarations .................................................... 475
8.4.4 Annotating Type Uses ........................................................ 476
8.4.5 Annotating this .................................................................... 477
8.5 Standard Annotations ...................................................................... 478
8.5.1 Annotations for Compilation ............................................. 480
8.5.2 Annotations for Managing Resources .............................. 480
8.5.3 Meta-Annotations ............................................................... 481
8.6 Source-Level Annotation Processing .............................................. 484
8.6.1 Annotation Processors ....................................................... 484
8.6.2 The Language Model API .................................................. 485
8.6.3 Using Annotations to Generate Source Code ................. 486
8.7 Bytecode Engineering ...................................................................... 489
8.7.1 Modifying Class Files ......................................................... 490
8.7.2 Modifying Bytecodes at Load Time .................................. 495
Chapter 9: The Java Platform Module System ......................................... 499
9.1 The Module Concept ....................................................................... 500
9.2 Naming Modules .............................................................................. 501
9.3 The Modular “Hello, World!” Program .......................................... 502
9.4 Requiring Modules ........................................................................... 504
9.5 Exporting Packages .......................................................................... 506
9.6 Modular JARs .................................................................................... 510
9.7 Modules and Reflective Access ....................................................... 511
9.8 Automatic Modules .......................................................................... 515
9.9 The Unnamed Module ..................................................................... 517
9.10 Command-Line Flags for Migration ............................................... 518
9.11 Transitive and Static Requirements ............................................... 519
9.12 Qualified Exporting and Opening .................................................. 521
9.13 Service Loading ................................................................................ 522
9.14 Tools for Working with Modules ................................................... 524
Chapter 10: Security ................................................................................... 529
10.1 Class Loaders .................................................................................... 530
10.1.1 The Class-Loading Process ................................................ 530
10.1.2 The Class Loader Hierarchy .............................................. 532
10.1.3 Using Class Loaders as Namespaces ................................ 534
10.1.4 Writing Your Own Class Loader ....................................... 534
10.1.5 Bytecode Verification .......................................................... 541
10.2 Security Managers and Permissions ............................................... 546
10.2.1 Permission Checking .......................................................... 546
10.2.2 Java Platform Security ........................................................ 547
10.2.3 Security Policy Files ............................................................ 551
10.2.4 Custom Permissions ........................................................... 559
10.2.5 Implementation of a Permission Class ............................. 560
10.3 User Authentication ......................................................................... 566
10.3.1 The JAAS Framework ......................................................... 566
10.3.2 JAAS Login Modules .......................................................... 573
10.4 Digital Signatures ............................................................................. 582
10.4.1 Message Digests .................................................................. 583
10.4.2 Message Signing ................................................................. 587
10.4.3 Verifying a Signature .......................................................... 589
10.4.4 The Authentication Problem ............................................. 592
10.4.5 Certificate Signing .............................................................. 594
10.4.6 Certificate Requests ............................................................ 596
10.4.7 Code Signing ....................................................................... 597
10.5 Encryption ......................................................................................... 599
10.5.1 Symmetric Ciphers ............................................................. 600
10.5.2 Key Generation ................................................................... 602
10.5.3 Cipher Streams .................................................................... 607
10.5.4 Public Key Ciphers ............................................................. 608
Chapter 11: Advanced Swing and Graphics ............................................. 613
11.1 Tables ................................................................................................ 613
11.1.1 A Simple Table .................................................................... 614
11.1.2 Table Models ....................................................................... 618
11.1.3 Working with Rows and Columns .................................... 622
11.1.3.1 Column Classes ................................................... 622
11.1.3.2 Accessing Table Columns ................................... 623
11.1.3.3 Resizing Columns ................................................ 624
11.1.3.4 Resizing Rows ...................................................... 625
11.1.3.5 Selecting Rows, Columns, and Cells ................. 626
11.1.3.6 Sorting Rows ........................................................ 627
11.1.3.7 Filtering Rows ...................................................... 628
11.1.3.8 Hiding and Displaying Columns ....................... 630
11.1.4 Cell Rendering and Editing ............................................... 639
11.1.4.1 Rendering Cells ................................................... 639
11.1.4.2 Rendering the Header ......................................... 641
11.1.4.3 Editing Cells ......................................................... 641
11.1.4.4 Custom Editors .................................................... 642
11.2 Trees .................................................................................................. 652
11.2.1 Simple Trees ........................................................................ 654
11.2.1.1 Editing Trees and Tree Paths ............................. 663
11.2.2 Node Enumeration .............................................................. 672
11.2.3 Rendering Nodes ................................................................ 674
11.2.4 Listening to Tree Events .................................................... 677
11.2.5 Custom Tree Models .......................................................... 684
11.3 Advanced AWT ................................................................................ 693
11.3.1 The Rendering Pipeline ...................................................... 694
11.3.2 Shapes .................................................................................. 696
11.3.2.1 The Shape Class Hierarchy .................................... 697
11.3.2.2 Using the Shape Classes ..................................... 698
11.3.3 Areas .................................................................................... 714
11.3.4 Strokes .................................................................................. 715
11.3.5 Paint ..................................................................................... 724
11.3.6 Coordinate Transformations .............................................. 727
11.3.7 Clipping ............................................................................... 733
11.3.8 Transparency and Composition ........................................ 735
11.4 Raster Images .................................................................................... 744
11.4.1 Readers and Writers for Images ........................................ 745
11.4.1.1 Obtaining Readers and Writers for Image File Types ..................................................................... 745
11.4.1.2 Reading and Writing Files with Multiple Images ................................................................... 747
11.4.2 Image Manipulation ............................................................ 756
11.4.2.1 Constructing Raster Images ................................ 756
11.4.2.2 Filtering Images ................................................... 763
11.5 Printing .............................................................................................. 772
11.5.1 Graphics Printing ................................................................ 772
11.5.2 Multiple-Page Printing ........................................................ 782
11.5.3 Print Services ....................................................................... 792
11.5.4 Stream Print Services ......................................................... 796
11.5.5 Printing Attributes .............................................................. 799
Chapter 12: Native Methods ...................................................................... 809
12.1 Calling a C Function from a Java Program ................................... 810
12.2 Numeric Parameters and Return Values ....................................... 817
12.3 String Parameters ............................................................................. 819
12.4 Accessing Fields ................................................................................ 825
12.4.1 Accessing Instance Fields ................................................... 825
12.4.2 Accessing Static Fields ........................................................ 829
12.5 Encoding Signatures ......................................................................... 831
12.6 Calling Java Methods ....................................................................... 832
12.6.1 Instance Methods ................................................................ 833
12.6.2 Static Methods ..................................................................... 834
12.6.3 Constructors ........................................................................ 835
12.6.4 Alternative Method Invocations ........................................ 835
12.7 Accessing Array Elements ............................................................... 840
12.8 Handling Errors ................................................................................ 844
12.9 Using the Invocation API ................................................................ 849
12.10 A Complete Example: Accessing the Windows Registry ............. 855
12.10.1 Overview of the Windows Registry .................................. 855
12.10.2 A Java Platform Interface for Accessing the Registry ..... 856
12.10.3 Implementation of Registry Access Functions as Native Methods ...................................................................857
Index ............................................................................................................. 873
Доп. информация: True PDF (в отличии от существующих раздач)

Программист

Post 30-Dec-2020 17:05

[Quote]

Beyond the Basic Stuff with Python: Best Practices for Writing Clean Code / За пределами основ Python: лучшие практики написания чистого кода
Год издания: 2020
Автор: Sweigart Al / Свейгарт Эл
Издательство: No Starch Press
ISBN: 9781593279677
Язык: Английский
Формат: PDF/epub
Качество: Издательский макет или текст (eBook)
Интерактивное оглавление: Да
Количество страниц: 386
Описание: You’ve completed a basic Python programming tutorial or finished Al Sweigart’s bestseller, Automate the Boring Stuff with Python. What’s the next step toward becoming a capable, confident software developer?
Welcome to Beyond the Basic Stuff with Python. More than a mere collection of advanced syntax and masterful tips for writing clean code, you’ll learn how to advance your Python programming skills by using the command line and other professional tools like code formatters, type checkers, linters, and version control. Sweigart takes you through best practices for setting up your development environment, naming variables, and improving readability, then tackles documentation, organization and performance measurement, as well as object-oriented design and the Big-O algorithm analysis commonly used in coding interviews. The skills you learn will boost your ability to program–not just in Python but in any language.
You’ll learn:
- Coding style, and how to use Python’s Black auto-formatting tool for cleaner code
- Common sources of bugs, and how to detect them with static analyzers
- How to structure the files in your code projects with the Cookiecutter template tool
- Functional programming techniques like lambda and higher-order functions
- How to profile the speed of your code with Python’s built-in timeit and cProfile modules
- The computer science behind Big-O algorithm analysis
- How to make your comments and docstrings informative, and how often to write them
- How to create classes in object-oriented programming, and why they’re used to organize code
Toward the end of the book you’ll read a detailed source-code breakdown of two classic command-line games, the Tower of Hanoi (a logic puzzle) and Four-in-a-Row (a two-player tile-dropping game), and a breakdown of how their code follows the book’s best practices. You’ll test your skills by implementing the program yourself.
Of course, no single book can make you a professional software developer. But Beyond the Basic Stuff with Python will get you further down that path and make you a better programmer, as you learn to write readable code that’s easy to debug and perfectly Pythonic

Оглавление

Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xix
Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xxi
PART I: GETTING STARTED . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
Chapter 1: Dealing with Errors and Asking for Help . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
Chapter 2: Environment Setup and the Command Line . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
PART II: BEST PRACTICES, TOOLS, AND TECHNIQUES . . . . . . . . 43
Chapter 3: Code Formatting with Black . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45
Chapter 4: Choosing Understandable Names . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59
Chapter 5: Finding Code Smells . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69
Chapter 6: Writing Pythonic Code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 87
Chapter 7: Programming Jargon . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 107
Chapter 8: Common Python Gotchas . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 133
Chapter 9: Esoteric Python Oddities . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 153
Chapter 10: Writing Effective Functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 161
Chapter 11: Comments, Docstrings, and Type Hints . . . . . . . . . . . . . . . . . . . . . . . . . . . . 181
Chapter 12: Organizing Your Code Projects with Git . . . . . . . . . . . . . . . . . . . . . . . . . . . 199
Chapter 13: Measuring Performance and Big O Algorithm Analysis . . . . . . . . . . . . . . . . 225
Chapter 14: Practice Projects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 247
PART III: OBJECT-ORIENTED PYTHON . . . . . . . . . . . . . . . . . . 273
Chapter 15: Object-Oriented Programming and Classes . . . . . . . . . . . . . . . . . . . . . . . . . 275
Chapter 16: Object-Oriented Programming and Inheritance . . . . . . . . . . . . . . . . . . . . . . 293
Chapter 17: Pythonic OOP: Properties and Dunder Methods . . . . . . . . . . . . . . . . . . . . . . 315
Index . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 339

Примеры страниц

Программист

Post 30-Dec-2020 11:15

[Quote]

Параллельное программирование на C++ с помощью библиотеки TBB
Год издания: 2020
Автор: Восс Майкл, Асенхо Рафаэль, Рейндерс Джеймс
Издательство: ДМК
ISBN: 978-5-97060-864-7
Язык: Русский
Формат: PDF
Качество: Издательский макет или текст (eBook)
Интерактивное оглавление: Да
Количество страниц: 675
Описание: (TBB). Написанная специалистами по TBB и параллельному программированию, она подытоживает их многолетний коллективный опыт paзpa6oтки и преподавания параллельного программирования с помощью TBB.
В книге приводятся многочисленные примеры и рекомендации, которые помогут вам в полной мере овладеть TBB и задействовать всю мощь параллельных систем.
Краткое содержание:
- использование TBB для paзpa6oтки переносимого, простого, масштабируемого и 6oлee понятного кода;
- передовые методы распараллеливания счетных задач;
- интеграция TBB с другими пакетами многопоточного программирования;
- создание мacштa6иpyeмыx высокопроизводительных программ, распараллеленных по данным;
- применение обобщенного программирования для написания эффективных алгоритмов.

Примеры страниц

Оглавление

От издательства 14
Об авторах 15
Благодарности 16
Предисловие 18
ЧАСТЬ I
Глава 1. Приступаем: «Hello, TBB!» 60
Глава 2. Обобщенные параллельные алгоритмы 85
Глава 3. Потоковые графы 122
Глава 4. TBB и параллельные алгоритмы стандартной библиотеки шаблонов C++ 145
Глава 5. Синхронизация – почему ее нужно избегать и как это сделать 167
Глава 6. Структуры данных для конкурентного программирования 201
Глава 7. Масштабируемое выделение памяти 224
Глава 8. TBB и параллельные паттерны 245
ЧАСТЬ II
Глава 9. Столпы компонуемости 261
Глава 10. Использование задач для создания собственных алгоритмов 283
Глава 11. Управление количеством потоков 312
Глава 12. Применение изоляции работы для обеспечения корректности и повышения производительности 331
Глава 13. Привязка потока к ядру и задачи к потоку 348
Глава 14. Приоритеты задач 359
Глава 15. Отмена и обработка исключений 369
Глава 16. Настройка TBB-алгоритмов: зернистость, локальность, параллелизм и детерминированность 388
Глава 17. Потоковые графы: дополнительные сведения 419
Глава 18. Дополнение потоковых графов асинхронными узлами 471
Глава 19. Накачанные потоковые графы: узлы OpenCL 488
Глава 20. TBB в системах с архитектурой NUMA 525
Приложение А. История и предшественники 546
Приложение В. TBB в кратком изложении 560
Глоссарий 655
Предметный указатель 668

Программист

Post 30-Dec-2020 03:35

[Quote]

Head First Agile, 1st Edition
Год издания: 2017
Автор: Andrew Stellman, Jennifer Greene
Жанр или тематика: Agile
Издательство: O'Reilly
ISBN: 9781449314330
Серия: Head First
Язык: Английский
Формат: PDF
Качество: Издательский макет или текст (eBook)
Интерактивное оглавление: Да
Количество страниц: 490
Описание: What will you learn from this book?
In Head First Agile, you'll learn all about the ideas behind agile and the straightforward practices that drive it. You'll take deep dives into Scrum, XP, Lean, and Kanban, the most common real-world agile approaches today. You'll learn how to use agile to help your teams plan better, work better together, write better code, and improve as a team—because agile not only leads to great results, but agile teams say they also have a much better time at work. Head First Agile will help you get agile into your brain... and onto your team!
Preparing for your PMI-ACP® certification?
This book also has everything you need to get certified, with 100% coverage of the PMI-ACP® exam. Luckily, the most effective way to prepare for the exam is to get agile into your brain—so instead of cramming, you're learning.
Why does this book look so different?
Based on the latest research in cognitive science and learning theory, Head First Agile uses a visually rich format to engage your mind, rather than a text-heavy approach that puts you to sleep. Why waste your time struggling with new concepts? This multi-sensory learning experience is designed for the way your brain really works.

Примеры страниц

Оглавление

Praise for Head First Agile
Praise for other Head First books
how to use this book: Intro
Who is this book for?
Who should probably back away from this book?
We know what you’re thinking.
And we know what your brain is thinking.
This must be important! Don’t forget it!
Metacognition: thinking about thinking
So just how DO you get your brain to think that the material about agile is a hungry tiger?
Here’s what WE did:
Here’s what YOU can do to bend your brain into submission
Read me
The redundancy is intentional and important.
The Brain Power exercises don’t have answers.
The activities are NOT optional.
Try the exam questions—even if you’re not studying for the exam!
The technical review team
Acknowledgments
O’Reilly Safari®
More Praise for Head First Agile
1. What is agile?: Principles and practices
The new features sound great...
...but things don’t always go as expected
Agile to the rescue!
A daily standup is a good starting point
Kate tries to hold a daily standup
Different team members have different attitudes
A better mindset makes the practice work better
So what is agile, anyway?
Mindset versus methodology
Scrum is the most common approach to agile
XP and Lean/Kanban
there are no Dumb Questions
The PMI-ACP certification can help you be more agile
2. Agile values and principles: Mindset meets method
Something big happened in Snowbird
Meeting of the minds
The Agile Manifesto
Adding practices in the real world can be a challenge
The four values of the Agile Manifesto guide the team to a better, more effective mindset
Manifesto Magnets
there are no Dumb Questions
Question Clinic: The “which-is-BEST” question
They think they’ve got a hit ...
... but it’s a flop!
The principles behind the Agile Manifesto
The agile principles help you deliver your product
Fireside Chats
there are no Dumb Questions
The agile principles help your team communicate and work together
there are no Dumb Questions
The new product is a hit!
Exam Questions
Exam Answers
Manifesto Magnets Solution
3. Managing projects with Scrum: The Rules of Scrum
Meet the Ranch Hand Games team
The Scrum events help you get your projects done
The Scrum roles help you understand who does what
The Scrum artifacts keep the team informed
The Increment is the sum of all backlog items that are actually completed and delivered at the end of the Sprint
there are no Dump Questions
The Scrum values make the team more effective
Story Time
there are no Dumb Questions
Question Clinic: The “which-comes-next” question
A task isn’t done until it’s “Done” done
Scrum teams adapt to changes throughout the Sprint
there are no Dumb Questions
The Agile Manifesto helps you really “get” Scrum
The Product Owner makes sure the team delivers value
Self-organizing means deciding as a team what to work on next
there are no Dumb Questions
Things are looking good for the team
Exam Questions
Exam Answers
4. Agile Planning and Estimation: Generally Accepted Scrum Practices
Meanwhile, back at the ranch...
So... what’s next?
Introducing GASPs!
No more 300-page specs... please?
User stories help teams understand what users need
Story points let the team focus on the relative size of each story
How story points work
The whole team estimates together
No more detailed project plans
Taskboards keep the team informed
there are no Dumb Questions
Question Clinic: The red herring
Burndown charts help the team see how much work is left
Velocity tells you how much your team can do in a sprint
Burn-ups keep your progress and your scope separate from each other
How do we know what to build?
Story maps help you prioritize your backlog
Personas help you get to know your users
there are no Dumb Questions
The news could be better...
Retrospectives help your team improve the way they work
Some tools to help you get more out of your retrospectives
Tools to help you set the stage:
Tools to help you gather data:
Tools to help you generate insights:
Tools to help you decide what to do:
Cubicle Conversation
Pizza party!
Exam Questions
Exam Answers
5. XP (extreme programming): Embracing change
Meet the team behind CircuitTrak
Gary’s the founder and CEO
Ana and Ryan are the lead engineers
Late nights and weekends lead to code problems
XP brings a mindset that helps the team and the code
Iterative development helps teams stay on top of changes
XP teams use stories to track their requirements
XP teams plan their work a quarter at a time
XP teams use one-week iterations
Slack means giving the team some breathing room
Courage and respect keep fear out of the project
Venn Magnets
Venn Magnets Solution
there are no Dumb Questions
Teams build better code when they work together
A whole team is built on trust
Trust means letting your teammates make mistakes
XP teams don’t have fixed or prescribed roles
Teams work best when they sit together
XP teams value communication
Teams work best with relaxed, rested minds
Leave yourself enough time to do the job
Let yourself make mistakes
Get rid of interruptions
Work at a sustainable pace
there are no Dumb Questions
Question Clinic: The “which-is-NOT” question
XP teams embrace change
Frequent feedback keeps changes small
Bad experiences cause a rational fear of change
XP practices give you feedback about the code
XP teams use automated builds that run quickly
Continuous integration prevents nasty surprises
The weekly cycle starts with writing tests
Agile teams get feedback from design and testing
Wireframes help the team get early feedback about the user interface
Build spike solutions to get an idea of a feature’s technical difficulty
Usability testing means testing your user interface on real users
Pair programming
there are no Dumb Questions
Complex code is really hard to maintain
When teams value simplicity, they build better code
Simplicity is a fundamental agile principle
When units are tightly coupled, it adds complexity to the project
It’s tempting to sacrifice simplicity for reusability
Every team accumulates technical debt
XP teams “pay down” technical debt in each weekly cycle
Incremental design starts (and ends) with simple code
there are no Dumb Questions
Exam Questions
Exam Answers
6. Lean/Kanban: Eliminating Waste and Managing Flow
Trouble with Audience Analyzer 2.5
Lean is a mindset (not a methodology)
Lean, Scrum, and XP are compatible
Lean principles help you see things differently
More Lean principles
Venn Magnets
Venn Magnets Solution
Some thinking tools you haven’t seen before
More Lean thinking tools
Cubicle Conversation
Categorizing waste can help you see it better
there are no Dumb Questions
Value stream maps help you see waste
Trying to do too many things at once
Anatomy of an Option
Systems thinking helps Lean teams see the whole
Some “improvements” didn’t work out
A failed experiment (and that’s a good thing!)
Lean teams use pull systems to make sure they’re always working on the most valuable tasks
Set up a pull system by establishing WIP limits
there are no Dumb Questions
Question Clinic: Least worst option
Kanban uses a pull system to make your process better
Use Kanban boards to visualize the workflow
How to use Kanban to improve your process
The team creates a workflow
Cubicle Conversation
there are no Dumb Questions
The team is delivering faster
Cumulative flow diagrams help you manage flow
Kanban teams talk about their policies
Feedback loops show you how it’s working
Kanban teams use lead time to create feadback loops
Now the whole team is collaborating on finding better ways to work!
Exam Questions
Exam Answers
7. Preparing for the PMI-ACP® exam: Check your knowledge
The PMI-ACP® certification is valuable...
...but you really need to know your stuff
The PMI-ACP® exam is based on the content outline
The content outline is an important preparation tool
“You are an agile practitioner...”
there are no Dumb Questions
A long-term relationship for your brain
Pool Puzzle
Pool Puzzle Solution
Exam Questions
Exam Answers
Agile teams use customer value to prioritize requirements
Value calculations help you figure out which projects to do
Exam Questions
Exam Answers
Exam Questions
Exam Questions
Exam Answers
Exam Answers
Adapt your leadership style as the team evolves
Situational leadership
A few last tools and techniques
Risk-adjusted backlog, pre-mortem, and risk burn down charts
A few last tools and techniques
Collaboration games
Exam Questions
Exam Answers
Exam Questions
Exam Questions
Exam Answers
Exam Answers
Are you ready for the final exam?
8. Professional responsibility: Making good choices
Doing the right thing
The main ideas
Keep the cash?
Fly business class?
New software
Shortcuts
A good price or a clean river?
We’re not all angels
Exam Questions
Exam Answers
9. Practice makes perfect: Practice PMI-ACP Exam
Before you look at the answers...
Index
 

The time now is: Today 13:31

All times are GMT + 4 Hours