Пример #1
0
 public static DataSet generate(Player player)
 {
     // this isn't a real query, just an example
     string statement = String.Format("SELECT * ",
                                      "FROM player ",
                                      "WHERE player = '{0}'", player.name);
     return DBUtil.runQuery(statement);
 }
Пример #2
0
 public static DataSet playerStatistic(string playerName)
 {
     Player player = new Player(playerName);
     // could just return this result, or maybe set up player.statistic w/ a new PlayerStatistic
     // set of info derived from the result of PlayerStatisticFactory.generate(player). then you
     // could do more with the data before returning the results. that's up to you. either way,
     // this is where this kind of stuff goes.
     return PlayerStatisticFactory.generate(player);
 }