Some third-party libraries exist to assist in integrating Twitter into an Android application (from

Size: px
Start display at page:

Download "Some third-party libraries exist to assist in integrating Twitter into an Android application (from"

Transcription

1 10 Chapter 8 Networkig Social Networkig Twitter is a social etworkig ad microbloggig service that eables its users to sed ad read messages kow as tweets.twitter is described as SMS of the Iteret, ad ideed, each tweet caot exceed 140 characters.twitter users ca follow other people s tweets or be followed by others. Recipe: Itegratig with Twitter Some third-party libraries exist to assist i itegratig Twitter ito a Adroid applicatio (from Twitter4J by Yusuke Yamamoto A ope-sourced, maveized, ad Google App Egie-safe Java library for the Twitter API, released uder the BSD licese java-twitter by DeWitt Clito Pure Java iterface for the Twitter API jtwitter by Daiel Witerstei Ope-source pure Java iterface to Twitter Twitter Cliet by Gist, Ic. Java cliet to coect to the streamig API For this recipe, the Twitter4J library by Yusuke Yamamoto is used, which has documetatio at recipe eables users to log i to Twitter ad make a tweet.at the same time, it retrieves ay updated tweets ad displays them to the scree. There are two screes to specify: the logi scree ad update status scree (see Figure 8.2).Also o the update status scree uder the EditText box, the latest status from the user accout is displayed.the two activities (oe for each scree) ad Iteret permissios eed to be declared i the AdroidMaifest XML file, as show i Listig 8.7. Figure 8.2 The logi Dowload (left) ad tweets from (right) from the Twitter recipe.

2 Social Networkig 211 Listig 8.7 AdroidMaifest.xml <?xml versio="1.0" ecodig="utf-8"?> <maifest xmls:adroid=" package="com.cookbook.twitter" adroid:versiocode="1" adroid:versioname="1.0"> <applicatio <activity adroid:ame=".twittercookbook" <itet-filter> <actio adroid:ame="adroid.itet.actio.main" <category adroid:ame="adroid.itet.category.launcher" </itet-filter> </activity> <activity adroid:ame=".updateadlist" </applicatio> <uses-permissio adroid:ame="adroid.permissio.internet" </maifest> The layout files eeded are logi.xml The logi scree, as show i Listig 8.8 mai.xml The scree to update the status ad display the home status, as show i Listig 8.9 usertimelierow.xml The view for display of each status timelie, as show i Listig 8.10 Listig 8.8 res/layout/logi.xml <?xml versio="1.0" ecodig="utf-8"?> <LiearLayout xmls:adroid=" adroid:orietatio="vertical" adroid:layout_height="fill_paret" > <TextView adroid:text="userame" <EditText adroid:id="@+id/usertext" adroid:siglelie="true"

3 12 Chapter 8 Networkig <TextView adroid:text="password" <EditText adroid:id="@+id/passwordtext" adroid:password="true" adroid:siglelie="true" <Butto adroid:id="@+id/logibutto" adroid:layout_width="wrap_cotet" adroid:text="logi" adroid:textsize="20dp" </LiearLayout> Listig 8.9 res/layout/mai.xml <?xml versio="1.0" ecodig="utf-8"?> <LiearLayout xmls:adroid=" adroid:orietatio="vertical" adroid:layout_height="fill_paret" adroid:backgroud="@drawable/twitter"> <TextView adroid:text="what is i your mid?" <EditText adroid:id="@+id/userstatus" <Butto adroid:id="@+id/updatebutto" adroid:layout_width="wrap_cotet" adroid:text="update" adroid:textsize="20dp"

4 Social Networkig 213 <ListView adroid:dividerheight="1px" adroid:layout_height="fill_paret" adroid:id="list </LiearLayout> Listig 8.10 res/layout/usertimelierow.xml <?xml versio="1.0" ecodig="utf-8"?> <LiearLayout adroid:layout_width="wrap_cotet" adroid:orietatio="vertical" xmls:adroid=" adroid:paddig="12dip"> <TextView adroid:layout_width="wrap_cotet" adroid:layout_margiright="4dp" adroid:text="diary Title " adroid:textstyle="bold" adroid:textsize="16dip" <TextView adroid:layout_width="wrap_cotet" adroid:text="date Recorded" adroid:textsize="14dip" </LiearLayout> The two activities eeded are the logi to Twitter activity ad the update ad list tweets activity.the logi activity is show i Listig It cotais a EditText object for userame ad password, Butto object to submit the logi data, SharedPrefereces object to save the logi iformatio upo iitial successful logi, ad Twitter object from the twitter4j library. Upo startup, the applicatio checks for logi iformatio from SharedPrefereces ad if available, it prepopulates the EditText boxes.whe the user clicks o the Butto, it iitiates the Twitter object with the userame ad password from the EditText boxes. After the Twitter object is iitiated, it tries to call getfollowersids() to verify if the logi is valid. If the logi is ivalid, a exceptio is throw, ad i this example, it shows a Toast message for logi failure.

5 14 Chapter 8 Networkig Listig 8.11 src/com/cookbook/twitter/twittercookbook.java package com.cookbook.twitter; import twitter4j.twitter; import twitter4j.twitterfactory; import adroid.app.activity; import adroid.cotet.itet; import adroid.cotet.sharedprefereces; import adroid.cotet.sharedprefereces.editor; import adroid.os.budle; import adroid.preferece.preferecemaager; import adroid.view.view; import adroid.view.view.oclicklisteer; import adroid.widget.butto; import adroid.widget.edittext; import adroid.widget.toast; public class TwitterCookBook exteds Activity { SharedPrefereces myprefs; EditText useret, passwordet; Butto logibt; static Twitter twitter; public void ocreate(budle savedistacestate) { super.ocreate(savedistacestate); myprefs = PrefereceMaager.getDefaultSharedPrefereces(this); fial Strig userame = myprefs.getstrig("userame", ull); fial Strig password = myprefs.getstrig("password", ull); setcotetview(r.layout.logi); useret = (EditText)fidViewById(R.id.userText); passwordet = (EditText)fidViewById(R.id.passwordText); logibt = (Butto)fidViewById(R.id.logiButto); useret.settext(userame); passwordet.settext(password); logibt.setoclicklisteer(ew OClickListeer() { public void oclick(view v) { try { twitter = ew TwitterFactory().getIstace(userET.getText().toStrig(), passwordet.gettext().tostrig()); twitter.getfollowersids();

6 Social Networkig 215 Itet i = ew Itet(TwitterCookBook.this, UpdateAdList.class); startactivity(i); Editor ed = myprefs.edit(); ed.putstrig("userame",useret.gettext().tostrig()); ed.putstrig("password", passwordet.gettext().tostrig()); ed.commit(); fiish(); ); catch (Exceptio e) { e.pritstacktrace(); Toast.makeText(TwitterCookBook.this, "logi failed!!", Toast.LENGTH_SHORT).show(); After the logi is passed, the UpdateAdList activity is started.as show i Listig 8.12, it cotais a EditText object for the user to eter their tweet, a Butto object to submit the tweet to the Twitter server, a Twitter object from the twitter4j library, a ResposeList of status for holdig the data retured from the Twitter object, ad a custom adapter for maagig the status data. The activity calls the gethometimelie() to retrieve the timelie status show o the Twitter home page whe a user logs i. Note that all Iteret access fuctio calls are placed iside a AsycTask to avoid hagig the UI thread.the gethometimelie() method is called every time the user submits a tweet ad updates the data adapter. To hold status data i a ListView format, the activity is exteded as ListActivity. Iside the ListActivity, a custom BaseAdapter called UserTimeLieAdapter is defied.this adapter uses ResposeList<Status> usertimelie to display the data i ListView. The ListActivity has two AsycTask classes: setup ad loadstatus.they both call the same operatio gethometimelie().the oly differece is that setup tries to iitiate the adapter ad set the ListActivity with UserTimeLieAdapter, whereas loadstatus just otifies the UserTimeLieAdapter that data is chaged. Listig 8.12 src/com/cookbook/twitter/updateadlist.java package com.cookbook.twitter; import twitter4j.resposelist; import twitter4j.status; import twitter4j.twitter;

7 16 Chapter 8 Networkig import adroid.app.listactivity; import adroid.cotet.cotext; import adroid.os.asyctask; import adroid.os.budle; import adroid.util.log; import adroid.view.layoutiflater; import adroid.view.view; import adroid.view.viewgroup; import adroid.view.view.oclicklisteer; import adroid.widget.baseadapter; import adroid.widget.butto; import adroid.widget.edittext; import adroid.widget.textview; public class UpdateAdList exteds ListActivity { EditText useret; Butto updatebt; Twitter twitter; ResposeList<Status> usertimelie; UserTimeLieAdapter myadapter; public void ocreate(budle savedistacestate) { super.ocreate(savedistacestate); setcotetview(r.layout.mai); useret = (EditText)fidViewById(R.id.userStatus); updatebt = (Butto)fidViewById(R.id.updateButto); twitter = TwitterCookBook.twitter; setup stup = ew setup(); stup.execute(); updatebt.setoclicklisteer(ew OClickListeer() { public void oclick(view v) { try { twitter.updatestatus(useret.gettext().tostrig()); loadstatus ldstatus = ew loadstatus(); ldstatus.execute(); useret.settext(""); catch (Exceptio e) { e.pritstacktrace(); );

8 Social Networkig 217 private class UserTimeLieAdapter exteds BaseAdapter{ private LayoutIflater miflater; public UserTimeLieAdapter(Cotext cotext) { miflater = LayoutIflater.from(cotext); public it getcout() { retur usertimelie.size(); public Status getitem(it i) { retur usertimelie.get(i); public log getitemid(it i) { retur i; public View getview(it arg0, View arg1, ViewGroup arg2) { fial ViewHolder holder; View v = arg1; if ((v == ull) (v.gettag() == ull)) { v = miflater.iflate(r.layout.usertimelierow, ull); holder = ew ViewHolder(); holder.mname = (TextView)v.fidViewById(R.id.ame); holder.mstatus = (TextView)v.fidViewById(R.id.msg); v.settag(holder); else { holder = (ViewHolder) v.gettag(); holder.status= getitem(arg0); holder.mname.settext(holder.status.getuser().getname()); holder.mstatus.settext(holder.status.gettext()); v.settag(holder); retur v;

9 18 Chapter 8 Networkig public class ViewHolder { Status status; TextView mname; TextView mstatus; private class setup exteds AsycTask<Strig, Iteger, Strig> { protected Strig doibackgroud(strig... searchkey) { try{ usertimelie = twitter.gethometimelie(); retur ""; catch(exceptio e){ Log.v("Exceptio Twitter query", "Exceptio:"+e.getMessage()); retur ""; protected void opostexecute(strig result) { try { myadapter = ew UserTimeLieAdapter(UpdateAdList.this); UpdateAdList.this.setListAdapter(myAdapter); catch(exceptio e) { Log.v("Exceptio Twitter query", "Exceptio:"+e.getMessage()); private class loadstatus exteds AsycTask<Strig, Iteger, Strig> { protected Strig doibackgroud(strig... searchkey) { try { usertimelie = twitter.gethometimelie(); retur ""; catch(exceptio e) { Log.v("Exceptio Twitter query", "Exceptio:"+e.getMessage()); retur "";

10 Social Networkig 219 protected void opostexecute(strig result) { try { myadapter.otifydatasetchaged(); catch(exceptio e) { Log.v("Exceptio twitter query", "Exceptio:"+e.getMessage());

System and Software Architecture Description (SSAD)

System and Software Architecture Description (SSAD) System ad Software Architecture Descriptio (SSAD) Diabetes Health Platform Team #6 Jasmie Berry (Cliet) Veerav Naidu (Project Maager) Mukai Nog (Architect) Steve South (IV&V) Vijaya Prabhakara (Quality

More information

Weston Anniversary Fund

Weston Anniversary Fund Westo Olie Applicatio Guide 2018 1 This guide is desiged to help charities applyig to the Westo to use our olie applicatio form. The Westo is ope to applicatios from 5th Jauary 2018 ad closes o 30th Jue

More information

Web OS Switch Software

Web OS Switch Software Web OS Switch Software BBI Quick Guide Nortel Networks Part Number: 213164, Revisio A, July 2000 50 Great Oaks Boulevard Sa Jose, Califoria 95119 408-360-5500 Mai 408-360-5501 Fax www.orteletworks.com

More information

Customer Portal Quick Reference User Guide

Customer Portal Quick Reference User Guide Customer Portal Quick Referece User Guide Overview This user guide is iteded for FM Approvals customers usig the Approval Iformatio Maagemet (AIM) customer portal to track their active projects. AIM is

More information

Oracle Server. What s New in this Release? Release Notes

Oracle  Server. What s New in this Release? Release Notes Oracle email Server Release Notes Release 5.2 for Widows NT May 2001 Part No. A90426-01 These release otes accompay Oracle email Server Release 5.2 for Widows NT. They cotai the followig topics: What s

More information

Guide to Applying Online

Guide to Applying Online Guide to Applyig Olie Itroductio Respodig to requests for additioal iformatio Reportig: submittig your moitorig or ed of grat Pledges: submittig your Itroductio This guide is to help charities submit their

More information

Java net programming II

Java net programming II Java et programmig II https://docs.oracle.com/javase/tutorial/etworkig/sockets/ Overview The problem Basic backgroud: TCP/IP, ports, Cliet/Server, sockets Commuicatio with sockets java.et (overview) Simple

More information

Sharing Collections. Share a Collection via . Share a Collection via Google Classroom. Quick Reference Guide

Sharing Collections. Share a Collection via  . Share a Collection via Google Classroom. Quick Reference Guide Quick Referece Guide Share a Collectio via Email Sharig your collectio with others is a great way to collaborate. You ca easily sed a lik to your colleagues, studets, classmates ad frieds. Recipiets do

More information

Global Support Guide. Verizon WIreless. For the BlackBerry 8830 World Edition Smartphone and the Motorola Z6c

Global Support Guide. Verizon WIreless. For the BlackBerry 8830 World Edition Smartphone and the Motorola Z6c Verizo WIreless Global Support Guide For the BlackBerry 8830 World Editio Smartphoe ad the Motorola Z6c For complete iformatio o global services, please refer to verizowireless.com/vzglobal. Whether i

More information

Exceptions. Your computer takes exception. The Exception Class. Causes of Exceptions

Exceptions. Your computer takes exception. The Exception Class. Causes of Exceptions Your computer takes exceptio s s are errors i the logic of a program (ru-time errors). Examples: i thread mai java.io.filenotfoud: studet.txt (The system caot fid the file specified.) i thread mai java.lag.nullpoiter:

More information

Avid Interplay Bundle

Avid Interplay Bundle Avid Iterplay Budle Versio 2.5 Cofigurator ReadMe Overview This documet provides a overview of Iterplay Budle v2.5 ad describes how to ru the Iterplay Budle cofiguratio tool. Iterplay Budle v2.5 refers

More information

Getting Started. Getting Started - 1

Getting Started. Getting Started - 1 Gettig Started Gettig Started - 1 Issue 1 Overview of Gettig Started Overview of Gettig Started This sectio explais the basic operatios of the AUDIX system. It describes how to: Log i ad log out of the

More information

Bike MS: 2013 Participant Center guide

Bike MS: 2013 Participant Center guide Bike MS: 2013 Participat Ceter guide bikems.org 1 Why use Olie Fudraisig Tools? Usig olie tools makes fudraisig easier Table of Cotets Participats who use persoal pages raise more moey! Bike MS $883 v.

More information

Bike MS: 2014 Participant Center guide

Bike MS: 2014 Participant Center guide Bike MS: 2014 Participat Ceter guide bikems.org 1 Table of Cotets Why Use Olie Fudraisig Tools... 2 Participat Ceter... 3 Guide to Olie Fudraisig... 3 Edit Persoal Page... 5 Address Book... 7 Email Messages...

More information

BIKE MS: 2015 PARTICIPANT CENTER GUIDE

BIKE MS: 2015 PARTICIPANT CENTER GUIDE BIKE MS: 2015 PARTICIPANT CENTER GUIDE bikems.org 1 Table of Cotets Why Use Olie Fudraisig Tools... 2 Participat Ceter... 3 Guide to Olie Fudraisig... 3 Edit Persoal Page... 5 Address Book... 7 Email Messages...

More information

Neolane Social Marketing. Neolane v6.1

Neolane Social Marketing. Neolane v6.1 Neolae Social Marketig Neolae v6.1 This documet, ad the software it describes, are provided subject to a Licese Agreemet ad may ot be used or copied outside of the provisios of the Licese Agreemet. No

More information

Adapter for Mainframe

Adapter for Mainframe BEA WebLogic Java Adapter for Maiframe Workflow Processig Guide Release 5.0 Documet Date: Jauary 2002 Copyright Copyright 2002 BEA Systems, Ic. All Rights Reserved. Restricted Rights Leged This software

More information

Hash Tables. Presentation for use with the textbook Algorithm Design and Applications, by M. T. Goodrich and R. Tamassia, Wiley, 2015.

Hash Tables. Presentation for use with the textbook Algorithm Design and Applications, by M. T. Goodrich and R. Tamassia, Wiley, 2015. Presetatio for use with the textbook Algorithm Desig ad Applicatios, by M. T. Goodrich ad R. Tamassia, Wiley, 2015 Hash Tables xkcd. http://xkcd.com/221/. Radom Number. Used with permissio uder Creative

More information

MOTIF XF Extension Owner s Manual

MOTIF XF Extension Owner s Manual MOTIF XF Extesio Ower s Maual Table of Cotets About MOTIF XF Extesio...2 What Extesio ca do...2 Auto settig of Audio Driver... 2 Auto settigs of Remote Device... 2 Project templates with Iput/ Output Bus

More information

K-NET bus. When several turrets are connected to the K-Bus, the structure of the system is as showns

K-NET bus. When several turrets are connected to the K-Bus, the structure of the system is as showns K-NET bus The K-Net bus is based o the SPI bus but it allows to addressig may differet turrets like the I 2 C bus. The K-Net is 6 a wires bus (4 for SPI wires ad 2 additioal wires for request ad ackowledge

More information

Threads and Concurrency in Java: Part 2

Threads and Concurrency in Java: Part 2 Threads ad Cocurrecy i Java: Part 2 1 Waitig Sychroized methods itroduce oe kid of coordiatio betwee threads. Sometimes we eed a thread to wait util a specific coditio has arise. 2003--09 T. S. Norvell

More information

Avid recommends that you read all the information in this ReadMe file thoroughly before installing or using any new software release.

Avid recommends that you read all the information in this ReadMe file thoroughly before installing or using any new software release. PostDeko for Editors Versio 8.4 ReadMe Importat Iformatio Avid recommeds that you read all the iformatio i this ReadMe file thoroughly before istallig or usig ay ew software release. Importat: Search the

More information

TUTORIAL Create Playlist Helen Doron Course

TUTORIAL Create Playlist Helen Doron Course TUTORIAL Create Playlist Hele Doro Course TUTY Tutorial Create Playlist Hele Doro Course Writte by Serafii Giampiero (INV SRL) Revised by Raffaele Forgioe (INV SRL) Editio EN - 0 Jue 0-0, INV S.r.l. Cotact:

More information

BEA Tuxedo. Using the CORBA Name Service

BEA Tuxedo. Using the CORBA Name Service BEA Tuxedo Usig the CORBA Name Service BEA Tuxedo Release 8.0 Documet Editio 8.0 Jue 2001 Copyright Copyright 2001 BEA Systems, Ic. All Rights Reserved. Restricted Rights Leged This software ad documetatio

More information

University of Waterloo Department of Electrical and Computer Engineering ECE 250 Algorithms and Data Structures

University of Waterloo Department of Electrical and Computer Engineering ECE 250 Algorithms and Data Structures Uiversity of Waterloo Departmet of Electrical ad Computer Egieerig ECE 250 Algorithms ad Data Structures Midterm Examiatio ( pages) Istructor: Douglas Harder February 7, 2004 7:30-9:00 Name (last, first)

More information

CMPT 125 Assignment 2 Solutions

CMPT 125 Assignment 2 Solutions CMPT 25 Assigmet 2 Solutios Questio (20 marks total) a) Let s cosider a iteger array of size 0. (0 marks, each part is 2 marks) it a[0]; I. How would you assig a poiter, called pa, to store the address

More information

Avid Unity Media Engine and Avid MEDIArray XT

Avid Unity Media Engine and Avid MEDIArray XT a Avid Uity Media Egie ad Avid MEDIArray XT Versio 5.0.1 ReadMe Revisio History Date Revised Release Chages Made 4/10/2008 v5.0.1 Avid is recommedig that Avid Uity MediaNetwork Macitosh cliets upgrade

More information

Guide for Online Renewal

Guide for Online Renewal guide for olie reewal Guide for Olie Reewal This guide is desiged to assist you i the completio of your aual olie reewal of registratio. 250 Bloor St. East, Suite 1000, Toroto ON M4W 1E6 Phoe: 416-972-9882

More information

BEA WebLogic XML/Non-XML Translator

BEA WebLogic XML/Non-XML Translator BEA WebLogic XML/No-XML Traslator A Compoet of BEA WebLogic Itegratio Plug-I Guide BEA WebLogic XML/No-XML Traslator Release 2.0 Documet Editio 2.0 July 2001 Copyright Copyright 2001 BEA Systems, Ic. All

More information

Using the Keyboard. Using the Wireless Keyboard. > Using the Keyboard

Using the Keyboard. Using the Wireless Keyboard. > Using the Keyboard 1 A wireless keyboard is supplied with your computer. The wireless keyboard uses a stadard key arragemet with additioal keys that perform specific fuctios. Usig the Wireless Keyboard Two AA alkalie batteries

More information

CSC 220: Computer Organization Unit 11 Basic Computer Organization and Design

CSC 220: Computer Organization Unit 11 Basic Computer Organization and Design College of Computer ad Iformatio Scieces Departmet of Computer Sciece CSC 220: Computer Orgaizatio Uit 11 Basic Computer Orgaizatio ad Desig 1 For the rest of the semester, we ll focus o computer architecture:

More information

Parabolic Path to a Best Best-Fit Line:

Parabolic Path to a Best Best-Fit Line: Studet Activity : Fidig the Least Squares Regressio Lie By Explorig the Relatioship betwee Slope ad Residuals Objective: How does oe determie a best best-fit lie for a set of data? Eyeballig it may be

More information

NVP-903 Series. Multi-Stream Network Video Encoder REFERENCE GUIDE

NVP-903 Series. Multi-Stream Network Video Encoder REFERENCE GUIDE NVP-903 Series Multi-Stream Network Video Ecoder REFERENCE GUIDE NVP-903 Series User Maual Table of Cotets 1 Itroductio... 4 1.1 Product Overview... 4 1.2 Product Features... 4 2 Pael Desig... 5 2.1 Frot

More information

Exercise Set: Implementing an Object-Oriented Design

Exercise Set: Implementing an Object-Oriented Design Exercise Set: Implemetig a Object-Orieted Desig I this exercise set, we have marked questios we thik are harder tha others with a [ ]. We have also marked questios for which solutios are provided at the

More information

Recursion. Computer Science S-111 Harvard University David G. Sullivan, Ph.D. Review: Method Frames

Recursion. Computer Science S-111 Harvard University David G. Sullivan, Ph.D. Review: Method Frames Uit 4, Part 3 Recursio Computer Sciece S-111 Harvard Uiversity David G. Sulliva, Ph.D. Review: Method Frames Whe you make a method call, the Java rutime sets aside a block of memory kow as the frame of

More information

Custodial Integrator Automation Guide

Custodial Integrator Automation Guide Custodial Itegrator Automatio Guide Compay Cofidetial Custodial Itegrator Product Versio: V3.8 Documet Versio: 14 Documet Issue Date: April 21, 2017 Techical Support: (866) 856-4951 Telephoe: (781) 376-0801

More information

Chapter 10. Defining Classes. Copyright 2015 Pearson Education, Ltd.. All rights reserved.

Chapter 10. Defining Classes. Copyright 2015 Pearson Education, Ltd.. All rights reserved. Chapter 10 Defiig Classes Copyright 2015 Pearso Educatio, Ltd.. All rights reserved. Overview 10.1 Structures 10.2 Classes 10.3 Abstract Data Types 10.4 Itroductio to Iheritace Copyright 2015 Pearso Educatio,

More information

BAAN IVc/BaanERP. Conversion Guide Oracle7 to Oracle8

BAAN IVc/BaanERP. Conversion Guide Oracle7 to Oracle8 BAAN IVc/BaaERP A publicatio of: Baa Developmet B.V. P.O.Box 143 3770 AC Bareveld The Netherlads Prited i the Netherlads Baa Developmet B.V. 1999. All rights reserved. The iformatio i this documet is subject

More information

10/23/18. File class in Java. Scanner reminder. Files. Opening a file for reading. Scanner reminder. File Input and Output

10/23/18. File class in Java. Scanner reminder. Files. Opening a file for reading. Scanner reminder. File Input and Output File class i Java File Iput ad Output TOPICS File Iput Exceptio Hadlig File Output Programmers refer to iput/output as "I/O". The File class represets files as objects. The class is defied i the java.io

More information

Overview Chapter 12 A display model

Overview Chapter 12 A display model Overview Chapter 12 A display model Why graphics? A graphics model Examples Bjare Stroustrup www.stroustrup.com/programmig 3 Why bother with graphics ad GUI? Why bother with graphics ad GUI? It s very

More information

Panel for Adobe Premiere Pro CC Partner Solution

Panel for Adobe Premiere Pro CC Partner Solution Pael for Adobe Premiere Pro CC Itegratio for more efficiecy The makes video editig simple, fast ad coveiet. The itegrated pael gives users immediate access to all medialoopster features iside Adobe Premiere

More information

Chapter 11. Friends, Overloaded Operators, and Arrays in Classes. Copyright 2014 Pearson Addison-Wesley. All rights reserved.

Chapter 11. Friends, Overloaded Operators, and Arrays in Classes. Copyright 2014 Pearson Addison-Wesley. All rights reserved. Chapter 11 Frieds, Overloaded Operators, ad Arrays i Classes Copyright 2014 Pearso Addiso-Wesley. All rights reserved. Overview 11.1 Fried Fuctios 11.2 Overloadig Operators 11.3 Arrays ad Classes 11.4

More information

BEA WebLogic Process Integrator

BEA WebLogic Process Integrator BEA WebLogic Process Itegrator A Compoet of BEA WebLogic Itegratio BEA WebLogic Process Itegrator Studio Olie Help BEA WebLogic Process Itegrator Release 2.0 Documet Editio 2.0 July 2001 Copyright Copyright

More information

Architectural styles for software systems The client-server style

Architectural styles for software systems The client-server style Architectural styles for software systems The cliet-server style Prof. Paolo Ciacarii Software Architecture CdL M Iformatica Uiversità di Bologa Ageda Cliet server style CS two tiers CS three tiers CS

More information

Chapter 4 The Datapath

Chapter 4 The Datapath The Ageda Chapter 4 The Datapath Based o slides McGraw-Hill Additioal material 24/25/26 Lewis/Marti Additioal material 28 Roth Additioal material 2 Taylor Additioal material 2 Farmer Tae the elemets that

More information

Morgan Kaufmann Publishers 26 February, COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Interface. Chapter 5

Morgan Kaufmann Publishers 26 February, COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Interface. Chapter 5 Morga Kaufma Publishers 26 February, 28 COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Iterface 5 th Editio Chapter 5 Set-Associative Cache Architecture Performace Summary Whe CPU performace icreases:

More information

Did you know that houses with CCTV are 90% less likely to be burgled? Introducing the new Easy Fit range of CCTV.

Did you know that houses with CCTV are 90% less likely to be burgled? Introducing the new Easy Fit range of CCTV. Easy Fit CCTV Rage Did you kow that houses with CCTV are 90% less likely to be burgled? Itroducig the ew Easy Fit rage of CCTV. Whether it s your home or your busiess, havig extra security ca help you

More information

CS 11 C track: lecture 1

CS 11 C track: lecture 1 CS 11 C track: lecture 1 Prelimiaries Need a CMS cluster accout http://acctreq.cms.caltech.edu/cgi-bi/request.cgi Need to kow UNIX IMSS tutorial liked from track home page Track home page: http://courses.cms.caltech.edu/courses/cs11/material

More information

IS-IS for IPv6. ISP Workshops

IS-IS for IPv6. ISP Workshops IS-IS for IPv6 ISP Workshops These materials are licesed uder the Creative Commos Attributio-NoCommercial 4.0 Iteratioal licese (http://creativecommos.org/liceses/by-c/4.0/) Last updated 8 th April 2018

More information

Copyright 2013 Trend Micro Incorporated. All rights reserved.

Copyright 2013 Trend Micro Incorporated. All rights reserved. Tred Micro reserves the right to make chages to this documet ad to the products described herei without otice. Before istallig or usig the software, please review the readme files, release otes, ad the

More information

Computers and Scientific Thinking

Computers and Scientific Thinking Computers ad Scietific Thikig David Reed, Creighto Uiversity Chapter 15 JavaScript Strigs 1 Strigs as Objects so far, your iteractive Web pages have maipulated strigs i simple ways use text box to iput

More information

Chapter 9. Pointers and Dynamic Arrays. Copyright 2015 Pearson Education, Ltd.. All rights reserved.

Chapter 9. Pointers and Dynamic Arrays. Copyright 2015 Pearson Education, Ltd.. All rights reserved. Chapter 9 Poiters ad Dyamic Arrays Copyright 2015 Pearso Educatio, Ltd.. All rights reserved. Overview 9.1 Poiters 9.2 Dyamic Arrays Copyright 2015 Pearso Educatio, Ltd.. All rights reserved. Slide 9-3

More information

Python Programming: An Introduction to Computer Science

Python Programming: An Introduction to Computer Science Pytho Programmig: A Itroductio to Computer Sciece Chapter 6 Defiig Fuctios Pytho Programmig, 2/e 1 Objectives To uderstad why programmers divide programs up ito sets of cooperatig fuctios. To be able to

More information

ECE4050 Data Structures and Algorithms. Lecture 6: Searching

ECE4050 Data Structures and Algorithms. Lecture 6: Searching ECE4050 Data Structures ad Algorithms Lecture 6: Searchig 1 Search Give: Distict keys k 1, k 2,, k ad collectio L of records of the form (k 1, I 1 ), (k 2, I 2 ),, (k, I ) where I j is the iformatio associated

More information

Baan Tools User Management

Baan Tools User Management Baa Tools User Maagemet Module Procedure UP008A US Documetiformatio Documet Documet code : UP008A US Documet group : User Documetatio Documet title : User Maagemet Applicatio/Package : Baa Tools Editio

More information

Τεχνολογία Λογισμικού

Τεχνολογία Λογισμικού ΕΘΝΙΚΟ ΜΕΤΣΟΒΙΟ ΠΟΛΥΤΕΧΝΕΙΟ Σχολή Ηλεκτρολόγων Μηχανικών και Μηχανικών Υπολογιστών Τεχνολογία Λογισμικού, 7ο/9ο εξάμηνο 2018-2019 Τεχνολογία Λογισμικού Ν.Παπασπύρου, Αν.Καθ. ΣΗΜΜΥ, ickie@softlab.tua,gr

More information

CS 111: Program Design I Lecture # 7: Web Crawler, Functions; Open Access

CS 111: Program Design I Lecture # 7: Web Crawler, Functions; Open Access CS 111: Program Desig I Lecture # 7: Web Crawler, Fuctios; Ope Access Robert H. Sloa & Richard Warer Uiversity of Illiois at Chicago September 13, 2016 Lab Hit/Remider word = "hi" word.upper() à "HI" Questio

More information

Python Programming: An Introduction to Computer Science

Python Programming: An Introduction to Computer Science Pytho Programmig: A Itroductio to Computer Sciece Chapter 1 Computers ad Programs 1 Objectives To uderstad the respective roles of hardware ad software i a computig system. To lear what computer scietists

More information

n We have discussed classes in previous lectures n Here, we discuss design of classes n Library design considerations

n We have discussed classes in previous lectures n Here, we discuss design of classes n Library design considerations Chapter 14 Graph class desig Bjare Stroustrup Abstract We have discussed classes i previous lectures Here, we discuss desig of classes Library desig cosideratios Class hierarchies (object-orieted programmig)

More information

L5355 Modbus Plus Communications Interface

L5355 Modbus Plus Communications Interface L5355 Modbus Plus Commuicatios Iterface Techical Maual HA470897 Issue 2 Copyright SSD Drives Ic 2005 All rights strictly reserved. No part of this documet may be stored i a retrieval system, or trasmitted

More information

Classes and Objects. Again: Distance between points within the first quadrant. José Valente de Oliveira 4-1

Classes and Objects. Again: Distance between points within the first quadrant. José Valente de Oliveira 4-1 Classes ad Objects jvo@ualg.pt José Valete de Oliveira 4-1 Agai: Distace betwee poits withi the first quadrat Sample iput Sample output 1 1 3 4 2 jvo@ualg.pt José Valete de Oliveira 4-2 1 The simplest

More information

top() Applications of Stacks

top() Applications of Stacks CS22 Algorithms ad Data Structures MW :00 am - 2: pm, MSEC 0 Istructor: Xiao Qi Lecture 6: Stacks ad Queues Aoucemets Quiz results Homework 2 is available Due o September 29 th, 2004 www.cs.mt.edu~xqicoursescs22

More information

BAAN IV. BAAN IV Installation Manual for DB2 on Windows NT

BAAN IV. BAAN IV Installation Manual for DB2 on Windows NT BAAN IV BAAN IV Istallatio Maual for DB2 o Widows NT A publicatio of: Baa Developmet B.V. P.O.Box 143 3770 AC Bareveld The Netherlads Prited i the Netherlads Baa Developmet B.V. 1999. All rights reserved.

More information

BEA Tuxedo. Creating CORBA Server Applications

BEA Tuxedo. Creating CORBA Server Applications BEA Tuxedo Creatig CORBA Server Applicatios BEA Tuxedo Release 8.0 Documet Editio 8.0 Jue 2001 Copyright Copyright 2001 BEA Systems, Ic. All Rights Reserved. Restricted Rights Leged This software ad documetatio

More information

Linked Lists 11/16/18. Preliminaries. Java References. Objects and references. Self references. Linking self-referential nodes

Linked Lists 11/16/18. Preliminaries. Java References. Objects and references. Self references. Linking self-referential nodes Prelimiaries Liked Lists public class StrageObject { Strig ame; StrageObject other; Arrays are ot always the optimal data structure: A array has fixed size eeds to be copied to expad its capacity Addig

More information

n It s exciting n It s lucrative n It s fun (sometimes!)

n It s exciting n It s lucrative n It s fun (sometimes!) Itroductio to CS1 Java Programmig cs163: No prior programmig experiece cs164: Prior programmig experiece Why Computer Sciece? It s excitig It s lucrative It s fu (sometimes!) Itroductio to CS1 Java Programmig

More information

BEA Tuxedo. Creating CORBA Client Applications

BEA Tuxedo. Creating CORBA Client Applications BEA Tuxedo Creatig CORBA Cliet Applicatios BEA Tuxedo 8.0 Documet Editio 8.0 Jue 2001 Copyright Copyright 2001 BEA Systems, Ic. All Rights Reserved. Restricted Rights Leged This software ad documetatio

More information

WORKED EXAMPLE 7.1. Producing a Mass Mailing. We want to automate the process of producing mass mailings. A typical letter might look as follows:

WORKED EXAMPLE 7.1. Producing a Mass Mailing. We want to automate the process of producing mass mailings. A typical letter might look as follows: Worked Example 7.1 Producig a Mass Mailig 1 WORKED EXAMPLE 7.1 Producig a Mass Mailig We wat to automate the process of producig mass mailigs. A typical letter might look as follows: To: Ms. Sally Smith

More information

Princeton Instruments Reference Manual

Princeton Instruments Reference Manual Priceto Istrumets Referece Maual Improvisio, Viscout Cetre II, Uiversity of Warwick Sciece Park, Millbur Hill Road, Covetry. CV4 7HS Tel: 0044 (0) 24 7669 2229 Fax: 0044 (0) 24 7669 0091 e-mail: admi@improvisio.com

More information

JCF: case studies. Bruce Eckel, Thinking in Java, 4th edition, PrenticeHall, New Jersey, cf.

JCF: case studies. Bruce Eckel, Thinking in Java, 4th edition, PrenticeHall, New Jersey, cf. JCF: case studies Bruce Eckel, Thikig i Java, 4th editio, PreticeHall, New Jersey, cf. http://midview.et/books/tij4 jvo@ualg.pt José Valete de Oliveira 20-1 CS1: From real to fractio How to covert a real

More information

Air Force Data Reference Architecture and Platform

Air Force Data Reference Architecture and Platform Headquarters U.S. Air Force Air Force Data Referece Architecture ad Platform Ms. Jackie Murray 11 Oct 2018 1 AF Data Challeges Large umber of legacy systems with umerous poit-to-poit iterfaces that are

More information

Threads and Concurrency in Java: Part 1

Threads and Concurrency in Java: Part 1 Cocurrecy Threads ad Cocurrecy i Java: Part 1 What every computer egieer eeds to kow about cocurrecy: Cocurrecy is to utraied programmers as matches are to small childre. It is all too easy to get bured.

More information

Threads and Concurrency in Java: Part 1

Threads and Concurrency in Java: Part 1 Threads ad Cocurrecy i Java: Part 1 1 Cocurrecy What every computer egieer eeds to kow about cocurrecy: Cocurrecy is to utraied programmers as matches are to small childre. It is all too easy to get bured.

More information

CS 111: Program Design I Lecture 19: Networks, the Web, and getting text from the Web in Python

CS 111: Program Design I Lecture 19: Networks, the Web, and getting text from the Web in Python CS 111: Program Desig I Lecture 19: Networks, the Web, ad gettig text from the Web i Pytho Robert H. Sloa & Richard Warer Uiversity of Illiois at Chicago April 3, 2018 Goals Lear about Iteret Lear about

More information

Abstract Data Types (ADTs) Stacks. The Stack ADT ( 4.2) Stack Interface in Java

Abstract Data Types (ADTs) Stacks. The Stack ADT ( 4.2) Stack Interface in Java Abstract Data Types (ADTs) tacks A abstract data type (ADT) is a abstractio of a data structure A ADT specifies: Data stored Operatios o the data Error coditios associated with operatios Example: ADT modelig

More information

CS211 Fall 2003 Prelim 2 Solutions and Grading Guide

CS211 Fall 2003 Prelim 2 Solutions and Grading Guide CS11 Fall 003 Prelim Solutios ad Gradig Guide Problem 1: (a) obj = obj1; ILLEGAL because type of referece must always be a supertype of type of object (b) obj3 = obj1; ILLEGAL because type of referece

More information

Avid Unity TransferManager

Avid Unity TransferManager a Avid Uity TrasferMaager Versio 2.9.9 Release Notes Importat Iformatio Avid recommeds that you read all the iformatio i these release otes thoroughly before istallig or usig ay ew software release. Importat:

More information

BEA Tuxedo. Using the CORBA Notification Service

BEA Tuxedo. Using the CORBA Notification Service BEA Tuxedo Usig the CORBA Notificatio Service BEA Tuxedo 8.0 Documet Editio 8.0 Jue 2001 Copyright Copyright 2001 BEA Systems, Ic. All Rights Reserved. Restricted Rights Leged This software ad documetatio

More information

Copyright Hewlett-Packard Development Company, L.P.

Copyright Hewlett-Packard Development Company, L.P. Media Ceter Software Guide The oly warraties for HP products ad services are set forth i the express warraty statemets accompayig such products ad services. Nothig herei should be costrued as costitutig

More information

Software Evolution. Software Engineering HS 16. Thomas Fritz & Martin Glinz

Software Evolution. Software Engineering HS 16. Thomas Fritz & Martin Glinz Software Egieerig HS 16 Software Evolutio Thomas Fritz & Marti Gliz May thaks to H. Gall, K. Kevic, M. Alle, V. Razmov, M. Laza, D. Shepherd, M. Felici, G. Murphy Learig Goals By the ed of this uit, you

More information

Having Fun. Getting Started

Having Fun. Getting Started start guide Gettig Started Itroducig Your Phoe...2 Service Activatio...4 SIM Card...5 Battery...6 Power...7 MOTOBLUR Accout...8 Call Fuctios...10 Home Scree...12 Persoalize Home Scree...20 Social Networkig...24

More information

BODiBEAT Station. Owner s Manual. Contents

BODiBEAT Station. Owner s Manual. Contents BODiBEAT Statio Ower s Maual Versio 1.2.c Cotets About the BODiBEAT Statio.................... 2 Viewig the Exercise Logs....................... 5 Creatig ad Maagig a Traiig Program........ 9 Maagig Sog

More information

BEA WebLogic Portal. Guide to Events and Behavior Tracking

BEA WebLogic Portal. Guide to Events and Behavior Tracking BEA WebLogic Portal Guide to Evets ad Behavior Trackig Versio 4.02 Documet Date: November 2001 Copyright Copyright 2001 BEA Systems, Ic. All Rights Reserved. Restricted Rights Leged This software ad documetatio

More information

JDBC (Java Database Connectivity)

JDBC (Java Database Connectivity) JDBC (Java Database Coectivity) Database System Cocepts, 6 th Ed. Siberschatz, Korth ad Sudarsha See www.db-book.com for coditios o re-use JDBC Java API for commuicatig with database systems supportig

More information

Τεχνολογία Λογισμικού

Τεχνολογία Λογισμικού ΕΘΝΙΚΟ ΜΕΤΣΟΒΙΟ ΠΟΛΥΤΕΧΝΕΙΟ Σχολή Ηλεκτρολόγων Μηχανικών και Μηχανικών Υπολογιστών Τεχνολογία Λογισμικού, 7ο/9ο εξάμηνο 2018-2019 Τεχνολογία Λογισμικού Ν.Παπασπύρου, Αν.Καθ. ΣΗΜΜΥ, ickie@softlab.tua,gr

More information

Recursion. Recursion. Mathematical induction: example. Recursion. The sum of the first n odd numbers is n 2 : Informal proof: Principle:

Recursion. Recursion. Mathematical induction: example. Recursion. The sum of the first n odd numbers is n 2 : Informal proof: Principle: Recursio Recursio Jordi Cortadella Departmet of Computer Sciece Priciple: Reduce a complex problem ito a simpler istace of the same problem Recursio Itroductio to Programmig Dept. CS, UPC 2 Mathematical

More information

BEA Tuxedo. Using the BEA Tuxedo System on Windows NT

BEA Tuxedo. Using the BEA Tuxedo System on Windows NT BEA Tuxedo Usig the BEA Tuxedo System o Widows NT BEA Tuxedo Release 7.1 Documet Editio 7.1 May 2000 Copyright Copyright 2000 BEA Systems, Ic. All Rights Reserved. Restricted Rights Leged This software

More information

n Some thoughts on software development n The idea of a calculator n Using a grammar n Expression evaluation n Program organization n Analysis

n Some thoughts on software development n The idea of a calculator n Using a grammar n Expression evaluation n Program organization n Analysis Overview Chapter 6 Writig a Program Bjare Stroustrup Some thoughts o software developmet The idea of a calculator Usig a grammar Expressio evaluatio Program orgaizatio www.stroustrup.com/programmig 3 Buildig

More information

TargetLink. Installation Notes. MATLAB R14SP3 Compatibility Update for TargetLink 2.1

TargetLink. Installation Notes. MATLAB R14SP3 Compatibility Update for TargetLink 2.1 TargetLik Istallatio Notes MATLAB R14SP3 Compatibility Update for TargetLik 2.1 TargetLik 2.1.5 November 2005 ds How to Cotact dspace Mail: Tel.: Fax: E-mail: Web: Geeral Techical Support: TargetLik Support:

More information

Avid Unity ISIS. Version ReadMe

Avid Unity ISIS. Version ReadMe Avid Uity ISIS Versio 2.0.6 ReadMe Date Revised Release Chages Made 7/20/2010 v2.0.6 Added details o why v2.0.6 is a importat update regardig a issue previously foud with the Avid Uity ISIS System Director.

More information

BEA WebLogic Commerce Server. Registration and User Processing Package

BEA WebLogic Commerce Server. Registration and User Processing Package BEA WebLogic Commerce Server Registratio ad User Processig Package BEA WebLogic Commerce Server 3.2 Documet Editio 3.2 December 2000 Copyright Copyright 2000 BEA Systems, Ic. All Rights Reserved. Restricted

More information

Extending The Sleuth Kit and its Underlying Model for Pooled Storage File System Forensic Analysis

Extending The Sleuth Kit and its Underlying Model for Pooled Storage File System Forensic Analysis Extedig The Sleuth Kit ad its Uderlyig Model for Pooled File System Foresic Aalysis Frauhofer Istitute for Commuicatio, Iformatio Processig ad Ergoomics Ja-Niclas Hilgert* Marti Lambertz Daiel Plohma ja-iclas.hilgert@fkie.frauhofer.de

More information

Avid DS Nitris. Installation and Administration Guide. Version 7.0. Avid make manage move media

Avid DS Nitris. Installation and Administration Guide. Version 7.0. Avid make manage move media Avid make maage move media Avid DS Nitris Istallatio ad Admiistratio Guide Versio 7.0 Copyright ad Disclaimer Product specificatios are subject to chage without otice ad do ot represet a commitmet o the

More information

Avid DS Nitris. Installation and Administration Guide. Version 7.5. Avid make manage move media

Avid DS Nitris. Installation and Administration Guide. Version 7.5. Avid make manage move media Avid make maage move media Avid DS Nitris Istallatio ad Admiistratio Guide Versio 7.5 Copyright ad Disclaimer Product specificatios are subject to chage without otice ad do ot represet a commitmet o the

More information

Workflow model GM AR. Gumpy. Dynagump. At a very high level, this is what gump does. We ll be looking at each of the items described here seperately.

Workflow model GM AR. Gumpy. Dynagump. At a very high level, this is what gump does. We ll be looking at each of the items described here seperately. Workflow model GM AR Gumpy RM Dyagump At a very high level, this is what gump does. We ll be lookig at each of the items described here seperately. User edits project descriptor ad commits s maitai their

More information

busiess.officedepot.com User Guide Coveiet. Effective. Smart. https://busiess.officedepot.com CUSTOMER SUPPORT Hours of operatio: Moday Friday, 8:00 A.M 8:00 P.M. (Easter Time) Live Chat: For immediate

More information

OPC Server ECL Comfort 210/310 OPC Server

OPC Server ECL Comfort 210/310 OPC Server OPC Server Descriptio j l j o j l k j l j Modbus-RS485 k Etheret or Iteret l Modbus-TCP ECL Cofort cotroller Heat eter o SCADA server The Dafoss is a OPC-copliat server that serves data to OPC cliets.

More information

Solution printed. Do not start the test until instructed to do so! CS 2604 Data Structures Midterm Spring, Instructions:

Solution printed. Do not start the test until instructed to do so! CS 2604 Data Structures Midterm Spring, Instructions: CS 604 Data Structures Midterm Sprig, 00 VIRG INIA POLYTECHNIC INSTITUTE AND STATE U T PROSI M UNI VERSI TY Istructios: Prit your ame i the space provided below. This examiatio is closed book ad closed

More information

CIS 121 Data Structures and Algorithms with Java Spring Stacks and Queues Monday, February 12 / Tuesday, February 13

CIS 121 Data Structures and Algorithms with Java Spring Stacks and Queues Monday, February 12 / Tuesday, February 13 CIS Data Structures ad Algorithms with Java Sprig 08 Stacks ad Queues Moday, February / Tuesday, February Learig Goals Durig this lab, you will: Review stacks ad queues. Lear amortized ruig time aalysis

More information

n Learn how resiliency strategies reduce risk n Discover automation strategies to reduce risk

n Learn how resiliency strategies reduce risk n Discover automation strategies to reduce risk Chapter Objectives Lear how resiliecy strategies reduce risk Discover automatio strategies to reduce risk Chapter #16: Architecture ad Desig Resiliecy ad Automatio Strategies 2 Automatio/Scriptig Resiliet

More information