本文整理汇总了Java中com.gitblit.wicket.pages.GitSearchPage类的典型用法代码示例。如果您正苦于以下问题:Java GitSearchPage类的具体用法?Java GitSearchPage怎么用?Java GitSearchPage使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
GitSearchPage类属于com.gitblit.wicket.pages包,在下文中一共展示了GitSearchPage类的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: init
import com.gitblit.wicket.pages.GitSearchPage; //导入依赖的package包/类
@Override
public void init() {
super.init();
// Setup page authorization mechanism
boolean useAuthentication = GitBlit.getBoolean(Keys.web.authenticateViewPages, false)
|| GitBlit.getBoolean(Keys.web.authenticateAdminPages, false);
if (useAuthentication) {
AuthorizationStrategy authStrategy = new AuthorizationStrategy();
getSecuritySettings().setAuthorizationStrategy(authStrategy);
getSecuritySettings().setUnauthorizedComponentInstantiationListener(authStrategy);
}
// Grab Browser info (like timezone, etc)
if (GitBlit.getBoolean(Keys.web.useClientTimezone, false)) {
getRequestCycleSettings().setGatherExtendedBrowserInfo(true);
}
// configure the resource cache duration to 90 days for deployment
if (!GitBlit.isDebugMode()) {
getResourceSettings().setDefaultCacheDuration(90 * 86400);
}
// setup the standard gitweb-ish urls
mount("/repositories", RepositoriesPage.class);
mount("/overview", OverviewPage.class, "r", "h");
mount("/summary", SummaryPage.class, "r");
mount("/pushes", PushesPage.class, "r", "h");
mount("/commits", LogPage.class, "r", "h");
mount("/log", LogPage.class, "r", "h");
mount("/tags", TagsPage.class, "r");
mount("/branches", BranchesPage.class, "r");
mount("/commit", CommitPage.class, "r", "h");
mount("/tag", TagPage.class, "r", "h");
mount("/tree", TreePage.class, "r", "h", "f");
mount("/blob", BlobPage.class, "r", "h", "f");
mount("/raw", RawPage.class, "r", "h", "f");
mount("/blobdiff", BlobDiffPage.class, "r", "h", "f");
mount("/commitdiff", CommitDiffPage.class, "r", "h");
mount("/compare", ComparePage.class, "r", "h");
mount("/patch", PatchPage.class, "r", "h", "f");
mount("/history", HistoryPage.class, "r", "h", "f");
mount("/search", GitSearchPage.class);
mount("/metrics", MetricsPage.class, "r");
mount("/blame", BlamePage.class, "r", "h", "f");
mount("/users", UsersPage.class);
mount("/logout", LogoutPage.class);
// setup ticket urls
mount("/tickets", TicketsPage.class, "r");
mount("/ticket", TicketPage.class, "r", "f");
// setup the markdown urls
mount("/docs", DocsPage.class, "r");
mount("/markdown", MarkdownPage.class, "r", "h", "f");
// federation urls
mount("/proposal", ReviewProposalPage.class, "t");
mount("/registration", FederationRegistrationPage.class, "u", "n");
mount("/activity", ActivityPage.class, "r", "h");
mount("/gravatar", GravatarProfilePage.class, "h");
mount("/lucene", LuceneSearchPage.class);
mount("/project", ProjectPage.class, "p");
mount("/projects", ProjectsPage.class);
mount("/user", UserPage.class, "user");
mount("/forks", ForksPage.class, "r");
mount("/fork", ForkPage.class, "r");
}
示例2: init
import com.gitblit.wicket.pages.GitSearchPage; //导入依赖的package包/类
@Override
public void init() {
super.init();
// Setup page authorization mechanism
boolean useAuthentication = GitBlit.getBoolean(Keys.web.authenticateViewPages, false)
|| GitBlit.getBoolean(Keys.web.authenticateAdminPages, false);
if (useAuthentication) {
AuthorizationStrategy authStrategy = new AuthorizationStrategy();
getSecuritySettings().setAuthorizationStrategy(authStrategy);
getSecuritySettings().setUnauthorizedComponentInstantiationListener(authStrategy);
}
// Grab Browser info (like timezone, etc)
if (GitBlit.getBoolean(Keys.web.useClientTimezone, false)) {
getRequestCycleSettings().setGatherExtendedBrowserInfo(true);
}
// configure the resource cache duration to 90 days for deployment
if (!GitBlit.isDebugMode()) {
getResourceSettings().setDefaultCacheDuration(90 * 86400);
}
// setup the standard gitweb-ish urls
mount("/summary", SummaryPage.class, "r");
mount("/log", LogPage.class, "r", "h");
mount("/tags", TagsPage.class, "r");
mount("/branches", BranchesPage.class, "r");
mount("/commit", CommitPage.class, "r", "h");
mount("/tag", TagPage.class, "r", "h");
mount("/tree", TreePage.class, "r", "h", "f");
mount("/blob", BlobPage.class, "r", "h", "f");
mount("/raw", RawPage.class, "r", "h", "f");
mount("/blobdiff", BlobDiffPage.class, "r", "h", "f");
mount("/commitdiff", CommitDiffPage.class, "r", "h");
mount("/patch", PatchPage.class, "r", "h", "f");
mount("/history", HistoryPage.class, "r", "h", "f");
mount("/search", GitSearchPage.class);
mount("/metrics", MetricsPage.class, "r");
mount("/blame", BlamePage.class, "r", "h", "f");
mount("/users", UsersPage.class);
mount("/logout", LogoutPage.class);
// setup ticket urls
mount("/tickets", TicketsPage.class, "r");
mount("/ticket", TicketPage.class, "r", "f");
// setup the markdown urls
mount("/docs", DocsPage.class, "r");
mount("/markdown", MarkdownPage.class, "r", "h", "f");
// federation urls
mount("/proposal", ReviewProposalPage.class, "t");
mount("/registration", FederationRegistrationPage.class, "u", "n");
mount("/activity", ActivityPage.class, "r", "h");
mount("/gravatar", GravatarProfilePage.class, "h");
mount("/lucene", LuceneSearchPage.class);
mount("/project", ProjectPage.class, "p");
mount("/projects", ProjectsPage.class);
mount("/user", UserPage.class, "user");
mount("/forks", ForksPage.class, "r");
mount("/fork", ForkPage.class, "r");
}