Package org.objectweb.speedo.query.api

Examples of org.objectweb.speedo.query.api.QueryManagerAttribute


            pmf = (POManagerFactoryItf) o;
        } else if (QUERY_MANAGER_BINDING.equals(s)) {
            queryManager = (QueryManager) o;
      if (queryManager != null) {
        try {
          QueryManagerAttribute qma = (QueryManagerAttribute)
          Fractal.getAttributeController(
              ((Interface) queryManager).getFcItfOwner()) ;
          prefetchOnExtent = qma.getPrefetchActivatedOnExtent();
          prefetchOnQuery = qma.getPrefetchActivatedOnQuery();
        } catch (Exception e) {
          logger.log(BasicLevel.WARN,
            "impossible to fetch the attribute prefetchActivatedOnExtent: ", e);
        }
      }
View Full Code Here


    String strval = getProperty(props, PREFETCH, "", true);
    if (strval.length()>0) {
      prefetch = BooleanHelper.parse(strval, false);
    }
    Component qm = getSubComponent(speedo, QUERY_MANAGER);
    QueryManagerAttribute qma = ((QueryManagerAttribute) Fractal.getAttributeController(qm));
    if (!prefetch) {
      qma.setPrefetchActivatedOnQuery(false);
      qma.setPrefetchActivatedOnExtent(false);
      logger.log(BasicLevel.INFO, sb.append(LocaleHelper.getSpeedoRB().getString("NONE")).toString());
        return;
    }
    boolean prefetchOnQuery = qma.getPrefetchActivatedOnQuery();
    boolean prefetchOnExtent = qma.getPrefetchActivatedOnExtent();
    boolean prefetchOnGenClass = true;
    String sep = ", ";

    boolean oneOf = false;
      strval = getProperty(props, PREFETCH_ON_QUERY, "", true);
    if (strval.length()>0) {
      prefetchOnQuery = BooleanHelper.parse(strval, false);
    }
    if (prefetchOnQuery) {
      if (oneOf) {
          sb.append(sep);
      }
        sb.append(LocaleHelper.getSpeedoRB().getString("QUERY"));
    }
    oneOf |= prefetchOnQuery;
    qma.setPrefetchActivatedOnQuery(prefetchOnQuery);

    strval = getProperty(props, PREFETCH_ON_EXTENT, "", true);
    if (strval.length()>0) {
      prefetchOnExtent = BooleanHelper.parse(strval, false);
    }
    if (prefetchOnExtent) {
      if (oneOf) {
          sb.append(sep);
      }
        sb.append(LocaleHelper.getSpeedoRB().getString("EXTENT"));
    }
    oneOf |= prefetchOnExtent;
    qma.setPrefetchActivatedOnExtent(prefetchOnExtent);

    strval = getProperty(props, PREFETCH_ON_GENCLASS, "", true);
    if (strval.length()>0) {
      prefetchOnGenClass= BooleanHelper.parse(strval, false);
    }
View Full Code Here

        CacheAttributeController ca = (CacheAttributeController)
          Fractal.getAttributeController(
                FractalHelper.getSubComponent(cache, "cache-manager", logger));
        UnbindManager um = (UnbindManager) cache.getFcInterface("unbind-manager");
        CacheManager cm = (CacheManager) cache.getFcInterface("cache-manager");
        QueryManagerAttribute qma = (QueryManagerAttribute)
          Fractal.getAttributeController(
                FractalHelper.getSubComponent(
                        speedo, AbstractSpeedo.QUERY_MANAGER, logger));
        Query qm = new Query(ca, um, cm, qma);
        server.registerMBean(qm, new ObjectName("speedo:name=query"));
View Full Code Here

TOP

Related Classes of org.objectweb.speedo.query.api.QueryManagerAttribute

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.