new in java.
I am generating data(e.g., 24, 16, 32, 38) in a row/column of a table. Now the data is displaying in random order. I want to display them in Descending order. Can anybody help me how to do this as I am new in Java development.
I am displaying the data using these lines of code:
case 1:
{
return history.getRssi();
}
From this Method:
public Object getValueAt( int row, int col )
{
if( null != histories && 0 <= row && row < getRowCount() )
{
try
{
History history = histories[row];
switch( col )
{
case 0:
return ( history.getCheckinTS().length() > 5 ) ? history.getCheckinTS().substring(5) : history.getCheckinTS();
case 1:
{
return history.getRssi();
}
case 2:
return history.getDeviceId();
} // switch
}
catch( Exception e )
{
System.out.println( "exception:" + e.toString() );
System.out.println( e.getStackTrace().toString() );
}
} // if ( null != tags && 0 <= row && row < tags.length )
return "";
}