如c#中 public static bool DoSQL(string SQL,out int EffectColumsCount)
同樣在java 中
怎麼做到這一點呢?
用
public static boolean DoSQL(String SQL,out int EffectColumsCount)
不行呀
...全文
684打赏收藏
請問j2ee中可否向c#那樣輸出個對象
如c#中 public static bool DoSQL(string SQL,out int EffectColumsCount) 同樣在java 中 怎麼做到這一點呢? 用 public static boolean DoSQL(String SQL,out int EffectColumsCount) 不行呀
解决方法:
编写一个小对象类:
public class SQLResult{
public boolean successful = false;
public int effectColumnsCount = 0;
}
用
public static void doSQL(String SQL, SQLResult result);
或者
public static SQLResult doSQL(String SQL);