SlideShare a Scribd company logo
1 of 48
Download to read offline
Pharo: Object at
your Fingertips
Marcus Denker
http://www.pharo-project.org
What is it?
Language + Environment
Simple Language (Smalltalk)
Object-Oriented, Dynamic, Reflective
Explore + Change running systems
!

The Ultimate Programming Environment!
Pharo
MIT license
Mac, Linux, Android, iOS, Windows
Great community
Improving steadily
Many excellent libraries
Started 2008

Pharo 1.0 released October 2009
2.0 is the current stable
Pharo3: Early 2014
Plan: 1 Release per year
Language
(in 10 minutes)
Pharo started with Smalltalk-80 (Squeak)
Language still very much Smalltalk
But the goal is to develop it further
Example: Reflective Capabilities
Less is better
No constructors
No types declaration
No interfaces
No packages/private/protected
No parametrized types
Yet really powerful
Objects are instances of Classes
Objects are instances of Classes
!

(10@200)
Objects are instances of Classes
!

(10@200) class
Objects are instances of Classes
!

(10@200) class
Point
Classes are objects too
Classes are objects too
!

Point selectors
!
Classes are objects too

!
Point selectors

!
> an IdentitySet(#eightNeighbors #+ #isZero #sortsBefore: #degrees #printOn: #sideOf:
#fourNeighbors #hash #roundUpTo: #min: #min:max: #max #adaptToCollection:andSend:
#quadrantOf: #crossProduct: #= #nearestPointOnLineFrom:to: #bitShiftPoint: #* #guarded
#insideTriangle:with:with: #grid: #truncateTo: #y #setR:degrees: #normal #directionToLineFrom:to:
#truncated #nearestPointAlongLineFrom:to: #theta #scaleTo: #encodePostscriptOn: #> #asPoint
#extent: #r #roundTo: #max: #interpolateTo:at: #triangleArea:with: #angleWith: #dotProduct:
#isSelfEvaluating #'<=' #to:intersects:to: #'//' #isInsideCircle:with:with: #< #scaleFrom:to: #corner:
#to:sideOf: #x #'>=' #roundDownTo: #onLineFrom:to:within: #transposed #ceiling #angle #basicType
#translateBy: #asFloatPoint #'' #adaptToNumber:andSend: #abs #negated #octantOf:
#asIntegerPoint #flipBy:centerAt: #scaleBy: #floor #onLineFrom:to: #isPoint #reflectedAbout: #/ #dist:
#asNonFractionalPoint #bearingToPoint: #reciprocal #rotateBy:centerAt: #rotateBy:about: #rounded
#setX:setY: #squaredDistanceTo: #normalized #veryDeepCopyWith: #- #storeOn: #rect: #deepCopy
#isIntegerPoint #min #adhereTo: #adaptToString:andSend:)
Methods are public
Instance variables are protected
Single Inheritance
2 instance variables

Single Inheritance

Object subclass: #Point!
! instanceVariableNames: 'x y'!
! classVariableNames: ''!
! poolDictionaries: ''!
! category: 'Kernel-BasicObjects'

subclass of Object
3 kinds of messages
Unary messages

5 factorial!
Transcript cr

Binary messages

3 + 4

Keywords messages
3 raisedTo: 10 modulo: 5!
!

Transcript show: 'hello world'
Blocks
• Anonymous method
• Passed as method argument or stored
• Functions

	 	

fct(x)= x*x+3, fct(2).

!

	 	
!

fct :=[:x| x * x + 3].
fct value: 2
Control structures
Every control structure is realized by message sends
4 timesRepeat: [Beeper beep]

max: aNumber!
! ^ self < aNumber !
! !
ifTrue: [aNumber] !
! !
ifFalse: [self]
A typical method in Point
Method name

Argument

Comment

<= aPoint !
! "Answer whether the receiver is neither!
! below nor to the right of aPoint."!
!

! ^ x <= aPoint x and: [y <= aPoint y]
Return

Block
Binary message
Keyword message
Instance variable

(2@3) <= (5@6)

true
Complete Syntax on a PostCard
exampleWithNumber: x
“A method that has unary, binary, and key word messages, declares arguments and
temporaries (but not block temporaries), accesses a global variable (but not and
instance variable), uses literals (array, character, symbol, string, integer, float), uses the
pseudo variable true false, nil, self, and super, and has sequence, assignment, return
and cascade. It has both zero argument and one argument blocks.”
	 |y|
true & false not & (nil isNil) ifFalse: [self halt].
	 y := self size + super size.
	 #($a #a ‘a’ 1 1.0)
do: [:each | Transcript show: (each class name); show: (each printString); show:
‘ ‘].
^x<y
Environment
Language + Environment are closely linked
Reflection is the basis
Classes, Methods, Packages are Objects
The tools manipulate these Objects
Class Browser
Inspector
Demo: Changing a class at runtime
Demo: Exploring the system
Demo: Inspect World
There is so much more…
Pharo Books
Pharo Success Stories
Continuous API Testing

keep your services under control 24/7

www.2denker.de

Norbert Hartl norbert@2denker.de
eMCee is a montoring service for backend interfaces
- Web application to define backend interfaces
- Monitors reliability of interface periodically
- Sends warning if status of interface changes
- Provides overview graphs about reliability
- Snapshots requests for debugging purposes

mail@2denker.de
• Entry Level Track & Trace Product
• Complements T3 Full Product
• One Page Javascript HTML5 / Ajax Client
• REST Back End in Pharo Smalltalk
• Gateways to multiple data providers
Pharo Consortium
Managed by INRIA
Who: companies, institutions, user groups
Privileged access to the core development team
Influence priorities of the next development

http://consortium.pharo.org
Future +
Research
More Reflection
Instance Variables as Objects —> Slots
!

Proxy model in the base language
!

Structuring reflective API (—> Mirrors)
Beyond Text
AST Everywhere
Used in Tools for Navigation
!

Do we need to store text?
!

Use for Behavioral Reflection
System - as - Objects

Put “virtualization” in the language
We already use “Images”
Make the Image a first class concept in the language
Open Pharo Sprints
May 2008 Bern

July 2009 Bern

October 2009 Lille
November 2009 Buenos Ares
March 2010 Bern

May 2010 Buenos Ares
June 2010 Bern
June 2010 Bruxelles
July 2010 London

September 2010 Barcelona
September 2010 Lille

January 2011 Lille
July 2011 Lille
October 2011 Bruxelles
February 2012 Bern
April 2012 Lille
September 2012 Ghent
October 2013 Lille

November 2013 Buenos Aires
Pharo: Objects at your Fingertips

More Related Content

What's hot

F# Eye For The C# Guy - f(by) Minsk 2014
F# Eye For The C# Guy - f(by) Minsk 2014F# Eye For The C# Guy - f(by) Minsk 2014
F# Eye For The C# Guy - f(by) Minsk 2014Phillip Trelford
 
More on Lex
More on LexMore on Lex
More on LexTech_MX
 
F# Eye 4 the C# Guy - DDD Cambridge Nights 2014
F# Eye 4 the C# Guy -  DDD Cambridge Nights 2014F# Eye 4 the C# Guy -  DDD Cambridge Nights 2014
F# Eye 4 the C# Guy - DDD Cambridge Nights 2014Phillip Trelford
 
F# for C# devs - Copenhagen .Net 2015
F# for C# devs - Copenhagen .Net 2015F# for C# devs - Copenhagen .Net 2015
F# for C# devs - Copenhagen .Net 2015Phillip Trelford
 
Introduction to Python Programming
Introduction to Python ProgrammingIntroduction to Python Programming
Introduction to Python ProgrammingVijaySharma802
 
Ruby For Java Programmers
Ruby For Java ProgrammersRuby For Java Programmers
Ruby For Java ProgrammersMike Bowler
 
2nd puc computer science chapter 8 function overloading
 2nd puc computer science chapter 8   function overloading 2nd puc computer science chapter 8   function overloading
2nd puc computer science chapter 8 function overloadingAahwini Esware gowda
 
PYTHON NOTES
PYTHON NOTESPYTHON NOTES
PYTHON NOTESNi
 
Domain Specific Languages In Scala Duse3
Domain Specific Languages In Scala Duse3Domain Specific Languages In Scala Duse3
Domain Specific Languages In Scala Duse3Peter Maas
 
Compiler Construction | Lecture 7 | Type Checking
Compiler Construction | Lecture 7 | Type CheckingCompiler Construction | Lecture 7 | Type Checking
Compiler Construction | Lecture 7 | Type CheckingEelco Visser
 
Basic Concepts in Python
Basic Concepts in PythonBasic Concepts in Python
Basic Concepts in PythonSumit Satam
 
Hack programming language
Hack programming languageHack programming language
Hack programming languageRadu Murzea
 
The Ring programming language version 1.5.4 book - Part 6 of 185
The Ring programming language version 1.5.4 book - Part 6 of 185The Ring programming language version 1.5.4 book - Part 6 of 185
The Ring programming language version 1.5.4 book - Part 6 of 185Mahmoud Samir Fayed
 

What's hot (20)

F# Eye For The C# Guy - f(by) Minsk 2014
F# Eye For The C# Guy - f(by) Minsk 2014F# Eye For The C# Guy - f(by) Minsk 2014
F# Eye For The C# Guy - f(by) Minsk 2014
 
More on Lex
More on LexMore on Lex
More on Lex
 
F# Eye 4 the C# Guy - DDD Cambridge Nights 2014
F# Eye 4 the C# Guy -  DDD Cambridge Nights 2014F# Eye 4 the C# Guy -  DDD Cambridge Nights 2014
F# Eye 4 the C# Guy - DDD Cambridge Nights 2014
 
Meta Object Protocols
Meta Object ProtocolsMeta Object Protocols
Meta Object Protocols
 
Python basics
Python basicsPython basics
Python basics
 
F# for C# devs - Copenhagen .Net 2015
F# for C# devs - Copenhagen .Net 2015F# for C# devs - Copenhagen .Net 2015
F# for C# devs - Copenhagen .Net 2015
 
Introduction to Python Programming
Introduction to Python ProgrammingIntroduction to Python Programming
Introduction to Python Programming
 
Python Basics
Python BasicsPython Basics
Python Basics
 
Ruby For Java Programmers
Ruby For Java ProgrammersRuby For Java Programmers
Ruby For Java Programmers
 
2nd puc computer science chapter 8 function overloading
 2nd puc computer science chapter 8   function overloading 2nd puc computer science chapter 8   function overloading
2nd puc computer science chapter 8 function overloading
 
java vs C#
java vs C#java vs C#
java vs C#
 
PYTHON NOTES
PYTHON NOTESPYTHON NOTES
PYTHON NOTES
 
Domain Specific Languages In Scala Duse3
Domain Specific Languages In Scala Duse3Domain Specific Languages In Scala Duse3
Domain Specific Languages In Scala Duse3
 
Compiler Construction | Lecture 7 | Type Checking
Compiler Construction | Lecture 7 | Type CheckingCompiler Construction | Lecture 7 | Type Checking
Compiler Construction | Lecture 7 | Type Checking
 
Unix Tutorial
Unix TutorialUnix Tutorial
Unix Tutorial
 
Python basics
Python basicsPython basics
Python basics
 
Basic Concepts in Python
Basic Concepts in PythonBasic Concepts in Python
Basic Concepts in Python
 
Hack programming language
Hack programming languageHack programming language
Hack programming language
 
The Ring programming language version 1.5.4 book - Part 6 of 185
The Ring programming language version 1.5.4 book - Part 6 of 185The Ring programming language version 1.5.4 book - Part 6 of 185
The Ring programming language version 1.5.4 book - Part 6 of 185
 
Python Session - 4
Python Session - 4Python Session - 4
Python Session - 4
 

Viewers also liked

Pharo Hands-On: 02 syntax
Pharo Hands-On: 02 syntaxPharo Hands-On: 02 syntax
Pharo Hands-On: 02 syntaxPharo
 
The Pharo Programming Language
The Pharo Programming LanguageThe Pharo Programming Language
The Pharo Programming Languagebergel
 
Reflection in Pharo: Beyond Smalltak
Reflection in Pharo: Beyond SmalltakReflection in Pharo: Beyond Smalltak
Reflection in Pharo: Beyond SmalltakMarcus Denker
 
2008 Sccc Smalltalk
2008 Sccc Smalltalk2008 Sccc Smalltalk
2008 Sccc Smalltalkbergel
 
Squeak & Pharo @ NYC Smalltalk
Squeak & Pharo @ NYC SmalltalkSqueak & Pharo @ NYC Smalltalk
Squeak & Pharo @ NYC SmalltalkSeanDeNigris
 
Pharo tutorial at ECOOP 2013
Pharo tutorial at ECOOP 2013Pharo tutorial at ECOOP 2013
Pharo tutorial at ECOOP 2013Pharo
 
Pharo Roadmap
Pharo RoadmapPharo Roadmap
Pharo RoadmapESUG
 
You Can’t Do That With Smalltalk!
You Can’t Do That With Smalltalk!You Can’t Do That With Smalltalk!
You Can’t Do That With Smalltalk!ESUG
 
Pharo Hands-on: 05 object model
Pharo Hands-on: 05 object modelPharo Hands-on: 05 object model
Pharo Hands-on: 05 object modelPharo
 
Haskell vs. F# vs. Scala
Haskell vs. F# vs. ScalaHaskell vs. F# vs. Scala
Haskell vs. F# vs. Scalapt114
 

Viewers also liked (12)

Pharo Hands-On: 02 syntax
Pharo Hands-On: 02 syntaxPharo Hands-On: 02 syntax
Pharo Hands-On: 02 syntax
 
The Pharo Programming Language
The Pharo Programming LanguageThe Pharo Programming Language
The Pharo Programming Language
 
Reflection in Pharo: Beyond Smalltak
Reflection in Pharo: Beyond SmalltakReflection in Pharo: Beyond Smalltak
Reflection in Pharo: Beyond Smalltak
 
Pharo devnology20150401
Pharo devnology20150401Pharo devnology20150401
Pharo devnology20150401
 
2008 Sccc Smalltalk
2008 Sccc Smalltalk2008 Sccc Smalltalk
2008 Sccc Smalltalk
 
Squeak & Pharo @ NYC Smalltalk
Squeak & Pharo @ NYC SmalltalkSqueak & Pharo @ NYC Smalltalk
Squeak & Pharo @ NYC Smalltalk
 
Pharo tutorial at ECOOP 2013
Pharo tutorial at ECOOP 2013Pharo tutorial at ECOOP 2013
Pharo tutorial at ECOOP 2013
 
Pharo Roadmap
Pharo RoadmapPharo Roadmap
Pharo Roadmap
 
You Can’t Do That With Smalltalk!
You Can’t Do That With Smalltalk!You Can’t Do That With Smalltalk!
You Can’t Do That With Smalltalk!
 
Pharo Hands-on: 05 object model
Pharo Hands-on: 05 object modelPharo Hands-on: 05 object model
Pharo Hands-on: 05 object model
 
Haskell vs. F# vs. Scala
Haskell vs. F# vs. ScalaHaskell vs. F# vs. Scala
Haskell vs. F# vs. Scala
 
Stoop 432-singleton
Stoop 432-singletonStoop 432-singleton
Stoop 432-singleton
 

Similar to Pharo: Objects at your Fingertips

Pharo: Objects at your Fingertips
Pharo: Objects at your FingertipsPharo: Objects at your Fingertips
Pharo: Objects at your FingertipsPharo
 
Pharo: A Reflective System
Pharo: A Reflective SystemPharo: A Reflective System
Pharo: A Reflective SystemPharo
 
Pharo Status ESUG 2014
Pharo Status ESUG 2014Pharo Status ESUG 2014
Pharo Status ESUG 2014Pharo
 
Visual Studio .NET2010
Visual Studio .NET2010Visual Studio .NET2010
Visual Studio .NET2010Satish Verma
 
Inria Tech Talk - Programmation Pharo - Mercredi 26 septembre 2018
Inria Tech Talk - Programmation Pharo - Mercredi 26 septembre 2018Inria Tech Talk - Programmation Pharo - Mercredi 26 septembre 2018
Inria Tech Talk - Programmation Pharo - Mercredi 26 septembre 2018FrenchTechCentral
 
Step talk
Step talkStep talk
Step talkESUG
 
Pharo, an innovative and open-source Smalltalk
Pharo, an innovative and open-source SmalltalkPharo, an innovative and open-source Smalltalk
Pharo, an innovative and open-source SmalltalkSerge Stinckwich
 
Pharo3 at Fosdem
Pharo3 at FosdemPharo3 at Fosdem
Pharo3 at FosdemPharo
 
The why and how of moving to php 7
The why and how of moving to php 7The why and how of moving to php 7
The why and how of moving to php 7Wim Godden
 
2013 pharo is yours revisited. Santiago DCC University of Chile Presentation.
2013 pharo is yours revisited. Santiago DCC University of Chile Presentation.2013 pharo is yours revisited. Santiago DCC University of Chile Presentation.
2013 pharo is yours revisited. Santiago DCC University of Chile Presentation.Pharo
 
2013 lecture-01-introduction
2013 lecture-01-introduction2013 lecture-01-introduction
2013 lecture-01-introductionPharo
 
Pharo: Programming in an Immersive World (Stéphane Ducasse Technology Stream)
Pharo: Programming in an Immersive World (Stéphane Ducasse Technology Stream)Pharo: Programming in an Immersive World (Stéphane Ducasse Technology Stream)
Pharo: Programming in an Immersive World (Stéphane Ducasse Technology Stream)IT Arena
 
Flex and PHP For the Flash Folks
Flex and PHP For the Flash FolksFlex and PHP For the Flash Folks
Flex and PHP For the Flash Folks10n Software, LLC
 
Fosdem 13: Pharo 2.0 update
Fosdem 13: Pharo 2.0 updateFosdem 13: Pharo 2.0 update
Fosdem 13: Pharo 2.0 updateMarcus Denker
 
Talk: Pharo at JM2L 2009
Talk: Pharo at JM2L 2009Talk: Pharo at JM2L 2009
Talk: Pharo at JM2L 2009Marcus Denker
 
Advanced WCF Workshop
Advanced WCF WorkshopAdvanced WCF Workshop
Advanced WCF WorkshopIdo Flatow
 
Programming on Windows 8.1: The New Stream and Storage Paradigm (Raffaele Ria...
Programming on Windows 8.1: The New Stream and Storage Paradigm (Raffaele Ria...Programming on Windows 8.1: The New Stream and Storage Paradigm (Raffaele Ria...
Programming on Windows 8.1: The New Stream and Storage Paradigm (Raffaele Ria...ITCamp
 
Microsoft (Silverlight)
Microsoft (Silverlight)Microsoft (Silverlight)
Microsoft (Silverlight)Vinayak Hegde
 
Introduction to python
Introduction to pythonIntroduction to python
Introduction to pythonMohammed Rafi
 

Similar to Pharo: Objects at your Fingertips (20)

Pharo: Objects at your Fingertips
Pharo: Objects at your FingertipsPharo: Objects at your Fingertips
Pharo: Objects at your Fingertips
 
Pharo: A Reflective System
Pharo: A Reflective SystemPharo: A Reflective System
Pharo: A Reflective System
 
Pharo Status ESUG 2014
Pharo Status ESUG 2014Pharo Status ESUG 2014
Pharo Status ESUG 2014
 
Visual Studio .NET2010
Visual Studio .NET2010Visual Studio .NET2010
Visual Studio .NET2010
 
Inria Tech Talk - Programmation Pharo - Mercredi 26 septembre 2018
Inria Tech Talk - Programmation Pharo - Mercredi 26 septembre 2018Inria Tech Talk - Programmation Pharo - Mercredi 26 septembre 2018
Inria Tech Talk - Programmation Pharo - Mercredi 26 septembre 2018
 
Step talk
Step talkStep talk
Step talk
 
Pharo, an innovative and open-source Smalltalk
Pharo, an innovative and open-source SmalltalkPharo, an innovative and open-source Smalltalk
Pharo, an innovative and open-source Smalltalk
 
Pharo3 at Fosdem
Pharo3 at FosdemPharo3 at Fosdem
Pharo3 at Fosdem
 
The why and how of moving to php 7
The why and how of moving to php 7The why and how of moving to php 7
The why and how of moving to php 7
 
Pharo3 at Fosdem
Pharo3 at FosdemPharo3 at Fosdem
Pharo3 at Fosdem
 
2013 pharo is yours revisited. Santiago DCC University of Chile Presentation.
2013 pharo is yours revisited. Santiago DCC University of Chile Presentation.2013 pharo is yours revisited. Santiago DCC University of Chile Presentation.
2013 pharo is yours revisited. Santiago DCC University of Chile Presentation.
 
2013 lecture-01-introduction
2013 lecture-01-introduction2013 lecture-01-introduction
2013 lecture-01-introduction
 
Pharo: Programming in an Immersive World (Stéphane Ducasse Technology Stream)
Pharo: Programming in an Immersive World (Stéphane Ducasse Technology Stream)Pharo: Programming in an Immersive World (Stéphane Ducasse Technology Stream)
Pharo: Programming in an Immersive World (Stéphane Ducasse Technology Stream)
 
Flex and PHP For the Flash Folks
Flex and PHP For the Flash FolksFlex and PHP For the Flash Folks
Flex and PHP For the Flash Folks
 
Fosdem 13: Pharo 2.0 update
Fosdem 13: Pharo 2.0 updateFosdem 13: Pharo 2.0 update
Fosdem 13: Pharo 2.0 update
 
Talk: Pharo at JM2L 2009
Talk: Pharo at JM2L 2009Talk: Pharo at JM2L 2009
Talk: Pharo at JM2L 2009
 
Advanced WCF Workshop
Advanced WCF WorkshopAdvanced WCF Workshop
Advanced WCF Workshop
 
Programming on Windows 8.1: The New Stream and Storage Paradigm (Raffaele Ria...
Programming on Windows 8.1: The New Stream and Storage Paradigm (Raffaele Ria...Programming on Windows 8.1: The New Stream and Storage Paradigm (Raffaele Ria...
Programming on Windows 8.1: The New Stream and Storage Paradigm (Raffaele Ria...
 
Microsoft (Silverlight)
Microsoft (Silverlight)Microsoft (Silverlight)
Microsoft (Silverlight)
 
Introduction to python
Introduction to pythonIntroduction to python
Introduction to python
 

More from Marcus Denker

ConstantBlocks in Pharo11
ConstantBlocks in Pharo11ConstantBlocks in Pharo11
ConstantBlocks in Pharo11Marcus Denker
 
First Class Variables as AST Annotations
First Class Variables as AST AnnotationsFirst Class Variables as AST Annotations
First Class Variables as AST AnnotationsMarcus Denker
 
Supporting Pharo / Getting Pharo Support
Supporting Pharo / Getting Pharo SupportSupporting Pharo / Getting Pharo Support
Supporting Pharo / Getting Pharo SupportMarcus Denker
 
Lecture: "Advanced Reflection: MetaLinks"
Lecture: "Advanced Reflection: MetaLinks"Lecture: "Advanced Reflection: MetaLinks"
Lecture: "Advanced Reflection: MetaLinks"Marcus Denker
 
thisContext in the Debugger
thisContext in the DebuggerthisContext in the Debugger
thisContext in the DebuggerMarcus Denker
 
Lecture. Advanced Reflection: MetaLinks
Lecture. Advanced Reflection: MetaLinksLecture. Advanced Reflection: MetaLinks
Lecture. Advanced Reflection: MetaLinksMarcus Denker
 
Improving code completion for Pharo
Improving code completion for PharoImproving code completion for Pharo
Improving code completion for PharoMarcus Denker
 
VUB Brussels Lecture 2019: Advanced Reflection: MetaLinks
VUB Brussels Lecture 2019: Advanced Reflection: MetaLinksVUB Brussels Lecture 2019: Advanced Reflection: MetaLinks
VUB Brussels Lecture 2019: Advanced Reflection: MetaLinksMarcus Denker
 
Lecture: Advanced Reflection. MetaLinks
Lecture: Advanced Reflection. MetaLinksLecture: Advanced Reflection. MetaLinks
Lecture: Advanced Reflection. MetaLinksMarcus Denker
 
Open-Source: An Infinite Game
Open-Source: An Infinite GameOpen-Source: An Infinite Game
Open-Source: An Infinite GameMarcus Denker
 
PharoTechTalk: Contributing to Pharo
PharoTechTalk: Contributing to PharoPharoTechTalk: Contributing to Pharo
PharoTechTalk: Contributing to PharoMarcus Denker
 
Feedback Loops in Practice
Feedback Loops in PracticeFeedback Loops in Practice
Feedback Loops in PracticeMarcus Denker
 

More from Marcus Denker (20)

Soil And Pharo
Soil And PharoSoil And Pharo
Soil And Pharo
 
ConstantBlocks in Pharo11
ConstantBlocks in Pharo11ConstantBlocks in Pharo11
ConstantBlocks in Pharo11
 
Demo: Improved DoIt
Demo: Improved DoItDemo: Improved DoIt
Demo: Improved DoIt
 
First Class Variables as AST Annotations
First Class Variables as AST AnnotationsFirst Class Variables as AST Annotations
First Class Variables as AST Annotations
 
Supporting Pharo / Getting Pharo Support
Supporting Pharo / Getting Pharo SupportSupporting Pharo / Getting Pharo Support
Supporting Pharo / Getting Pharo Support
 
Lecture: "Advanced Reflection: MetaLinks"
Lecture: "Advanced Reflection: MetaLinks"Lecture: "Advanced Reflection: MetaLinks"
Lecture: "Advanced Reflection: MetaLinks"
 
thisContext in the Debugger
thisContext in the DebuggerthisContext in the Debugger
thisContext in the Debugger
 
Variables in Pharo
Variables in PharoVariables in Pharo
Variables in Pharo
 
Lecture. Advanced Reflection: MetaLinks
Lecture. Advanced Reflection: MetaLinksLecture. Advanced Reflection: MetaLinks
Lecture. Advanced Reflection: MetaLinks
 
Improving code completion for Pharo
Improving code completion for PharoImproving code completion for Pharo
Improving code completion for Pharo
 
VUB Brussels Lecture 2019: Advanced Reflection: MetaLinks
VUB Brussels Lecture 2019: Advanced Reflection: MetaLinksVUB Brussels Lecture 2019: Advanced Reflection: MetaLinks
VUB Brussels Lecture 2019: Advanced Reflection: MetaLinks
 
Slot Composition
Slot CompositionSlot Composition
Slot Composition
 
Lecture: Advanced Reflection. MetaLinks
Lecture: Advanced Reflection. MetaLinksLecture: Advanced Reflection. MetaLinks
Lecture: Advanced Reflection. MetaLinks
 
PHARO IOT
PHARO IOTPHARO IOT
PHARO IOT
 
Open-Source: An Infinite Game
Open-Source: An Infinite GameOpen-Source: An Infinite Game
Open-Source: An Infinite Game
 
Lecture: MetaLinks
Lecture: MetaLinksLecture: MetaLinks
Lecture: MetaLinks
 
PharoTechTalk: Contributing to Pharo
PharoTechTalk: Contributing to PharoPharoTechTalk: Contributing to Pharo
PharoTechTalk: Contributing to Pharo
 
Feedback Loops in Practice
Feedback Loops in PracticeFeedback Loops in Practice
Feedback Loops in Practice
 
Pharo6 - ESUG17
Pharo6 - ESUG17Pharo6 - ESUG17
Pharo6 - ESUG17
 
Pharo6
Pharo6Pharo6
Pharo6
 

Recently uploaded

Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):comworks
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLScyllaDB
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxhariprasad279825
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek SchlawackFwdays
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationSlibray Presentation
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...shyamraj55
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupFlorian Wilhelm
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 3652toLead Limited
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Patryk Bandurski
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubKalema Edgar
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Mark Simos
 
Commit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyCommit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyAlfredo García Lavilla
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebUiPathCommunity
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsRizwan Syed
 

Recently uploaded (20)

Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQL
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptx
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck Presentation
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project Setup
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding Club
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
 
Commit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyCommit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easy
 
Hot Sexy call girls in Panjabi Bagh 🔝 9953056974 🔝 Delhi escort Service
Hot Sexy call girls in Panjabi Bagh 🔝 9953056974 🔝 Delhi escort ServiceHot Sexy call girls in Panjabi Bagh 🔝 9953056974 🔝 Delhi escort Service
Hot Sexy call girls in Panjabi Bagh 🔝 9953056974 🔝 Delhi escort Service
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio Web
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL Certs
 

Pharo: Objects at your Fingertips

  • 1. Pharo: Object at your Fingertips Marcus Denker http://www.pharo-project.org
  • 2. What is it? Language + Environment Simple Language (Smalltalk) Object-Oriented, Dynamic, Reflective Explore + Change running systems ! The Ultimate Programming Environment!
  • 3. Pharo MIT license Mac, Linux, Android, iOS, Windows Great community Improving steadily Many excellent libraries
  • 4. Started 2008 Pharo 1.0 released October 2009 2.0 is the current stable Pharo3: Early 2014 Plan: 1 Release per year
  • 6. Pharo started with Smalltalk-80 (Squeak) Language still very much Smalltalk But the goal is to develop it further Example: Reflective Capabilities
  • 7. Less is better No constructors No types declaration No interfaces No packages/private/protected No parametrized types Yet really powerful
  • 9. Objects are instances of Classes ! (10@200)
  • 10. Objects are instances of Classes ! (10@200) class
  • 11. Objects are instances of Classes ! (10@200) class Point
  • 13. Classes are objects too ! Point selectors !
  • 14. Classes are objects too ! Point selectors ! > an IdentitySet(#eightNeighbors #+ #isZero #sortsBefore: #degrees #printOn: #sideOf: #fourNeighbors #hash #roundUpTo: #min: #min:max: #max #adaptToCollection:andSend: #quadrantOf: #crossProduct: #= #nearestPointOnLineFrom:to: #bitShiftPoint: #* #guarded #insideTriangle:with:with: #grid: #truncateTo: #y #setR:degrees: #normal #directionToLineFrom:to: #truncated #nearestPointAlongLineFrom:to: #theta #scaleTo: #encodePostscriptOn: #> #asPoint #extent: #r #roundTo: #max: #interpolateTo:at: #triangleArea:with: #angleWith: #dotProduct: #isSelfEvaluating #'<=' #to:intersects:to: #'//' #isInsideCircle:with:with: #< #scaleFrom:to: #corner: #to:sideOf: #x #'>=' #roundDownTo: #onLineFrom:to:within: #transposed #ceiling #angle #basicType #translateBy: #asFloatPoint #'' #adaptToNumber:andSend: #abs #negated #octantOf: #asIntegerPoint #flipBy:centerAt: #scaleBy: #floor #onLineFrom:to: #isPoint #reflectedAbout: #/ #dist: #asNonFractionalPoint #bearingToPoint: #reciprocal #rotateBy:centerAt: #rotateBy:about: #rounded #setX:setY: #squaredDistanceTo: #normalized #veryDeepCopyWith: #- #storeOn: #rect: #deepCopy #isIntegerPoint #min #adhereTo: #adaptToString:andSend:)
  • 18. 2 instance variables Single Inheritance Object subclass: #Point! ! instanceVariableNames: 'x y'! ! classVariableNames: ''! ! poolDictionaries: ''! ! category: 'Kernel-BasicObjects' subclass of Object
  • 19. 3 kinds of messages Unary messages 5 factorial! Transcript cr Binary messages 3 + 4 Keywords messages 3 raisedTo: 10 modulo: 5! ! Transcript show: 'hello world'
  • 20. Blocks • Anonymous method • Passed as method argument or stored • Functions fct(x)= x*x+3, fct(2). ! ! fct :=[:x| x * x + 3]. fct value: 2
  • 21. Control structures Every control structure is realized by message sends 4 timesRepeat: [Beeper beep] max: aNumber! ! ^ self < aNumber ! ! ! ifTrue: [aNumber] ! ! ! ifFalse: [self]
  • 22. A typical method in Point Method name Argument Comment <= aPoint ! ! "Answer whether the receiver is neither! ! below nor to the right of aPoint."! ! ! ^ x <= aPoint x and: [y <= aPoint y] Return Block Binary message Keyword message Instance variable (2@3) <= (5@6) true
  • 23. Complete Syntax on a PostCard exampleWithNumber: x “A method that has unary, binary, and key word messages, declares arguments and temporaries (but not block temporaries), accesses a global variable (but not and instance variable), uses literals (array, character, symbol, string, integer, float), uses the pseudo variable true false, nil, self, and super, and has sequence, assignment, return and cascade. It has both zero argument and one argument blocks.” |y| true & false not & (nil isNil) ifFalse: [self halt]. y := self size + super size. #($a #a ‘a’ 1 1.0) do: [:each | Transcript show: (each class name); show: (each printString); show: ‘ ‘]. ^x<y
  • 25. Language + Environment are closely linked
  • 28. The tools manipulate these Objects
  • 31. Demo: Changing a class at runtime
  • 34. There is so much more…
  • 37. Continuous API Testing keep your services under control 24/7 www.2denker.de Norbert Hartl norbert@2denker.de
  • 38. eMCee is a montoring service for backend interfaces - Web application to define backend interfaces - Monitors reliability of interface periodically - Sends warning if status of interface changes - Provides overview graphs about reliability - Snapshots requests for debugging purposes mail@2denker.de
  • 39.
  • 40. • Entry Level Track & Trace Product • Complements T3 Full Product • One Page Javascript HTML5 / Ajax Client • REST Back End in Pharo Smalltalk • Gateways to multiple data providers
  • 41. Pharo Consortium Managed by INRIA Who: companies, institutions, user groups Privileged access to the core development team Influence priorities of the next development http://consortium.pharo.org
  • 42.
  • 44. More Reflection Instance Variables as Objects —> Slots ! Proxy model in the base language ! Structuring reflective API (—> Mirrors)
  • 45. Beyond Text AST Everywhere Used in Tools for Navigation ! Do we need to store text? ! Use for Behavioral Reflection
  • 46. System - as - Objects Put “virtualization” in the language We already use “Images” Make the Image a first class concept in the language
  • 47. Open Pharo Sprints May 2008 Bern July 2009 Bern October 2009 Lille November 2009 Buenos Ares March 2010 Bern May 2010 Buenos Ares June 2010 Bern June 2010 Bruxelles July 2010 London September 2010 Barcelona September 2010 Lille January 2011 Lille July 2011 Lille October 2011 Bruxelles February 2012 Bern April 2012 Lille September 2012 Ghent October 2013 Lille November 2013 Buenos Aires