本文整理汇总了Java中br.com.caelum.vraptor.Result类的典型用法代码示例。如果您正苦于以下问题:Java Result类的具体用法?Java Result怎么用?Java Result使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
Result类属于br.com.caelum.vraptor包,在下文中一共展示了Result类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: TopicController
import br.com.caelum.vraptor.Result; //导入依赖的package包/类
public TopicController(Result result, JForumConfig config,
TopicService topicService, ForumRepository forumRepository,
SmilieRepository smilieRepository, PostRepository postRepository,
TopicRepository topicRepository,
CategoryRepository categoryRepository,
RankingRepository rankingRepository, SessionManager sessionManager,
PollRepository pollRepository,
ForumLimitedTimeRepository forumLimitedTimeRepository,
AttachmentService attachmentService, HttpServletRequest request, UserSession userSession) {
this.result = result;
this.forumRepository = forumRepository;
this.smilieRepository = smilieRepository;
this.topicService = topicService;
this.postRepository = postRepository;
this.config = config;
this.topicRepository = topicRepository;
this.categoryRepository = categoryRepository;
this.rankingRepository = rankingRepository;
this.sessionManager = sessionManager;
this.pollRepository = pollRepository;
this.forumLimitedTimeRepository = forumLimitedTimeRepository;
this.attachmentService = attachmentService;
this.request = request;
this.userSession = userSession;
}
示例2: filterForumListing
import br.com.caelum.vraptor.Result; //导入依赖的package包/类
/**
* Filter the property bag for forums/show, based on group interaction
* settings
*
* @param propertyBag the property bag for the "show" method of the {@link ForumController} action
* @param userSession the user session of the current logged user
*/
public void filterForumListing(Result result, UserSession userSession) {
@SuppressWarnings("unchecked")
Collection<UserSession> sessions = (Collection<UserSession>) result.included().get("onlineUsers");
if (sessions == null) {
sessions = new ArrayList<UserSession>();
}
Set<UserSession> newSessions = new HashSet<UserSession>();
User currentUser = userSession.getUser();
for (Group group : currentUser.getGroups()) {
for (UserSession anotherUserSession : sessions) {
User user = anotherUserSession.getUser();
if (user != null && user.getGroups().contains(group)) {
newSessions.add(anotherUserSession);
}
}
}
result.include("totalLoggedUsers", newSessions.size());
result.include("onlineUsers", newSessions);
}
示例3: ModerationController
import br.com.caelum.vraptor.Result; //导入依赖的package包/类
public ModerationController(Result result, RoleManager roleManager,
ModerationService moderationService,
CategoryRepository categoryRepository,
TopicRepository topicRepository, JForumConfig config,
ModerationLogRepository logRepository, UserSession userSession) {
this.result = result;
this.roleManager = roleManager;
this.moderationService = moderationService;
this.categoryRepository = categoryRepository;
this.topicRepository = topicRepository;
this.config = config;
this.logRepository = logRepository;
this.userSession = userSession;
}
示例4: UserController
import br.com.caelum.vraptor.Result; //导入依赖的package包/类
public UserController(UserRepository userRepository, UserSession userSession, UserService userService,
SessionManager sessionFacade, JForumConfig config, LostPasswordService lostPasswordService,
AvatarService avatarService, RankingRepository rankingRepository, Result result,
HttpServletRequest request) {
this.userRepository = userRepository;
this.userService = userService;
this.sessionManager = sessionFacade;
this.userSession = userSession;
this.config = config;
this.lostPasswordService = lostPasswordService;
this.avatarService = avatarService;
this.rankingRepository = rankingRepository;
this.result = result;
this.request = request;
}
示例5: GroupAdminController
import br.com.caelum.vraptor.Result; //导入依赖的package包/类
public GroupAdminController(GroupService service, GroupRepository repository,
CategoryRepository categoryRepository, Result result, UserSession userSession,
HttpServletRequest request) {
this.service = service;
this.groupRepository = repository;
this.categoryRepository = categoryRepository;
this.userSession = userSession;
this.result = result;
this.request = request;
}
示例6: RSSController
import br.com.caelum.vraptor.Result; //导入依赖的package包/类
public RSSController(Result result, RSSService rssService,
UserSession userSession, JForumConfig config) {
this.result = result;
this.rssService = rssService;
this.userSession = userSession;
this.config = config;
}
示例7: ForumAdminController
import br.com.caelum.vraptor.Result; //导入依赖的package包/类
public ForumAdminController(ForumService service, ForumRepository forumRepository,
CategoryRepository categoryRepository, Result result, UserSession userSession) {
this.forumService = service;
this.categoryRepository = categoryRepository;
this.forumRepository = forumRepository;
this.result = result;
this.userSession = userSession;
}
示例8: PostController
import br.com.caelum.vraptor.Result; //导入依赖的package包/类
public PostController(PostRepository postRepository, SmilieRepository smilieRepository,
PostService postService, JForumConfig config, UserSession userSession,
AttachmentService attachmentService, HttpServletRequest request, Result result) {
this.postRepository = postRepository;
this.smilieRepository = smilieRepository;
this.postService = postService;
this.config = config;
this.userSession = userSession;
this.attachmentService = attachmentService;
this.request = request;
this.result = result;
}
示例9: LuceneAdminController
import br.com.caelum.vraptor.Result; //导入依赖的package包/类
public LuceneAdminController(JForumConfig config,
ForumRepository forumRepository, SessionFactory sessionFactory,
Result result) {
this.config = config;
this.forumRepository = forumRepository;
this.sessionFactory = sessionFactory;
this.result = result;
}
示例10: UserAdminController
import br.com.caelum.vraptor.Result; //导入依赖的package包/类
public UserAdminController(UserRepository repository, GroupRepository groupRepository, JForumConfig config,
UserService userService, Result result, UserSession userSession) {
this.userRepository = repository;
this.groupRepository = groupRepository;
this.config = config;
this.userService = userService;
this.result = result;
this.userSession = userSession;
}
示例11: SearchController
import br.com.caelum.vraptor.Result; //导入依赖的package包/类
public SearchController(CategoryRepository categoryRepository,
JForumConfig config, SearchRepository searchRepository,
UserSession userSession, Result result) {
this.categoryRepository = categoryRepository;
this.config = config;
this.searchRepository = searchRepository;
this.userSession = userSession;
this.result = result;
}
示例12: PrivateMessageController
import br.com.caelum.vraptor.Result; //导入依赖的package包/类
public PrivateMessageController(PrivateMessageRepository repository, UserRepository userRepository,
PrivateMessageService service, Result result, UserSession userSession) {
this.repository = repository;
this.userRepository = userRepository;
this.service = service;
this.result = result;
this.userSession = userSession;
}
示例13: ForumController
import br.com.caelum.vraptor.Result; //导入依赖的package包/类
public ForumController(CategoryRepository categoryRepository,
ForumRepository forumRepository, UserSession userSession,
UserRepository userRepository, MostUsersEverOnlineService mostUsersEverOnlineService,
JForumConfig config, GroupInteractionFilter groupInteractionFilter,
Result result, SessionManager sessionManager) {
this.categoryRepository = categoryRepository;
this.userSession = userSession;
this.forumRepository = forumRepository;
this.userRepository = userRepository;
this.mostUsersEverOnlineService = mostUsersEverOnlineService;
this.config = config;
this.groupInteractionFilter = groupInteractionFilter;
this.result = result;
this.sessionManager = sessionManager;
}
示例14: PostReportController
import br.com.caelum.vraptor.Result; //导入依赖的package包/类
public PostReportController(PostReportRepository repository, JForumConfig config,
Result result, UserSession userSession) {
this.repository = repository;
this.userSession = userSession;
this.config = config;
this.result = result;
}
示例15: PostEditInterceptor
import br.com.caelum.vraptor.Result; //导入依赖的package包/类
public PostEditInterceptor(PostRepository postRepository, ForumLimitedTimeRepository repository,
JForumConfig config, HttpServletRequest request, Result result,
UserSession userSession, SessionManager sessionManager) {
this.postRepository = postRepository;
this.repository = repository;
this.config = config;
this.userSession = userSession;
this.request = request;
this.result = result;
this.sessionManager = sessionManager;
}