|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.ikasan.console.web.controller.MasterDetailControllerUtil
public class MasterDetailControllerUtil
Common utility functions used by MVC controllers that deal with paged Master/Detail search functions
| Constructor Summary | |
|---|---|
MasterDetailControllerUtil()
|
|
| Method Summary | |
|---|---|
static void |
addPagedModelAttributes(String orderBy,
Boolean orderAsc,
String pointToPointFlowProfileSearch,
Boolean pointToPointFlowProfileSelectAll,
Boolean moduleSelectAll,
org.springframework.ui.ModelMap model,
int pageNo,
int pageSize,
PagedSearchResult<?> pagedResult,
javax.servlet.http.HttpServletRequest request,
Map<String,Object> searchParams)
Adds all standard control attributes to the model for displaying the search results page |
static void |
addParam(Map<String,Object> searchParams,
String paramName,
Object paramValue)
Adds a parameter to the searchParams map, only if it has a value |
static boolean |
defaultFalse(Boolean input)
Standardises the input field to use false if otherwise not supplied |
static boolean |
defaultTrue(Boolean input)
Standardises the input field to use true if otherwise not supplied |
static int |
defaultZero(Integer input)
Returns the input value if not null, otherwise 0 |
static String |
nullForEmpty(String input)
Returns the input value or null for an empty String |
static String |
resolveOrderBy(String orderBy)
Returns the input value if not null, otherwise "id" |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public MasterDetailControllerUtil()
| Method Detail |
|---|
public static void addParam(Map<String,Object> searchParams,
String paramName,
Object paramValue)
searchParams - - The search parameters map to add toparamName - - The name of the parameter to addparamValue - - The value of the parameter to add
public static void addPagedModelAttributes(String orderBy,
Boolean orderAsc,
String pointToPointFlowProfileSearch,
Boolean pointToPointFlowProfileSelectAll,
Boolean moduleSelectAll,
org.springframework.ui.ModelMap model,
int pageNo,
int pageSize,
PagedSearchResult<?> pagedResult,
javax.servlet.http.HttpServletRequest request,
Map<String,Object> searchParams)
orderBy - - The field we are ordering byorderAsc - - Flag to determine if we are ordering by ascending value
or notpointToPointFlowProfileSearch - - Flag to indicate what type of searchpointToPointFlowProfileSelectAll - - Select all boolean for
pointToPointFlowProfile based searchmoduleSelectAll - - Select all boolean for pointToPointFlowProfile
based searchmodel - - The model we are displaying (the data)pageNo - - The page number we are onpageSize - - The page Size (how many results to display per page)pagedResult - - The paged result pagerequest - - standard HttpRequestsearchParams - - The search parameters we're usingpublic static boolean defaultFalse(Boolean input)
input - - The ascending order flag
public static boolean defaultTrue(Boolean input)
input - - The ascending order flag
public static String resolveOrderBy(String orderBy)
orderBy - - Field to order by
public static int defaultZero(Integer input)
input - - input
public static String nullForEmpty(String input)
input - - input
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||