Upload
vuongcong
View
219
Download
0
Embed Size (px)
Citation preview
Hans-PetterHalvorsen,M.Sc.
ProgrammingLanguages
&Frameworks
O.W
idder.(2013).g
eek&
poke.A
vailable:http
://geek-and-poke.com
RequirementsAnalysis
Design
Implementation
Testing
Maintenance
Planning
TheSoftwareDevelopment
Lifecycle
Implementation
C/C++
C#
Python
VisualBasic
Java
Objective-C
PHP
Ruby
Perl
MATLAB LabVIEWSwift
http://redmonk.com/sogrady/2015/01/14/language-rankings-1-15/
PopularProgrammingLanguages
1JavaScript2Java3PHP4Python5C#5C++5Ruby8CSS9C10Objective-C
11Perl11Shell13R14Scala15Haskell16Matlab17Go17VisualBasic19Clojure19Groovy
http://redmonk.com/sogrady/2015/01/14/language-rankings-1-15/
Top20
OOP• OOP– ObjectOrientedProgramming• Object-orientedprogramming(OOP)isaprogramminglanguagemodelorganizedaround"objects"ratherthan"actions"anddataratherthanlogic.
• ThefirststepinOOPistoidentifyalltheobjectsyouwanttomanipulateandhowtheyrelatetoeachother,anexerciseoftenknownasdatamodeling(UML,ClassDiagrams)
• Onceyou'veidentifiedanobject,yougeneralizeitasaClass
• Arealinstanceofaclassiscalledan“object”oran“instanceofaclass”.
OOP• ImportantfeatureswithOOPare:– ClassesandObjects– Inheritance– Polymorphism– Encapsulation
• Java,Python,C++,VisualBasic.NETandC#arepopularOOPlanguagestoday.
• Simulawasthefirstobject-orientedprogramminglanguage.– Simulawasdevelopedinthe1960sbyKristenNygaardfromNorway(UniversityofOslo).
– SinceSimula-typeobjectsarereimplementedinC++,JavaandC#theinfluenceofSimulaisoftenunderstated.ThecreatorofC++(1979),BjarneStroustrup(fromDenmark),hasacknowledgedthatSimulawasthegreatestinfluenceonhimtodevelopC++.
ProgrammingLanguages&Frameworks
ProgrammingLanguages• C,C++• Java• C#• Objective-C• Swift• VisualBasic,VB.NET• Perl• Python• PHP• JavaScript• …
• MATLAB• LabVIEW• …
IntegratedDevelopmentEnvironment(IDE)
• ProgrammmingLanguagesvs.IDE• OneIDEcanhandlemultipleLanguages
• C#• Java• Objective-C/Swift• LabVIEW
• VisualStudio• Eclipse• Xcode• LabVIEW
http://www.youtube.com/watch?v=8Px-GHPxB4I
.NETvs.Java
Java
http://www.youtube.com/watch?feature=endscreen&NR=1&v=HXvm76e2X1Q
Hans-PetterHalvorsen,M.Sc.
ProgrammingLanguages
IDE
VB.NET
C#C
F#
C++
JavaScript
J#
TheVisualStudioIDEisactuallywritteniC++/C#
C• Cisageneral-purposecomputerprogramminglanguagedevelopedbetween1969and1973byDennisRitchieattheBellTelephoneLaboratoriesforusewiththeUnixoperatingsystem.
• CisoneofthemostpopularprogramminglanguagesofalltimeandthereareveryfewcomputerarchitecturesforwhichaCcompilerdoesnotexist.
• Chasgreatlyinfluencedmanyotherpopularprogramminglanguages,mostnotablyC++,whichbeganasanextensiontoC.
• Cisaprocedurallanguage,i.e.noobject-orientedprogramming.Cisacompiledlanguage.
C++• C++isacompiled,general-purposeobject-orientedprogramminglanguage.Itisregardedasanintermediate-levellanguage,asitcomprisesacombinationofbothhigh-levelandlow-levellanguagefeatures.
• ItwasdevelopedbyBjarneStroustrupin1979asanextensiontoC.
• C++isoneofthemostpopularprogramminglanguagesanditsapplicationdomainsincludesystemssoftware(suchasMicrosoftWindows),applicationsoftware,devicedrivers,embeddedsoftware,high-performanceserverandclientapplications,andentertainmentsoftwaresuchasvideogames.
• SeveralgroupsprovidebothfreeandproprietaryC++compilersoftware.
C++
http://www.digi.no/932591/c-oppfinneren-tildelt-norsk-it-pris
C#
• C#ispronounced“seesharp”.• C#isanobject-orientedprogramminglanguageandpartofthe.NETfamilyfrom
Microsoft.• ThemostrecentversionisC#4.5.1anditispartofVisualStudio2013.• C#isintendedtobeasimple,modern,general-purpose,object-oriented
programminglanguage.ItsdevelopmentteamisledbyAndersHejlsberg.• C#isverysimilartoC++andJava.C#isdevelopedbyMicrosoftandworksonlyon
theWindowsplatform.• C#isbasedonthe.NETFramework(pronounced“dotnet”).• .NETisasoftwareframeworkthatrunsprimarilyonMicrosoftWindows.The
.NETFramework1.0andC#1.0wasreleasedin2002aspartofVisualStudio.NET2002.
• VisualStudioistheIntegratedDevelopmentEnvironment(IDE)youusewhenprogramminginC#andthe.NETplatform.
Objective-C• Objective-Cisageneral-purpose,high-level,object-orientedprogramminglanguagethatisbasedontheCprogramminglanguage.
• ItisthemainprogramminglanguageusedbyApplefortheOSXandiOSandtheirrespectiveAPIs,CocoaandCocoaTouch.ApplehavereleasedanewProgramminglanguagecalledSwiftthatisthenewrecommendedlanguageforiOS/OSXDevelopment
• Originallydevelopedintheearly1980s,itwasselectedasthemainlanguageusedbyNeXTforitsNeXTSTEPoperatingsystem,fromwhichOSXandiOSarederived.
Swift
Java• Javaiscurrentlyoneofthemostpopular
programminglanguagesinuse,andiswidelyusedfromapplicationsoftwaretowebapplications.
• JavaapplicationsaretypicallycompiledanditrunsonanyJavaVirtualMachine(JVM)regardlessofthecomputerarchitecture.
• Javaisageneral-purposeobject-oriented.Itisintendedtoletapplicationdevelopers“writeonce,runanywhere”.
• AcommonIDEforprogrammingwithJavaistheEclipseIDE.
• JavaandEclipseareusedtocreateAndroidApps.
PHP• PHPisaserver-sidescriptinglanguagedesignedforwebdevelopmentbutalsousedasageneral-purposeprogramminglanguage.
• PHPcodeisembeddedintotheHTMLsourcedocumentandinterpretedbyawebserverwhichgeneratesthewebpagedocument.
• PHPisnowinstalledonmorethan244millionwebsitesand2.1millionwebservers,e.g.,Facebook.com
• PHPcanbedeployedonmostwebserversandasastandaloneinterpreter,onalmosteveryoperatingsystemandplatformfreeofcharge.
http://www.digi.no/for_utviklere/2015/06/13/feiret-20-ar-med-php-basert-webutvikling
Hans-PetterHalvorsen,M.Sc.
Frameworks
Softwareframeworksincludesupportprograms,compilers,codelibraries,toolsets,andapplicationprogramminginterfaces(APIs)
Programming/SoftwareFramework
ProgrammingLanguage
APIs
Libraries
Tools
Framework• FrameworksmakesiteasiertocreateSoftware
• YoucancreateyousoftwareusingexistingFrameworks
• Ifyouarecreatinglargesoftwaresystems,youshouldinadditioncreateyourownFrameworks(codereuse,moremodular,etc.)
Programming/SoftwareFramework
• .NETFramework• ASP.NET (partof.NET)– usedforWebDevelopment
• ASP.NETAJAX• RubyonRails(WebApplicationFrameworkfortheRubyProgrammingLanguage)
• CocoaFramework(MacOSX,iOS)• ...• ...hundreds
.NETFramework
• AProgrammingFrameworkfromMicrosoft
• C#,VB.NET,VisualStudio• CLR(CommonLanguageRuntime)
• Released2002
.NETFramework• The.NETFramework(pronounced“dotnet”)isasoftware
frameworkthatrunsprimarilyonMicrosoftWindows.• Itincludesalargelibraryandsupportsseveralprogramming
languageswhichallowlanguageinteroperability(eachlanguagecanusecodewritteninotherlanguages).
• The.NETlibraryisavailabletoalltheprogramminglanguagesthat.NETsupports.
• Programswrittenforthe.NETFrameworkexecuteinasoftwareenvironment,knownastheCommonLanguageRuntime(CLR),anapplicationvirtualmachinethatprovidesimportantservicessuchassecurity,memorymanagement,andexceptionhandling.
• TheclasslibraryandtheCLRtogetherconstitutethe.NETFramework.
• Thelatestversionof.NETFrameworkis.NETFramework4.5.1(includedwithVisualStudio2015)
.NETFramew
ork
Wikipedia.(2013)..NETFramework.Available:http://en.wikipedia.org/wiki/.NET_Framework
ASP.NET• ASP.NETisaserver-sideWebapplicationframeworkdesignedforWebdevelopmenttoproducedynamicWebpages.
• ItwasdevelopedbyMicrosofttoallowprogrammerstobuilddynamicwebsites,webapplicationsandwebservices.
• ItwasfirstreleasedinJanuary2002withversion1.0ofthe.NETFramework,andisthesuccessortoMicrosoft'sActiveServerPages(ASP)technology.
• ASP.NETisbuiltontheCommonLanguageRuntime(CLR),allowingprogrammerstowriteASP.NETcodeusinganysupported.NETlanguage.
Wikipedia. (2013).ASP.NET.Available:http://en.wikipedia.org/wiki/ASP.NET
WebServer
ASP.NET
C#/VB.NET
.NETFramework
WebBrowser
HTML JavaScript
Server-side
Client
ASP.NET
CSS
Theserver-sideASP.NETpagesareconvertedontheservertoHTMLpagesbeforeitissenttotheclient
ASP.NETisusedtocreatedynamicwebpages
WebSites
ASP.NET
C#/VB.NET
.NETFramework
ASP.NETWebPages
ASP.NETWebForms
ASP.NETMVC
ASP.NET– DifferentwaysofcreatingWebSiteswithASP.NET
http://www.asp.net
Youcanuse(atleast)3differentapproacheswhencreatingWebSiteswithASP.NET
Exercise– Programming
• ListtheProgramminglangaugesandframeworksyouhavebeenusing
• Whathaveyouusedthemfor?
Summary
33
References• Wikipedia.(2013)..NETFramework.Available:
http://en.wikipedia.org/wiki/.NET_Framework• Wikipedia.(2013).ASP.NET.Available:
http://en.wikipedia.org/wiki/ASP.NET• I.Sommerville,SoftwareEngineering:Pearson,2010.• S.Adams.Dilbert.Available:http://dilbert.com• O.Widder.(2013).geek&poke.Available:http://geek-and-
poke.com• B.Lund.(2013).Lunch.Available:http://www.lunchstriper.no,
http://www.dagbladet.no/tegneserie/lunch/
Hans-PetterHalvorsen,M.Sc.
UniversityCollegeofSoutheastNorwaywww.usn.no
E-mail:[email protected]:http://home.hit.no/~hansha/