congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
EntityBag.flush
Code IndexAdd Tabnine to your IDE (free)

How to use
flush
method
in
com.oberasoftware.jasdb.api.session.EntityBag

Best Java code snippets using com.oberasoftware.jasdb.api.session.EntityBag.flush (Showing top 1 results out of 315)

origin: oberasoftware/jasdb

@Test
public void testBagFlush() throws JasDBException {
  DBSession session = sessionFactory.createSession();
  EntityBag bag = session.createOrGetBag("testbag");
  long sizeBefore = bag.getDiskSize();
  int TEST_SIZE = 1000;
  for(int i=0; i<TEST_SIZE; i++) {
    bag.addEntity(new SimpleEntity());
  }
  bag.flush();
  assertTrue(bag.getDiskSize() > sizeBefore);
}
com.oberasoftware.jasdb.api.sessionEntityBagflush

Javadoc

Forcibly flushes all the data in the bag to the storage

Popular methods of EntityBag

  • addEntity
    Adds an entity to the bag of entities
  • find
    Builds a query for document in the storage for a specific queryfield with optional sorting parameter
  • getEntities
    Execute a query returning all records in the bag with a given max
  • getEntity
    Retrieves a specific entity from the bag
  • removeEntity
    Removes the entity from the bag using the id
  • updateEntity
    Updates an entity in the bag of entities
  • ensureIndex
    Ensures there is an index present on a given field in this bag, will create if not existent, will do
  • getDiskSize
    Returns the size on the disk of the entities
  • getSize
    Returns the amount of entities in the bag
  • persist
    Persists the provided entity, if not exists will be created, if already exists it will be updated
  • removeIndex
    Removes the index from the bag
  • removeIndex

Popular in Java

  • Making http post requests using okhttp
  • compareTo (BigDecimal)
  • getExternalFilesDir (Context)
  • getSharedPreferences (Context)
  • Table (com.google.common.collect)
    A collection that associates an ordered pair of keys, called a row key and a column key, with a sing
  • HttpServer (com.sun.net.httpserver)
    This class implements a simple HTTP server. A HttpServer is bound to an IP address and port number a
  • File (java.io)
    An "abstract" representation of a file system entity identified by a pathname. The pathname may be a
  • FileReader (java.io)
    A specialized Reader that reads from a file in the file system. All read requests made by calling me
  • Notification (javax.management)
  • Servlet (javax.servlet)
    Defines methods that all servlets must implement. A servlet is a small Java program that runs within
  • 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