Tabnine Logo
EntityIdException.<init>
Code IndexAdd Tabnine to your IDE (free)

How to use
com.moz.fiji.schema.EntityIdException
constructor

Best Java code snippets using com.moz.fiji.schema.EntityIdException.<init> (Showing top 7 results out of 315)

origin: com.moz.fiji.schema/fiji-schema

/**
 * Convert class of object to the correct ComponentType.
 * @param obj Input object (key component).
 * @return ComponentType representing the class of the input object.
 */
private static ComponentType getType(Object obj) {
 if (obj instanceof String) {
  return ComponentType.STRING;
 } else if (obj instanceof Integer) {
  return ComponentType.INTEGER;
 } else if (obj instanceof Long) {
  return ComponentType.LONG;
 }
 throw new EntityIdException("Unexpected type for Component " + obj.getClass().getName());
}
origin: com.moz.fiji.schema/fiji-schema

/**
 * Extract a row key component as a byte[].
 *
 * @param keyComponent a row key component expected to be either byte[] or String.
 * @return the row key component as a byte[].
 * @throws EntityIdException if the key component is invalid.
 *     Key components must be String or byte[].
 */
private static byte[] getBytesKeyComponent(Object keyComponent) {
 if (keyComponent instanceof byte[]) {
  return (byte[]) keyComponent;
 } else if (keyComponent instanceof String) {
  return Bytes.toBytes((String) keyComponent);
 } else {
  throw new EntityIdException(String.format(
    "Invalid row key component: '%s', expecting byte[] or String", keyComponent));
 }
}
origin: com.moz.fiji.schema/fiji-schema

 throw new EntityIdException("Invalid hbase row key");
if (format.getSalt().getSuppressKeyMaterialization()) {
 if (pos < hbaseRowKey.length) {
  throw new EntityIdException("Extra bytes in key after hash when materialization is"
    + "suppressed");
   } catch (UnsupportedEncodingException e) {
    LOG.error(e.toString());
    throw new EntityIdException(String.format(
      "UnsupportedEncoding for component %d", fijiRowElem));
    buf = ByteBuffer.wrap(hbaseRowKey, pos, Integer.SIZE / Byte.SIZE);
   } catch (IndexOutOfBoundsException e) {
    throw new EntityIdException("Malformed hbase Row Key");
    buf = ByteBuffer.wrap(hbaseRowKey, pos, Long.SIZE / Byte.SIZE);
   } catch (IndexOutOfBoundsException e) {
    throw new EntityIdException("Malformed hbase Row Key");
 throw new EntityIdException("Extra bytes in hbase row key cannot be mapped to any "
   + "component");
 throw new EntityIdException("Too few components decoded from hbase row key. Component "
   + "number " + fijiRowElem + " cannot be null");
origin: com.moz.fiji.schema/fiji-schema

throw new EntityIdException("Too many components in fiji Row Key");
throw new EntityIdException("Too few components in fiji Row key");
  continue;
 } else {
  throw new EntityIdException("Non null component follows null component");
  continue;
 } else {
  throw new EntityIdException("Unexpected null component in fiji row key."
    + String.format("Expected at least %d non-null components",
      format.getNullableStartIndex()));
   fijiRowKey.set(i, ((Integer) fijiRowKey.get(i)).longValue());
  } else {
  throw new EntityIdException(String.format(
    "Invalid type for component %s at index %d in fijiRowKey",
    fijiRowKey.get(i).toString(), i));
origin: com.moz.fiji.schema/fiji-schema

case STRING:
 if (((String)fijiRowKey.get(pos)).contains("\u0000")) {
  throw new EntityIdException("String component cannot contain \u0000");
 } catch (UnsupportedEncodingException e) {
  LOG.error(e.toString());
  throw new EntityIdException(String.format(
    "UnsupportedEncoding for component %d", pos));
origin: com.moz.fiji.hive/fiji-hive-lib

 break;
default:
 throw new EntityIdException("Unexpected type for Component " + componentType);
origin: com.moz.fiji.hive/fiji-hive-lib

 WritableUtils.writeEnum(out, Component.NULL);
} else {
 throw new EntityIdException("Unexpected type for Component "
   + component.getClass().getName());
com.moz.fiji.schemaEntityIdException<init>

Javadoc

Creates a new EntityIdException with the specified detail message.

Popular methods of EntityIdException

    Popular in Java

    • Start an intent from android
    • onCreateOptionsMenu (Activity)
    • setScale (BigDecimal)
    • getSystemService (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
    • Component (java.awt)
      A component is an object having a graphical representation that can be displayed on the screen and t
    • ServerSocket (java.net)
      This class represents a server-side socket that waits for incoming client connections. A ServerSocke
    • ByteBuffer (java.nio)
      A buffer for bytes. A byte buffer can be created in either one of the following ways: * #allocate
    • Connection (java.sql)
      A connection represents a link from a Java application to a database. All SQL statements and results
    • Table (org.hibernate.mapping)
      A relational table
    • Top Vim 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