Codota Logo
DataBaseConnector.getPrimaryKeyIndices
Code IndexAdd Codota to your IDE (free)

How to use
getPrimaryKeyIndices
method
in
de.julielab.xmlData.dataBase.DataBaseConnector

Best Java code snippets using de.julielab.xmlData.dataBase.DataBaseConnector.getPrimaryKeyIndices (Showing top 2 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
ScheduledThreadPoolExecutor s =
  • Codota Iconnew ScheduledThreadPoolExecutor(corePoolSize)
  • Codota IconThreadFactory threadFactory;new ScheduledThreadPoolExecutor(corePoolSize, threadFactory)
  • Codota IconString str;new ScheduledThreadPoolExecutor(1, new ThreadFactoryBuilder().setNameFormat(str).build())
  • Smart code suggestions by Codota
}
origin: de.julielab/jcore-xmi-db-reader

private String getPkStringFromData(byte[][] data) {
  List<Integer> pkIndices = dbc.getPrimaryKeyIndices();
  StringBuilder sb = new StringBuilder();
  for (int i = 0; i < pkIndices.size(); ++i) {
    Integer index = pkIndices.get(i);
    byte[] pkElementValue = data[index];
    String elementString = new String(pkElementValue);
    sb.append(elementString);
    if (i < pkIndices.size() - 1)
      sb.append("-");
  }
  return sb.toString();
}
origin: de.julielab/jcore-db-reader

public static String setDBProcessingMetaData(DataBaseConnector dbc, boolean readDataTable, String tableName, byte[][] data, JCas cas) {
  String pkString = null;
  // remove previously added dbMetaData
  JCasUtil.select(cas, DBProcessingMetaData.class).forEach(x -> x.removeFromIndexes());
  DBProcessingMetaData dbMetaData = new DBProcessingMetaData(cas);
  List<Integer> pkIndices = dbc.getPrimaryKeyIndices();
  StringArray pkArray = new StringArray(cas, pkIndices.size());
  for (int i = 0; i < pkIndices.size(); ++i) {
    Integer index = pkIndices.get(i);
    String pkElementValue = new String(data[index], Charset.forName("UTF-8"));
    pkArray.set(i, pkElementValue);
  }
  if (log.isDebugEnabled())
    log.debug("Setting primary key to {}", Arrays.toString(pkArray.toArray()));
  dbMetaData.setPrimaryKey(pkArray);
  if (!readDataTable)
    dbMetaData.setSubsetTable(
        tableName.contains(".") ? tableName : dbc.getActivePGSchema() + "." + tableName);
  dbMetaData.addToIndexes();
  return pkString;
}
de.julielab.xmlData.dataBaseDataBaseConnectorgetPrimaryKeyIndices

Popular methods of DataBaseConnector

  • <init>
  • checkTableDefinition
  • getActiveDataPGSchema
  • getFieldConfiguration
  • obtainOrReserveConnection
  • tableExists
  • addXmiAnnotationFieldConfiguration
  • addXmiDocumentFieldConfiguration
  • addXmiTextFieldConfiguration
  • close
  • getActiveTableFieldConfiguration
  • getNextOrThisDataTable
  • getActiveTableFieldConfiguration,
  • getNextOrThisDataTable,
  • isDataTable,
  • releaseConnections,
  • reserveConnection,
  • checkTableSchemaCompatibility,
  • countRowsOfDataTable,
  • countUnprocessed,
  • createSchema

Popular in Java

  • Parsing JSON documents to java classes using gson
  • onCreateOptionsMenu (Activity)
  • getContentResolver (Context)
  • scheduleAtFixedRate (Timer)
    Schedules the specified task for repeated fixed-rate execution, beginning after the specified delay.
  • GridLayout (java.awt)
    The GridLayout class is a layout manager that lays out a container's components in a rectangular gri
  • PrintStream (java.io)
    A PrintStream adds functionality to another output stream, namely the ability to print representatio
  • Proxy (java.net)
    This class represents proxy server settings. A created instance of Proxy stores a type and an addres
  • Collections (java.util)
    This class consists exclusively of static methods that operate on or return collections. It contains
  • Locale (java.util)
    A Locale object represents a specific geographical, political, or cultural region. An operation that
  • IOUtils (org.apache.commons.io)
    General IO stream manipulation utilities. This class provides static utility methods for input/outpu
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now