about summary refs log tree commit diff
path: root/usth/ICT2.7/P1L3 Integrated Development Environment Subtitles
diff options
context:
space:
mode:
authorNguyễn Gia Phong <mcsinyx@disroot.org>2020-07-19 20:34:40 +0700
committerNguyễn Gia Phong <mcsinyx@disroot.org>2020-07-19 20:34:40 +0700
commit8a7dfa0972c83fd811a4296e7373574bea4a28d0 (patch)
tree16d37247e8b909ce5f885affd2b2473faab891fd /usth/ICT2.7/P1L3 Integrated Development Environment Subtitles
parentdc6f57c3af35f599abab2c4bac950654282cb519 (diff)
downloadcp-8a7dfa0972c83fd811a4296e7373574bea4a28d0.tar.gz
[usth/ICT2.7] Remove Udacity transcribes
Diffstat (limited to 'usth/ICT2.7/P1L3 Integrated Development Environment Subtitles')
-rw-r--r--usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/1 - Lesson Overview - lang_en_vs5.srt39
-rw-r--r--usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/2 - Eclipse Introduction - lang_en_vs5.srt91
-rw-r--r--usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/3 - IDE Overview - lang_en_vs6.srt143
-rw-r--r--usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/4 - Plug-Ins - lang_en_vs5.srt99
-rw-r--r--usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/5 - Eclipse Demo: Create Java Project - lang_en_vs5.srt323
-rw-r--r--usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/6 - Eclipse Demo: Create a Class - lang_en_vs6.srt135
-rw-r--r--usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/7 - Eclipse Demo: Run Configuration - lang_en_vs6.srt115
-rw-r--r--usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/8 - Eclipse Demo: Debugging - lang_en_vs5.srt275
8 files changed, 0 insertions, 1220 deletions
diff --git a/usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/1 - Lesson Overview - lang_en_vs5.srt b/usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/1 - Lesson Overview - lang_en_vs5.srt
deleted file mode 100644
index afc573d..0000000
--- a/usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/1 - Lesson Overview - lang_en_vs5.srt
+++ /dev/null
@@ -1,39 +0,0 @@
-1

-00:00:00,650 --> 00:00:07,470

-Hi, and welcome to the first of several lessons on tools of the trade. I'm

-

-2

-00:00:07,470 --> 00:00:12,200

-very excited about these lessons, because I believe that tools are a cornerstone

-

-3

-00:00:12,200 --> 00:00:14,390

-of the software engineering discipline, and it

-

-4

-00:00:14,390 --> 00:00:17,570

-is of paramount importance to know and

-

-5

-00:00:17,570 --> 00:00:20,330

-use them. In this lesson, we will

-

-6

-00:00:20,330 --> 00:00:25,530

-talk about integrated development environments, normally called IDEs.

-

-7

-00:00:25,530 --> 00:00:29,780

-And these are software applications that support developers in many of their

-

-8

-00:00:29,780 --> 00:00:36,870

-everyday tasks, such as writing, compiling, and debugging code. And to make the

-

-9

-00:00:36,870 --> 00:00:42,470

-discussion more concrete we will focus on a specific IDE, Eclipse. We will

-

-10

-00:00:42,470 --> 00:00:47,250

-first present Eclipse, and then get some hands-on experience through a demo.

diff --git a/usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/2 - Eclipse Introduction - lang_en_vs5.srt b/usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/2 - Eclipse Introduction - lang_en_vs5.srt
deleted file mode 100644
index 1d0ff56..0000000
--- a/usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/2 - Eclipse Introduction - lang_en_vs5.srt
+++ /dev/null
@@ -1,91 +0,0 @@
-1

-00:00:00,160 --> 00:00:02,750

-As I just told you, tools are fundamental in

-

-2

-00:00:02,750 --> 00:00:06,050

-software engineering. And I will stress this concept over and

-

-3

-00:00:06,050 --> 00:00:08,240

-over, throughout the class. And today we're going to talk

-

-4

-00:00:08,240 --> 00:00:11,310

-about a tool that is especially important, which is integrated

-

-5

-00:00:11,310 --> 00:00:15,060

-development environments, or IDEs. And you're probably familiar with

-

-6

-00:00:15,060 --> 00:00:18,060

-IDEs. So IDEs are environments that give you support for

-

-7

-00:00:18,060 --> 00:00:21,580

-your development activities. For example, for writing code, editing code,

-

-8

-00:00:21,580 --> 00:00:25,320

-compiling code, and so on. And we will focus specifically

-

-9

-00:00:25,320 --> 00:00:28,890

-on one particular IDE, which is called Eclipse. And

-

-10

-00:00:28,890 --> 00:00:31,450

-what I'm showing here is the two splash screens for

-

-11

-00:00:31,450 --> 00:00:35,350

