图书介绍

Erlang编程 英文版PDF|Epub|txt|kindle电子书版本网盘下载

Erlang编程 英文版
  • (瑞典)塞萨芮利,(英)汤普森著 著
  • 出版社: 南京:东南大学出版社
  • ISBN:9787564122690
  • 出版时间:2010
  • 标注页数:474页
  • 文件大小:44MB
  • 文件页数:495页
  • 主题词:程序语言-程序设计-英文

PDF下载


点此进入-本书在线PDF格式电子书下载【推荐-云解压-方便快捷】直接下载PDF格式图书。移动端-PC端通用
种子下载[BT下载速度快]温馨提示:(请使用BT下载软件FDM进行下载)软件下载地址页直链下载[便捷但速度慢]  [在线试读本书]   [在线获取解压码]

下载说明

Erlang编程 英文版PDF格式电子书版下载

下载的文件为RAR压缩包。需要使用解压软件进行解压得到PDF格式图书。

建议使用BT下载工具Free Download Manager进行下载,简称FDM(免费,没有广告,支持多平台)。本站资源全部打包为BT种子。所以需要使用专业的BT下载软件进行下载。如BitComet qBittorrent uTorrent等BT下载工具。迅雷目前由于本站不是热门资源。不推荐使用!后期资源热门了。安装了迅雷也可以迅雷进行下载!

(文件页数 要大于 标注页数,上中下等多册电子书除外)

注意:本站所有压缩包均有解压码: 点击下载压缩包解压工具

图书目录

1.Introduction1

Why Should I Use Erlang?1

The History of Erlang3

Erlang's Characteristics4

High-Level Constructs4

Concurrent Processes and Message Passing5

Scalable,Safe,and Efficient Concurrency6

Soft Real-Time Properties6

Robustness6

Distributed Computation7

Integration and Openness8

Erlang and Multicore9

Case Studies10

The AXD301 ATM Switch10

CouchDB11

Comparing Erlang to C++12

How Should I Use Erlang?14

2.Basic Erlang15

Integers15

The Erlang Shell16

Floats17

Mathematical Operators17

Atoms19

Booleans20

Tuples21

Lists22

Characters and Strings22

Atoms and Strings23

Building and Processing Lists24

List Functions and Operations25

Term Comparison28

Variables30

Complex Data Structures32

Pattern Matching33

Functions38

Modules40

Compilation and the Erlang Virtual Machine40

Module Directives41

Exercises43

3.Sequential Erlang45

Conditional Evaluations46

The case Construct46

Variable Scope48

The if Construct49

Guards50

Built-in Functions53

Object Access and Examination53

Type Conversion54

Process Dictionary55

Meta Programming55

Process,Port,Distribution,and System Information56

Input and Output57

Recursion59

Tail-Recursive Functions63

Tail-Call Recursion Optimization66

Iterations Versus Recursive Functions67

Runtime Errors68

Handling Errors70

Using try... catch70

Using catch74

Library Modules77

Documentation77

Useful Modules79

The Debugger80

Exercises82

4.Concurrent Programming89

Creating Processes90

Message Passing92

Receiving Messages94

Selective and Nonselective Receives97

An Echo Example100

Registered Processes102

Timeouts104

Benchmarking106

Process Skeletons107

Tail Recursion and Memory Leaks108

A Case Study on Concurrency-Oriented Programming110

Race Conditions,Deadlocks,and Process Starvation112

The Process Manager114

Exercises115

5.Process Design Patterns117

Client/Server Models118

A Client/Server Example119

A Process Pattern Example125

Finite State Machines126

An FSM Example127

A Mutex Semaphore129

Event Managers and Handlers131

A Generic Event Manager Example132

Event Handlers135

Exercises137

6.Process Error Handling139

Process Links and Exit Signals139

Trapping Exits142

The monitor BIFs144

The exit BIFs145

BIFs and Terminology146

Propagation Semantics148

Robust Systems148

Monitoring Clients150

A Supervisor Example152

Exercises154

7.Recordsand Macros157

Records158

Introducing Records158

Working with Records159

Functions and Pattern Matching over Records160

Records in the Shell161

Record Implementation162

Record BIFs164

Macros165

Simple Macros165

Parameterized Macros166

Debugging and Macros166

Include Files168

Exercises168

8.Software Upgrade173

Upgrading Modules173

Behind the Scenes176

Loading Code179

The Code Server180

Purging Modules182

Upgrading Processes182

The .erlang File186

Exercise186

9.More Data Types and High-Level Constructs189

Functional Programming for Real189

Funs and Higher-Order Functions190

Functions As Arguments190

Writing Down Functions:fun Expressions192

Functions As Results193

Using Already Defined Functions194

Functions and Variables195

Predefined,Higher-Order Functions195

Lazy Evaluation and Lists197

List Comprehensions198

A First Example198

General List Comprehensions198

Multiple Generators200

