Coding Style, Javadoc Documentation Conventions, Git, UML and JUnit

Réussis tes devoirs et examens dès maintenant avec Quizwiz!

What symbol is used in a UML class diagram to indicate that a field has public access?

+

Maximum number of characters in single line of source code

100

How many spaces should the unit of indentation be?

2

How many times would a @Before annotated method get executed if there are 3 test methods in a test class?

3

Which javadoc tags are required tags for the method, compareTo, shown in the following interface? public interface Comparable { public int compareTo(Object o); }

@param, @return

What does the @override annotation include?

A class method overriding a superclass method, a class method implementing an interface method, and an interface method respecifying a superinterface method

T/F: In Javadoc, a @return tag is required for all constructors.

False

T/F: In Javadoc, the @throws tag should only be used for unchecked exceptions and @exception tag should be used for checked exceptions

False

T/F: The Google Java Style Guide and Oracle Coding Conventions recommend declaring multiple variables on the same line for efficiency. For example, the declaration of two integers such as int level, size; is preferred over int level; int size;

False

T/F: The names of variables declared class constants should all be uppercase with words separated by underscores. A example of a constant is: public static int MIN_WIDTH = 4;

False

What git command do you use to get project off of the internet?

Git Clone

What are constructors?

Member functions that perform initialization when an object is first created; always given the same name as the class ex, class Customer; constructor Customer()

What is the recommended visibility for an instance variable of a class?

Private

T/F: A switch statement should have the following form: switch (condition) { case ABC: statements; /* falls through */ case DEF: statements; break; default: statements; break; }

True

T/F: According to Google Java Style Guide, all binary operators should be separated from their operands by a space.

True

T/F: In Javadoc, if a method can throw three checked exceptions then there should be three @throws tags on adjacent lines listing the exceptions in alphabetical order.

True

T/F: In Javadoc, the documenting of an unchecked exception with a @exception tag or a @throws tag is optional

True

What character encoding should be used for all Java source files?

UTF-8

In linux, which command is used to copy files?

cp

Preferred identifier for the naming of a package containing code from Elon for a graphical user interface

edu.elon.gui

In the git bash shell, what is the name of the git command to move all of your changes since your last commit to the staging area

git add

What is the name of the git command to compare two commits and prints each line present in one commit and not the other

git diff

What is the name of the git command to put the most recent commit up on the remote repository?

git push

Which linux command is used to make a new directory?

mkdir

What method checks that a condition is false?

void assertFalse(boolean condition)


Ensembles d'études connexes

LearningCurve 4a: Sensation and Perception Are Distinct Activities (LO 4.1-4.3)

View Set

Exam 1 - Evolution & History of Life

View Set

business analytics chapter 1 quiz

View Set

The Kreb's Cycle and Electron Transport

View Set

American Politics Chapter 11 (Qz 9)

View Set

Physical Geography of the US and Canada

View Set

TOPIC 7: PERFORMANCE MANAGEMENT (End of Topic Review)

View Set