Package cn.edu.zju.acm.onlinejudge.util

Examples of cn.edu.zju.acm.onlinejudge.util.ProblemsetRankList


            int[] totalArray = new int[solved.size()];
            for (int i = 0; i < solvedArray.length; ++i) {
                solvedArray[i] = solved.get(i);
                totalArray[i] = total.get(i);
            }
            ProblemsetRankList r = new ProblemsetRankList(offset, count);
            r.setUsers(users.toArray(new UserProfile[0]));
            r.setSolved(solvedArray);
            r.setTotal(totalArray);
            return r;
        } catch (SQLException e) {
            throw new PersistenceException("Failed to get the rank list", e);
        } finally {
            Database.dispose(conn);
View Full Code Here


            if(sort==null)
            {
                sort="ac";
            }

            ProblemsetRankList ranklist =
                    StatisticsManager.getInstance().getProblemsetRankList(contest.getId(), from, count, sort);
            if (from > 0) {
                context.setAttribute("previousFrom", from - count > 0 ? from - count : 0);
            }
            if (ranklist.getSolved().length == count) {
                context.setAttribute("nextFrom", from + count);
            }

            context.setAttribute("RankList", ranklist);
        }
View Full Code Here

TOP

Related Classes of cn.edu.zju.acm.onlinejudge.util.ProblemsetRankList

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.