-two versions of eclipse, Helios and Kepler. Eclipse is an

-

-12

-00:00:35,350 --> 00:00:39,200

-open, extensible development environment that was initially created by IBM

-

-13

-00:00:39,200 --> 00:00:41,510

-and is now managed by the Eclipse Foundation. And of

-

-14

-00:00:41,510 --> 00:00:43,840

-course, there are many other great IDEs such as for

-

-15

-00:00:43,840 --> 00:00:47,310

-example, Microsoft Visual Studio or Netbeans. We will be using

-

-16

-00:00:47,310 --> 00:00:50,830

-Eclipse because it is open and because it is multi-platform,

-

-17

-00:00:50,830 --> 00:00:52,390

-which means that you can use Eclipse

-

-18

-00:00:52,390 --> 00:00:55,140

-no matter what operating system we're using.

-

-19

-00:00:55,140 --> 00:00:59,030

-So if we consider the most commonly used operating system, such as Mac

-

-20

-00:00:59,030 --> 00:01:02,780

-OS, Windows, Linux, Eclipse runs on any

-

-21

-00:01:02,780 --> 00:01:04,769

-of these environments. Therefore, no matter what

-

-22

-00:01:04,769 --> 00:01:06,490

-you're using, you'll be able to install

-

-23

-00:01:06,490 --> 00:01:08,560

-Eclipse, run Eclipse, and follow the class.

diff --git a/usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/3 - IDE Overview - lang_en_vs6.srt b/usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/3 - IDE Overview - lang_en_vs6.srt
deleted file mode 100644
index e2b63b3..0000000
--- a/usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/3 - IDE Overview - lang_en_vs6.srt
+++ /dev/null
@@ -1,143 +0,0 @@
-1

-00:00:00,130 --> 00:00:05,680

-So, now let's look in a little more detail to what is an IDE. An IDE is a

-

-2

-00:00:05,680 --> 00:00:09,790

-software application that supports software developers in many of

-

-3

-00:00:09,790 --> 00:00:13,840

-their everyday tasks. It has many useful features. Most IDEs

-

-4

-00:00:13,840 --> 00:00:16,790

-provide views that can be used to navigate, project

-

-5

-00:00:16,790 --> 00:00:20,140

-resources from different perspectives. For example, you might want to

-

-6

-00:00:20,140 --> 00:00:22,390

-look at your code differently when you're writing code,

-

-7

-00:00:22,390 --> 00:00:25,950

-and when you're debugging. They also normally provide an intelligent

-

-8

-00:00:25,950 --> 00:00:29,380

-source code editor. For example, an editor that will allow you

-

-9

-00:00:29,380 --> 00:00:32,110

-to browse the documentation when you're writing a code that

-

-10

-00:00:32,110 --> 00:00:35,780

-uses a specific method, or that will give you autocompletion when

-

-11

-00:00:35,780 --> 00:00:37,990

-you start writing the name of an object and you want to

-

-12

-00:00:37,990 --> 00:00:40,820

-get the methods for that object. And all of these things

-

-13

-00:00:40,820 --> 00:00:43,420

-can be very useful while you're developing and can save you a

-

-14

-00:00:43,420 --> 00:00:47,750

-lot of time. Modern IDE's will also normally give you support for

-

-15

-00:00:47,750 --> 00:00:49,540

-version control systems that then you

-

-16

-00:00:49,540 --> 00:00:52,490

-can use for softer configuration management.

-

-17

-00:00:52,490 --> 00:00:55,720

-And we're going to discuss in detail version control systems in

-

-18

-00:00:55,720 --> 00:00:58,380

-the next tools of the trade lesson, and we're also

-

-19

-00:00:58,380 --> 00:01:01,135

-going to see how it can be integrated within an IDE.

-

-20

-00:01:01,135 --> 00:01:04,730

-IDEs also give you builders so they give you build automation

-

-21

-00:01:04,730 --> 00:01:08,070

-tools, they give you runtime support. So that you can

-

-22

-00:01:08,070 --> 00:01:10,960

-run your projects from within the IDE and, for example,

-

-23

-00:01:10,960 --> 00:01:14,550

-observe some aspects of the execution. In addition to giving

-

-24

-00:01:14,550 --> 00:01:17,562

-you support for the runtime, they give you support for testing.

-

-25

-00:01:17,562 --> 00:01:21,267

-Many IDEs allow you to run tests from within

-

-26

-00:01:21,267 --> 00:01:23,520

-the IDE and to check the results of the tests

-

-27

-00:01:23,520 --> 00:01:26,300

-from within the IDE. Not only that. Normally, after you

-

-28

-00:01:26,300 --> 00:01:28,210

-run your tests, if there are some test cases that

-

-29

-00:01:28,210 --> 00:01:31,500

-fail, you can also use your IDEs to do debugging.