Standard Functions200

Binaries and Serialization201

Binaries202

The Bit Syntax203

Pattern-Matching Bits205

Bitstring Comprehensions206

Bit Syntax Example:Decoding TCP Segments206

Bitwise Operators208

Serialization208

References210

Exercises211

10.ETSand DetsTables213

ETS Tables213

Implementations and Trade-offs214

Creating Tables216

Handling Table Elements217

Example:Building an Index,Act Ⅰ218

Traversing Tables220

Example:Building an Index,Act Ⅱ222

Extracting Table Information:match223

Extracting Table Information:select225

Other Operations on Tables226

Records and ETS Tables226

Visualizing Tables228

Dets Tables229

A Mobile Subscriber Database Example231

The Database Backend Operations232

The Database Server237

Exercises242

11.Distributed Programming in Erlang245

Distributed Systems in Erlang245

Distributed Computing in Erlang:The Basics247

Node Names and Visibility249

Communication and Security250

Communication and Messages252

Node Connections253

Remote Procedure Calls256

The rpc Module258

Essential Distributed Programming Modules258

The epmd Process260

Distributed Erlang Behind Firewalls261

Exercises261

12.OTP Behaviors263

Introduction to OTP Behaviors263

Generic Servers266

Starting Your Server266

Passing Messages268

Stopping the Server270

The Example in Full271

Running gen_server273

Supervisors276

Supervisor Specifications277

Child Specifications278

Supervisor Example279

Dynamic Children280

Applications281

Directory Structure282

The Application Resource File283

Starting and Stopping Applications284

The Application Monitor287

Release Handling287

Other Behaviors and Further Reading290

Exercises291

13.Introducing Mnesia293

When to Use Mnesia293

Configuring Mnesia295

Setting Up the Schema295

Starting Mnesia296

Mnesia Tables296

Transactions299

Writing299

Reading and Deleting300

Indexing301

Dirty Operations302

Partitioned Networks304

Further Reading305

Exercises306

14.GUI Programming with wxErlang309

wxWidgets309

wxErlang:An Erlang Binding for wxWidgets310

Objects and Types311

Event Handling,Object Identifiers,and Event Types312

Putting It All Together313

A First Example:MicroBlog314

The MiniBlog Example317

Obtaining and Running wxErlang321

Exercises321

15.Socket Programming323

User Datagram Protocol323

Transmission Control Protocol327

A TCP Example328

The inet Module331

Further Reading333

Exercises334

16.Interfacing Erlang with Other Programming Languages335

An Overview of Interworking336

Interworking with Java337

Nodes and Mailboxes337

Representing Erlang Types338

Communication338

Putting It Together:RPC Revisited339

Interaction340

The Small Print341

Taking It Further342

C Nodes342

Going Further345

Erlang from the Unix Shell:erl_call346

Port Programs346

Erlang Port Commands347

Communicating Data to and from a Port349

Library Support for Communication350

Working in Ruby:erlectricity351

Linked-in Drivers and the FFI352

Exercises353

17.Trace BIFs,the dbg Tracer,and Match Specifications355

Introduction355

The Trace BIFs357

Process Trace Flags358

Inheritance Flags360

Garbage Collection and Timestamps361

Tracing Calls with the trace_pattern BIF362

The dbg Tracer365

Getting Started with dbg366

Tracing and Profiling Functions369

Tracing Local and Global Function Calls369

Distributed Environments371

Redirecting the Output371

Match Specifications:The fun Syntax374

Generating Specifications Using fun2ms375

Difference Between ets and dbg Match Specifications382

Match Specifications:The Nuts and Bolts383

The Head383

Conditions384

The Specification Body387

Saving Match Specifications390

Further Reading391

Exercises392

18.Types and Documentation395

Types in Erlang395

An Example:Records with Typed Fields395

Erlang Type Notation396

TypEr:Success Types and Type Inference399

Dialyzer:A DIscrepancy AnaLYZer for ERlang Programs401

Documentation with EDoc402

Documenting usr_db.erl403

Running EDoc405

Types in EDoc407

Going Further with EDoc408

Exercises410

19.EUnit and Test-Driven Development411

Test-Driven Development411

EUnit412

How to Use EUnit413

Functional Testing,an Example:Tree Serialization413

The EUnit Infrastructure416

Assert Macros416

Test-Generating Functions416

EUnit Test Representation417

Testing State-Based Systems418

Fixtures:Setup and Cleanup418

Testing Concurrent Programs in Erlang419

Exercises420

20.Style and Efficiency421

Applications and Modules421

Libraries422

Dirty Code423

Interfaces423

Return Values424

Internal Data Structures425

Processes and Concurrency426

Stylistic Conventions430

Coding Strategies435

Efficiency437

Sequential Programming437

Lists439

Tail Recursion and Non-tail Recursion440

Concurrency440

And Finally...442

Appendix:Using Erlang445

Index451

热门推荐