ext js 4 architecture

57

Upload: sencha

Post on 25-Jun-2015

3.022 views

Category:

Technology


3 download

DESCRIPTION

Ext JS 4 has a thoroughly revamped architecture that enables faster performance and more developer flexibility. In this session, we will take a tour through the revamped architecture of Ext JS 4.x, taking a high-level look at the updated data package, component hierarchy and core APIs. Afterwards, developers will have an understanding of why Ext JS 4 works the way it does and how best to leverage its underlying APIs.

TRANSCRIPT

Page 1: Ext JS 4 Architecture
Page 2: Ext JS 4 Architecture

Ext 4 Architecture

Ed Spencer@edspencer

Page 3: Ext JS 4 Architecture

Ext JS Architecture

Components

State UtilitiesLayouts Data

Page 4: Ext JS 4 Architecture

Shared with Sencha Touch

Page 5: Ext JS 4 Architecture

Sencha Platform

Ext JS Sencha Touch

Platform

Page 6: Ext JS 4 Architecture

Sencha Platform

Data Layouts Utilities Charts Animation

Platform

Page 7: Ext JS 4 Architecture

Components

Data

Layout

Utilities

Component

Page 8: Ext JS 4 Architecture

Example

Store

Layout

Renderers

Grid

Page 9: Ext JS 4 Architecture

Ext 3

Store

Writer

Proxy

RecordReader

Page 10: Ext JS 4 Architecture

Ext 4

Store

Writer

Proxy

Reader

Model

Page 11: Ext JS 4 Architecture

Models

Writer

Proxy

Reader

Model

Page 12: Ext JS 4 Architecture

Models

Model

Page 13: Ext JS 4 Architecture

Models

Model

Fields

Page 14: Ext JS 4 Architecture

Models

Model

Fields

Associations

Page 15: Ext JS 4 Architecture

Models

Model

Fields

Associations

Validations

Page 16: Ext JS 4 Architecture

Models

Model

Fields

Associations

Validations

Proxy

Page 17: Ext JS 4 Architecture

Models

Model

Fields

Associations

Validations

Proxy

Business logic

Page 18: Ext JS 4 Architecture

Example

Page 19: Ext JS 4 Architecture

Example

User Order OrderItem

Page 20: Ext JS 4 Architecture

Example

User

Page 21: Ext JS 4 Architecture

Example

Order

Page 22: Ext JS 4 Architecture

Example

OrderItem

Page 23: Ext JS 4 Architecture

Loading Nested Data

GET /users/1.json

Page 24: Ext JS 4 Architecture

Loading Nested Data

GET /users/1.json

Automatically loads associations

Page 25: Ext JS 4 Architecture

Automatically loads associations

Page 26: Ext JS 4 Architecture

Integrated with Components

Page 27: Ext JS 4 Architecture

Integrated with Components

Page 28: Ext JS 4 Architecture

Integrated with Components

Page 29: Ext JS 4 Architecture

Stores

Page 30: Ext JS 4 Architecture

Store’s supporting cast

Store

Data Sorters Filters

Page 31: Ext JS 4 Architecture

Richer Store API

Sorters

Filters

Page 32: Ext JS 4 Architecture

Richer Store API

Sorters

Filters

Sorters and Filters are MixedCollections

Page 33: Ext JS 4 Architecture

Richer Store API

Sorters

Filters

Sorters and Filters are MixedCollections

Add/remove any time

Page 34: Ext JS 4 Architecture

Richer Store API

Sorters

Filters

Sorters and Filters are MixedCollections

Add/remove any time

Ext.util.Sorter

Page 35: Ext JS 4 Architecture

Richer Store API

Sorters

Filters

Sorters and Filters are MixedCollections

Add/remove any time

Ext.util.SorterExt.util.Filter

Page 36: Ext JS 4 Architecture

Proxies

Page 37: Ext JS 4 Architecture

Proxies

Proxy

ClientProxy ServerProxy

Page 38: Ext JS 4 Architecture

Server Proxies

AjaxProxy RestProxy ScriptTagProxy

ServerProxy

Page 39: Ext JS 4 Architecture

Client Proxies

ClientProxy

MemoryProxy WebStorageProxy WebSqlProxy

Page 40: Ext JS 4 Architecture

Proxies

ProxyStore/Model Operation

Page 41: Ext JS 4 Architecture

Ext.data.Operation

Operation

Page 42: Ext JS 4 Architecture

Ext.data.Operation

Operation

Mediates between Store and Proxy

Page 43: Ext JS 4 Architecture

Ext.data.Operation

Operation

Mediates between Store and Proxy

Create, Read, Update or Destroy

Page 44: Ext JS 4 Architecture

Ext.data.Operation

Operation

Mediates between Store and Proxy

Create, Read, Update or Destroy

Asynchronous

Page 45: Ext JS 4 Architecture

Ext.data.Batch

Batch

Create

Update

Destroy

Page 46: Ext JS 4 Architecture

Ext.data.Batch

Batch

Page 47: Ext JS 4 Architecture

Ext.data.Batch

Batch

Combines Operations

Page 48: Ext JS 4 Architecture

Ext.data.Batch

Batch

Combines Operations

Batches into 1 request

Page 49: Ext JS 4 Architecture

Ext.data.Batch

Batch

Combines Operations

Batches into 1 request

Can run sequentially

Page 50: Ext JS 4 Architecture

Summary

Page 51: Ext JS 4 Architecture

SummaryLarge scale Architecture in 3.x good

Page 52: Ext JS 4 Architecture

SummaryLarge scale Architecture in 3.x good

New data capabilities: Models

Page 53: Ext JS 4 Architecture

SummaryLarge scale Architecture in 3.x good

New data capabilities: Models Associations

Page 54: Ext JS 4 Architecture

SummaryLarge scale Architecture in 3.x good

New data capabilities: Models Associations Validations

Page 55: Ext JS 4 Architecture

SummaryLarge scale Architecture in 3.x good

New data capabilities: Models Associations Validations Flexible Proxies

Page 56: Ext JS 4 Architecture

SummaryLarge scale Architecture in 3.x good

New data capabilities: Models Associations Validations Flexible Proxies Operations & Batches

Page 57: Ext JS 4 Architecture

Questions?