-

-30

-00:01:31,500 --> 00:01:35,620

-Many IDEs include graphical debuggers. Debuggers will allow you to

-

-31

-00:01:35,620 --> 00:01:39,400

-navigate through the code, set which points, stop and restart

-

-32

-00:01:39,400 --> 00:01:43,160

-the execution. Inspect variables, and do all of the activities

-

-33

-00:01:43,160 --> 00:01:46,320

-that help debugging. And, to help you be more efficient

-

-34

-00:01:46,320 --> 00:01:49,440

-and more effective when you do debugging. And into addition to

-

-35

-00:01:49,440 --> 00:01:52,760

-all these features that are listed here IDEs can normally provide

-

-36

-00:01:52,760 --> 00:01:56,650

-you even more features through a mechanishm that is called plugins.

diff --git a/usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/4 - Plug-Ins - lang_en_vs5.srt b/usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/4 - Plug-Ins - lang_en_vs5.srt
deleted file mode 100644
index 040293e..0000000
--- a/usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/4 - Plug-Ins - lang_en_vs5.srt
+++ /dev/null
@@ -1,99 +0,0 @@
-1

-00:00:00,110 --> 00:00:03,134

-In fact most IDEs are extensible through the use of

-

-2

-00:00:03,134 --> 00:00:06,158

-plug-ins. And by the way, note that plug-ins might be

-

-3

-00:00:06,158 --> 00:00:09,326

-called differently on different platforms. For example, if you're using

-

-4

-00:00:09,326 --> 00:00:12,970

-a Microsoft Visual Studio, plug-ins are normally called add-ins, but

-

-5

-00:00:12,970 --> 00:00:15,598

-the concept is more or less the same. So, what

-

-6

-00:00:15,598 --> 00:00:18,555

-is a plug-in? Well, let's imagine our IDE to be

-

-7

-00:00:18,555 --> 00:00:22,320

-this box. A plug-in is additional functionality that you can

-

-8

-00:00:22,320 --> 00:00:25,430

-actually plug into this box so that this box starts

-

-9

-00:00:25,430 --> 00:00:28,830

-offering more features to the user. For example, you

-

-10

-00:00:28,830 --> 00:00:32,850

-can add to Eclipse the Checkstyle plug-in. Which, paraphrasing the

-

-11

-00:00:32,850 --> 00:00:35,950

-Checkstyle website, helps you ensure that your Java code

-

-12

-00:00:35,950 --> 00:00:38,890

-complies with a set of coding standards by inspecting the

-

-13

-00:00:38,890 --> 00:00:41,690

-code and pointing out items that deviate from a

-

-14

-00:00:41,690 --> 00:00:44,870

-defined set of coding rules. Again, this is a functionality

-

-15

-00:00:44,870 --> 00:00:47,330

-the core of Eclipse doesn't have. You can add

-

-16

-00:00:47,330 --> 00:00:50,600

-the Checkstyle plug-in, and this functionality will become available in

-

-17

-00:00:50,600 --> 00:00:54,840

-the IDE. Another example of plug-in is the EGit plug-in which

-

-18

-00:00:54,840 --> 00:00:58,660

-adds support for the Git version control system in Eclipse. And

-

-19

-00:00:58,660 --> 00:01:01,290

-actually this is something that we'll cover in detail, we'll have

-

-20

-00:01:01,290 --> 00:01:04,150

-a demo, and we will actually use it throughout the class, so

-

-21

-00:01:04,150 --> 00:01:07,018

-I'm not going to say anything more about the EGit plug-in for

-

-22

-00:01:07,018 --> 00:01:09,300

-now. But again, what the plug-in will do is to add

-

-23

-00:01:09,300 --> 00:01:13,220

-the Git functionality to Eclipse. A functionality that is not in

-

-24

-00:01:13,220 --> 00:01:16,110

-the core of Eclipse and that is available to the user after

-

-25

-00:01:16,110 --> 00:01:17,181

-you add the plug-in.

diff --git a/usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/5 - Eclipse Demo: Create Java Project - lang_en_vs5.srt b/usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/5 - Eclipse Demo: Create Java Project - lang_en_vs5.srt
deleted file mode 100644
index 8788858..0000000
--- a/usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/5 - Eclipse Demo: Create Java Project - lang_en_vs5.srt
+++ /dev/null
@@ -1,323 +0,0 @@
-1

-00:00:00,070 --> 00:00:02,550

-In the rest of this lesson we're going to look at eclipse and

-

-2

-00:00:02,550 --> 00:00:05,290

-try to get more familiar with eclipse in a hands on manner

-

-3

-00:00:05,290 --> 00:00:07,550

-through a demo. In the demo we will cover some of the

-

-4

-00:00:07,550 --> 00:00:11,040

-basic aspects of eclipse like how to run eclipse, how to select

-

-5

-00:00:11,040 --> 00:00:14,400

-their workspace, how to create a project, how to create the class

-

-6

-00:00:14,400 --> 00:00:18,240

-within the project and so on. I'll also cover some more advanced

-

-7

-00:00:18,240 --> 00:00:21,610

-aspects, like how to create builders, run your project within Eclipse, and

-

-8

-00:00:21,610 --> 00:00:25,800

-how to use their Eclipse debugger. So let's get to the demo.

-

-9

-00:00:25,800 --> 00:00:28,220

-So let's start Eclipse. Eclipse is going to ask me

-

-10

-00:00:28,220 --> 00:00:31,600

-for the location of my workspace and in this

-

-11

-00:00:31,600 --> 00:00:34,530

-case, I selected a suitable directory and you can

-

-12

-00:00:34,530 --> 00:00:38,480

-also use that checkbox on the left to avoid Eclipse

-

-13

-00:00:38,480 --> 00:00:40,640

-for asking you again about where to put the

-

-14

-00:00:40,640 --> 00:00:43,860

-workspace. And the workspace is basically the place the

-

-15

-00:00:43,860 --> 00:00:48,310

-directory. Where, Eclipse will place all of your projects.

-

-16

-00:00:48,310 --> 00:00:50,830

-So, now when you start Eclipse, if it's the first

-

-17

-00:00:50,830 --> 00:00:53,480

-time you might get this Welcome screen. It's not going to happen

-

-18

-00:00:53,480 --> 00:00:57,500

-again on subsequent executions, but I just wanted to make sure

-

-19

-00:00:57,500 --> 00:01:00,210

-that I covered all the bases. And so, whatcha want to

-

-20

-00:01:00,210 --> 00:01:03,360

-do here is to basically go to the java perspective

-

-21

-00:01:03,360 --> 00:01:06,760

-which you can do by clicking over there or you can

-

-22

-00:01:06,760 --> 00:01:09,240

-also use the menus. So in this case we will have

-

-23

-00:01:09,240 --> 00:01:12,810

-to go to Window, open Perspective, and if the Perspective is

-

-24

-00:01:12,810 --> 00:01:15,660

-not here, you'll have to click on Other. And at this point,

-

-25

-00:01:15,660 --> 00:01:18,030

-that you can click on Java Perspective, then you

-

-26

-00:01:18,030 --> 00:01:21,680

-click okay. And the perspective is basically, the visual work

-

-27

-00:01:21,680 --> 00:01:24,810

-space where you will be operating. So, after we selected

-

-28

-00:01:24,810 --> 00:01:29,350

-perspective, we can actually close the welcome screen. And here,

-

-29

-00:01:29,350 --> 00:01:32,000

-you see that you have this different areas and on

-

-30

-00:01:32,000 --> 00:01:34,930

-the left You have the package explorer. This is the

-

-31

-00:01:34,930 --> 00:01:37,650

-area where your packages will be, you've got a task list,

-

-32

-00:01:37,650 --> 00:01:41,280

-and an outline on the right which we'll cover later.

-

-33

-00:01:41,280 --> 00:01:44,870

-And then you have underneath, the bottom, a problems, java

-

-34

-00:01:44,870 --> 00:01:48,330

-doc and declaration views and we will see some of

-

-35

-00:01:48,330 --> 00:01:51,320

-these views in actions later. And here in the center

-

-36

-00:01:51,320 --> 00:01:54,290

-you have the area. Which is called a code editor,

-

-37

-00:01:54,290 --> 00:01:58,360

-which is where you'll be writing, editing, and modifying, basically,

-

-38

-00:01:58,360 --> 00:02:00,440

-your code. This is where most of the action takes

-

-39

-00:02:00,440 --> 00:02:03,140

-place. So let's start by creating a Java project. And

-

-40

-00:02:03,140 --> 00:02:06,950

-to do that we can use either the context menu, or

-

-41

-00:02:06,950 --> 00:02:09,560

-you can just use the menu, select new Java project.

-

-42

-00:02:09,560 --> 00:02:12,390

-You'll be greeted by this, wizard, and. And at this

-

-43

-00:02:12,390 --> 00:02:15,500

-point in the wizard, you can select the name of

-

-44

-00:02:15,500 --> 00:02:19,100

-your project. I'm just going to call it a very simple way

-

-45

-00:02:19,100 --> 00:02:21,990

-my project. And I going to use the default location for

-

-46

-00:02:21,990 --> 00:02:24,070

-the project, as you can see it will be placed

-

-47

-00:02:24,070 --> 00:02:27,440

-in the work space that I selected before. I'm going to

-

-48

-00:02:27,440 --> 00:02:32,080

-also use the default. Java Runtime Environment, which is Java 1.7

