@ Override public void run ( ) { long bidId = m_bidId ++ ; long advertiserId = Math . abs ( m_rand . nextLong ( ) ) % NUM_ADVERTISERS ; GeographyValue bidRegion = Regions . pickRandomRegion ( ) ; TimestampType bidStartTime = new TimestampType ( ) ; TimestampType bidEndTime = new TimestampType ( bidStartTime . getTime ( ) + AdBrokerBenchmark . BID_DURATION_SECONDS * 1000000 ) ; // Amount of bid: a hundredth of a penny up to around a tenth of a penny. double amount = 0.00001 + 0.01 * m_rand . nextDouble ( ) ; DecimalFormat df = new DecimalFormat ( "#.####" ) ; amount = Double . valueOf ( df . format ( amount ) ) ; try { m_client . callProcedure ( new NullCallback ( ) , "bids.Insert" , bidId , advertiserId , bidRegion , bidStartTime , bidEndTime , amount ) ; } catch ( Exception e ) { e . printStackTrace ( ) ; } }
This is the run method for this Runnable subclass .