Tabnine Logo
IndexOptions.getLanguageOverride
Code IndexAdd Tabnine to your IDE (free)

How to use
getLanguageOverride
method
in
com.mongodb.client.model.IndexOptions

Best Java code snippets using com.mongodb.client.model.IndexOptions.getLanguageOverride (Showing top 5 results out of 315)

origin: jphp-group/jphp

@Override
public Memory unconvert(Environment env, TraceInfo trace, IndexOptions arg) throws Throwable {
  if (arg == null) return Memory.NULL;
  ArrayMemory options = ArrayMemory.createHashed(12);
  options.put("name", arg.getName());
  options.put("background", arg.isBackground());
  options.put("sparse", arg.isSparse());
  options.put("unique", arg.isUnique());
  if (arg.getDefaultLanguage() != null) options.put("defaultLanguage", arg.getDefaultLanguage());
  if (arg.getBits() != null) options.put("bits", arg.getBits());
  if (arg.getMax() != null) options.put("max", arg.getMax());
  if (arg.getMin() != null) options.put("min", arg.getMin());
  if (arg.getLanguageOverride() != null) options.put("languageOverride", arg.getLanguageOverride());
  if (arg.getVersion() != null) options.put("version", arg.getVersion());
  if (arg.getTextVersion() != null) options.put("textVersion", arg.getTextVersion());
  if (arg.getSphereVersion() != null) options.put("sphereVersion", arg.getSphereVersion());
  return options;
}
origin: org.mongodb/mongo-java-driver

.weights(toBsonDocument(model.getOptions().getWeights()))
.defaultLanguage(model.getOptions().getDefaultLanguage())
.languageOverride(model.getOptions().getLanguageOverride())
.textVersion(model.getOptions().getTextVersion())
.sphereVersion(model.getOptions().getSphereVersion())
origin: MorphiaOrg/morphia

@Test
public void indexOptionsConversion() {
  IndexOptionsBuilder indexOptions = indexOptions();
  com.mongodb.client.model.IndexOptions options = indexHelper.convert(indexOptions, false);
  assertEquals("index_name", options.getName());
  assertTrue(options.isBackground());
  assertTrue(options.isUnique());
  assertTrue(options.isSparse());
  assertEquals(Long.valueOf(42), options.getExpireAfter(TimeUnit.SECONDS));
  assertEquals("en", options.getDefaultLanguage());
  assertEquals("de", options.getLanguageOverride());
  assertEquals(indexHelper.convert(indexOptions.collation()), options.getCollation());
  assertTrue(indexHelper.convert(indexOptions, true).isBackground());
  assertTrue(indexHelper.convert(indexOptions.background(false), true).isBackground());
  assertTrue(indexHelper.convert(indexOptions.background(true), true).isBackground());
  assertTrue(indexHelper.convert(indexOptions.background(true), false).isBackground());
  assertFalse(indexHelper.convert(indexOptions.background(false), false).isBackground());
}
origin: org.wso2.extension.siddhi.store.mongodb/siddhi-store-mongodb

indexOptionsMap.put("expireAfterSeconds", expectedIndexOptions.getExpireAfter(TimeUnit.SECONDS));
indexOptionsMap.put("weights", expectedIndexOptions.getWeights());
indexOptionsMap.put("languageOverride", expectedIndexOptions.getLanguageOverride());
indexOptionsMap.put("defaultLanguage", expectedIndexOptions.getDefaultLanguage());
indexOptionsMap.put("textVersion", expectedIndexOptions.getTextVersion());
origin: org.mongodb/mongodb-driver-core

.weights(toBsonDocument(model.getOptions().getWeights()))
.defaultLanguage(model.getOptions().getDefaultLanguage())
.languageOverride(model.getOptions().getLanguageOverride())
.textVersion(model.getOptions().getTextVersion())
.sphereVersion(model.getOptions().getSphereVersion())
com.mongodb.client.modelIndexOptionsgetLanguageOverride

Javadoc

Gets the name of the field that contains the language string.

For text indexes, the name of the field, in the collection's documents, that contains the override language for the document.

Popular methods of IndexOptions

  • <init>
  • unique
    Should the index should be unique.
  • name
    Sets the name of the index.
  • background
    Should the index should be created in the background
  • expireAfter
    Sets the time to live for documents in the collection
  • sparse
    Should the index only references documents with the specified field
  • partialFilterExpression
    Sets the filter expression for the documents to be included in the index
  • defaultLanguage
    Sets the language for the text index.The language that determines the list of stop words and the rul
  • languageOverride
    Sets the name of the field that contains the language string.For text indexes, the name of the field
  • weights
    Sets the weighting object for use with a text index.An document that represents field and weight pai
  • bits
    Sets the number of precision of the stored geohash value of the location data in 2d indexes.
  • getName
    Gets the name of the index.
  • bits,
  • getName,
  • isUnique,
  • max,
  • min,
  • sphereVersion,
  • bucketSize,
  • collation,
  • getDefaultLanguage

Popular in Java

  • Finding current android device location
  • orElseThrow (Optional)
    Return the contained value, if present, otherwise throw an exception to be created by the provided s
  • getOriginalFilename (MultipartFile)
    Return the original filename in the client's filesystem.This may contain path information depending
  • requestLocationUpdates (LocationManager)
  • Selector (java.nio.channels)
    A controller for the selection of SelectableChannel objects. Selectable channels can be registered w
  • TimerTask (java.util)
    The TimerTask class represents a task to run at a specified time. The task may be run once or repeat
  • TreeSet (java.util)
    TreeSet is an implementation of SortedSet. All optional operations (adding and removing) are support
  • Executors (java.util.concurrent)
    Factory and utility methods for Executor, ExecutorService, ScheduledExecutorService, ThreadFactory,
  • JOptionPane (javax.swing)
  • FileUtils (org.apache.commons.io)
    General file manipulation utilities. Facilities are provided in the following areas: * writing to a
  • From CI to AI: The AI layer in your organization
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