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

How to use
initialise
method
in
uk.gov.gchq.gaffer.store.Store

Best Java code snippets using uk.gov.gchq.gaffer.store.Store.initialise (Showing top 6 results out of 315)

origin: uk.gov.gchq.gaffer/map-store

@Override
public void initialise(final String graphId, final Schema schema, final StoreProperties properties) throws StoreException {
  // Initialise store
  super.initialise(graphId, schema, properties);
  // Initialise maps
  mapImpl = createMapImpl();
}
origin: uk.gov.gchq.gaffer/federated-store

/**
 * Initialise this FederatedStore with any sub-graphs defined within the
 * properties.
 *
 * @param graphId    the graphId to label this FederatedStore.
 * @param unused     unused
 * @param properties properties to initialise this FederatedStore with, can
 *                   contain details on graphs to add to scope.
 * @throws StoreException if no cache has been set
 */
@Override
public void initialise(final String graphId, final Schema unused, final StoreProperties properties) throws StoreException {
  super.initialise(graphId, new Schema(), properties);
  customPropertiesAuths = getCustomPropertiesAuths();
  isPublicAccessAllowed = Boolean.valueOf(getProperties().getIsPublicAccessAllowed());
}
origin: uk.gov.gchq.gaffer/accumulo-store

/**
 * Performs general initialisation without creating the table.
 *
 * @param graphId    The graph ID.
 * @param schema     The Gaffer Schema.
 * @param properties The Accumulo store properties.
 * @throws StoreException If the store could not be initialised.
 */
public void preInitialise(final String graphId, final Schema schema, final StoreProperties properties) throws StoreException {
  setProperties(properties);
  final String deprecatedTableName = getProperties().getTable();
  if (null == graphId && null != deprecatedTableName) {
    // Deprecated
    super.initialise(deprecatedTableName, schema, getProperties());
  } else if (null != deprecatedTableName && !deprecatedTableName.equals(graphId)) {
    throw new IllegalArgumentException(
        "The table in store.properties should no longer be used. " +
            "Please use a graphId instead or for now just set the graphId to be the same value as the store.properties table.");
  } else {
    super.initialise(graphId, schema, getProperties());
  }
  final String keyPackageClass = getProperties().getKeyPackageClass();
  try {
    this.keyPackage = Class.forName(keyPackageClass).asSubclass(AccumuloKeyPackage.class).newInstance();
  } catch (final InstantiationException | IllegalAccessException | ClassNotFoundException e) {
    throw new StoreException("Unable to construct an instance of key package: " + keyPackageClass, e);
  }
  this.keyPackage.setSchema(getSchema());
}
origin: uk.gov.gchq.gaffer/proxy-store

@SuppressFBWarnings(value = "BC_UNCONFIRMED_CAST", justification = "The properties should always be ProxyProperties")
@Override
public void initialise(final String graphId, final Schema unusedSchema, final StoreProperties properties) throws StoreException {
  setProperties(properties);
  client = createClient();
  schema = fetchSchema();
  traits = fetchTraits();
  supportedOperations = fetchOperations();
  super.initialise(graphId, schema, getProperties());
  checkDelegateStoreStatus();
}
origin: uk.gov.gchq.gaffer/parquet-store

@Override
public void initialise(final String graphId, final Schema schema, final StoreProperties properties) throws StoreException {
  if (!(properties instanceof ParquetStoreProperties)) {
    throw new StoreException("ParquetStore must be initialised with properties of class ParquetStoreProperties");
  }
  final ParquetStoreProperties parquetStoreProperties = (ParquetStoreProperties) properties;
  if (null == parquetStoreProperties.getDataDir()) {
    throw new StoreException("The ParquetStoreProperties must contain a non-null data directory ("
        + ParquetStoreProperties.DATA_DIR + ")");
  }
  if (null == parquetStoreProperties.getTempFilesDir()) {
    throw new StoreException("The ParquetStoreProperties must contain a non-null temporary data directory ("
        + ParquetStoreProperties.TEMP_FILES_DIR + ")");
  }
  super.initialise(graphId, schema, parquetStoreProperties);
  try {
    fs = FileSystem.get(new Configuration());
  } catch (final IOException e) {
    throw new StoreException("Could not connect to the file system", e);
  }
  schemaUtils = new SchemaUtils(getSchema());
  loadIndex();
}
origin: uk.gov.gchq.gaffer/graph

private void updateStore(final GraphConfig config) {
  if (null == store) {
    store = Store.createStore(config.getGraphId(), cloneSchema(schema), properties);
  } else if ((null != config.getGraphId() && !config.getGraphId().equals(store.getGraphId()))
      || (null != schema)
      || (null != properties && !properties.equals(store.getProperties()))) {
    if (null == config.getGraphId()) {
      config.setGraphId(store.getGraphId());
    }
    if (null == schema || schema.getGroups().isEmpty()) {
      schema = store.getSchema();
    }
    if (null == properties) {
      properties = store.getProperties();
    }
    try {
      store.initialise(config.getGraphId(), cloneSchema(schema), properties);
    } catch (final StoreException e) {
      throw new IllegalArgumentException("Unable to initialise the store with the given graphId, schema and properties", e);
    }
  }
  store.setGraphLibrary(config.getLibrary());
  if (null == schema || schema.getGroups().isEmpty()) {
    schema = store.getSchema();
  }
}
uk.gov.gchq.gaffer.storeStoreinitialise

Popular methods of Store

  • getProperties
  • getSchema
  • execute
  • createStore
  • getGraphId
  • setGraphLibrary
  • validateSchemaElementDefinition
  • validateSchemas
  • getGraphLibrary
  • getNextOperations
  • getOriginalSchema
  • getSupportedOperations
  • getOriginalSchema,
  • getSupportedOperations,
  • getTraits,
  • hasTrait,
  • isSupported,
  • runAsync,
  • setOriginalSchema,
  • startCacheServiceLoader,
  • validateSchema

Popular in Java

  • Finding current android device location
  • setRequestProperty (URLConnection)
  • runOnUiThread (Activity)
  • findViewById (Activity)
  • ServerSocket (java.net)
    This class represents a server-side socket that waits for incoming client connections. A ServerSocke
  • KeyStore (java.security)
    KeyStore is responsible for maintaining cryptographic keys and their owners. The type of the syste
  • Calendar (java.util)
    Calendar is an abstract base class for converting between a Date object and a set of integer fields
  • Collections (java.util)
    This class consists exclusively of static methods that operate on or return collections. It contains
  • Logger (org.slf4j)
    The org.slf4j.Logger interface is the main user entry point of SLF4J API. It is expected that loggin
  • Option (scala)
  • Top 17 Free Sublime Text Plugins
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