Return-Path: X-Original-To: apmail-poi-commits-archive@minotaur.apache.org Delivered-To: apmail-poi-commits-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 03E9710332 for ; Wed, 14 Aug 2013 08:26:17 +0000 (UTC) Received: (qmail 54414 invoked by uid 500); 14 Aug 2013 08:26:16 -0000 Delivered-To: apmail-poi-commits-archive@poi.apache.org Received: (qmail 54373 invoked by uid 500); 14 Aug 2013 08:26:15 -0000 Mailing-List: contact commits-help@poi.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@poi.apache.org Delivered-To: mailing list commits@poi.apache.org Received: (qmail 54362 invoked by uid 99); 14 Aug 2013 08:26:15 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 14 Aug 2013 08:26:15 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 14 Aug 2013 08:26:12 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id B729223889BF; Wed, 14 Aug 2013 08:25:52 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1513764 - in /poi/trunk/src: contrib/poi-ruby/java/org/apache/poi/ excelant/java/org/apache/poi/ss/excelant/util/ java/org/apache/poi/hssf/model/ java/org/apache/poi/hssf/usermodel/ java/org/apache/poi/ss/formula/function/ ooxml/java/org/a... Date: Wed, 14 Aug 2013 08:25:52 -0000 To: commits@poi.apache.org From: centic@apache.org X-Mailer: svnmailer-1.0.9 Message-Id: <20130814082552.B729223889BF@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: centic Date: Wed Aug 14 08:25:51 2013 New Revision: 1513764 URL: http://svn.apache.org/r1513764 Log: Various small Eclipse warning fixes, also ensure close() of stream in Ant-Task, although WorkbookFactory usually takes care of this, however in exception-cases it could be missing Modified: poi/trunk/src/contrib/poi-ruby/java/org/apache/poi/RubyOutputStream.java poi/trunk/src/excelant/java/org/apache/poi/ss/excelant/util/ExcelAntWorkbookUtil.java poi/trunk/src/excelant/java/org/apache/poi/ss/excelant/util/ExcelAntWorkbookUtilFactory.java poi/trunk/src/java/org/apache/poi/hssf/model/CommentShape.java poi/trunk/src/java/org/apache/poi/hssf/usermodel/HSSFWorkbook.java poi/trunk/src/java/org/apache/poi/ss/formula/function/FunctionMetadataReader.java poi/trunk/src/ooxml/java/org/apache/poi/util/OOXMLLite.java poi/trunk/src/ooxml/java/org/apache/poi/xssf/usermodel/helpers/XSSFFormulaUtils.java Modified: poi/trunk/src/contrib/poi-ruby/java/org/apache/poi/RubyOutputStream.java URL: http://svn.apache.org/viewvc/poi/trunk/src/contrib/poi-ruby/java/org/apache/poi/RubyOutputStream.java?rev=1513764&r1=1513763&r2=1513764&view=diff ============================================================================== --- poi/trunk/src/contrib/poi-ruby/java/org/apache/poi/RubyOutputStream.java (original) +++ poi/trunk/src/contrib/poi-ruby/java/org/apache/poi/RubyOutputStream.java Wed Aug 14 08:25:51 2013 @@ -29,7 +29,7 @@ import java.io.IOException; public class RubyOutputStream extends OutputStream { - //pointer to native ruby VALUE + //pointer to native ruby VALUE protected long rubyIO; public RubyOutputStream (long rubyIO) @@ -38,7 +38,8 @@ public class RubyOutputStream extends Ou // incRef(); } - protected void finalize() + @Override + protected void finalize() throws Throwable { // decRef(); @@ -47,13 +48,15 @@ public class RubyOutputStream extends Ou // protected native void incRef(); // protected native void decRef(); - public native void close() + @Override + public native void close() throws IOException; /* (non-Javadoc) * @see java.io.OutputStream#write(int) */ + @Override public native void write(int arg0) throws IOException; } Modified: poi/trunk/src/excelant/java/org/apache/poi/ss/excelant/util/ExcelAntWorkbookUtil.java URL: http://svn.apache.org/viewvc/poi/trunk/src/excelant/java/org/apache/poi/ss/excelant/util/ExcelAntWorkbookUtil.java?rev=1513764&r1=1513763&r2=1513764&view=diff ============================================================================== --- poi/trunk/src/excelant/java/org/apache/poi/ss/excelant/util/ExcelAntWorkbookUtil.java (original) +++ poi/trunk/src/excelant/java/org/apache/poi/ss/excelant/util/ExcelAntWorkbookUtil.java Wed Aug 14 08:25:51 2013 @@ -41,10 +41,10 @@ import java.util.Iterator; /** * A general utility class that abstracts the POI details of loading the * workbook, accessing and updating cells. - * + * * @author Jon Svede ( jon [at] loquatic [dot] com ) * @author Brian Bush ( brian [dot] bush [at] nrel [dot] gov ) - * + * */ public class ExcelAntWorkbookUtil extends Typedef { @@ -53,24 +53,24 @@ public class ExcelAntWorkbookUtil extend private Workbook workbook; private HashMap xlsMacroList; - + /** * Constructs an instance using a String that contains the fully qualified * path of the Excel file. This constructor initializes a Workbook instance * based on that file name. - * + * * @param fName */ protected ExcelAntWorkbookUtil(String fName) { excelFileName = fName; xlsMacroList = new HashMap() ; loadWorkbook(); - + } /** * Constructs an instance based on a Workbook instance. - * + * * @param wb */ protected ExcelAntWorkbookUtil(Workbook wb) { @@ -87,7 +87,11 @@ public class ExcelAntWorkbookUtil extend File workbookFile = new File(excelFileName); try { FileInputStream fis = new FileInputStream(workbookFile); - workbook = WorkbookFactory.create(fis); + try { + workbook = WorkbookFactory.create(fis); + } finally { + fis.close(); + } } catch(Exception e) { throw new BuildException("Cannot load file " + excelFileName + ". Make sure the path and file permissions are correct.", e); @@ -95,9 +99,9 @@ public class ExcelAntWorkbookUtil extend return workbook ; } - + /** - * Used to add a UDF to the evaluator. + * Used to add a UDF to the evaluator. * @param name * @param clazzName * @throws ClassNotFoundException @@ -105,18 +109,18 @@ public class ExcelAntWorkbookUtil extend * @throws IllegalAccessException */ public void addFunction( String name, String clazzName ) throws ClassNotFoundException, InstantiationException, IllegalAccessException { - Class clazzInst = Class.forName( clazzName ) ; + Class clazzInst = Class.forName( clazzName ) ; Object newInst = clazzInst.newInstance() ; if( newInst instanceof FreeRefFunction ) { addFunction( name, (FreeRefFunction)newInst ) ; } - + } - + /** * Updates the internal HashMap of functions with instance and alias passed * in. - * + * * @param name * @param func */ @@ -126,7 +130,7 @@ public class ExcelAntWorkbookUtil extend /** * returns a UDFFinder that contains all of the functions added. - * + * * @return */ protected UDFFinder getFunctions() { @@ -149,17 +153,17 @@ public class ExcelAntWorkbookUtil extend return udff; } - + /** * Returns a formula evaluator that is loaded with the functions that * have been supplied. - * - * @param excelFileName + * + * @param fileName * @return */ - protected FormulaEvaluator getEvaluator( String excelFileName ) { + protected FormulaEvaluator getEvaluator( String fileName ) { FormulaEvaluator evaluator ; - if (excelFileName.endsWith(".xlsx")) { + if (fileName.endsWith(".xlsx")) { if( xlsMacroList != null && xlsMacroList.size() > 0 ) { evaluator = XSSFFormulaEvaluator.create( (XSSFWorkbook) workbook, null, @@ -182,7 +186,7 @@ public class ExcelAntWorkbookUtil extend /** * Returns the Workbook instance associated with this WorkbookUtil. - * + * * @return */ public Workbook getWorkbook() { @@ -192,34 +196,34 @@ public class ExcelAntWorkbookUtil extend /** * Returns the fileName that was used to initialize this instance. May * return null if the instance was constructed from a Workbook object. - * + * * @return */ public String getFileName() { return excelFileName; } - + /** * Returns the list of sheet names. - * + * * @return */ public ArrayList getSheets() { ArrayList sheets = new ArrayList() ; - + int sheetCount = workbook.getNumberOfSheets() ; - + for( int x=0; x workbookUtilMap ; - + private static ExcelAntWorkbookUtilFactory factory ; - + private ExcelAntWorkbookUtilFactory() { - workbookUtilMap = new HashMap() ; + workbookUtilMap = new HashMap() ; } - + /** - * Using the fileName, check the internal map to see if an instance + * Using the fileName, check the internal map to see if an instance * of the WorkbookUtil exists. If not, then add an instance to the map. - * + * * @param fileName * @return */ public static ExcelAntWorkbookUtil getInstance( String fileName ) { - + if( factory == null ) { factory = new ExcelAntWorkbookUtilFactory() ; } - if( workbookUtilMap != null && + if( workbookUtilMap != null && workbookUtilMap.containsKey( fileName ) ) { return workbookUtilMap.get( fileName ) ; - } else { - ExcelAntWorkbookUtil wbu = new ExcelAntWorkbookUtil( fileName ) ; - workbookUtilMap.put( fileName, wbu ) ; - return wbu ; } + + ExcelAntWorkbookUtil wbu = new ExcelAntWorkbookUtil( fileName ) ; + workbookUtilMap.put( fileName, wbu ) ; + return wbu ; } } Modified: poi/trunk/src/java/org/apache/poi/hssf/model/CommentShape.java URL: http://svn.apache.org/viewvc/poi/trunk/src/java/org/apache/poi/hssf/model/CommentShape.java?rev=1513764&r1=1513763&r2=1513764&view=diff ============================================================================== --- poi/trunk/src/java/org/apache/poi/hssf/model/CommentShape.java (original) +++ poi/trunk/src/java/org/apache/poi/hssf/model/CommentShape.java Wed Aug 14 08:25:51 2013 @@ -99,7 +99,8 @@ public final class CommentShape extends * @param opt The escher records holding the proerties * @return number of escher options added */ - protected int addStandardOptions( HSSFShape shape, EscherOptRecord opt ) + @Override + protected int addStandardOptions( HSSFShape shape, EscherOptRecord opt ) { super.addStandardOptions(shape, opt); Modified: poi/trunk/src/java/org/apache/poi/hssf/usermodel/HSSFWorkbook.java URL: http://svn.apache.org/viewvc/poi/trunk/src/java/org/apache/poi/hssf/usermodel/HSSFWorkbook.java?rev=1513764&r1=1513763&r2=1513764&view=diff ============================================================================== --- poi/trunk/src/java/org/apache/poi/hssf/usermodel/HSSFWorkbook.java (original) +++ poi/trunk/src/java/org/apache/poi/hssf/usermodel/HSSFWorkbook.java Wed Aug 14 08:25:51 2013 @@ -196,7 +196,7 @@ public final class HSSFWorkbook extends private static final String[] WORKBOOK_DIR_ENTRY_NAMES = { "Workbook", // as per BIFF8 spec "WORKBOOK", // Typically from third party programs - "BOOK", // Typically odd Crystal Reports exports + "BOOK", // Typically odd Crystal Reports exports }; @@ -245,7 +245,7 @@ public final class HSSFWorkbook extends { this(directory, preserveNodes); } - + /** * given a POI POIFSFileSystem object, and a specific directory * within it, read in its Workbook and populate the high and @@ -347,7 +347,7 @@ public final class HSSFWorkbook extends * the Workbook. * * @param records a collection of sheet's records. - * @param offset the offset to search at + * @param offset the offset to search at * @see org.apache.poi.hssf.record.LabelRecord * @see org.apache.poi.hssf.record.LabelSSTRecord * @see org.apache.poi.hssf.record.SSTRecord @@ -455,7 +455,8 @@ public final class HSSFWorkbook extends * deprecated May 2008 * @deprecated use setSelectedTab(int) */ - public void setSelectedTab(short index) { + @Deprecated + public void setSelectedTab(short index) { setSelectedTab((int)index); } public void setSelectedTabs(int[] indexes) { @@ -506,7 +507,8 @@ public final class HSSFWorkbook extends * deprecated May 2008 * @deprecated - Misleading name - use getActiveSheetIndex() */ - public short getSelectedTab() { + @Deprecated + public short getSelectedTab() { return (short) getActiveSheetIndex(); } @@ -523,7 +525,8 @@ public final class HSSFWorkbook extends * deprecated May 2008 * @deprecated - Misleading name - use setFirstVisibleTab() */ - public void setDisplayedTab(short index) { + @Deprecated + public void setDisplayedTab(short index) { setFirstVisibleTab(index); } @@ -537,7 +540,8 @@ public final class HSSFWorkbook extends * deprecated May 2008 * @deprecated - Misleading name - use getFirstVisibleTab() */ - public short getDisplayedTab() { + @Deprecated + public short getDisplayedTab() { return (short) getFirstVisibleTab(); } @@ -630,14 +634,16 @@ public final class HSSFWorkbook extends * @deprecated for POI internal use only (formula parsing). This method is likely to * be removed in future versions of POI. */ - public int getExternalSheetIndex(int internalSheetIndex) { + @Deprecated + public int getExternalSheetIndex(int internalSheetIndex) { return workbook.checkExternSheet(internalSheetIndex); } /** * @deprecated for POI internal use only (formula rendering). This method is likely to * be removed in future versions of POI. */ - public String findSheetNameFromExternSheet(int externSheetIndex){ + @Deprecated + public String findSheetNameFromExternSheet(int externSheetIndex){ // TODO - don't expose internal ugliness like externSheet indexes to the user model API return workbook.findSheetNameFromExternSheet(externSheetIndex); } @@ -649,7 +655,8 @@ public final class HSSFWorkbook extends * @param definedNameIndex zero-based to DEFINEDNAME or EXTERNALNAME record * @return the string representation of the defined or external name */ - public String resolveNameXText(int refIndex, int definedNameIndex) { + @Deprecated + public String resolveNameXText(int refIndex, int definedNameIndex) { // TODO - make this less cryptic / move elsewhere return workbook.resolveNameXText(refIndex, definedNameIndex); } @@ -830,7 +837,7 @@ public final class HSSFWorkbook extends public HSSFSheet getSheetAt(int index) { validateSheetIndex(index); - return (HSSFSheet) _sheets.get(index); + return _sheets.get(index); } /** @@ -849,7 +856,7 @@ public final class HSSFWorkbook extends if (sheetname.equalsIgnoreCase(name)) { - retval = (HSSFSheet) _sheets.get(k); + retval = _sheets.get(k); } } return retval; @@ -959,11 +966,12 @@ public final class HSSFWorkbook extends * @param endColumn 0 based end of repeating columns. * @param startRow 0 based start of repeating rows. * @param endRow 0 based end of repeating rows. - * + * * @deprecated use {@link HSSFSheet#setRepeatingRows(CellRangeAddress)} * or {@link HSSFSheet#setRepeatingColumns(CellRangeAddress)} */ - public void setRepeatingRowsAndColumns(int sheetIndex, + @Deprecated + public void setRepeatingRowsAndColumns(int sheetIndex, int startColumn, int endColumn, int startRow, int endRow) { HSSFSheet sheet = getSheetAt(sheetIndex); @@ -999,16 +1007,16 @@ public final class HSSFWorkbook extends return -1; } - + HSSFName createBuiltInName(byte builtinCode, int sheetIndex) { - NameRecord nameRecord = + NameRecord nameRecord = workbook.createBuiltInName(builtinCode, sheetIndex + 1); HSSFName newName = new HSSFName(this, nameRecord, null); names.add(newName); return newName; } - + HSSFName getBuiltInName(byte builtinCode, int sheetIndex) { int index = findExistingBuiltinNameRecordIdx(sheetIndex, builtinCode); if (index < 0) { @@ -1018,7 +1026,7 @@ public final class HSSFWorkbook extends } } - + /** * create a new Font and add it to the workbook's font table * @return new font object @@ -1168,7 +1176,8 @@ public final class HSSFWorkbook extends * @see org.apache.poi.poifs.filesystem.POIFSFileSystem */ - public void write(OutputStream stream) + @Override + public void write(OutputStream stream) throws IOException { byte[] bytes = getBytes(); @@ -1294,7 +1303,8 @@ public final class HSSFWorkbook extends /** @deprecated Do not call this method from your applications. Use the methods * available in the HSSFRow to add string HSSFCells */ - public int addSSTString(String string) + @Deprecated + public int addSSTString(String string) { return workbook.addSSTString(new UnicodeString(string)); } @@ -1302,7 +1312,8 @@ public final class HSSFWorkbook extends /** @deprecated Do not call this method from your applications. Use the methods * available in the HSSFRow to get string HSSFCells */ - public String getSSTString(int index) + @Deprecated + public String getSSTString(int index) { return workbook.getSSTString(index).getString(); } @@ -1321,7 +1332,7 @@ public final class HSSFWorkbook extends if (nameIndex < 0) { return null; } - return (HSSFName) names.get(nameIndex); + return names.get(nameIndex); } public HSSFName getNameAt(int nameIndex) { @@ -1333,7 +1344,7 @@ public final class HSSFWorkbook extends throw new IllegalArgumentException("Specified name index " + nameIndex + " is outside the allowable range (0.." + (nNames-1) + ")."); } - return (HSSFName) names.get(nameIndex); + return names.get(nameIndex); } public NameRecord getNameRecord(int nameIndex) { @@ -1452,12 +1463,12 @@ public final class HSSFWorkbook extends /** - * As {@link #getNameIndex(String)} is not necessarily unique + * As {@link #getNameIndex(String)} is not necessarily unique * (name + sheet index is unique), this method is more accurate. - * + * * @param name the name whose index in the list of names of this workbook * should be looked up. - * @return an index value >= 0 if the name was found; -1, if the name was + * @return an index value >= 0 if the name was found; -1, if the name was * not found */ int getNameIndex(HSSFName name) { @@ -1495,9 +1506,9 @@ public final class HSSFWorkbook extends /** - * As {@link #removeName(String)} is not necessarily unique + * As {@link #removeName(String)} is not necessarily unique * (name + sheet index is unique), this method is more accurate. - * + * * @param name the name to remove. */ void removeName(HSSFName name) { @@ -1580,7 +1591,7 @@ public final class HSSFWorkbook extends public int addPicture(byte[] pictureData, int format) { initDrawings(); - + byte[] uid = DigestUtils.md5(pictureData); EscherBitmapBlip blipRecord = new EscherBitmapBlip(); blipRecord.setRecordId( (short) ( EscherBitmapBlip.RECORD_ID_START + format ) ); @@ -1667,14 +1678,14 @@ public final class HSSFWorkbook extends HSSFPictureData picture = new HSSFPictureData(blip); pictures.add(picture); } - - + + } // Recursive call. searchForPictures(escherRecord.getChildRecords(), pictures); } - + } /** @@ -1731,7 +1742,7 @@ public final class HSSFWorkbook extends } /** * Recursively iterates a shape container to get all embedded objects. - * + * * @param parent the parent. * @param objects the list of embedded objects to populate. */ @@ -1806,7 +1817,7 @@ public final class HSSFWorkbook extends /** * Changes an external referenced file to another file. - * A formular in Excel which refers a cell in another file is saved in two parts: + * A formular in Excel which refers a cell in another file is saved in two parts: * The referenced file is stored in an reference table. the row/cell information is saved separate. * This method invokation will only change the reference in the lookup-table itself. * @param oldUrl The old URL to search for and which is to be replaced Modified: poi/trunk/src/java/org/apache/poi/ss/formula/function/FunctionMetadataReader.java URL: http://svn.apache.org/viewvc/poi/trunk/src/java/org/apache/poi/ss/formula/function/FunctionMetadataReader.java?rev=1513764&r1=1513763&r2=1513764&view=diff ============================================================================== --- poi/trunk/src/java/org/apache/poi/ss/formula/function/FunctionMetadataReader.java (original) +++ poi/trunk/src/java/org/apache/poi/ss/formula/function/FunctionMetadataReader.java Wed Aug 14 08:25:51 2013 @@ -31,13 +31,13 @@ import org.apache.poi.ss.formula.ptg.Ptg /** * Converts the text meta-data file into a FunctionMetadataRegistry - * + * * @author Josh Micich */ final class FunctionMetadataReader { private static final String METADATA_FILE_NAME = "functionMetadata.txt"; - + /** plain ASCII text metadata file uses three dots for ellipsis */ private static final String ELLIPSIS = "..."; @@ -50,7 +50,7 @@ final class FunctionMetadataReader { // except in these cases "LOG10", "ATAN2", "DAYS360", "SUMXMY2", "SUMX2MY2", "SUMX2PY2", }; - private static final Set DIGIT_ENDING_FUNCTION_NAMES_SET = new HashSet(Arrays.asList(DIGIT_ENDING_FUNCTION_NAMES)); + private static final Set DIGIT_ENDING_FUNCTION_NAMES_SET = new HashSet(Arrays.asList(DIGIT_ENDING_FUNCTION_NAMES)); public static FunctionMetadataRegistry createRegistry() { InputStream is = FunctionMetadataReader.class.getResourceAsStream(METADATA_FILE_NAME); @@ -106,10 +106,10 @@ final class FunctionMetadataReader { validateFunctionName(functionName); // TODO - make POI use isVolatile - fdb.add(functionIndex, functionName, minParams, maxParams, + fdb.add(functionIndex, functionName, minParams, maxParams, returnClassCode, parameterClassCodes, hasNote); } - + private static byte parseReturnTypeCode(String code) { if(code.length() == 0) { @@ -163,7 +163,7 @@ final class FunctionMetadataReader { } /** - * Makes sure that footnote digits from the original OOO document have not been accidentally + * Makes sure that footnote digits from the original OOO document have not been accidentally * left behind */ private static void validateFunctionName(String functionName) { @@ -181,7 +181,7 @@ final class FunctionMetadataReader { if(DIGIT_ENDING_FUNCTION_NAMES_SET.contains(functionName)) { return; } - throw new RuntimeException("Invalid function name '" + functionName + throw new RuntimeException("Invalid function name '" + functionName + "' (is footnote number incorrectly appended)"); } Modified: poi/trunk/src/ooxml/java/org/apache/poi/util/OOXMLLite.java URL: http://svn.apache.org/viewvc/poi/trunk/src/ooxml/java/org/apache/poi/util/OOXMLLite.java?rev=1513764&r1=1513763&r2=1513764&view=diff ============================================================================== --- poi/trunk/src/ooxml/java/org/apache/poi/util/OOXMLLite.java (original) +++ poi/trunk/src/ooxml/java/org/apache/poi/util/OOXMLLite.java Wed Aug 14 08:25:51 2013 @@ -17,6 +17,7 @@ package org.apache.poi.util; +import junit.framework.TestCase; import junit.framework.TestSuite; import junit.textui.TestRunner; @@ -92,7 +93,8 @@ public final class OOXMLLite { String cls = arg.replace(".class", ""); try { - Class test = Class.forName(cls); + @SuppressWarnings("unchecked") + Class test = (Class) Class.forName(cls); suite.addTestSuite(test); } catch (ClassNotFoundException e) { throw new RuntimeException(e); @@ -115,7 +117,7 @@ public final class OOXMLLite { /** * Copy classes and interfaces declared as members of this class */ - for(Class fc : cls.getDeclaredClasses()){ + for(Class fc : cls.getDeclaredClasses()){ className = fc.getName(); classRef = className.replace('.', '/') + ".class"; destFile = new File(_destDest, classRef); @@ -159,7 +161,7 @@ public final class OOXMLLite { /** * - * @param ptrn the pattern to filter output + * @param ptrn the pattern to filter output * @return the classes loaded by the system class loader keyed by class name */ @SuppressWarnings("unchecked") Modified: poi/trunk/src/ooxml/java/org/apache/poi/xssf/usermodel/helpers/XSSFFormulaUtils.java URL: http://svn.apache.org/viewvc/poi/trunk/src/ooxml/java/org/apache/poi/xssf/usermodel/helpers/XSSFFormulaUtils.java?rev=1513764&r1=1513763&r2=1513764&view=diff ============================================================================== --- poi/trunk/src/ooxml/java/org/apache/poi/xssf/usermodel/helpers/XSSFFormulaUtils.java (original) +++ poi/trunk/src/ooxml/java/org/apache/poi/xssf/usermodel/helpers/XSSFFormulaUtils.java Wed Aug 14 08:25:51 2013 @@ -77,8 +77,10 @@ public final class XSSFFormulaUtils { } public String getSheetNameByExternSheet(int externSheetIndex) { - if (externSheetIndex == sheetIndex) return name; - else return _fpwb.getSheetNameByExternSheet(externSheetIndex); + if (externSheetIndex == sheetIndex) + return name; + + return _fpwb.getSheetNameByExternSheet(externSheetIndex); } public String resolveNameXText(NameXPtg nameXPtg) { --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscribe@poi.apache.org For additional commands, e-mail: commits-help@poi.apache.org