我想收集以下 12 个指标(TotalEmail、SentEmail 等)。为此,我使用了本地方法(getValues())。因为我使用了 12 个 Statement 和 ResultSet 对象。它工作正常。你能建议我任何其他方法来减少变量的内存使用吗?
获取值(){
private Statement TotalEmail = null;
private Statement SentEmail = null;
private Statement FailEmail = null;
private Statement ActiveUser = null;
private Statement FailLogin = null;
private Statement SentLogin = null;
private Statement TotalBilling = null;
private Statement FailBilling = null;
private Statement SuccessBilling= null;
private Statement TotalSubmission = null;
private Statement FailSubmission = null;
private Statement SuccessSubmission = null;
private ResultSet TotalEmailRS = null;
private ResultSet SentEmailRS = null;
private ResultSet FailEmailRS = null;
private ResultSet ActiveUserRS = null;
private ResultSet FailLoginRS = null;
private ResultSet SentLoginRS = null;
private ResultSet TotalBillingRS = null;
private ResultSet FailBillingRS = null;
private ResultSet SuccessBillingRS = null;
private ResultSet TotalSubmissionRS = null;
private ResultSet FailSubmissionRS = null;
private ResultSet SuccessSubmissionRS = null;
}