0% found this document useful (0 votes)
153 views9 pages

Todays Workshop Notes

The document provides instructions for a Java programming workshop. It includes links to download Java JDK and instructions on setting up the environment variables. It discusses Java programming concepts like classes, objects, data types, and access modifiers. It provides code examples to print "Hello World" and add two numbers. It assigns tasks to write programs for subtraction, multiplication and division operations. It also includes links to videos explaining Java concepts in more detail.

Uploaded by

Ashu
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
153 views9 pages

Todays Workshop Notes

The document provides instructions for a Java programming workshop. It includes links to download Java JDK and instructions on setting up the environment variables. It discusses Java programming concepts like classes, objects, data types, and access modifiers. It provides code examples to print "Hello World" and add two numbers. It assigns tasks to write programs for subtraction, multiplication and division operations. It also includes links to videos explaining Java concepts in more detail.

Uploaded by

Ashu
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 9

upload task to the link

link : --> https://forms.gle/vcyYv5RPTd23Vf3y5

https://www.youtube.com/amolujagare

Imp things for workshop

1. Join whatsapp group


- Confirmation email
- Today's meeting invitation
2. Provide Gmail

https://www.oracle.com/in/java/technologies/javase/javase-jdk8-downloads.html

Download and install jdk →

Setup the environment variables

Programming → language

Java → grammar → rules

1. Every program has a starting point

Here it is a main function

public static void main(String[] args)


{
// statements

2. main function is always written inside a class

class ClassName
{
public static void main(String[] args)
{
// statements
}

Write a program to print “hello world”

class HelloWord
{
public static void main(String[] args)
{
System.out.println(“Hello World”);
}

Save the file using className.java

1. Compile

Javac fileName.java

2. Run
Java className

Before we compile reach to the directory on command prompt

Program 2 → Addition of 2 numbers

a = 10;
b = 20 ;

c;

c =a+b;

Integer → whole number → 10


Decimal → 1.2

Datatype
int , double

class Addition
{

public static void main(String[] args)


{
int a;
int b;
int c;

c = a+b;

System.out.println(c);
}
}

Todays Task

Write a program to perform below operations


a. Subtraction
b. Multiplication
c. Division
upload task to the link
link : --> https://forms.gle/vcyYv5RPTd23Vf3y5

Submit before 4 PM

http://youtube.com/amolujagare

Queries : [email protected]

Course content of 3 months program


https://scriptinglogic.org/selenium-webdriver-with-cucumber/

Day 2 :

1. Eclipse
https://www.eclipse.org/downloads/
2. Intellij idea
https://www.jetbrains.com/idea/download

Shortcuts in intellij idea

a. psvm - public static void main(String[]


args) {
}
b. sout - System.out.println();

class
- Collection of data members and member functions
- Data member
int a , double d, char c ,String str;

- Member function
- void functionName()
{
// body
}

- We can not access the data members or member function, inside


main function directly

Inside the member function of the class the data members or member
function can be accessed directly with no need to create an object.
Object is the instance of a class
Each object when created , it allocates a separate memory to each
members

Constructor :

- It is used to initialize the object


- It has same name as that of class name
- It is a method with no return type (like void)

when there is no constructor defined inside the class then default


constructor is invoked and it initializes the object

When you write a constructor with no body inside it , it does the same
effect as that of the default constructor ,and it is called as empty
constructor

Access Modifiers :

Public
Private
Default
Protected - inheritance

Scope of the data member or member function

Default : when you don't specify the access modifier then it is a default
access modifiers

Default members can be


● In the same class
● Another class in the same package
● Can not be accessed in another class in another package

Public members can be


● In the same class
● In Another class in the same package
● In another class in another package

Private members can be accessed in the same class only

Other java concepts


https://www.youtube.com/watch?app=desktop&v=9UbQA9KT9Ts&list
=PLTBsF5WLNKWFa4ANGtbKSOfhNRx4dOj7V

Mercury → HP → paid tool

Selenium → open sources


Today's task

create class student with 2 object and display its values

int rno;
String name;
String division;

display()
upload task to the link
link : --> https://forms.gle/vcyYv5RPTd23Vf3y5

Submit before 4 PM

Day 3 :

Selenium project installation (intellij idea)

1. Create a project
2. Create a folder name it as lib
3. Download the selenium libraries selenium.dev
4. Add them into the lib folder
5. Download webdrivermanager jars and add it into lib
https://jar-download.com/artifact-search/webdrivermanager
6. Set the lib folder as library

Get vs navigate
https://www.youtube.com/watch?v=TVJPt3EGrXQ

xpath
https://www.youtube.com/watch?v=jk9PvIf3z8A

HTML basic video


Today's task

perform login operation


http://demo.guru99.com/v4

User ID : mngr331891
Password : dYsAtyp

upload task to the link


link : --> https://forms.gle/vcyYv5RPTd23Vf3y5

Submit before 4 PM
[email protected]

Day 4 :

1. login with valid credentials


2. login with invalid credentials
3. login with blank credentials

CSS selector
https://www.youtube.com/watch?v=f9oHY2RxRzs

Report generation
https://www.youtube.com/watch?v=O0m3GZHzeAU

Junit : article
https://scriptinglogic.com/selenium/junit/
Apply assertion to below test method,
@Test // task
public void myTest3()
{
WebDriverManager.chromedriver().setup();
WebDriver driver = new ChromeDriver();
driver.manage().window().maximize();

driver.get("http://stock.scriptinglogic.net/");

WebElement txtUsername = driver.findElement(By.id("login-username"));


txtUsername.sendKeys("");

WebElement txtPassword = driver.findElement(By.id("login-password"));


txtPassword.sendKeys("");

WebElement btnLogin = driver.findElement(By.name("submit"));


btnLogin.click();

// compare - page tilte or url


}

Take screenshot of webpage : twitter (open in browser)


upload task to the link
link : --> https://forms.gle/vcyYv5RPTd23Vf3y5

Submit before 4 PM
[email protected]

Tomorrow there is quiz


Those who completed all the task can participate
Winner will get amazon voucher 299/-

You might also like