Package org.eclipse.jgit.transport.resolver

Examples of org.eclipse.jgit.transport.resolver.ServiceNotEnabledException


      if (cfg.enabled) {
        if (user == null || "".equals(user))
          user = "anonymous";
        return createFor(req, db, user);
      }
      throw new ServiceNotEnabledException();
    }

    if (user != null && !"".equals(user))
      return createFor(req, db, user);
    throw new ServiceNotAuthorizedException();
View Full Code Here


    }

    boolean allowAnonymousPushes = settings.getBoolean(Keys.git.allowAnonymousPushes, false);
    if (!allowAnonymousPushes && UserModel.ANONYMOUS.equals(user)) {
      // prohibit anonymous pushes
      throw new ServiceNotEnabledException();
    }

    String url = settings.getString(Keys.web.canonicalUrl, null);
    if (StringUtils.isEmpty(url)) {
      url = gitblitUrl;
View Full Code Here

      }
      if (!pc.isVisible()) {
        if (pc.getCurrentUser() instanceof AnonymousUser) {
          throw new ServiceNotAuthorizedException();
        } else {
          throw new ServiceNotEnabledException();
        }
      }
      req.setAttribute(ATT_CONTROL, pc);

      try {
View Full Code Here

   *             repository, such as due to a permission error.
   */
  public void access(HttpServletRequest req, Repository db)
      throws ServiceNotEnabledException, ServiceNotAuthorizedException {
    if (!isEnabled(db))
      throw new ServiceNotEnabledException();
  }
View Full Code Here

      if (cfg.enabled) {
        if (user == null || "".equals(user))
          user = "anonymous";
        return createFor(req, db, user);
      }
      throw new ServiceNotEnabledException();
    }

    if (user != null && !"".equals(user))
      return createFor(req, db, user);
    throw new ServiceNotAuthorizedException();
View Full Code Here

  public UploadPack create(final HttpServletRequest req, final Repository db)
      throws ServiceNotEnabledException, ServiceNotAuthorizedException {
    if (db.getConfig().get(CONFIG).enabled)
      return new UploadPack(db);
    else
      throw new ServiceNotEnabledException();
  }
View Full Code Here

TOP

Related Classes of org.eclipse.jgit.transport.resolver.ServiceNotEnabledException

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.