-

-49

-00:02:32,080 --> 00:02:36,250

-in this case. I'm going to keep the selected default layout

-

-50

-00:02:36,250 --> 00:02:39,120

-and the, then I'm going to go to the next step. Here,

-

-51

-00:02:39,120 --> 00:02:42,380

-we're first presented with the location of the source code for

-

-52

-00:02:42,380 --> 00:02:46,840

-our project. The default is a directory SRC in my project

-

-53

-00:02:46,840 --> 00:02:49,320

-and for the output file, the directory bin. So repeat, we're now

-

-54

-00:02:49,320 --> 00:02:52,410

-going to change that. Here in case you need other projects to

-

-55

-00:02:52,410 --> 00:02:55,240

-build your own, then you can specify them here. Here we

-

-56

-00:02:55,240 --> 00:02:57,570

-are building a simple project, so there's no need for that.

-

-57

-00:02:57,570 --> 00:03:00,890

-And here we can specify which libraries our project requires. As

-

-58

-00:03:00,890 --> 00:03:03,880

-you can see, the Java library's already specified. And you can

-

-59

-00:03:03,880 --> 00:03:07,840

-also add other jars, which can even be External jars. And

-

-60

-00:03:07,840 --> 00:03:11,840

-finally this is the tab that allows you to specify which

-

-61

-00:03:11,840 --> 00:03:14,300

-part of you project. So how your project will be exported,

-

-62

-00:03:14,300 --> 00:03:16,760

-so lets not worry about that for now. Lets click finish.

-

-63

-00:03:16,760 --> 00:03:19,300

-And as you can see here on the package explorer, my

-

-64

-00:03:19,300 --> 00:03:22,920

-project appeared. So now we can open the project by clicking

-

-65

-00:03:22,920 --> 00:03:24,920

-on the triangle right next to it, and as you can

-

-66

-00:03:24,920 --> 00:03:28,250

-see there is the SRC directory, where my source code will go,

-

-67

-00:03:28,250 --> 00:03:31,760

-and there's also an indication that we're using the JRE, so that's

-

-68

-00:03:31,760 --> 00:03:35,800

-the Java system directory within our project. And this is just for people

-

-69

-00:03:35,800 --> 00:03:38,860

-who are interested in what happens you know, under the hood. So

-

-70

-00:03:38,860 --> 00:03:41,840

-if you don't care about that, you can just skip this part. So

-

-71

-00:03:41,840 --> 00:03:45,200

-basically here I'm showing you how we can go to the directory

-

-72

-00:03:45,200 --> 00:03:49,250

-where the project was created. We can see the bin and src directories.

-

-73

-00:03:49,250 --> 00:03:52,020

-And there's also some other files here that you can

-

-74

-00:03:52,020 --> 00:03:54,780

-see these 'dot' files that you will not normally, see. And

-

-75

-00:03:54,780 --> 00:03:57,870

-those are kind of bookkeeping files. So these are files that

-

-76

-00:03:57,870 --> 00:04:02,280

-contain information about your project and that are created automatically by

-

-77

-00:04:02,280 --> 00:04:05,860

-Eclipse. And, for example, will have various indication about the

-

-78

-00:04:05,860 --> 00:04:09,580

-configuration of the project, some settings and the class path for

-

-79

-00:04:09,580 --> 00:04:11,880

-the project. And, as I said, you don't have to worry

-

-80

-00:04:11,880 --> 00:04:14,490

-about this if you just want to go Eclipse as you're never

-

-81

-00:04:14,490 --> 00:04:16,551

-going to mess with the command line.

diff --git a/usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/6 - Eclipse Demo: Create a Class - lang_en_vs6.srt b/usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/6 - Eclipse Demo: Create a Class - lang_en_vs6.srt
deleted file mode 100644
index 3bd4f11..0000000
--- a/usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/6 - Eclipse Demo: Create a Class - lang_en_vs6.srt
+++ /dev/null
@@ -1,135 +0,0 @@
-1

-00:00:00,130 --> 00:00:02,420

-So now that we know, we saw what happens under

-

-2

-00:00:02,420 --> 00:00:04,570

-the hood, and as I said, don't worry about it if

-

-3

-00:00:04,570 --> 00:00:06,689

-you don't care about that part. Now we can go back

-

-4

-00:00:06,689 --> 00:00:09,850

-to Eclipse, and we can start creating a package. A package

-

-5

-00:00:09,850 --> 00:00:13,125

-is basically a way of organizing your classes into a

-

-6

-00:00:13,125 --> 00:00:17,015

-hierarchy. In this case, I'm going to specify the package name as

-

-7

-00:00:17,015 --> 00:00:21,350

-edu.gatech, which means that I'm creating really two packages, a package

-

-8

-00:00:21,350 --> 00:00:25,480

