SlideShare a Scribd company logo
1 of 28
An Introduction to IBM WebSphere sMash for PHP Programmers       Jonathan Lawrence & Robin Fernandes Software Developers, WebSphere Development, IBM projectzero.org
Agenda ,[object Object],[object Object],[object Object],[object Object],[object Object]
What is WebSphere sMash? ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
What is WebSphere sMash? ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
WebSphere sMash for the application long tail Usage Number of Applications Java Enterprise Edition For business department and mid-market customers looking for rapidly developed agile applications, short implementation cycles and ways to easily reuse existing investments. Time to value is more important than enduring value  Strategic, long-lived applications Dynamic Scripting Application Server
Accelerate business and IT alignment  Speed Simplicity Agility Dynamic scripting languages Templates & pre-built services No-charge, robust browser & Eclipse based tooling Simply create rich Web 2.0 interfaces  Application “is” the server Clean, short-lived runtime
Speed WebSphere sMash is easy for  developers  to access, learn, and use ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Simplicity WebSphere sMash makes it simple to “mash-up” services and feeds ,[object Object],[object Object],[object Object]
Agility WebSphere sMash focuses on deploying applications, not servers ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Dynamic Scripting ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Application-centric Runtime ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Modular Architecture ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Available Modules ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Agenda ,[object Object],[object Object],[object Object],[object Object],[object Object]
Agenda ,[object Object],[object Object],[object Object],[object Object],[object Object]
WebSphere sMash PHP Support ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
PHP in WebSphere sMash Java Virtual Machine ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],P8 Runtime Interpreter/Compiler PHP runtime Java  Extensions C Extensions XAPI-J XAPI-C PDT2 Java- Bridge JAR JAR JAR JAR Groovy runtime WebSphere sMash  HTTP server Zero Programming Model DBGp Debug
Benefits of PHP in sMash. ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
PHP – Java Bridge – Basic use <?php java_import( &quot;java.util.Date&quot; ); $date  =  new  Date( 81 ,  9 ,  12 ); echo  $date  . PHP_EOL; // prints: Sun Oct 11 00:00:00 BST 1981 java_import( &quot;java.util.HashMap&quot; ); $map  =  new  HashMap(); $map ->put( &quot;stuff&quot; ,  array ( 1 , 2 , 3 , 4 , 5 )); var_dump( $map ->get( &quot;stuff&quot; )); // prints: array(5) { ... Access Java methods and fields from PHP  <?php java_import( &quot;java.lang.System&quot; ); echo  System::currentTimeMillis(); try  { System::getProperty( FALSE ); }  catch  (JavaException  $exception ) { echo  $exception ->getMessage(); } Static methods and fields are accessible too Types are automatically converted at boundary of PHP runtime Java exceptions can be caught and handled in PHP
Java Bridge – Extending Java in PHP <?php java_import( &quot;java.io.File&quot; ); class  SubFile  extends  File { function  SuperFile( $path ) { parent ::__construct( $path ); } function  isThisCool() { return TRUE ;  // Way cool } } $file  =  new  Sub File( &quot;/&quot; ); var_dump( $file ->isDirectory()); var_dump( $file ->isThisCool()); PHP classes can extend Java classes
PHP- Java Bridge – Iterators and Overloads Signatures provide explicit control for overloaded methods <?php java_import( &quot;java.util.ArrayList&quot; ); $list  =  new  ArrayList(); $list ->add( &quot;Hello World!&quot; ); $list ->add( FALSE ); $list ->add( 1234567890 ); foreach  ( $list  as  $key  =>  $value ) { echo  &quot; $key   $value &quot; ; } Java iteration is bridged into PHP <?php java_import( &quot;java.lang.String&quot; ); $signature  =  new  JavaSignature(JAVA_INT); var_dump(String::valueOf( $signature ,  1234567890 ));
Java Bridge – More features… <?php java_import( &quot;java.math.BigDecimal&quot; , NULL,  FALSE ,  &quot;My_BigDecimal&quot; ); $value  =  new  My_BigDecimal( &quot;1.18E+10&quot; ); echo  $value ; Import a Java class under a different name to avoid clashes <?php java_import( &quot;java.lang.Comparable&quot; ); echo (ReflectionClass::export( &quot;Comparable&quot; )); PHP reflection works on Java classes <?php java_import( &quot;java.io.File&quot; ); $file  =  new  File( &quot;/home/robinf&quot; ); var_dump( $file ->Parent); //equivalent to: var_dump( $file ->getParent()); Java bean support provides field access for get/set method calls
Agenda ,[object Object],[object Object],[object Object],[object Object],[object Object]
Agenda ,[object Object],[object Object],[object Object],[object Object],[object Object]
Some PHP Applications that run on sMash Forums CRM wiki Desktop Virtualisation Ajax Debugging Content Management Blogging FirePHP
Features we didn’t cover ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Project Zero –  projectzero.org ,[object Object],[object Object],[object Object],[object Object],[object Object],Visit   http://projectzero.org Project Zero is the development and incubation community around WebSphere sMash  Come to our stand for more demos!
Legal Notices ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]

More Related Content

What's hot

108 advancedjava
108 advancedjava108 advancedjava
108 advancedjava
Anil Kumar
 
Php Asp Net Interoperability Rc Jao
Php Asp Net Interoperability Rc JaoPhp Asp Net Interoperability Rc Jao
Php Asp Net Interoperability Rc Jao
jedt
 
Rest and Sling Resolution
Rest and Sling ResolutionRest and Sling Resolution
Rest and Sling Resolution
DEEPAK KHETAWAT
 
Laravel Restful API and AngularJS
Laravel Restful API and AngularJSLaravel Restful API and AngularJS
Laravel Restful API and AngularJS
Blake Newman
 
Laurens Van Den Oever Xopus Presentation
Laurens Van Den Oever Xopus PresentationLaurens Van Den Oever Xopus Presentation
Laurens Van Den Oever Xopus Presentation
Ajax Experience 2009
 

What's hot (20)

Getting started with laravel
Getting started with laravelGetting started with laravel
Getting started with laravel
 
108 advancedjava
108 advancedjava108 advancedjava
108 advancedjava
 
Laravel 5 Annotations: RESTful API routing
Laravel 5 Annotations: RESTful API routingLaravel 5 Annotations: RESTful API routing
Laravel 5 Annotations: RESTful API routing
 
What Is Hobo ?
What Is Hobo ?What Is Hobo ?
What Is Hobo ?
 
Laravel ppt
Laravel pptLaravel ppt
Laravel ppt
 
Php Asp Net Interoperability Rc Jao
Php Asp Net Interoperability Rc JaoPhp Asp Net Interoperability Rc Jao
Php Asp Net Interoperability Rc Jao
 
CakePHP
CakePHPCakePHP
CakePHP
 
sMash at May NYPHP UG
sMash at May NYPHP UGsMash at May NYPHP UG
sMash at May NYPHP UG
 
Laravel development (Laravel History, Environment Setup & Laravel Installatio...
Laravel development (Laravel History, Environment Setup & Laravel Installatio...Laravel development (Laravel History, Environment Setup & Laravel Installatio...
Laravel development (Laravel History, Environment Setup & Laravel Installatio...
 
Securing Your Web Server
Securing Your Web ServerSecuring Your Web Server
Securing Your Web Server
 
Laravel Tutorial PPT
Laravel Tutorial PPTLaravel Tutorial PPT
Laravel Tutorial PPT
 
Rest and Sling Resolution
Rest and Sling ResolutionRest and Sling Resolution
Rest and Sling Resolution
 
Php&amp;yii2
Php&amp;yii2Php&amp;yii2
Php&amp;yii2
 
Advanced PHP Web Development Tools in 2015
Advanced PHP Web Development Tools in 2015Advanced PHP Web Development Tools in 2015
Advanced PHP Web Development Tools in 2015
 
Tech talk webtech
Tech talk webtechTech talk webtech
Tech talk webtech
 
Laravel Eloquent ORM
Laravel Eloquent ORMLaravel Eloquent ORM
Laravel Eloquent ORM
 
AMF Testing Made Easy! DeepSec 2012
AMF Testing Made Easy! DeepSec 2012AMF Testing Made Easy! DeepSec 2012
AMF Testing Made Easy! DeepSec 2012
 
Laravel Restful API and AngularJS
Laravel Restful API and AngularJSLaravel Restful API and AngularJS
Laravel Restful API and AngularJS
 
Laurens Van Den Oever Xopus Presentation
Laurens Van Den Oever Xopus PresentationLaurens Van Den Oever Xopus Presentation
Laurens Van Den Oever Xopus Presentation
 
AEM - Binary less replication
AEM - Binary less replicationAEM - Binary less replication
AEM - Binary less replication
 

Similar to An Introduction to Websphere sMash for PHP Programmers

Web Development Environments: Choose the best or go with the rest
Web Development Environments:  Choose the best or go with the restWeb Development Environments:  Choose the best or go with the rest
Web Development Environments: Choose the best or go with the rest
george.james
 
eXo Platform SEA - Play Framework Introduction
eXo Platform SEA - Play Framework IntroductioneXo Platform SEA - Play Framework Introduction
eXo Platform SEA - Play Framework Introduction
vstorm83
 
Java EE 7 (Hamed Hatami)
Java EE 7 (Hamed Hatami)Java EE 7 (Hamed Hatami)
Java EE 7 (Hamed Hatami)
Hamed Hatami
 

Similar to An Introduction to Websphere sMash for PHP Programmers (20)

Lamp Zend Security
Lamp Zend SecurityLamp Zend Security
Lamp Zend Security
 
Introduction to php
Introduction to phpIntroduction to php
Introduction to php
 
PHP and MySQL
PHP and MySQLPHP and MySQL
PHP and MySQL
 
Web Development Environments: Choose the best or go with the rest
Web Development Environments:  Choose the best or go with the restWeb Development Environments:  Choose the best or go with the rest
Web Development Environments: Choose the best or go with the rest
 
My Saminar On Php
My Saminar On PhpMy Saminar On Php
My Saminar On Php
 
eXo Platform SEA - Play Framework Introduction
eXo Platform SEA - Play Framework IntroductioneXo Platform SEA - Play Framework Introduction
eXo Platform SEA - Play Framework Introduction
 
Mixing Java and PHP with Sugar and WebSphere
Mixing Java and PHP with Sugar and WebSphereMixing Java and PHP with Sugar and WebSphere
Mixing Java and PHP with Sugar and WebSphere
 
Mashups
MashupsMashups
Mashups
 
Simplify your professional web development with symfony
Simplify your professional web development with symfonySimplify your professional web development with symfony
Simplify your professional web development with symfony
 
A Microsoft primer for PHP devs
A Microsoft primer for PHP devsA Microsoft primer for PHP devs
A Microsoft primer for PHP devs
 
Survey of restful web services frameworks
Survey of restful web services frameworksSurvey of restful web services frameworks
Survey of restful web services frameworks
 
Web forms and server side scripting
Web forms and server side scriptingWeb forms and server side scripting
Web forms and server side scripting
 
Everyone loves PHP
Everyone loves PHPEveryone loves PHP
Everyone loves PHP
 
Developing Java Web Applications
Developing Java Web ApplicationsDeveloping Java Web Applications
Developing Java Web Applications
 
Java EE 7 (Hamed Hatami)
Java EE 7 (Hamed Hatami)Java EE 7 (Hamed Hatami)
Java EE 7 (Hamed Hatami)
 
PHP ITCS 323
PHP ITCS 323PHP ITCS 323
PHP ITCS 323
 
php
phpphp
php
 
Lamp
LampLamp
Lamp
 
Learning ASP.NET 5 and MVC 6
Learning ASP.NET 5 and MVC 6Learning ASP.NET 5 and MVC 6
Learning ASP.NET 5 and MVC 6
 
Unleash your Symfony projects with eZ Platform
Unleash your Symfony projects with eZ PlatformUnleash your Symfony projects with eZ Platform
Unleash your Symfony projects with eZ Platform
 

Recently uploaded

IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
Enterprise Knowledge
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
Earley Information Science
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
vu2urc
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
Joaquim Jorge
 

Recently uploaded (20)

Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 

An Introduction to Websphere sMash for PHP Programmers

  • 1. An Introduction to IBM WebSphere sMash for PHP Programmers Jonathan Lawrence & Robin Fernandes Software Developers, WebSphere Development, IBM projectzero.org
  • 2.
  • 3.
  • 4.
  • 5. WebSphere sMash for the application long tail Usage Number of Applications Java Enterprise Edition For business department and mid-market customers looking for rapidly developed agile applications, short implementation cycles and ways to easily reuse existing investments. Time to value is more important than enduring value Strategic, long-lived applications Dynamic Scripting Application Server
  • 6. Accelerate business and IT alignment Speed Simplicity Agility Dynamic scripting languages Templates & pre-built services No-charge, robust browser & Eclipse based tooling Simply create rich Web 2.0 interfaces Application “is” the server Clean, short-lived runtime
  • 7.
  • 8.
  • 9.
  • 10.
  • 11.
  • 12.
  • 13.
  • 14.
  • 15.
  • 16.
  • 17.
  • 18.
  • 19. PHP – Java Bridge – Basic use <?php java_import( &quot;java.util.Date&quot; ); $date = new Date( 81 , 9 , 12 ); echo $date . PHP_EOL; // prints: Sun Oct 11 00:00:00 BST 1981 java_import( &quot;java.util.HashMap&quot; ); $map = new HashMap(); $map ->put( &quot;stuff&quot; , array ( 1 , 2 , 3 , 4 , 5 )); var_dump( $map ->get( &quot;stuff&quot; )); // prints: array(5) { ... Access Java methods and fields from PHP <?php java_import( &quot;java.lang.System&quot; ); echo System::currentTimeMillis(); try { System::getProperty( FALSE ); } catch (JavaException $exception ) { echo $exception ->getMessage(); } Static methods and fields are accessible too Types are automatically converted at boundary of PHP runtime Java exceptions can be caught and handled in PHP
  • 20. Java Bridge – Extending Java in PHP <?php java_import( &quot;java.io.File&quot; ); class SubFile extends File { function SuperFile( $path ) { parent ::__construct( $path ); } function isThisCool() { return TRUE ; // Way cool } } $file = new Sub File( &quot;/&quot; ); var_dump( $file ->isDirectory()); var_dump( $file ->isThisCool()); PHP classes can extend Java classes
  • 21. PHP- Java Bridge – Iterators and Overloads Signatures provide explicit control for overloaded methods <?php java_import( &quot;java.util.ArrayList&quot; ); $list = new ArrayList(); $list ->add( &quot;Hello World!&quot; ); $list ->add( FALSE ); $list ->add( 1234567890 ); foreach ( $list as $key => $value ) { echo &quot; $key $value &quot; ; } Java iteration is bridged into PHP <?php java_import( &quot;java.lang.String&quot; ); $signature = new JavaSignature(JAVA_INT); var_dump(String::valueOf( $signature , 1234567890 ));
  • 22. Java Bridge – More features… <?php java_import( &quot;java.math.BigDecimal&quot; , NULL, FALSE , &quot;My_BigDecimal&quot; ); $value = new My_BigDecimal( &quot;1.18E+10&quot; ); echo $value ; Import a Java class under a different name to avoid clashes <?php java_import( &quot;java.lang.Comparable&quot; ); echo (ReflectionClass::export( &quot;Comparable&quot; )); PHP reflection works on Java classes <?php java_import( &quot;java.io.File&quot; ); $file = new File( &quot;/home/robinf&quot; ); var_dump( $file ->Parent); //equivalent to: var_dump( $file ->getParent()); Java bean support provides field access for get/set method calls
  • 23.
  • 24.
  • 25. Some PHP Applications that run on sMash Forums CRM wiki Desktop Virtualisation Ajax Debugging Content Management Blogging FirePHP
  • 26.
  • 27.
  • 28.