Resolves checkstyle errors for feature-toggle fluentinterface flux flyweight front-controller (#1078)

* Reduces checkstyle errors in feature-toggle

* Reduces checkstyle errors in fluentinterface

* Reduces checkstyle errors in flux

* Reduces checkstyle errors in flyweight

* Reduces checkstyle errors in front-controller
This commit is contained in:
Anurag Agarwal
2019-11-12 01:54:23 +05:30
committed by Ilkka Seppälä
parent c954a436ad
commit 37599eb48f
46 changed files with 197 additions and 258 deletions

View File

@ -24,9 +24,7 @@
package com.iluwatar.flux.action;
/**
*
* Action is the data payload dispatched to the stores when something happens.
*
*/
public abstract class Action {

View File

@ -24,9 +24,7 @@
package com.iluwatar.flux.action;
/**
*
* Types of actions.
*
*/
public enum ActionType {

View File

@ -24,9 +24,7 @@
package com.iluwatar.flux.action;
/**
*
* Content items.
*
*/
public enum Content {

View File

@ -24,9 +24,7 @@
package com.iluwatar.flux.action;
/**
*
* ContentAction is a concrete action.
*
*/
public class ContentAction extends Action {

View File

@ -25,9 +25,7 @@ package com.iluwatar.flux.action;
/**
*
* MenuAction is a concrete action.
*
*/
public class MenuAction extends Action {

View File

@ -24,9 +24,7 @@
package com.iluwatar.flux.action;
/**
*
* Menu items.
*
*/
public enum MenuItem {

View File

@ -31,26 +31,24 @@ import com.iluwatar.flux.view.ContentView;
import com.iluwatar.flux.view.MenuView;
/**
*
* Flux is the application architecture that Facebook uses for building client-side web
* applications. Flux eschews MVC in favor of a unidirectional data flow. When a user interacts with
* a React view, the view propagates an action through a central dispatcher, to the various stores
* that hold the application's data and business logic, which updates all of the views that are
* affected.
* <p>
* This example has two views: menu and content. They represent typical main menu and content area
* of a web page. When menu item is clicked it triggers events through the dispatcher. The events
* are received and handled by the stores updating their data as needed. The stores then notify the
* views that they should rerender themselves.
* <p>
* http://facebook.github.io/flux/docs/overview.html
*
* <p>This example has two views: menu and content. They represent typical main menu and content
* area of a web page. When menu item is clicked it triggers events through the dispatcher. The
* events are received and handled by the stores updating their data as needed. The stores then
* notify the views that they should rerender themselves.
*
* <p>http://facebook.github.io/flux/docs/overview.html
*/
public class App {
/**
* Program entry point
*
* Program entry point.
*
* @param args command line args
*/
public static void main(String[] args) {

View File

@ -23,20 +23,17 @@
package com.iluwatar.flux.dispatcher;
import java.util.LinkedList;
import java.util.List;
import com.iluwatar.flux.action.Action;
import com.iluwatar.flux.action.Content;
import com.iluwatar.flux.action.ContentAction;
import com.iluwatar.flux.action.MenuAction;
import com.iluwatar.flux.action.MenuItem;
import com.iluwatar.flux.store.Store;
import java.util.LinkedList;
import java.util.List;
/**
*
* Dispatcher sends Actions to registered Stores.
*
*/
public final class Dispatcher {
@ -44,7 +41,8 @@ public final class Dispatcher {
private List<Store> stores = new LinkedList<>();
private Dispatcher() {}
private Dispatcher() {
}
public static Dispatcher getInstance() {
return instance;
@ -55,7 +53,7 @@ public final class Dispatcher {
}
/**
* Menu item selected handler
* Menu item selected handler.
*/
public void menuItemSelected(MenuItem menuItem) {
dispatchAction(new MenuAction(menuItem));

View File

@ -29,9 +29,7 @@ import com.iluwatar.flux.action.Content;
import com.iluwatar.flux.action.ContentAction;
/**
*
* ContentStore is a concrete store.
*
*/
public class ContentStore extends Store {

View File

@ -29,9 +29,7 @@ import com.iluwatar.flux.action.MenuAction;
import com.iluwatar.flux.action.MenuItem;
/**
*
* MenuStore is a concrete store.
*
*/
public class MenuStore extends Store {

View File

@ -23,16 +23,13 @@
package com.iluwatar.flux.store;
import com.iluwatar.flux.action.Action;
import com.iluwatar.flux.view.View;
import java.util.LinkedList;
import java.util.List;
import com.iluwatar.flux.action.Action;
import com.iluwatar.flux.view.View;
/**
*
* Store is a data model.
*
*/
public abstract class Store {

View File

@ -30,9 +30,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
*
* ContentView is a concrete view.
*
*/
public class ContentView implements View {

View File

@ -31,9 +31,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
*
* MenuView is a concrete view.
*
*/
public class MenuView implements View {

View File

@ -26,9 +26,7 @@ package com.iluwatar.flux.view;
import com.iluwatar.flux.store.Store;
/**
*
* Views define the representation of data.
*
*/
public interface View {