Lecture 26 | Programming Methodology (Stanford)
-
0:10 - 0:13put
-
0:13 - 0:16this presentation is delivered by the stanford center for professional
-
0:16 - 0:23development
-
0:26 - 0:27study questions
-
0:27 - 0:31about anything we've done so far and last and what you've got and foreign
-
0:31 - 0:32experts topic
-
0:32 - 0:36before we dive in particular topic
-
0:36 - 0:37feeling okay
-
0:37 - 0:40one of things that we sort of gone the whole time in this class we use these
-
0:40 - 0:43things called a cm librarians
-
0:43 - 0:47and they sam libraries are set of libraries contractually created by a
-
0:47 - 0:50task force people they say the association for community really talked
-
0:50 - 0:53about them at the very beginning of the christ we talked about these libraries
-
0:53 - 0:57who put together some nice libraries have stopped at a really useful for
-
0:57 - 0:59teaching which is actually why we use them
-
0:59 - 1:02and so today i want to do it left a little bit underneath the hood and talk
-
1:02 - 1:05a little bit about standard java
-
1:05 - 1:08which is what you would get if you didn't use the aclu libraries and
-
1:08 - 1:11you just use the standard java libros now i have no reason why you can't
-
1:11 - 1:13continue to use the a c white recap of the class
-
1:13 - 1:15that's another set of libraries that were written by a group of people that
-
1:15 - 1:17you're certainly welcome to use
-
1:17 - 1:19so there's no reason why you
-
1:19 - 1:20should stop using them
-
1:20 - 1:23but i just want to give you a little bit there's a couple important issues relate
-
1:23 - 1:26to standard java that now is a time when we can find a lift the covers and it's
-
1:26 - 1:28time for you to know
-
1:28 - 1:35so the first thing that's related to thinking about standards outlined
-
1:35 - 1:38you know when you're running your programs in uganda clips and you do your
-
1:38 - 1:41you click on the little running guide to compile your programs and then it gives
-
1:41 - 1:44you a list attention we ob
-
1:44 - 1:48classes you actually might want to run sometimes if you only have one project
-
1:48 - 1:49images only get one twice
-
1:49 - 1:53but i think i think about it a maryland like in the game show for program i
-
1:53 - 1:55actually have like four or five different classes
-
1:55 - 1:59how can always knew which class to run acknowledged his name sir for class was
-
1:59 - 2:01the class and i actually should run
-
2:01 - 2:08right i had a bunch of classes and their anyone wanna venture a guess
-
2:09 - 2:13it's only class wounded orion which is barry related to
-
2:13 - 2:16and underlying issue which is that it's the only class that actually was
-
2:16 - 2:17extending program
-
2:17 - 2:20and so wanted extended program what actually was happening underneath the
-
2:20 - 2:26hood of the atm_ libros is you are getting a method
-
2:26 - 2:30and maine is actually the place now your total old enough to see main
-
2:30 - 2:35maine is actually the method at which java classes actually start running
-
2:35 - 2:38and so i think you should think now as you get a little distributor like and i
-
2:38 - 2:40never wrote method called me
-
2:40 - 2:44i never saw a method called main you're telling me that's where java programs
-
2:44 - 2:45actually start running
-
2:45 - 2:46yeah in fact it is
-
2:46 - 2:49and it's because programs
-
2:49 - 2:52provided this main method for you and with his main method in the program
-
2:52 - 2:55was essentially get the rest of your program running by getting a few things
-
2:55 - 2:57set up a ninety cannot cure runner
-
2:57 - 3:00so you didn't actually need to worry about this
-
3:00 - 3:01but now you're sort of old enough
-
3:01 - 3:05to actually see what that means after dissolve about
-
3:05 - 3:09so if we think about what this means that the guys and though hope for the
-
3:09 - 3:11main method is also kind of where this part of a reason why we never showed you
-
3:11 - 3:13the main method before
-
3:13 - 3:17the head of hair for the main method is actually public
-
3:17 - 3:19static
-
3:19 - 3:20poorly
-
3:20 - 3:23team but we're not done yet me and actually have some arguments
-
3:23 - 3:26it has been a rehab stream
-
3:26 - 3:28called pardons
-
3:28 - 3:32as arguments and then something here happens inside of me
-
3:32 - 3:35and we showed that you're on the first day we would have to go through and
-
3:35 - 3:36explain what all these words man
-
3:36 - 3:40before we explain what main even wise before we explained you how do you
-
3:40 - 3:41writer first program
-
3:41 - 3:42that would have been a pain
-
3:42 - 3:46but now we can just tell you right public means is a public method you know
-
3:46 - 3:49that if i call the other public methods you've written
-
3:49 - 3:51static means that this is actually eight
-
3:51 - 3:54method that belongs to the class
-
3:54 - 3:57it's it instead it's not something that you would actually call on a particular
-
3:57 - 3:58object right
-
3:58 - 4:02so you never have some project like yours mine object action i call acts dot
-
4:02 - 4:02main
-
4:02 - 4:05maine is just something that gets called
-
4:05 - 4:09class method as opposed to being a method that gets called on an instant
-
4:09 - 4:11and avoid means just returns nothing
-
4:11 - 4:15what it's getting passed in here is an array of strings you might say it was
-
4:15 - 4:19that array of strings coming from that's actually harks back to the days of your
-
4:19 - 4:22when computers weren't all nice in graphical when everything
-
4:22 - 4:25and when people actually well programs they wrote a program and then they were
-
4:25 - 4:28typing on what's called the command line they wrote the name of the program out
-
4:28 - 4:29the actually typed it
-
4:29 - 4:32and then they typed a bunch of things that they want to be passed into the
-
4:32 - 4:33program
-
4:33 - 4:36as sort of like initial information to start that program
-
4:36 - 4:39though the national thanks hope you had some program like names are for
-
4:39 - 4:43you might actually start off by giving the name of the program
-
4:43 - 4:45and then happening separate you might give it some other people think that you
-
4:45 - 4:47might give the name of the data file
-
4:47 - 4:49like leader dot correct
-
4:49 - 4:53anybody given it some other things as well but were separated by spaces
-
4:53 - 4:58and this list of stop is essentially what gets passed in here is arguments
-
4:58 - 4:59there just rings
-
4:59 - 5:03and this is how the program would actually know what came in on what we
-
5:03 - 5:06refer to as the command line when the program is kicked off a mighty
-
5:06 - 5:10from our job is not that although the language right exotic came around really
-
5:10 - 5:12sagging popularity in nineteen ninety five
-
5:12 - 5:16people aren't doing a lot of nineteen ninety five like i already have like my
-
5:16 - 5:19mouth and i have my folders and i have all this other stuff
-
5:19 - 5:21even if you were like six years old
-
5:21 - 5:24you probably already dead right and you like i never typed this stop
-
5:24 - 5:28so why do i care about at the reason why you care about is actually java derived
-
5:28 - 5:30from another language called seat which
-
5:30 - 5:32and as a variation called c_ plus plus
-
5:32 - 5:36that was created when people writing programs in the days of your and the
-
5:36 - 5:40whole notion of maine and having some arguments they get passed to me kind of
-
5:40 - 5:43came along with sort of the baggage of
-
5:43 - 5:47actually having a program language becomes the sort of matches the c
-
5:47 - 5:50stop programming languages when they did do this
-
5:50 - 5:53so a lot of the times in a row java program these days there aren't really
-
5:53 - 5:57any argument regarding mister some system parameters something like that
-
5:57 - 5:58we don't usually worry about them
-
5:58 - 5:59okay but just so
-
5:59 - 6:02when you go and look at some other java program is that you can be a scam
-
6:02 - 6:05library can you see this main thing in your wondering what's it all about
-
6:05 - 6:07this is you don't think i mean analogously toronto
-
6:07 - 6:10it's just won't give you know the whole time you've been thinking of running for
-
6:10 - 6:12your execution starts
-
6:12 - 6:15maine is really were executions
-
6:15 - 6:17that you think about
-
6:17 - 6:21okay execution actually started in maine so how did this thing actually kick off
-
6:21 - 6:23my runescape
-
6:23 - 6:25now you're short old enough to see that's you
-
6:25 - 6:28so what it actually did like let's say this was the main method in a program
-
6:28 - 6:29like
-
6:29 - 6:30named surf
-
6:30 - 6:32so somewhere
-
6:32 - 6:36inside of eight op program inside the ec and libraries for program we have
-
6:36 - 6:37this main method
-
6:37 - 6:41they figured out what the name of your class was essentially it had a one-liner
-
6:41 - 6:41renewed
-
6:41 - 6:44that would have been approval incidents
-
6:44 - 6:49new name surfer
-
6:49 - 6:51and started
-
6:51 - 6:53departed
-
6:53 - 6:55start to wonder why
-
6:55 - 6:56and now
-
6:56 - 6:59you know what this means what was actually doing what it means you would
-
6:59 - 7:01main started note
-
7:01 - 7:04object exist in the world like at the static method
-
7:04 - 7:08so there's no object that you're you know giving them a message to your just
-
7:08 - 7:12main just kind of starts off wakes up says hey i mean what am i going to do
-
7:12 - 7:13why don't i create
-
7:13 - 7:18some object of this particular tightening surfer which happens
-
7:18 - 7:20instantiate an object which is your program
-
7:20 - 7:24and then remember your program as we can talk about implements the run method and
-
7:24 - 7:26actually a program underneath the hood
-
7:26 - 7:30implements the run double interface that we talked about last time remember with
-
7:30 - 7:32threads we talked about the run a bowl interface
-
7:32 - 7:35lol programs and plant or animal interface and how you kick off something
-
7:35 - 7:38that's run double use a start
-
7:38 - 7:43so what it basically did was created an object of your class which was named
-
7:43 - 7:43surfer
-
7:43 - 7:47and told at the start and it happened to start pass along these arguments
-
7:47 - 7:50but you never needed to see those arguments the matter fact you never did
-
7:50 - 7:51see them because
-
7:51 - 7:55when your articles instantiated it didn't expect any arguments
-
7:55 - 7:59so the argument actually got pass this thing called stock we just ignored them
-
7:59 - 7:59basically
-
7:59 - 8:03and then started to run method to kick everything off
-
8:03 - 8:06and last summer we talked about start we talked about this in the context of
-
8:06 - 8:09thread so we said hello you create a new thread
-
8:09 - 8:11and that are the object that you're gonna start running we put inside of
-
8:11 - 8:13thread we take the thread off with start
-
8:13 - 8:16in this case we're not actually creating a new thread
-
8:16 - 8:20we're just saying i want to start executing basically decided that bag is
-
8:20 - 8:22created it implements run of course they'll start running from the method
-
8:22 - 8:23run
-
8:23 - 8:27but i'm not creating a new thread so this thing is going to execute in the
-
8:27 - 8:29same thread of execution
-
8:29 - 8:31as the entire
-
8:31 - 8:35so i don't suddenly kick off something that's running in parallel with this guy
-
8:35 - 8:37it's actually just sequentially going to start name surfer
-
8:37 - 8:42and that's the last thing that this guy does which is based on a valuable
-
8:42 - 8:43sam questions about that
-
8:43 - 8:46kind of a funky concept but that's basically what's going on you should see
-
8:46 - 8:47it
-
8:47 - 8:50we're creating an instance of your program and then just kicking it off
-
8:50 - 8:53and that's why this whole time we have this thing called the run method that
-
8:53 - 8:54had to be public
-
8:54 - 8:58because is implementing the rundle interface but now you've seen any
-
8:58 - 9:01and the only reason you know you kind of mca
-
9:01 - 9:04added meaning your program to begin with and include all the score the only
-
9:04 - 9:05reason we didn't put it in there before
-
9:05 - 9:08it because will want to planing to stop
-
9:08 - 9:12in week two of the class like right after kalra lower like all the dancing
-
9:12 - 9:13provide on right
-
9:13 - 9:16artillery by turning around the world i think java
-
9:16 - 9:18public static void main string args like
-
9:18 - 9:21what is going on right we hadn't done a raise
-
9:21 - 9:23then done classes with
-
9:23 - 9:27fingering about static we certainly and methods then demand bremer past
-
9:27 - 9:33so we just wait until the end of ninety cm now you know what's going on
-
9:33 - 9:34now that we have a bad idea
-
9:34 - 9:38now we can think about okay if this is kind of like the standard javaworld days
-
9:38 - 9:42let me think about taking this idea and using its help me take my existing
-
9:42 - 9:45programs that i've written and pack them up into a form so i can share them with
-
9:45 - 9:47family and friends
-
9:47 - 9:49so that's what we're going to do next
-
9:49 - 9:55the basic concept of doing this as something that's called a jar file
-
9:55 - 9:59and you've actually seen jar files before because you've been working with
-
9:59 - 10:02something this whole time in your product projects
-
10:02 - 10:04called pcm dot jar
-
10:04 - 10:06this was just eight jar file
-
10:06 - 10:08they contained all the atm_ libraries
-
10:08 - 10:11so basically college are pile is where to get its name is not because it's like
-
10:11 - 10:14i did a big mason jar although you can think of it like that
-
10:14 - 10:17it stands for a job loc
-
10:17 - 10:19archive
-
10:19 - 10:21that's where the name comes
-
10:21 - 10:24and the basically behind a jar file as this thing can contain a bunch of
-
10:24 - 10:28different stuff most the time when it contains is a bunch of classes in job
-
10:28 - 10:32and you could think of this is the compiled version of the classes
-
10:32 - 10:36you can actually put source code inside of a jar if you want but most the time
-
10:36 - 10:37when you get a jock
-
10:37 - 10:40it doesn't have the source code associate with it it just has the actual
-
10:40 - 10:42dot class five to the compiled version of the files
-
10:42 - 10:45so you could put source pausing here if you want it
-
10:45 - 10:48you complete data files in here if you want to put a bunch things in here if
-
10:48 - 10:48you want
-
10:48 - 10:52what we're really going to focus on the case of putting classes
-
10:52 - 10:55so one of these already existed for you with a cm dot jar
-
10:55 - 10:58and want to figure out how to actually create some of these ourselves
-
10:58 - 11:01and use them because they could actually think of them as something that's
-
11:01 - 11:02wonderful
-
11:02 - 11:05were executed like ships and not confuse ramblings
-
11:05 - 11:07so click on the computer
-
11:07 - 11:09here's name sir
-
11:09 - 11:12and then a natural working version of nameserver so i'm not going to show
-
11:12 - 11:15press the files in case you're going to make this
-
11:15 - 11:19but all the code in here and for the first thing i didn't mean surfer program
-
11:19 - 11:23if i thought about me i want to think of this and the standard javaworld now even
-
11:23 - 11:26though i'm do you still using the atm_ libraries
-
11:26 - 11:29when i want to build this jar i want to build the joint away the sort of makes
-
11:29 - 11:33maximally portable like i can give it to someone who's over here on the species
-
11:33 - 11:34i've never here on the snack
-
11:34 - 11:37and they don't need to have a klutz or anything like that they can just one of
-
11:37 - 11:38the whole point
-
11:38 - 11:40so the first thing to do
-
11:40 - 11:43if the introduced my friend the main method
-
11:43 - 11:46and so basically i put in the car that you just opt out at a method public
-
11:46 - 11:51static void main as this array of strings called arc that sits parameters
-
11:51 - 11:54that's just the way maine is always defined to be
-
11:54 - 11:57and what it's going to do is create a new name sir project
-
11:57 - 11:58and kick it off
-
11:58 - 12:02and that's the only thing i need to add to my program so anywhere you had some
-
12:02 - 12:03class
-
12:03 - 12:04extended program
-
12:04 - 12:07you would add these three lines of code
-
12:07 - 12:11so basically get us sort of compliant with standard job
-
12:11 - 12:14once we do that now we need to create this thing called the jar file which is
-
12:14 - 12:18thing the racks would be able to x
-
12:18 - 12:21one thing you might be saying to yourself this maryland you told me the
-
12:21 - 12:24aclu libras already sort of provide this for me so why my putting it
-
12:24 - 12:29explicitly in there is a matter of fact it's not super required to be in their
-
12:29 - 12:29explicitly
-
12:29 - 12:33the real reason why we put in their explicitly is to try to maximize
-
12:33 - 12:36portability because even though java spoke at this property were like
-
12:36 - 12:39uh... we would like the java code want to make a run on pcs in run on maxim
-
12:39 - 12:44ic ron you know this time tiger and not for adults other stuff
-
12:44 - 12:48in reality personal differences between these operating systems
-
12:48 - 12:51and so little problems creep up here in there every once in while you actually
-
12:51 - 12:53saw fuck you does in class on occasion
-
12:53 - 12:56so your experience them in the letter
-
12:56 - 13:00by putting in this one explicitly robin kind of relying on the code it in the a
-
13:00 - 13:04c l_ libros exactly doing a bunch more complicated stuff right because
-
13:04 - 13:07itni in for what the name of your class wise right you never told that
-
13:07 - 13:09explicitly gracie i'm library
-
13:09 - 13:12yeah i need a new one of these guys actually there's job as a story called
-
13:12 - 13:14reflection reckon actually go in safe
-
13:14 - 13:18i'll let me take a moment to reflect i'm going to go and look at the names of
-
13:18 - 13:19your classes
-
13:19 - 13:22and then do something actually generate some code based on the names of your
-
13:22 - 13:24classes which is what it was doing
-
13:24 - 13:28that kind of stuff going down a little bit coffee so we're just gonna say aid a
-
13:28 - 13:31cm don't worry about it i'm just given it to you i'm a i'm a nice guy
-
13:31 - 13:36say he's put this in to make it exposes our maximizes portability main reason
-
13:36 - 13:40so how do we create a thing called a dropout what we're doing here
-
13:40 - 13:42steps are all in excruciating detail on your hand out they don't need to worry
-
13:42 - 13:46about scribbling down notes quickly but what we're gonna do is you first click
-
13:46 - 13:48as the death multiple by the whole thing
-
13:48 - 13:53you select the project that you wanna create the jobs are from so nameserver
-
13:53 - 13:56and then we've got a farm and you and we pick export
-
13:56 - 13:59to this whole time you were to imports when you are bringing stuff in and now
-
13:59 - 14:01it's finally time for you to give something back to the world in the form
-
14:01 - 14:03of export
-
14:03 - 14:05so what you want to be when you click export is
-
14:05 - 14:08it brings up a little dialogue box sometimes the sand clothes sometimes
-
14:08 - 14:11it's open if it's not a big givers closed
-
14:11 - 14:14an inside job when you click on jar products which you want to bring about
-
14:14 - 14:18sniper and jar like on there for a permanent star if i can act
-
14:18 - 14:20cams can take you through all the steps
-
14:20 - 14:23we need to specify couple things your first we need to specify with in the jar
-
14:23 - 14:27file salmon open up names are for and what i want to put inside the job cause
-
14:27 - 14:30i don't want to have all of name surfer and the jar file it turns out
-
14:30 - 14:33if you throw everything in there including the stuff called dot project
-
14:33 - 14:35not classpath
-
14:35 - 14:37it actually gets a little bit confused to some of those things are not germane
-
14:37 - 14:40to what we want to pack up and our jar there just kind of other
-
14:40 - 14:43uh... administrative information what we really want to have his everything
-
14:43 - 14:45inside the default pack
-
14:45 - 14:48so i just click on before package i can double click on this to make sure that
-
14:48 - 14:50all of my java files are
-
14:50 - 14:54that's what i want to my job i want basically all of my job file for the
-
14:54 - 14:57compiled version of all blanco ob
-
14:57 - 14:58job files
-
14:58 - 15:01and make sure that this is click but by the father just make sure export
-
15:01 - 15:03generated class files and resources
-
15:03 - 15:07so what it's going to do is compiled those java files into that corresponding
-
15:07 - 15:07class files
-
15:07 - 15:09and that's what it's going to put in a jar
-
15:09 - 15:13there are other options like i got export the java source file taiwan it
-
15:13 - 15:15right then i get some of the actual source code
-
15:15 - 15:18most the time you don't want to do this if you don't want people like sort of
-
15:18 - 15:21sniffing for your source code just like there take the compiled by these are my
-
15:21 - 15:24brethren give you the first timers like thirty days and my birth a good point
-
15:24 - 15:27but we've got a given you this works
-
15:27 - 15:28so once we have this
-
15:28 - 15:33waiter now specified where do we want to save this jar file so that's what this
-
15:33 - 15:36you know select the export destination what they should have a status
-
15:36 - 15:38what you want to say that
-
15:38 - 15:41that the export destination so where we want to say that we can browse around
-
15:41 - 15:45where we want to save it is based on hard created a folder that has all my
-
15:45 - 15:46name surfer code in it over here
-
15:46 - 15:50i'm just gonna save the jar found that same folder so this is just in the same
-
15:50 - 15:53folder for my project called names or for that has all of my class files in it
-
15:53 - 15:56you don't put out wherever you want just don't forget where you quit that's kind
-
15:56 - 15:57of the key
-
15:57 - 16:00so this is why i'm going to say that so that's kind of sad
-
16:00 - 16:02up and you don't need to worry about the options down here the options down here
-
16:02 - 16:03just you know
-
16:03 - 16:06they're fine faults that there are
-
16:06 - 16:09then you come here to this point it seems like
-
16:09 - 16:13olney what's going on export file compile errors of compile warnings yet
-
16:13 - 16:15which one export everything we don't care
-
16:15 - 16:17stories click
-
16:17 - 16:21and then we come here this is the most interesting part of the whole thing
-
16:21 - 16:24what we want to do when we actually create this jar file and this is
-
16:24 - 16:28something we only need to do when we have other jar file but the a c ally
-
16:28 - 16:29brief need to worry about
-
16:29 - 16:33wait for what's known as generate a manifest file
-
16:33 - 16:37basically all the manifest file is it's a complicated name manifest in backup
-
16:37 - 16:40investors out forms like all what has been you know it sounds like you're on a
-
16:40 - 16:43boat doesn't like to have the cruise director and i like all words the
-
16:43 - 16:44passenger manifest
-
16:44 - 16:47wrote a column manifested austin emphathize like two month long and then
-
16:47 - 16:50you add one lines when it becomes three lines one
-
16:50 - 16:54it's basically just a little bit of administrative information that's capt
-
16:54 - 16:55around with your jar file
-
16:55 - 16:59so knows all what kinda stuff for you using with this jar file that's really
-
16:59 - 17:00all it is
-
17:00 - 17:03so what we want to do is generate the manifest file we make sure save the
-
17:03 - 17:06manifest in the workspaces check which it should be if you click generate and
-
17:06 - 17:07test file
-
17:07 - 17:10and then you need to specify where you want to save the manifest file
-
17:10 - 17:13and the place i want to say that is basically in the same folder for my name
-
17:13 - 17:17sir for project in the name manifests are usually the name you give it a good
-
17:17 - 17:18browse around if you want to
-
17:18 - 17:21but usually the name you give it is the name of the folder that all your project
-
17:21 - 17:25stuff sent and then the name manifest destiny than actual name
-
17:25 - 17:26answer any questions about that
-
17:26 - 17:27manifest off
-
17:27 - 17:30the other thing you need to do when you're specifying a georgia george just
-
17:30 - 17:32a bunch of classes
-
17:32 - 17:34it needs to know in some sense
-
17:34 - 17:37if someone can that running this chart with you actually you'll see that in
-
17:37 - 17:39fact you can run a jar
-
17:39 - 17:42where should it start which class is the one
-
17:42 - 17:44of which i should call its main
-
17:44 - 17:48and that's what you specify here select the class of the application entry
-
17:48 - 17:49points
-
17:49 - 17:51is kind of a very formal way of saying
-
17:51 - 17:54where should i start running
-
17:54 - 17:58so the place i want to start running is it lists you all of the classes
-
17:58 - 18:01that have a main method for those are all the ones and start running some
-
18:01 - 18:05names are for the only one i click up and so it says the main classes name sir
-
18:05 - 18:09and now there's no more next buttons now i can do is put finish
-
18:09 - 18:14and i just created a juror
-
18:14 - 18:17and you like are you guys got doubleclick doubleclick
-
18:17 - 18:18or not there yet
-
18:18 - 18:21now there's two things that you'll notice if you look over here in the
-
18:21 - 18:23package explorer
-
18:23 - 18:26you'll notice now we have something called a manifest fark is that's why i
-
18:26 - 18:26saved it
-
18:26 - 18:30and i also have names surfer jot dot jar the jar file i just created they were
-
18:30 - 18:33both put in the same folder with my other
-
18:33 - 18:36you know files that's why i want to save them so they have michelle from the
-
18:36 - 18:39package explore now you're the funky things
-
18:39 - 18:43even though we created this manifest in created this jar they don't have quite
-
18:43 - 18:46the right information that we want to what we do is we double click on the
-
18:46 - 18:48manifest file to open it up
-
18:48 - 18:49here's the whole manifest file
-
18:49 - 18:52it's got a version which is one point no
-
18:52 - 18:55and it's not the main class which is named surf why does it know the main
-
18:55 - 18:58classes nameserver
-
18:58 - 19:01cuz i told it right that the application entry point just forward
-
19:01 - 19:04letting me know that i told it
-
19:04 - 19:06that's why the application starts
-
19:06 - 19:08now there's one other thing i need
-
19:08 - 19:10besides ducking for cover one can you get started
-
19:10 - 19:13what i need to do it i need to say hey you know what
-
19:13 - 19:15names are free and i think it's time
-
19:15 - 19:18but you also need to use the aclu libraries and it says
-
19:18 - 19:21how yet you didn't tell me about the same i've written you say well now i'm
-
19:21 - 19:22going to add
-
19:22 - 19:27the coveted third mondale and talked about in the manifest fosamax modify the
-
19:27 - 19:27manifest file
-
19:27 - 19:30at something called the classpath
-
19:30 - 19:34and all of class that is it's actually looks just like this capital c dash
-
19:34 - 19:35capital p
-
19:35 - 19:37classpath just tells basically
-
19:37 - 19:39uh... the application
-
19:39 - 19:43what other stuff for using are there other jar files that you're using and so
-
19:43 - 19:45what you specify here
-
19:45 - 19:49is the name of any jar files that you're going to be using as part of your
-
19:49 - 19:51program separated by space
-
19:51 - 19:55some unease pcm dodge are here is a cm najjar overhear has
-
19:55 - 19:58i'm way you'd be a cm libraries no drawn some jar file
-
19:58 - 20:02and i'm also going to use the jar file i just created name surfer dot jar
-
20:02 - 20:06if i had three or four more jar file that list them on the same line so if
-
20:06 - 20:09you were going to write an application someday where you're like
-
20:09 - 20:13hey i got this drop off my friend here the job by downloaded from the web which
-
20:13 - 20:14i wouldn't encourage you to do
-
20:14 - 20:17and hear the sardar falcon somewhere else his list of all your space in
-
20:17 - 20:18between
-
20:18 - 20:22and then you save the file that's the problem most difficult thing that people
-
20:22 - 20:24forget it saved the fosse save the manifesto
-
20:24 - 20:27and now what exactly do all this
-
20:27 - 20:31created jawahar all over again placard
-
20:31 - 20:32wife it's just like misaddressed
-
20:32 - 20:34here and i was going to work
-
20:34 - 20:37he recommended a little bit different if i'm robin dong a file maneuvering export
-
20:37 - 20:39i'm going to take the advanced ports i'm going to write
-
20:39 - 20:42like on the project name pick export
-
20:42 - 20:45just says that brings up exactly same window
-
20:45 - 20:47i'm going to export a jar file
-
20:47 - 20:50i come over here why do i want to export sorry abt all this crap eunice again
-
20:50 - 20:53what i want to export is not all the stuff i just want to export everything
-
20:53 - 20:55in my default
-
20:55 - 20:59why do i want to say that i want to save it in the same place i had before you
-
20:59 - 21:00might say but now im
-
21:00 - 21:03aren't going to replace the one that already exists
-
21:03 - 21:07i need to replace the one that already exist updated my manifest i need say hey
-
21:07 - 21:09buddy it's not just about you anymore
-
21:09 - 21:14now it also involves a cm judge our like okay okay you can replace the old
-
21:14 - 21:16so i'm going to put it in the uk
-
21:16 - 21:17places before
-
21:17 - 21:22now a quick next here's the thing about export warning export baritone karen
-
21:22 - 21:22export
-
21:22 - 21:25here is the only place where things are different
-
21:25 - 21:29the second time i go through this whole thing i don't want to generate another
-
21:29 - 21:30manifest file
-
21:30 - 21:34cuz i generated a manifest file the first time and then i modified
-
21:34 - 21:39what i want to do is use that modified to manifest file so i say use existing
-
21:39 - 21:41manifest from workspace
-
21:41 - 21:42which is again just a formal way of saying
-
21:42 - 21:45yeah use the manifest part are you there
-
21:45 - 21:48asked me where they manifest on strangely enough if you look
-
21:48 - 21:52this is exactly the same tax this year
-
21:52 - 21:54yang belgrade's it it's like
-
21:54 - 21:58while real broader trapping the suns out everyone singin in the streets
-
21:58 - 22:00that's you know you just say that that's the one you want to use its going to be
-
22:00 - 22:02the same name
-
22:02 - 22:03and now i noticed this
-
22:03 - 22:05which class of the entry point is great out
-
22:05 - 22:09it's great acts like a little bit before your entry point is named surfer
-
22:09 - 22:12that's in the manifest file if that's already in a manifest on using it
-
22:12 - 22:16doesn't need to know what again so it doesn't even like me specified again
-
22:16 - 22:17so you know that's different
-
22:17 - 22:18and then i click finish
-
22:18 - 22:21and give me one last warning you sure you want to over i got last drop on he
-
22:21 - 22:25was your friend he was hanging out with you since the beginning about
-
22:25 - 22:27three minutes ago and i say yes long way
-
22:27 - 22:30we we know each other that long thanks for playing
-
22:30 - 22:33now i've created this drop on your life
-
22:33 - 22:33primary
-
22:33 - 22:36what you do now
-
22:36 - 22:39i come over here and i said
-
22:39 - 22:42or the jar file displayed
-
22:42 - 22:44one thing i can do it the drop by the n_ double click on it
-
22:44 - 22:47and by double click on the jar file
-
22:47 - 22:50it just starts kicking off the names are propagation
-
22:50 - 22:54right i don't need a clips anymore to go and ron and have little run big compile
-
22:54 - 22:59i have a lap haitian unlike our yeah bob how popular it right now bob kind of
-
22:59 - 23:02alfono means on that some other interesting ones are going to be the
-
23:02 - 23:05other night off
-
23:05 - 23:07six after the sixties
-
23:07 - 23:09dawn done deal thanks for playing
-
23:09 - 23:12so can you name your children vermont make a comeback
-
23:12 - 23:15and so he interpret just kinda running here and it's fun it's just a little
-
23:15 - 23:16stand-alone application
-
23:16 - 23:19now if you want to pack it to the sop and send it to a friend of yours what
-
23:19 - 23:23you would actually do he wouldn't just sending surfer about dot jar
-
23:23 - 23:26what you would do is you would say hey you know what i want to do
-
23:26 - 23:28i want to create
-
23:28 - 23:29i'll i'll just do it in here
-
23:29 - 23:31some new folder
-
23:31 - 23:35so i'm going to create some new folder and all call this my programmer whatever
-
23:35 - 23:37you want to call him talking to call it mean surfer again ferreting out for the
-
23:37 - 23:39call mister my program
-
23:39 - 23:41and want to put my program
-
23:41 - 23:42that folder
-
23:42 - 23:44if the jar
-
23:44 - 23:45of my program
-
23:45 - 23:50also going to put in the jar obviously enlai break as i also need that kind of
-
23:50 - 23:50separate
-
23:50 - 23:55and i also need in here and he gave the files like names dot data and not names
-
23:55 - 23:58dash data reading about all the data to get reading on the program starts it's
-
23:58 - 24:01not like magically that's just going to be very down right it's not going to go
-
24:01 - 24:03in try to find out file
-
24:03 - 24:04so i need to put all this stuff here
-
24:04 - 24:07and now this folder or something i could zip up and sent to a friend of mine on
-
24:07 - 24:09my friend get so they would be like all
-
24:09 - 24:11nature provides our
-
24:11 - 24:13and then they go
-
24:13 - 24:16so now you can package up any program that you've written in this class
-
24:16 - 24:17remember to put in maine
-
24:17 - 24:20you got to go through started this to part
-
24:20 - 24:24create the jar exporter process modify the manifest great other jar put it out
-
24:24 - 24:25there again
-
24:25 - 24:26but you're going to go
-
24:26 - 24:28face any questions about that
-
24:28 - 24:31now you can package up in and share with friends
-
24:31 - 24:34now what's even cooler than sharing with friends that you could email stuff too
-
24:34 - 24:36is share with friends on the web
-
24:36 - 24:39as you just have mike you know millions of fans on the web most of the leaders
-
24:39 - 24:42don't know about but they're probably you know in the late hours of the night
-
24:42 - 24:45looking at your web page that exist
-
24:45 - 24:46and you can actually take
-
24:46 - 24:48anne
-
24:48 - 24:51files that you crave your like jar files and make them available in a web browser
-
24:51 - 24:54now there's one other thing i should mention the scandal thing before you
-
24:54 - 24:55send now you go
-
24:55 - 24:59credo messed up and send it off your mom or dad died monday i break our book why
-
24:59 - 25:00it's a good time
-
25:00 - 25:04in order for them to run your job clouds they need to have the java runtime
-
25:04 - 25:05environment install
-
25:05 - 25:09i remember on like the second week of class when we said although it is just
-
25:09 - 25:10one oh six website
-
25:10 - 25:14you need to download eclipse there's a thing called the jr you also need to
-
25:14 - 25:15download
-
25:15 - 25:15if you have a map
-
25:15 - 25:19the jerry in most cases already installed if you have windows it's not
-
25:19 - 25:19installed
-
25:19 - 25:23they need to go and down you can actually sent into the cfo_ six pages
-
25:23 - 25:27a day download the gary here is a copy of my cannot five
-
25:27 - 25:28go ahead and install it
-
25:28 - 25:31and then they can run your programs because your program can't run if you're
-
25:31 - 25:34poor if the computer doesn't have a job or write it's a bunch of stuff is going
-
25:34 - 25:36to execute java bytecode
-
25:36 - 25:36if you'd like
-
25:36 - 25:39what java bytecode allen told me were java bytecode is
-
25:39 - 25:42i don't know what to do with it and so i won't run into any of the java runtime
-
25:42 - 25:43environment
-
25:43 - 25:47now assuming of johnson's summer have the java runtime environment
-
25:47 - 25:50they could go to take a web page
-
25:50 - 25:52and you might put some page on the web
-
25:52 - 25:56yeah allows you to load your applicant your ap lit is just in web applied
-
25:56 - 25:58version of your program
-
25:58 - 25:59and so here
-
25:59 - 26:02all look it's running inside a web browser right this is of the actual
-
26:02 - 26:07application this is my web browser or cuz i could like from here go to
-
26:07 - 26:07you know
-
26:07 - 26:10i don't know some search engine
-
26:10 - 26:12right i'm sittin in the web browser
-
26:12 - 26:14i'm not just running a regular application
-
26:14 - 26:18on my desktop but this guy's actually running in my web browser
-
26:18 - 26:20how did i make that happen
-
26:20 - 26:21here's how i make it
-
26:21 - 26:24i create a web page
-
26:24 - 26:27if you don't know about age ten on creating web pages
-
26:27 - 26:30unfortunately i can explain that to you and five minutes
-
26:30 - 26:33but what i can show you is basically what this bosnia look like so if you
-
26:33 - 26:37know a little bit of html or you just want to essentially copy and paste this
-
26:37 - 26:38idea
-
26:38 - 26:39this'll work for you
-
26:39 - 26:43so all you do as you say i want to decipher the entire page that generates
-
26:43 - 26:45that allows your applicant run
-
26:45 - 26:48usse this page's html state is all things called pat
-
26:48 - 26:53the name of that page is named surfer an acquittal table on the cradle border
-
26:53 - 26:56around my applications but i want to business
-
26:56 - 26:59what's my application my whole updation is right here
-
26:59 - 27:01i have a catholic
-
27:01 - 27:03what's the name of the archive
-
27:03 - 27:08which is a java archive the contains my applicants name surfer dot jar
-
27:08 - 27:11code is what's the entry point right this time no longer have the manifest
-
27:11 - 27:14file available to it so it does what's my entry point
-
27:14 - 27:18named jeffrey dot class that's where you start running felt that i want to go to
-
27:18 - 27:20nature for dot class fine with me now if i start running
-
27:20 - 27:23and the space i'm going to give you are running on the screen is five hundred
-
27:23 - 27:24seven hundred by five hundred
-
27:24 - 27:26and that little snippet of code
-
27:26 - 27:30is what goes on whatever web surfer this webserver this is sitting on
-
27:30 - 27:32looks for those job clouds
-
27:32 - 27:36slaps them into the page and then someone good to go to running for java
-
27:36 - 27:38program inside of us
-
27:38 - 27:41just wondered how many people know html
-
27:41 - 27:45you folks are over summer some number folks that this might be reasonable
-
27:45 - 27:48thing to do if not you just don't need to worry about it it's not a big deal
-
27:48 - 27:51just send the application your friends
-
27:51 - 27:54the one i can use you know if you create a little webpage
-
27:54 - 27:57is that when something is running on the web page it does not have access to the
-
27:57 - 27:59rest of the files
-
27:59 - 28:01what that means is
-
28:01 - 28:06if i actually happened to be over here notice i have index dot html i have name
-
28:06 - 28:09surfer dodge are not have a cm dot rar
-
28:09 - 28:12what happened to my name's dash datafile
-
28:12 - 28:14yet it doesn't exist
-
28:14 - 28:17why doesn't exist 'cause i couldn't really anyway 'cause once i'm running on
-
28:17 - 28:21the web browser for security reasons it doesn't let you get going to pull stuff
-
28:21 - 28:23out of your files
-
28:23 - 28:27okay 'cause evaded people could you really bad things your computer
-
28:27 - 28:30what you need to do if you're like a mountain where is that data you you
-
28:30 - 28:33minus running show from the web what'd you do
-
28:33 - 28:36yours fears the dirty little secret
-
28:36 - 28:39actually created giant array that had all the data in it
-
28:39 - 28:41and made a part of the program
-
28:41 - 28:44so sometimes you can do stuff like that if you don't want to actually read from
-
28:44 - 28:45a file
-
28:45 - 28:48the other thing you can do is you can take those files and include them in the
-
28:48 - 28:49jar file
-
28:49 - 28:52to the jar copy not only have compiled class in the cars have data files about
-
28:52 - 28:55another way of doing if you want to do it
-
28:55 - 28:58but we just don't have time to talk about the decals those kind of the same
-
28:58 - 28:58process
-
28:58 - 29:03and when you're exporting stuff the dropped by use of something data files
-
29:03 - 29:05so that's clearly executed
-
29:05 - 29:08now i know that we know all this funky stuff about all acts to go back put on a
-
29:08 - 29:12web page if i want to just like you know feel unhappy i'm going to go
-
29:12 - 29:15it's time to come back to our friend
-
29:15 - 29:18standard job as a standard java what kind of allowed us to all you know think
-
29:18 - 29:20about doing to stop as we learned about me
-
29:20 - 29:24and i want to show you a couple examples of program could actually don't use the
-
29:24 - 29:25aclu libraries at all
-
29:25 - 29:28to show you why we use the a c my brisket one thing you might be wondering
-
29:28 - 29:30if
-
29:30 - 29:34why weren't we just doing the standard java thing the whole time
-
29:34 - 29:35and part of the reason is
-
29:35 - 29:39things are just so much easier and cooler when you have the same way myself
-
29:39 - 29:41we go back over to a close
-
29:41 - 29:44we're coming down with names are for an office manifesto
-
29:44 - 29:48here's a program that's written in standard java rights at hello world on
-
29:48 - 29:50the screen
-
29:50 - 29:53this is something you could down in the first class by saying public last hello
-
29:53 - 29:56world extends console program imprint lane
-
29:56 - 29:59hello world out to the screen and you would have gotten it in the consul
-
29:59 - 30:03so what's different here what's different here is we have public last
-
30:03 - 30:04hello world
-
30:04 - 30:07and it doesn't extend anything it doesn't extend program doesn't extend
-
30:07 - 30:08concord program
-
30:08 - 30:13there's no imports for the a c l_ libraries we're not using any defense
-
30:13 - 30:17so we don't have a console program we don't have a nice little consul
-
30:17 - 30:20but we white stuff out to this displays a nice little window
-
30:20 - 30:24while we do have a something called the system output consul and if we want to
-
30:24 - 30:28put stuff on back it looks real seller to what you had before we'd use print
-
30:28 - 30:32land which is why we made the method that you use call prints match theirs
-
30:32 - 30:37but weeks a systemic dot out dot println text one print out
-
30:37 - 30:40again here i have a meaner it might mean that they can have whatever i want and
-
30:40 - 30:42that's just for execution starts
-
30:42 - 30:43so if i compiled list
-
30:43 - 30:45and running
-
30:45 - 30:47let me just compile and run to show you why
-
30:47 - 30:51hello world in kind of this world is not all that cool
-
30:51 - 30:53careful our world
-
30:53 - 30:54it just ran
-
30:54 - 30:59and they're like partner and i don't see anything
-
30:59 - 31:02cuz you don't get a call we know that comes up is like a lower over here i am
-
31:02 - 31:04on this window for a budget act
-
31:04 - 31:06you have what's called the system console
-
31:06 - 31:10the system console like you happen to be using a development in violent like a
-
31:10 - 31:11klutz or something else
-
31:11 - 31:14is basically just a window in that development environment that shows
-
31:14 - 31:16messages that you print out
-
31:16 - 31:19if you happen to be in the bad old days but i think i raised over here where you
-
31:19 - 31:22have command-line text we actually type stuff in
-
31:22 - 31:25because i would just be that same window where the text would appear where you
-
31:25 - 31:26can't
-
31:26 - 31:30so if you don't get it in a separate we know it is not all that will get a lot
-
31:30 - 31:34of times would notify closed anyway so you don't see a
-
31:34 - 31:38now if we want to pick up a notch it's a token on yahoo so wide use the consul
-
31:38 - 31:42one i do something graphical so here's graphical hello world
-
31:42 - 31:44and so what we want to do is
-
31:44 - 31:45we want to create a window
-
31:45 - 31:49a new window that is going to have some title associated with it and we're going
-
31:49 - 31:52to put the text hello world in that window
-
31:52 - 31:55why we need to do what we get worse to excuse respectively
-
31:55 - 31:58we need to create something called a j three in which you never have to worry
-
31:58 - 31:59about before
-
31:59 - 32:02what they gave frame it's actually a frame that's going to pull the window
-
32:02 - 32:05so it's actually one week run we're going to start running rapidshare
-
32:05 - 32:09it's going to create a little window force that we can display stuffing
-
32:09 - 32:10well we're going to put in that window
-
32:10 - 32:13we're going to put a label j labeled you've seen before this is just like
-
32:13 - 32:14you've seen before
-
32:14 - 32:17we're going to create a j label that's called hello world
-
32:17 - 32:20and we want this label to be centered justified as opposed to left just
-
32:20 - 32:24fighter rightist five tiny stage a label dot center to center justified
-
32:24 - 32:28if i don't give a destination it'll by default be left justified looked kind of
-
32:28 - 32:29because one attacker
-
32:29 - 32:32and then i grabbed this label to my frame
-
32:32 - 32:36so similar to the idea cabinet can listen adding stuff to the candice's
-
32:36 - 32:39exactly analogous right we want to make it just as easily when you saw standard
-
32:39 - 32:39java
-
32:39 - 32:41all the same concept applied
-
32:41 - 32:45here were just adding the j label which as you know now is a g component in the
-
32:45 - 32:47big java hierarchy
-
32:47 - 32:50and j components can be added to ge frames
-
32:50 - 32:52so we have a jail able to get at a twenty three
-
32:52 - 32:56i set aside tragic frame which is five hundred by three hundred that tells me
-
32:56 - 32:58how big the windows going to be when it starts
-
32:58 - 33:01and then there's the other crafty stuff but i need to do that just you would
-
33:01 - 33:02think alike
-
33:02 - 33:05why do i need to do that right it's just doesn't make any sense
-
33:05 - 33:09that i would not otherwise want to have it this way what you're going to do
-
33:09 - 33:12if someone clicks close on the window a little x the top of the screen to close
-
33:12 - 33:12the window
-
33:12 - 33:14i need to say hey
-
33:14 - 33:18if son click that then you need to close yourself otherwise the window by the way
-
33:18 - 33:20the application keeps running
-
33:20 - 33:23which seems odd but we need to have that they're pretty optician stop running
-
33:23 - 33:24and then we think
-
33:24 - 33:27window yeah i know i created un everything
-
33:27 - 33:28you need to make yourself visible
-
33:28 - 33:31otherwise no one will be able to see you
-
33:31 - 33:35why when i pray that we know that i was i going to make a visible
-
33:35 - 33:37that's how we use the a c l_ libraries
-
33:37 - 33:40so we need to make sure that this guy visibility is true
-
33:40 - 33:42and appear on this
-
33:42 - 33:45you're a graphical hello so after all the squawk to write
-
33:45 - 33:51yours graphical lovro
-
33:51 - 33:55we do have one and all of that explain to you so that you could get hello world
-
33:55 - 33:56bring your like
-
33:56 - 34:00somewhere in the social now work in a corner need to worry about how the world
-
34:00 - 34:01in the middle of my screen
-
34:01 - 34:03that's cuz you have this new hybrid
-
34:03 - 34:07so like okay let's let's keep it up even one more not shit you know i couple
-
34:07 - 34:10right what are those now stopping interaction like that should be
-
34:10 - 34:14something that maybe you know i get some benefit from having to stand for java so
-
34:14 - 34:16out of interactive version of hello
-
34:16 - 34:19through the interactive version of lalo na some of the stop should begin to get
-
34:19 - 34:22a little bit more
-
34:22 - 34:24repetitive in the sense that you have your main you have your j frame the
-
34:24 - 34:27frame is called interactive flow that's the title of that window
-
34:27 - 34:30what we're going to add to this day play with a new
-
34:30 - 34:32class that we're going to create called a moving label
-
34:32 - 34:35and i'll show you what a moving label doesn't just second but we need to set
-
34:35 - 34:36aside the window
-
34:36 - 34:40again set default close operation exit on clothes
-
34:40 - 34:44and set visibility to true so baseball this does is create this window or
-
34:44 - 34:45particular size
-
34:45 - 34:48and if you add this thing called a moving label to it and moving label just
-
34:48 - 34:51another class i create what's a movie label
-
34:51 - 34:54a moving label is a j component
-
34:54 - 34:57it needs to be a gay component because i want to add a tool for
-
34:57 - 35:01and to display something to frame i what i can only display components knapp
-
35:01 - 35:03brings this can extend component
-
35:03 - 35:05and it's going to implement our friend of mouse listener
-
35:05 - 35:08because it's going to listen for the past year what all i remember mouths
-
35:08 - 35:11listener that's why like the mouse got click and drag at all that stuff sans
-
35:11 - 35:12act the same
-
35:12 - 35:16so i have my construct ojai constructor had to have some starting texas label
-
35:16 - 35:19and starting x and y location
-
35:19 - 35:21thatcher what kind of familiar to you
-
35:21 - 35:24anti based i guess tore off the tax expert yet to like
-
35:24 - 35:26and this guy wants the lesson from out of that
-
35:26 - 35:30so ted adam else listeners and it needs to say
-
35:30 - 35:31if you get some out of that
-
35:31 - 35:35send them to me to send them debits switches
-
35:35 - 35:38so this a little bit different than what you've written in your programs before
-
35:38 - 35:41where you just said you know adam alice was knowing you didn't you just had an
-
35:41 - 35:46open print close pronounced 'cause we kind of poop
-
35:46 - 35:49naturally by things get a little bit funky
-
35:49 - 35:53the difference between this and thinking about having some sort of label that you
-
35:53 - 35:56just display on the campus right some taxes just put up on your canvas and it
-
35:56 - 35:58just sits there and it's fun
-
35:58 - 36:02is that this guy i know i have to worry about what's known as painting itself
-
36:02 - 36:05which means it needs to draw itself on the screen your like but when i have
-
36:05 - 36:08labeled before they just knew how to draw themselves
-
36:08 - 36:11yeah that's because we gave you a label does a little bit smarter knew that it
-
36:11 - 36:12was a label that should rockville
-
36:12 - 36:16this guy needs to be told you're going to draw yourself
-
36:16 - 36:19though that they call paying component that gets called whenever this guy
-
36:19 - 36:22should get displayed on the screen or some other thread that's going to call
-
36:22 - 36:23the for you automatically
-
36:23 - 36:26and it says here is the graphics
-
36:26 - 36:27context in which a dryer self
-
36:27 - 36:30safely within our graphics contact somebody draw some strength
-
36:30 - 36:33and that's a method name everything is not important here i just showed you
-
36:33 - 36:36those extra craft you need to worry about right which is why we didn't want
-
36:36 - 36:38to do all the stuff began
-
36:38 - 36:42now this booking steamy or whatever the mountains clicked i get the new acts
-
36:42 - 36:43wire location
-
36:43 - 36:44and i repeat
-
36:44 - 36:47what is repaint meaning to redraw yourself
-
36:47 - 36:52and i'm going to redraw myself at this new xy location because when i call
-
36:52 - 36:53repaint
-
36:53 - 36:56someone comes along and says hey to repaint this area
-
36:56 - 36:59i'm going to call dual pane component method so you can read paint yourself
-
36:59 - 37:00you like
-
37:00 - 37:04well this is really we are now in like almost we're here i get a mouse click
-
37:04 - 37:08and i know that i want to drop my sri drama itself but rather than telling
-
37:08 - 37:09myself directly to redraw myself
-
37:09 - 37:13i don't tell the system paid i'll need to get repainted in the systems as
-
37:13 - 37:14possible
-
37:14 - 37:15uh... as the sort of like
-
37:15 - 37:20you know that java high allison arafat happiness are pointed you want to know
-
37:20 - 37:23like you need tear
-
37:23 - 37:25someday if you act like they were anti-war
-
37:25 - 37:26we won't get in
-
37:26 - 37:29units i can breed on partner
-
37:29 - 37:30other hot
-
37:30 - 37:33you know i think i need to repay my topic how to fix that those are ok you
-
37:33 - 37:37need repairs are four one i'm ready for you to repeat yourself
-
37:37 - 37:39all call your pain components method
-
37:39 - 37:42until then no no you don't repeat itself
-
37:42 - 37:45and saturday that's other stuff in the system to worry about all yall in there
-
37:45 - 37:46with you you have to get repainted
-
37:46 - 37:49okay now call your pain component you come a long thick
-
37:49 - 37:52all cable nominee promised off the new act violently
-
37:52 - 37:55so kinda convoluted the whole notion of like
-
37:55 - 37:59you're doing something here and you're asking someone else to do something for
-
37:59 - 38:03you and i'm going to call you back to do what you were julian sands
-
38:03 - 38:07now makes a little bit more sounds after we talked about directed at you've seen
-
38:07 - 38:09all the stuff
-
38:09 - 38:11thurday class not so hot
-
38:11 - 38:14so if we were on this
-
38:14 - 38:17this is called up interactive hello
-
38:17 - 38:20base but where does it just brings up the article that sixty s by six a rocks
-
38:20 - 38:23in the middle of the straight and not everytime i click them
-
38:23 - 38:26mouse button right because this is the mouth with the bank over here
-
38:26 - 38:28everytime i click the mouse button
-
38:28 - 38:32the x_ y_ location of the mouse becomes the new base point
-
38:32 - 38:33for the tax they get stronger
-
38:33 - 38:37and so i just moved to rounds
-
38:37 - 38:40any questions about that
-
38:40 - 38:41so there's a standard java
-
38:41 - 38:45you've seen all the concepts in the a c we using the atm_ i've read the
-
38:45 - 38:48concepts rather saying the notion of adding things and i should have about
-
38:48 - 38:51seles has not affect the whole mouth listeners concept we just took the
-
38:51 - 38:56standard job ideas and use them sort of in conjunction with used him libraries
-
38:56 - 38:58but there's a lot of things in the a scam i break it just made it so much
-
38:58 - 39:02easier to like for example b graphics contest entries or to write a social
-
39:02 - 39:05network for whatever and say you're welcome to continue using the atm_
-
39:05 - 39:07library dot
-
39:07 - 39:10but some people are wondering wide will use these libraries and this is the
-
39:10 - 39:14reason why there's just a whole lot of propped you'd have to worry about
-
39:14 - 39:20i'm question
-
39:20 - 39:24you'd be use in like you know your favorite word processor like notepad
-
39:24 - 39:28and there's actually some places which i won't you know name but that there is
-
39:28 - 39:31it's actually reasonable that you know that some schools and your first
-
39:31 - 39:34programming class what you do is they say while you need to have like no
-
39:34 - 39:36pattern you need to have some text editor
-
39:36 - 39:39and then we're gonna do command-line stuff you're gonna type in like name
-
39:39 - 39:43surfer names dash data dot textron your program and then everything's gonna be
-
39:43 - 39:44taxed
-
39:44 - 39:48so one thing i want to leave you with now in our final few moments together
-
39:48 - 39:51sort of a notion we were starting to meet next week talk about life after the
-
39:51 - 39:54five had to give you notion that if you want to go on in terms of learning more
-
39:54 - 39:57about java specially standard java
-
39:57 - 40:01we said i just started things off by giving you you know this book which
-
40:01 - 40:04talks all about the cm libraries and this i think is a great book to actually
-
40:04 - 40:06learn everything with a new vcm libraries
-
40:06 - 40:12but if you want to go on worth of other resources you can use
-
40:12 - 40:16that's not pretty if you don't like the java section of any bookstore just would
-
40:16 - 40:20be practiced a while one but i would recommend not that i get my kickbacks
-
40:20 - 40:23restart called learning job a it's actually pretty good time some of the
-
40:23 - 40:27examples just off your actually based on this book it's a little bit
-
40:27 - 40:30that's why we don't use the text book in this class if in fact and we get up did
-
40:30 - 40:32we break two thousand page mark
-
40:32 - 40:36all right so close it so close with the index
-
40:36 - 40:41now in nineteen
-
40:41 - 40:44that some other books that actually the original specification of the java
-
40:44 - 40:47programming language the same older version of the book is this is one that
-
40:47 - 40:49was like a week candidate if you are not the old version
-
40:49 - 40:52i forget which version of acting out a second edition i think now there are
-
40:52 - 40:54like three or four some impact
-
40:54 - 40:55looks a little bit bigger birds actually
-
40:55 - 40:59four books it specifies the language job it's actually very well written as a
-
40:59 - 41:02reference inside of recommend this as well
-
41:02 - 41:05if you're going to like all i want it all
-
41:05 - 41:06the big job
-
41:06 - 41:07is vague
-
41:07 - 41:11i think it might actually crossed the thousand page all yachts like thousand
-
41:11 - 41:14the spirits like twelve hundred
-
41:14 - 41:17and if you really want to get a hard time like but now i'm all about web
-
41:17 - 41:19based java
-
41:19 - 41:23java server programming like everything or do i like a lot of things you don't
-
41:23 - 41:26want to know if whatever they want to know one more
-
41:26 - 41:28and that's just a small set
-
41:28 - 41:31right so they're just a few bucks i'd recommend if you want to go on beyond
-
41:31 - 41:32this class
-
41:32 - 41:35but you can go into any bookstore news get inundated with a ton of stuff but
-
41:35 - 41:39now you have a context for kind of putting all the pieces together because
-
41:39 - 41:41you've seen all the other things that you actually need to know to be able to
-
41:41 - 41:46work with the huge set of tools that job actually
-
41:46 - 41:49so any questions about any of our staff
-
41:49 - 41:50you're going to go
-
41:50 - 41:53alright power to a couple minutes early cuz most the time i like to go a couple
-
41:53 - 41:55minutes late
-
41:55 - 41:55have a good weekend
- Title:
- Lecture 26 | Programming Methodology (Stanford)
- Description:
-
Lecture by Professor Mehran Sahami for the Stanford Computer Science Department (CS106A). Professor Sahami lectures non-standard Java and shows the class a few books he recommends for further readings on Java.
CS106A is an Introduction to the engineering of computer applications emphasizing modern software engineering principles: object-oriented design, decomposition, encapsulation, abstraction, and testing. Uses the Java programming language. Emphasis is on good programming style and the built-in facilities of the Java language.
Complete Playlist for the Course:
http://www.youtube.com/view_play_list?p=84A56BC7F4A1F852CS106A at Stanford Unversity:
http://www.stanford.edu/class/cs106a/Stanford Center for Professional Development:
http://scpd.stanford.edu/Stanford University:
http://www.stanford.eduStanford University Channel on YouTube:
http://www.youtube.com/stanford - Video Language:
- English
- Duration:
- 42:11