Tabnine Logo
BaseCondition.hasPreFilter
Code IndexAdd Tabnine to your IDE (free)

How to use
hasPreFilter
method
in
io.yawp.repository.query.condition.BaseCondition

Best Java code snippets using io.yawp.repository.query.condition.BaseCondition.hasPreFilter (Showing top 5 results out of 315)

origin: feroult/yawp

private boolean hasPropertyFilter() {
  return builder.getCondition() != null && builder.getCondition().hasPreFilter();
}
origin: feroult/yawp

@Override
public void init(Repository r, Class<?> clazz) {
  boolean allSubConditionsHasPreFilter = true;
  boolean oneSubConditionHasPreFilter = false;
  for (BaseCondition c : conditions) {
    c.init(r, clazz);
    if (!c.hasPreFilter()) {
      allSubConditionsHasPreFilter = false;
    } else {
      oneSubConditionHasPreFilter = true;
    }
    if (c.hasPostFilter()) {
      hasPostFilter = true;
    }
  }
  hasPreFilter = (oneSubConditionHasPreFilter && logicalOperator == LogicalOperator.AND)
      || (allSubConditionsHasPreFilter && logicalOperator == LogicalOperator.OR);
}
origin: feroult/yawp

private void prepareQueryWhere(QueryBuilder<?> builder, Query q) throws FalsePredicateException {
  BaseCondition condition = builder.getCondition();
  if (condition != null && condition.hasPreFilter()) {
    q.setFilter(createFilter(builder, condition));
  }
}
origin: feroult/yawp

private String joinedWhere(JoinedCondition joinedCondition) throws FalsePredicateException {
  BaseCondition[] conditions = joinedCondition.getConditions();
  LogicalOperator logicalOperator = joinedCondition.getLogicalOperator();
  List<String> wheres = new ArrayList<>();
  for (int i = 0; i < conditions.length; i++) {
    try {
      BaseCondition condition = conditions[i];
      if (!condition.hasPreFilter()) {
        continue;
      }
      wheres.add(where(condition));
    } catch (FalsePredicateException e) {
      if (logicalOperator == LogicalOperator.AND) {
        throw e;
      }
    }
  }
  if (wheres.isEmpty()) {
    throw new FalsePredicateException();
  }
  if (wheres.size() == 1) {
    return wheres.get(0);
  }
  return applyLogicalOperator(logicalOperator, wheres);
}
origin: feroult/yawp

try {
  BaseCondition condition = conditions[i];
  if (!condition.hasPreFilter()) {
    continue;
io.yawp.repository.query.conditionBaseConditionhasPreFilter

Popular methods of BaseCondition

  • evaluate
  • init
  • not
  • and
  • applyPostFilter
  • hasPostFilter
  • or
  • toMap

Popular in Java

  • Updating database using SQL prepared statement
  • getApplicationContext (Context)
  • scheduleAtFixedRate (Timer)
  • compareTo (BigDecimal)
  • BorderLayout (java.awt)
    A border layout lays out a container, arranging and resizing its components to fit in five regions:
  • MessageDigest (java.security)
    Uses a one-way hash function to turn an arbitrary number of bytes into a fixed-length byte sequence.
  • Iterator (java.util)
    An iterator over a sequence of objects, such as a collection.If a collection has been changed since
  • SSLHandshakeException (javax.net.ssl)
    The exception that is thrown when a handshake could not be completed successfully.
  • HttpServletRequest (javax.servlet.http)
    Extends the javax.servlet.ServletRequest interface to provide request information for HTTP servlets.
  • Logger (org.slf4j)
    The org.slf4j.Logger interface is the main user entry point of SLF4J API. It is expected that loggin
  • Top Sublime Text plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now