Package com.esri.gpt.framework.context

Examples of com.esri.gpt.framework.context.ApplicationConfiguration


  return suspended;
}
 
private int getMaxAttempts() {
  ApplicationContext appCtx = ApplicationContext.getInstance();
  ApplicationConfiguration appCfg = appCtx.getConfiguration();
  StringAttributeMap parameters = appCfg.getCatalogConfiguration().getParameters();
  return Val.chkInt(parameters.getValue("webharvester.maxAttempts"),DEFAULT_MAX_ATTEMPTS);
}
View Full Code Here


   */
  public ArrayList<SelectItem> getProtocols() {
    ArrayList<SelectItem> protocols = new ArrayList<SelectItem>();
    MessageBroker msgBroker = getContextBroker().extractMessageBroker();
    ApplicationContext appCtx = ApplicationContext.getInstance();
    ApplicationConfiguration appCfg = appCtx.getConfiguration();
    ProtocolFactories protocolFactories = appCfg.getProtocolFactories();
    for (String key : protocolFactories.getKeys()) {
      ProtocolFactory pf = protocolFactories.get(key);
      if (pf instanceof AgpProtocolFactory && !AGSProcessorConfig.isAvailable()) {
        continue;
      }
View Full Code Here

   * @return locator
   * @throws IllegalArgumentException if "lucene.locatorClass" parameter is invalid
   */
  public static Locator newInstance() {
    ApplicationContext appCtx = ApplicationContext.getInstance();
    ApplicationConfiguration appCfg = appCtx.getConfiguration();

    String locatorClassName = appCfg.getCatalogConfiguration().getParameters().getValue("lucene.locatorClass");

    if (Val.chkStr(locatorClassName).length() == 0) {
      return new Locator();
    } else {
      try {
View Full Code Here

  /**
   * Creates instance of the locator.
   */
  protected Locator() {
    ApplicationContext appCtx = ApplicationContext.getInstance();
    ApplicationConfiguration appCfg = appCtx.getConfiguration();
    this.url = appCfg.getInteractiveMap().getLocatorUrl();
  }
View Full Code Here

    return toSkip != null ? toSkip.contains(uuid) : false;
  }

  protected Set<String> getSitesToSkip() {
    ApplicationContext appCtx = ApplicationContext.getInstance();
    ApplicationConfiguration appCfg = appCtx.getConfiguration();
    StringAttributeMap parameters = appCfg.getCatalogConfiguration().getParameters();
    String skip = Val.chkStr(parameters.getValue("webharvester.skip"));

    TreeSet<String> set = new TreeSet<String>();
    set.addAll(Arrays.asList(skip.split(",")));
    return set;
View Full Code Here

    return isSuspended();
  }
 
  private int getMaxAttempts() {
    ApplicationContext appCtx = ApplicationContext.getInstance();
    ApplicationConfiguration appCfg = appCtx.getConfiguration();
    StringAttributeMap parameters = appCfg.getCatalogConfiguration().getParameters();
    return Val.chkInt(parameters.getValue("webharvester.maxAttempts"),DEFAULT_MAX_ATTEMPTS);
  }
View Full Code Here

  public void appendRecord(Collection<Resource> records, ServiceHandlerFactory factory, ServiceInfo serviceInfo, boolean isNative) throws Exception {
    super.appendRecord(records, factory, serviceInfo, isNative);

    // configuration parameters for data element recursion
    ApplicationContext appCtx = ApplicationContext.getInstance();
    ApplicationConfiguration cfg = appCtx.getConfiguration();
    StringAttributeMap params = cfg.getCatalogConfiguration().getParameters();
    boolean recurse = true;
    if (Val.chkStr(params.getValue("AGSProcessor.GeoDataServer.recurse")).equalsIgnoreCase("false")) {
      recurse = false;
    }
    boolean expandDescendants = false;
View Full Code Here

  }

  public AgpValidator() {

    ApplicationContext appCtx = ApplicationContext.getInstance();
    ApplicationConfiguration appCfg = appCtx.getConfiguration();

    String sArcgisDotComAllowed = appCfg.getCatalogConfiguration().getParameters().getValue("webharvester.agp2agp.arcgisDotCom.allowed");
    this.arcgisDotComAllowed = Val.chkBool(sArcgisDotComAllowed, false);


    String sCrossAllowed = appCfg.getCatalogConfiguration().getParameters().getValue("webharvester.agp2agp.sameDomain.allowed");
    this.crossAllowed = Val.chkBool(sCrossAllowed, false);
  }
View Full Code Here

  return suspended;
}
 
private int getMaxAttempts() {
  ApplicationContext appCtx = ApplicationContext.getInstance();
  ApplicationConfiguration appCfg = appCtx.getConfiguration();
  StringAttributeMap parameters = appCfg.getCatalogConfiguration().getParameters();
  return Val.chkInt(parameters.getValue("webharvester.maxAttempts"),DEFAULT_MAX_ATTEMPTS);
}
View Full Code Here

          }
        };

        if (unit.getPublisher() != null) {
          // delete all records identified by each sourceUri available in Iterable
          ApplicationConfiguration appCfg = ApplicationContext.getInstance().getConfiguration();
          boolean webharvesterCleanup = Val.chkBool(appCfg.getCatalogConfiguration().getParameters().getValue("webharvester.cleanup"), true);
          if (webharvesterCleanup) {
            LOGGER.info("[SYNCHRONIZER] Attempting to clean non-existend records from: "+unit);
            DeleteSourceUrisRequest deleteSourceUrisRequest = new DeleteSourceUrisRequest(context, unit.getPublisher(), iterable);
            try {
              deleteSourceUrisRequest.execute();
View Full Code Here

TOP

Related Classes of com.esri.gpt.framework.context.ApplicationConfiguration

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.