本文整理汇总了Java中org.richfaces.component.SortOrder类的典型用法代码示例。如果您正苦于以下问题:Java SortOrder类的具体用法?Java SortOrder怎么用?Java SortOrder使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
SortOrder类属于org.richfaces.component包,在下文中一共展示了SortOrder类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: init
import org.richfaces.component.SortOrder; //导入依赖的package包/类
@PostConstruct
public void init() {
HashMap<String, TableColumns> columnNamesMapping = getColumnNamesMapping();
columnNamesMapping.put(PURCHASE_ORDER_NUMBER, TableColumns.PURCHASE_ORDER_NUMBER);
columnNamesMapping.put(SERVICE_NAME, TableColumns.SERVICE_NAME);
columnNamesMapping.put(SUBSCRIPTION_ID, TableColumns.SUBSCRIPTION_ID);
columnNamesMapping.put(UNIT, TableColumns.UNIT);
columnNamesMapping.put(ACTIVATION, TableColumns.ACTIVATION_TIME);
columnNamesMapping.put(STATUS, TableColumns.STATUS);
getSortOrders().put(PURCHASE_ORDER_NUMBER, SortOrder.unsorted);
getSortOrders().put(SERVICE_NAME, SortOrder.unsorted);
getSortOrders().put(SUBSCRIPTION_ID, SortOrder.unsorted);
getSortOrders().put(UNIT, SortOrder.unsorted);
getSortOrders().put(ACTIVATION, SortOrder.descending);
getSortOrders().put(STATUS, SortOrder.unsorted);
}
示例2: init
import org.richfaces.component.SortOrder; //导入依赖的package包/类
@PostConstruct
public void init() {
Map<String, TableColumns> columnNamesMapping = getColumnNamesMapping();
columnNamesMapping.put(CUSTOMER_NAME, TableColumns.CUSTOMER_NAME);
columnNamesMapping.put(CUSTOMER_ID, TableColumns.CUSTOMER_ID);
columnNamesMapping.put(SUBSCRIPTION_ID, TableColumns.SUBSCRIPTION_ID);
columnNamesMapping.put(ACTIVATION_TIME, TableColumns.ACTIVATION_TIME);
columnNamesMapping.put(SERVICE_NAME, TableColumns.SERVICE_NAME);
getSortOrders().put(CUSTOMER_NAME, SortOrder.unsorted);
getSortOrders().put(CUSTOMER_ID, SortOrder.unsorted);
getSortOrders().put(SUBSCRIPTION_ID, SortOrder.unsorted);
getSortOrders().put(ACTIVATION_TIME, SortOrder.descending);
getSortOrders().put(SERVICE_NAME, SortOrder.unsorted);
}
示例3: get
import org.richfaces.component.SortOrder; //导入依赖的package包/类
@Override
public SortOrder get(Object key) {
SortOrder value = super.get(key);
if (value == null && key.toString().endsWith(DEFAULT_COLUM_SUFFIX)) {
value = SortOrder.ascending;
}
return value;
}
示例4: init
import org.richfaces.component.SortOrder; //导入依赖的package包/类
@PostConstruct
public void init() {
getColumnNamesMapping().put(PURCHASE_ORDER_NUMBER, TableColumns.PURCHASE_ORDER_NUMBER);
getColumnNamesMapping().put(SERVICE_NAME, TableColumns.SERVICE_NAME);
getColumnNamesMapping().put(SUBSCRIPTION_ID, TableColumns.SUBSCRIPTION_ID);
getColumnNamesMapping().put(ACTIVATION, TableColumns.ACTIVATION_TIME);
getColumnNamesMapping().put(STATUS, TableColumns.STATUS);
getSortOrders().put(PURCHASE_ORDER_NUMBER, SortOrder.unsorted);
getSortOrders().put(SERVICE_NAME, SortOrder.unsorted);
getSortOrders().put(SUBSCRIPTION_ID, SortOrder.unsorted);
getSortOrders().put(ACTIVATION, SortOrder.descending);
getSortOrders().put(STATUS, SortOrder.unsorted);
}
示例5: init
import org.richfaces.component.SortOrder; //导入依赖的package包/类
@PostConstruct
public void init() {
getColumnNamesMapping().put(USER_ID, TableColumns.USER_ID);
getColumnNamesMapping().put(FIRST_NAME, TableColumns.FIRST_NAME);
getColumnNamesMapping().put(LAST_NAME, TableColumns.LAST_NAME);
getColumnNamesMapping().put(ROLE_IN_UNIT, TableColumns.ROLE_IN_UNIT);
getSortOrders().put(USER_ID, SortOrder.unsorted);
getSortOrders().put(FIRST_NAME, SortOrder.unsorted);
getSortOrders().put(LAST_NAME, SortOrder.unsorted);
getSortOrders().put(ROLE_IN_UNIT, SortOrder.unsorted);
}
示例6: init
import org.richfaces.component.SortOrder; //导入依赖的package包/类
@PostConstruct
public void init() {
getColumnNamesMapping().put(SUBSCRIPTION_ID,
TableColumns.SUBSCRIPTION_ID);
getColumnNamesMapping().put(ROLE_IN_SUB, TableColumns.ROLE_IN_SUB);
getSortOrders().put(SUBSCRIPTION_ID, SortOrder.unsorted);
getSortOrders().put(ROLE_IN_SUB, SortOrder.unsorted);
}
示例7: testColumnSortingMap_Default
import org.richfaces.component.SortOrder; //导入依赖的package包/类
@Test
public void testColumnSortingMap_Default() {
String key = CLIENTID
+ TableState.ColumnSortingMap.DEFAULT_COLUM_SUFFIX;
ColumnSortingMap map = new TableState.ColumnSortingMap();
assertEquals(SortOrder.ascending, map.get(key));
}
示例8: testColumnSortingMap
import org.richfaces.component.SortOrder; //导入依赖的package包/类
@Test
public void testColumnSortingMap() {
SortOrder value = SortOrder.descending;
ColumnSortingMap map = new TableState.ColumnSortingMap();
map.put(CLIENTID, value);
assertSame(value, map.get(CLIENTID));
}
示例9: bug11725
import org.richfaces.component.SortOrder; //导入依赖的package包/类
@Test
public void bug11725() {
//given
//when
model.init();
//then
assertEquals(SortOrder.descending, model.getSortOrders().get(model.getACTIVATION()));
}
示例10: bug11725
import org.richfaces.component.SortOrder; //导入依赖的package包/类
@Test
public void bug11725() {
//given
//when
beanUnderTheTest.init();
//then
assertEquals(SortOrder.descending, beanUnderTheTest.getSortOrders().get(beanUnderTheTest.getACTIVATION()));
}
示例11: setSortOrderToFirstName
import org.richfaces.component.SortOrder; //导入依赖的package包/类
public void setSortOrderToFirstName() {
if (SortOrder.ascending == sortOrderFirstName) {
sortOrderFirstName = SortOrder.descending;
} else {
sortOrderFirstName = SortOrder.ascending;
}
sortOrderLastName = SortOrder.unsorted;
sortOrderSpecialties = SortOrder.unsorted;
}
示例12: setSortOrderToLastName
import org.richfaces.component.SortOrder; //导入依赖的package包/类
public void setSortOrderToLastName() {
sortOrderFirstName = SortOrder.unsorted;
if (SortOrder.ascending==sortOrderLastName) {
sortOrderLastName = SortOrder.descending;
} else {
sortOrderLastName = SortOrder.ascending;
}
sortOrderSpecialties = SortOrder.unsorted;
}
示例13: setSortOrderToSpecialties
import org.richfaces.component.SortOrder; //导入依赖的package包/类
public void setSortOrderToSpecialties() {
sortOrderFirstName = SortOrder.unsorted;
sortOrderLastName = SortOrder.unsorted;
if (SortOrder.ascending==sortOrderSpecialties) {
sortOrderSpecialties = SortOrder.descending;
} else {
sortOrderSpecialties = SortOrder.ascending;
}
}
示例14: switchSortOrder
import org.richfaces.component.SortOrder; //导入依赖的package包/类
public void switchSortOrder(){
if(petTypeSortOrder == SortOrder.ascending){
petTypeSortOrder = SortOrder.descending;
} else {
petTypeSortOrder = SortOrder.ascending;
}
}
示例15: switchSortOrder
import org.richfaces.component.SortOrder; //导入依赖的package包/类
public void switchSortOrder(){
if(specialtySortOrder==SortOrder.ascending){
specialtySortOrder=SortOrder.descending;
} else {
specialtySortOrder=SortOrder.ascending;
}
}