-gatech inside package edu. And I can start creating classes inside

-

-9

-00:00:25,480 --> 00:00:28,770

-my packages. So here, I can use the contextual menu, select

-

-10

-00:00:28,770 --> 00:00:32,055

-New&gt;Class, and I'll get another wizard that will allow me to

-

-11

-00:00:32,055 --> 00:00:35,160

-specify the name of the class. I'm not very creative here,

-

-12

-00:00:35,160 --> 00:00:38,250

-so I'm just going to call it Hello World. There's many other parameters

-

-13

-00:00:38,250 --> 00:00:41,710

-you can set, and in particular, you can define whether you

-

-14

-00:00:41,710 --> 00:00:45,450

-want a main method in your class. Where having a main

-

-15

-00:00:45,450 --> 00:00:48,460

-method means that your class can be the main class in

-

-16

-00:00:48,460 --> 00:00:50,850

-your project, can be the one that is run when you run

-

-17

-00:00:50,850 --> 00:00:54,340

-your project. After we click the button, the Finish button, we,

-

-18

-00:00:54,340 --> 00:00:56,859

-we get the class. So we also get template code for the

-

-19

-00:00:56,859 --> 00:00:59,604

-class, as you can see here, so we go to the editor

-

-20

-00:00:59,604 --> 00:01:02,120

-function, you can see that there is a to do. Where you

-

-21

-00:01:02,120 --> 00:01:05,019

-have to put your code, and here we are simply, basically printing,

-

-22

-00:01:05,019 --> 00:01:08,370

-you know, the typical first program. We just going to print Hello World

-

-23

-00:01:08,370 --> 00:01:11,180

-in Java. And something you can note is that as we are

-

-24

-00:01:11,180 --> 00:01:16,370

-typing, Eclipse gives us a auto complete suggestions, which is very helpful.

-

-25

-00:01:16,370 --> 00:01:19,650

-For example, in case you don't remember the exact syntax,

-

-26

-00:01:19,650 --> 00:01:22,190

-or the method, or you don't remember the parameters of the

-

-27

-00:01:22,190 --> 00:01:24,470

-method. Which is, you know, often the case especially where you

-

-28

-00:01:24,470 --> 00:01:27,590

-work with large libraries. So having that feature can really, really

-

-29

-00:01:27,590 --> 00:01:30,050

-help you. So now if we want to run our code

-

-30

-00:01:30,050 --> 00:01:33,380

-we can either click on the button up here, or we

-

-31

-00:01:33,380 --> 00:01:37,960

-can right-click in the Call window and select Run As Java

-

-32

-00:01:37,960 --> 00:01:41,370

-Application. And if we do that, Eclipse will run our tool,

-

-33

-00:01:41,370 --> 00:01:45,650

-and it will create, as you can see here, a console view that basically contains

-

-34

-00:01:45,650 --> 00:01:49,790

-the textual output of my program. And as expected, the output is Hello World.

diff --git a/usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/7 - Eclipse Demo: Run Configuration - lang_en_vs6.srt b/usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/7 - Eclipse Demo: Run Configuration - lang_en_vs6.srt
deleted file mode 100644
index ad54f06..0000000
--- a/usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/7 - Eclipse Demo: Run Configuration - lang_en_vs6.srt
+++ /dev/null
@@ -1,115 +0,0 @@
-1

-00:00:00,140 --> 00:00:02,660

-So now that we have run our program, let's see what

-

-2

-00:00:02,660 --> 00:00:05,660

-happens exactly when you run a program within Eclipse. And to

-

-3

-00:00:05,660 --> 00:00:08,410

-do that I'm going to use the menu over here which is

-

-4

-00:00:08,410 --> 00:00:12,500

-the Run menu and I'm going to select Run Configurations, and this

-

-5

-00:00:12,500 --> 00:00:15,190

-brings up a window where you can change or run configurations.

-

-6

-00:00:15,190 --> 00:00:17,200

-Well first of all, you can see that here on the

-

-7

-00:00:17,200 --> 00:00:22,260

-left under Java application. Eclipse automatically created a Hello World run

-

-8

-00:00:22,260 --> 00:00:25,300

-configuration for our program. And this is where you can configure

-

-9

-00:00:25,300 --> 00:00:28,370

-the different parameters for your execution. For example,

-

-10

-00:00:28,370 --> 00:00:30,520

-you can select the main class. So here

-

-11

-00:00:30,520 --> 00:00:34,745

-it's, obviously, edu.gatech.HelloWorld. You can define different program

-

-12

-00:00:34,745 --> 00:00:36,920

-arguments. We don't have any for now. You can

-

-13

-00:00:36,920 --> 00:00:39,480

-also pass arguments to the virtual machine. You

-

-14

-00:00:39,480 --> 00:00:41,960

