1 21 package net.mlw.vlh.web.tag.support; 22 23 import java.util.Map ; 24 25 import net.mlw.vlh.ValueListInfo; 26 import net.mlw.vlh.web.tag.TableInfo; 27 28 32 public class CsvDisplayProvider implements DisplayProvider 33 { 34 35 38 public String getMimeType() 39 { 40 return "text/csv"; 41 } 42 43 46 public String getHeaderRowPreProcess() 47 { 48 return ""; 49 } 50 51 public String getHeaderCellPreProcess(ColumnInfo columnInfo, ValueListInfo info) 52 { 53 return ""; 54 } 55 56 60 public String getHeaderLabel(ColumnInfo columnInfo, TableInfo tableInfo, ValueListInfo info, Map includeParameters) 61 { 62 return columnInfo.getTitle(); 63 } 64 65 68 public String getHeaderCellPostProcess() 69 { 70 return ","; 71 } 72 73 76 public String getHeaderRowPostProcess() 77 { 78 return "\n"; 79 } 80 81 84 public String getRowPreProcess(Attributes attributes) 85 { 86 return ""; 87 } 88 89 92 public String getCellPreProcess(Attributes attributes) 93 { 94 return "\""; 95 } 96 97 100 public String getCellPostProcess() 101 { 102 return "\","; 103 } 104 105 108 public String getRowPostProcess() 109 { 110 return "\n"; 111 } 112 113 public boolean doesIncludeBodyContent() 114 { 115 return false; 116 } 117 118 124 public String emphase(String text, String emphasisPattern, String style) 125 { 126 return text; 128 } 129 130 public String getNestedHeaderPreProcess(ColumnInfo columnInfo, ValueListInfo info) 131 { 132 return ""; 133 } 134 135 public String getNestedHeaderPostProcess() 136 { 137 return ""; 138 } 139 } | Popular Tags |