Ross Laidlaw created OODT-573:
---------------------------------
Summary: Suggested refactoring for return statement in
getTopNProducts method in LuceneCatalog class
Key: OODT-573
URL: https://issues.apache.org/jira/browse/OODT-573
Project: OODT
Issue Type: Improvement
Components: file manager
Affects Versions: 0.6
Reporter: Ross Laidlaw
Assignee: Ross Laidlaw
Priority: Trivial
Fix For: 0.6
The getTopNProducts method in org.apache.oodt.cas.filemgr.catalog.LuceneCatalog
currently has the following return statement:
{code:title=LuceneCatalog.java|borderStyle=solid}
public List<Product> getTopNProducts(int n, ProductType type) throws
CatalogException
{
...
if (products != null) {
return products;
} else
return null;
}
{code}
I believe that we can replace the above statement with the following:
{code:title=LuceneCatalog.java|borderStyle=solid}
public List<Product> getTopNProducts(int n, ProductType type) throws
CatalogException
{
...
return products;
}
{code}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira