congrats Icon
New! Tabnine Pro 14-day free trial
Start a free trial
Tabnine Logo
IsEqual
Code IndexAdd Tabnine to your IDE (free)

How to use
IsEqual
in
uk.gov.gchq.koryphe.impl.predicate

Best Java code snippets using uk.gov.gchq.koryphe.impl.predicate.IsEqual (Showing top 10 results out of 315)

origin: gchq/Gaffer

    .postTransformFilter(new ElementFilter.Builder()
        .select(TestPropertyNames.PROP_1)
        .execute(new IsEqual("9"))
        .build())
    .build();
assertEquals(1, postTransformFilterComponents.size());
assertArrayEquals(new String[]{TestPropertyNames.PROP_1}, postTransformFilterComponents.get(0).getSelection());
assertEquals(new IsEqual("9"), postTransformFilterComponents.get(0).getPredicate());
origin: uk.gov.gchq.gaffer/parquet-store

private Pair<FilterPredicate, Set<Path>> addPrimitiveFilter(final Predicate filterFunction,
                              final String selection,
                              final String group) throws SerialisationException {
  // All supported filters will be in the if else statement below
  if (filterFunction instanceof IsEqual) {
    return addIsEqualFilter(selection, schemaUtils.getConverter(group).gafferObjectToParquetObjects(selection, ((IsEqual) filterFunction).getControlValue()), group, false);
  } else if (filterFunction instanceof IsLessThan) {
    if (((IsLessThan) filterFunction).getOrEqualTo()) {
      return addIsLessThanOrEqualToFilter(selection, schemaUtils.getConverter(group).gafferObjectToParquetObjects(selection, ((IsLessThan) filterFunction).getControlValue()), group);
    } else {
      return addIsLessThanFilter(selection, schemaUtils.getConverter(group).gafferObjectToParquetObjects(selection, ((IsLessThan) filterFunction).getControlValue()), group);
    }
  } else if (filterFunction instanceof IsMoreThan) {
    if (((IsMoreThan) filterFunction).getOrEqualTo()) {
      return addIsMoreThanOrEqualToFilter(selection, schemaUtils.getConverter(group).gafferObjectToParquetObjects(selection, ((IsMoreThan) filterFunction).getControlValue()), group);
    } else {
      return addIsMoreThanFilter(selection, schemaUtils.getConverter(group).gafferObjectToParquetObjects(selection, ((IsMoreThan) filterFunction).getControlValue()), group);
    }
  } else if (filterFunction instanceof IsTrue) {
    return new Pair<>(eq(booleanColumn(selection), Boolean.TRUE), getAllPathsForColumn(group));
  } else if (filterFunction instanceof IsFalse) {
    return new Pair<>(eq(booleanColumn(selection), Boolean.FALSE), getAllPathsForColumn(group));
  } else {
    LOGGER.warn(filterFunction.getClass().getCanonicalName() +
        " is not a natively supported filter by the Parquet store, therefore execution will take longer to perform this filter.");
    return null;
  }
}
origin: gchq/Gaffer

    .execute(new IsMoreThan(2))
    .select(1)
    .execute(new IsEqual("some value"))
    .build()))
.build();
origin: gchq/Gaffer

    .execute(new IsMoreThan(2))
    .select(1)
    .execute(new IsEqual("some value"))
    .build())
.build();
origin: uk.gov.gchq.gaffer/doc

public void isEqualTo5() {
  // ---------------------------------------------------------
  final IsEqual function = new IsEqual(5);
  // ---------------------------------------------------------
  runExample(function,
      null,
      5, 5L, "5", '5');
}
origin: uk.gov.gchq.gaffer/doc

public void isEqualToString5() {
  // ---------------------------------------------------------
  final IsEqual function = new IsEqual("5");
  // ---------------------------------------------------------
  runExample(function,
      null,
      5, 5L, "5", '5');
}
origin: uk.gov.gchq.gaffer/doc

  public void isEqualLong5() {
    // ---------------------------------------------------------
    final IsEqual function = new IsEqual(5L);
    // ---------------------------------------------------------

    runExample(function,
        null,
        5, 5L, "5", '5');
  }
}
origin: uk.gov.gchq.gaffer/doc

public void isLessThan2EqualTo5OrIsMoreThan10() {
  // ---------------------------------------------------------
  final Or function = new Or<>(
      new IsLessThan(2),
      new IsEqual(5),
      new IsMoreThan(10)
  );
  // ---------------------------------------------------------
  runExample(function,
      "When using an Or predicate with a single selected value you can just use the constructor new Or(predicates))'",
      1, 2, 3, 5, 15, 1L, 3L, 5L);
}
origin: uk.gov.gchq.gaffer/spark-library

final Predicate<?> isEqual = new IsEqual(equalNullSafe.value());
final Set<String> relevantGroups = getGroupsFromFilter(filter);
if (null != relevantGroups) {
origin: uk.gov.gchq.gaffer/doc

.preAggregationFilter(new ElementFilter.Builder()
    .select("edgeGroup")
    .execute(new IsEqual(CollectionUtil.treeSet("RoadUse")))
    .build())
.build())
.preAggregationFilter(new ElementFilter.Builder()
    .select("edgeGroup")
    .execute(new IsEqual(CollectionUtil.treeSet("RoadUse")))
    .build())
.groupBy()
uk.gov.gchq.koryphe.impl.predicateIsEqual

Javadoc

An IsEqual is a java.util.function.Predicate that checks that the input is equal to a control value.

Most used methods

  • <init>
  • getControlValue

Popular in Java

  • Making http post requests using okhttp
  • onRequestPermissionsResult (Fragment)
  • scheduleAtFixedRate (Timer)
  • getSharedPreferences (Context)
  • ObjectMapper (com.fasterxml.jackson.databind)
    ObjectMapper provides functionality for reading and writing JSON, either to and from basic POJOs (Pl
  • Point (java.awt)
    A point representing a location in (x,y) coordinate space, specified in integer precision.
  • Modifier (javassist)
    The Modifier class provides static methods and constants to decode class and member access modifiers
  • Cipher (javax.crypto)
    This class provides access to implementations of cryptographic ciphers for encryption and decryption
  • JFileChooser (javax.swing)
  • BasicDataSource (org.apache.commons.dbcp)
    Basic implementation of javax.sql.DataSource that is configured via JavaBeans properties. This is no
  • Top 25 Plugins for Webstorm
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

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