lower on the evolutionary ladder there just before we refer to the permit types when you pass primitive types as parameters what you're getting is a copy of the value of the primitive type what does that mean amy what i call some function and i say hey function on the past you eight three like in my move method over here i pass in a three which is in a major what actually happens when i make this method call as i passed eight copy of the three and so it does move method i try to change this value around to something else all i'm doing is changing the copy i'm not changing the actual parameter that was passed and so if this wasn't about you but sad to have some variables here accent and why and up here i had interest and why when i make this method called i get copies of whatever values are in the boxes for x and y and so if move triste amok with x unlike although changing is the copies not changing the ex-wife out here right that's what we talked about a long time but we talked about little maryland one off to france with mom in the mona lisa you wanted hacksaw damone lease up with my lease they just got a copy because it wants the gift shop yeah primitive types you go to the gift shop something funky happens though when you're dealing with objects okay so when you're dealing with objects they are not primitive types there are ject and so when you make it a method call where you pass some object along what you are actually dealing is you are passing the object practically what we refer to is the object preference what does that actually mean what that means is let's say i called her to call some method over here where actually pass in a point so let's say there's some method over here are like all movement throughout college is the around which is supposed to set up twenty hero and i pass it p one and this is just some method that i wrote maybe them the elements of the pointer actually public let's say the poster private to this function can actually access those things what happens when i pass p one well what happens when i pass key one to this change zero method or this change zero function is i'm passing where p one lives so the premature i actually passed is the address that same yourself you dress that's in here as let's say the value you know eight zero zero zero i pass is my prayer murder in hero zero zero which means what i have is a referance because i have that pointer to where p one a really lives in memory which means if thats method decides that it's going to muck around with p one himself a p one move yourself to some other location the values that it's going to change when it makes method called on the parameter of its past in is at this place in memory 'cause it knows where this place in memory is right you want to think about when you're passing objects this is as we talked about it before sort of like the mafia when you pass around objects are talking to a mafia and when you talk to him off yet they know where you live they can come in and mess with you have a want they are not getting a copy of the unified and a m off you know i call i'm going to send mike alone along to the copy and you know or mike lotta long them off you know this offer them now when you're going to go talk to like the godfather of the godmother you're not sending in your call you're going or self right you know i ko godfather and he's like oh you come here on the day i my daughter's wedding here in that sense and seen the movie the godfather itself but if you haven't seen a go see it but will in fact about that right now we will talk about is the fact that if they know where you lead any changes you make a right onto a copy and that's a critical idea to know that is what we were for two up here past byte value because what you're getting is just a copy of the value you're not getting the referenced this is what we actually referred to as passing by object reference so i'll just change the dock here toolbox which means when you pass object around your pass their reference to the object you know where the object let here's a little way you can think about it to remember our story about little may run who goes to see the mona lisa think about it this way one where i want to see the mona lisa again here is the mona lisa smiling here's a little marron provided marron ponytail chainsaw when he wants to actually if the mona lisa were just some integer he's going to go to get a job he's doing a copies but the mona lisa is actually something it's really valuable so what we do with them only so it's going to capsule a didn't speak safe that's a object and so when we want to say send the mona lisa over to my como my new york not that they would action displayed at the moment but let me send it to the moma new york we're sending the actual mona lisa we're not sending a copy of them only so we're sending the actual think so then the my new york not comes along and says hey you know what securities much more lax here understand shop this thing up so it takes to change not to them only son chops it up and that's the real mona lisa so when we're done with it being displayed at the moment and it goes back to our frontal loob grandparents so here it is in perry yeah it's still sliced in half bad times major international instead don't let this happen to you if you're going to mess with an object that's passed around and know that you're changing the actual object so one thing you might say about this he said hey maryland you were saying talking about mona lisa encapsulating them an object so if i have some integer and i actually want to change it could i create an object around in a major and then pass the objects and allow someone else to change the integer inside that object would that work in fact that word and if you're interested in doing that there is an example the does exactly that on page two hundred thirty-five the book just it is important to memorize every single page of the book but it's their at because that's check yes two thirty five just something you should know many questions about that so last but not least one other thing i should mention since we're on the subject of saying here what i think one of these primitive types and encapsulated inside a class it turns out job actually has a bunch of classes already built in which were encapsulation of these data pregnancies are something called integer with the capital are in the forward which is actually a class that is a class that stores a single integer the only unfortunate thing about this classes you would say hey and i can create integers and i can pass right in the journal change manager right this class is actually give you any methods to change the value so it doesn't get to the effect you want will use them later on the border something different but just so you know these exists there's a double and then there's the class version which is actually uppercase doubles of java is to be sensitive in if you ever put uppercase w would actually been using the class version of it similarly would lillian there is blue legionnaires uppercase new and then with cards a little bit different yep are over here and here is the forward character is the classic severe sort of a classic loveland these are the primitive equivalents for everything we're doing so far unless you get told to use the classic won't let me just use the primitive equipment life will be good this is just kind of an artifact of programming languages sometimes in life things just happened happened this when you get you versions of something just because that's the way like that but these class versions the rimmer like strings we said strings were immutable you can't actually change the string in place i can do is create a new one these classes are also immutable once you create an integer and give it some initial value you can't change that initial value if you want to say hey i want to take that out your dad one you need to create a new object if type in a jerk which has the old value plus one added to it you get a new objects are there and you tube on the same way stranger immutable you create new ones you can change the value once you've got not finished jenny questions about this or any questions about this whole notion of pointers and references in passing the stuff around this parameters you presence not it's time for our next right after it an x_-ray topic is something that really is a great topic and meter seinfeld something you've been doing this whole time and now it's time to lift up the covers and say hey you know what there are some much more dangerous things you can do that you've been doing right now so before we try to give it a safety scissors well you know they have like the rounded corners and they're like robert member safety scissors there are fun i like fifty sanders now they say we take a safety scissors we came to the mail we shut them up a real sharp we have you hold them up and run with them so carries where things get dangerous files you're going to learn how to read and create files as well which means the opportunity to arrays files are right over them which is why i think is dead interest but it's really not bad dangerous lies you're careful right when you're running with scissors just point them down and things'll behind why people ran with scissors made no sense to me that but yeah i have really look at this piece of paper come on we're all going as the white paper cutting marathon i'm so files what is the file you thought the whole time right when you've created some program like you had my program dot java i would just stored in some file somewhere and you when you write a paper or you know in your favor microsoft uh... your paper might off your favor word processor which may or may not be a microsoft product you're creating a file and in job i'd you should be able to create files and read files as well so that's something we're going to do in the first thing we're going to take about is reading files it's not my father and i think about reading or not necessarily java files waxing to think about just plain text files oftentimes you'll see these things is you know have some name followed by a dot qualified cfc which is kind of the extension means tax but that's or going to deal with it just by the contain a bunch of characters without any the characters being like special meaning characters or anything 