public boolean isExpired(){
  return paymentDetails.hasExpires() && System.currentTimeMillis() / 1000L > paymentDetails.getExpires();
}

public boolean isExpired ( ) { return paymentDetails . hasExpires ( ) && System . currentTimeMillis ( ) / 1000L > paymentDetails . getExpires ( ) ; }
this should always be called before attempting to call sendpayment .
