Changeset 7820 for lang/scala/sandbox
- Timestamp:
- 03/12/08 02:01:59 (9 months ago)
- Location:
- lang/scala/sandbox/src/jp/ryugate/apache
- Files:
-
- 2 modified
-
POI.scala (modified) (2 diffs)
-
POISpecification.scala (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
lang/scala/sandbox/src/jp/ryugate/apache/POI.scala
r7818 r7820 97 97 } 98 98 99 def getOrCreate(ci:int) = get(ci) match { // index start from 1 100 case None => hssf_row.createCell((ci-1).toShort) 101 case Some(v) => v 102 } 103 99 104 def apply(cellnum:int) = get(cellnum) match { 100 105 case None => throw new NoSuchElementException(cellnum + " (Cell not found)") … … 118 123 119 124 //-------------------------------------------- 120 def setCell(ci:int, value:String, encoding:Short):HSSFCell = { // index start from 1121 val cell = hssf_row.createCell((ci-1).toShort)125 def setCell(ci:int, value:String, encoding:Short):HSSFCell = { 126 val cell = getOrCreate(ci) 122 127 cell.setEncoding(encoding) 123 128 cell.setCellValue(value) -
lang/scala/sandbox/src/jp/ryugate/apache/POISpecification.scala
r7818 r7820 73 73 bk.sheet(1) must notBeNull 74 74 sheet.row(1).setCell(1,"hoge").setCellStyle(style) 75 sheet.col( 2).setCell(2,"piyo").setCellStyle(style)75 sheet.col(1).setCell(1,"piyo") 76 76 sheet.setCell(3,3,"HOGE").setCellStyle(style) 77 77
![(please configure the [header_logo] section in trac.ini)](/share/chrome/site/your_project_logo.png)