-can define which Java runtime environment you want to

-

-15

-00:00:41,960 --> 00:00:47,720

-use, Classpath and other environmental options. So let's

-

-16

-00:00:47,720 --> 00:00:50,650

-now try to pass some arguments to our program.

-

-17

-00:00:50,650 --> 00:00:54,390

-So for example here, I am just going to write George as

-

-18

-00:00:54,390 --> 00:00:58,450

-a possible parameter. I say Apply so that modify the configuration and

-

-19

-00:00:58,450 --> 00:01:01,510

-if i run the program of course, the output is not changing

-

-20

-00:01:01,510 --> 00:01:04,440

-because my program does not use the argument. But, let's see if

-

-21

-00:01:04,440 --> 00:01:07,060

-we do use the argument, what happens. So I'm going to slightly

-

-22

-00:01:07,060 --> 00:01:10,030

-modify the final program so that now, instead of printing hello

-

-23

-00:01:10,030 --> 00:01:13,420

-world, it will print hello followed by the first argument that I

-

-24

-00:01:13,420 --> 00:01:15,700

-will pass to the program. And if I do that, and I

-

-25

-00:01:15,700 --> 00:01:19,420

-go and I run the program, what I get is exactly what I

-

-26

-00:01:19,420 --> 00:01:23,420

-was expecting, which is Hello George. So this is the way in which you

-

-27

-00:01:23,420 --> 00:01:26,120

-can pass arguments to your execution, which

-

-28

-00:01:26,120 --> 00:01:27,640

-is something that might come in handy

-

-29

-00:01:27,640 --> 00:01:30,390

-for some other projects. When you need to run some code with an argument.

diff --git a/usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/8 - Eclipse Demo: Debugging - lang_en_vs5.srt b/usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/8 - Eclipse Demo: Debugging - lang_en_vs5.srt
deleted file mode 100644
index 025c2ba..0000000
--- a/usth/ICT2.7/P1L3 Integrated Development Environment Subtitles/8 - Eclipse Demo: Debugging - lang_en_vs5.srt
+++ /dev/null
@@ -1,275 +0,0 @@
-1

-00:00:00,160 --> 00:00:03,090

-Now let's look at how we can do debugging within

-

-2

-00:00:03,090 --> 00:00:06,240

-Eclipse. I created a new file called AddNumbers which I'm

-

-3

-00:00:06,240 --> 00:00:10,770

-showing here. It takes two numbers, parses them into integers,

-

-4

-00:00:10,770 --> 00:00:14,870

-adds them and prints the sum, supposedly, of the two numbers.

-

-5

-00:00:14,870 --> 00:00:17,450

-Now we look at the run configuration for this program,

-

-6

-00:00:17,450 --> 00:00:19,670

-and here you can see that we're passing two arguments,

-

-7

-00:00:19,670 --> 00:00:22,060

-two and five, to the program. So now let's run

-

-8

-00:00:22,060 --> 00:00:25,468

-our program and see what happens. And the result says that

-

-9

-00:00:25,468 --> 00:00:28,150

-2 plus 5 is equal to 10, which is not

-

-10

-00:00:28,150 --> 00:00:31,030

-exactly correct. So we need to debug our program. We

-

-11

-00:00:31,030 --> 00:00:33,310

-need to figure out what's wrong with the program, why

-

-12

-00:00:33,310 --> 00:00:37,140

-the wrong result was, produced. So we're going to add a break

-

-13

-00:00:37,140 --> 00:00:40,260

-point here by double-clicking here on the side of the

-

-14

-00:00:40,260 --> 00:00:42,940

-code. And the break point is basically a place where I'm

-

-15

-00:00:42,940 --> 00:00:46,240

-telling my debugger to stop during the execution because I

-

-16

-00:00:46,240 --> 00:00:50,750

-want to inspect the state of the program. So to start

-

-17

-00:00:50,750 --> 00:00:54,690

-debugging, we select Debug as Java Application from the Context

-

-18

-00:00:54,690 --> 00:00:58,170

-menu, similar to what we were doing for running the program.

-

-19

-00:00:58,170 --> 00:01:00,190

-And as you can see, this asks us whether we want

-

-20

-00:01:00,190 --> 00:01:03,720

-to pass to the debug perspective, which is a, a perspective

-

-21

-00:01:03,720 --> 00:01:07,110

-specifically designed for debugging. We say yes. And as you

-

-22

-00:01:07,110 --> 00:01:10,750

-see here, it shows us, it's like a different, set of

-

-23

-00:01:10,750 --> 00:01:13,310

-views, so we can see the code down here with an

-

-24

-00:01:13,310 --> 00:01:16,100

-indication of where the execution is. And of course the execution

-

-25

-00:01:16,100 --> 00:01:18,610

-stopped at the break point, which is exactly where

-

-26

