Removed AvoidStarImport Rule
Added JavaDocType Rule
This commit is contained in:
@ -23,36 +23,39 @@
|
||||
package com.iluwatar.semaphore;
|
||||
|
||||
/**
|
||||
* Fruit is a resource stored in a FruitBowl.
|
||||
* Fruit is a resource stored in a FruitBowl.
|
||||
*/
|
||||
public class Fruit {
|
||||
|
||||
/**
|
||||
* Enumeration of Fruit Types
|
||||
*/
|
||||
public static enum FruitType {
|
||||
ORANGE, APPLE, LEMON
|
||||
}
|
||||
|
||||
|
||||
private FruitType type;
|
||||
|
||||
|
||||
public Fruit(FruitType type) {
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
|
||||
public FruitType getType() {
|
||||
return type;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* toString method
|
||||
*/
|
||||
*/
|
||||
public String toString() {
|
||||
switch (type) {
|
||||
case ORANGE:
|
||||
return "Orange";
|
||||
case APPLE:
|
||||
case APPLE:
|
||||
return "Apple";
|
||||
case LEMON:
|
||||
case LEMON:
|
||||
return "Lemon";
|
||||
default:
|
||||
default:
|
||||
return "";
|
||||
}
|
||||
}
|
||||
|
@ -25,10 +25,13 @@ package com.iluwatar.semaphore;
|
||||
import org.junit.Test;
|
||||
import java.io.IOException;
|
||||
|
||||
/**
|
||||
* Application Test Entrypoint
|
||||
*/
|
||||
public class AppTest{
|
||||
@Test
|
||||
public void test() throws IOException {
|
||||
String[] args = {};
|
||||
App.main(args);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user