This example declares a method called setQuantity that accepts a variable called qty of type int .
public void setQuantity(int qty);
This example declares a method called getQuantity that returns a variable of type int .
public int getQuantity();
Top |