-00:01:18,610 --> 00:01:21,850

-we told the debugger to stop. So let's look at

-

-27

-00:01:21,850 --> 00:01:24,400

-some of the other views in this perspective. The view

-

-28

-00:01:24,400 --> 00:01:27,370

-here on the right-hand side, for example, shows the variables

-

-29

-00:01:27,370 --> 00:01:30,720

-in scope and the break points that are currently active

-

-30

-00:01:30,720 --> 00:01:33,240

-for the debugging session. This is where the editor is

-

-31

-00:01:33,240 --> 00:01:36,710

-at. The outline of the program and the console at

-

-32

-00:01:36,710 --> 00:01:41,520

-the bottom. So now let's execute one line by clicking

-

-33

-00:01:41,520 --> 00:01:45,400

-on the Step Over button here at the top, and this will

-

-34

-00:01:45,400 --> 00:01:49,150

-execute the line that is currently highlighted and therefore it will move to

-

-35

-00:01:49,150 --> 00:01:51,500

-the next line. And as you can see, one nice feature is that

-

-36

-00:01:51,500 --> 00:01:54,760

-if I move the mouse over a variable, I can see the value

-

-37

-00:01:54,760 --> 00:01:57,710

-of the variable. And the same thing I can do if I look

-

-38

-00:01:57,710 --> 00:02:00,690

-at the variables windows here on the right. If I click it, it

-

-39

-00:02:00,690 --> 00:02:03,960

-will tell me what is the value of the variable, and in case

-

-40

-00:02:03,960 --> 00:02:07,410

-of more complex variables you can even expand it and get more details.

-

-41

-00:02:07,410 --> 00:02:10,870

-So now let's step over another line by clicking again this button,

-

-42

-00:02:10,870 --> 00:02:13,180

-and as you can see now we get to the line that

-

-43

-00:02:13,180 --> 00:02:16,410

-is actually performing the sum, supposedly, so now let's do the same

-

-44

-00:02:16,410 --> 00:02:19,100

-thing that we did before, and let's mouse over b, and we can

-

-45

-00:02:19,100 --> 00:02:22,150

-see that the value of b is five, as expected. So now

-

-46

-00:02:22,150 --> 00:02:27,080

-let's step over this line as well, and execute the actual sum. And

-

-47

-00:02:27,080 --> 00:02:29,730

-doing the mouseover thing, we can see that the value of sum

-

-48

-00:02:29,730 --> 00:02:33,000

-is ten, which is not right, of course. In fact, if we check

-

-49

-00:02:33,000 --> 00:02:35,590

-a gain we can see that value of A is two. The

-

-50

-00:02:35,590 --> 00:02:39,130

-value of B is five and therefore it's clear that there's something

-

-51

-00:02:39,130 --> 00:02:41,780

-wrong going on here, and at this point we can notice that

-

-52

-00:02:41,780 --> 00:02:44,030

-here we are doing multiplication instead

-

-53

-00:02:44,030 --> 00:02:46,010

-of addition. And therefore that's what the

-

-54

-00:02:46,010 --> 00:02:49,260

-error is. And this is clearly a very simple case. Right? A

-

-55

-00:02:49,260 --> 00:02:51,440

-case in which probably you just needed to look at the code and

-

-56

-00:02:51,440 --> 00:02:54,150

-you didn't need the debugger. But you probably got the idea right?

-

-57

-00:02:54,150 --> 00:02:58,055

-So this can be extremely useful when you're debugging, when you're studying more

-

-58

-00:02:58,055 --> 00:03:01,533

-complex programs. If you want to stop the debugger because you're

-

-59

-00:03:01,533 --> 00:03:04,557

-done with your debugging session as in this case, you can

-

-60

-00:03:04,557 --> 00:03:07,518

-either click here on the Terminate button or you can also

-

-61

-00:03:07,518 --> 00:03:11,109

-just simply tell the debugger to continue the execution, to resume

-

-62

-00:03:11,109 --> 00:03:15,140

-the execution until the program terminates naturally. So, in this case,

-

-63

-00:03:15,140 --> 00:03:17,520

-we're going to click here just to show what happens. And what

-

-64

-00:03:17,520 --> 00:03:20,230

-happens is that, you know, the execution will just continue until

-

-65

-00:03:20,230 --> 00:03:23,690

-the program exits. So now let's say that we want to fix

-

-66

-00:03:23,690 --> 00:03:27,740

-this problem that we just discovered. So we replace the multiplication

-

-67

-00:03:27,740 --> 00:03:30,600

-with an addition, we save the program, and we execute the

-

-68

-00:03:30,600 --> 00:03:33,860

-program again by clicking on this button. And at this point,

-

-69

-00:03:33,860 --> 00:03:37,320

-unsurprisingly, we get the right result as shown in the console.