Package org.apache.flink.types

Examples of org.apache.flink.types.NullKeyFieldException


   */
  private final Object accessField(Field field, Object object) {
    try {
      object = field.get(object);
    } catch (NullPointerException npex) {
      throw new NullKeyFieldException("Unable to access field "+field+" on object "+object);
    } catch (IllegalAccessException iaex) {
      throw new RuntimeException("This should not happen since we call setAccesssible(true) in PojoTypeInfo."
      + " fields: " + field + " obj: " + object);
    }
    return object;
View Full Code Here


        }
      }
      return 0;
    }
    catch (NullPointerException npex) {
      throw new NullKeyFieldException(this.keyFields[i].toString());
    }
  }
View Full Code Here

        }
      }
      return 0;
    }
    catch (NullFieldException nfex) {
      throw new NullKeyFieldException(nfex);
    }
    catch (IndexOutOfBoundsException iobex) {
      throw new KeyFieldOutOfBoundsException(keyPositions[i]);
    }
  }
View Full Code Here

        this.comparators[i].putNormalizedKey(value.getFieldNotNull(this.keyPositions[i]), target, offset, len);
        numBytes -= len;
        offset += len;
      }
    } catch (NullFieldException nfex) {
      throw new NullKeyFieldException(nfex);
    } catch (NullPointerException npex) {
      throw new NullKeyFieldException(this.keyPositions[i]);
    }
  }
View Full Code Here

        code *= HASH_SALT[i & 0x1F]; // salt code with (i % HASH_SALT.length)-th salt component
      }
      return code;
    }
    catch (NullPointerException npex) {
      throw new NullKeyFieldException(this.keyFields[i]);
    }
    catch (IndexOutOfBoundsException iobex) {
      throw new KeyFieldOutOfBoundsException(this.keyFields[i]);
    }
  }
View Full Code Here

  @Override
  public void setReference(Record toCompare) {
    for (int i = 0; i < this.keyFields.length; i++) {
      if (!toCompare.getFieldInto(this.keyFields[i], this.keyHolders[i])) {
        throw new NullKeyFieldException(this.keyFields[i]);
      }
    }
  }
View Full Code Here

  @Override
  public boolean equalToReference(Record candidate) {
    for (int i = 0; i < this.keyFields.length; i++) {
      final Key<?> k = candidate.getField(this.keyFields[i], this.transientKeyHolders[i]);
      if (k == null) {
        throw new NullKeyFieldException(this.keyFields[i]);
      } else if (!k.equals(this.keyHolders[i])) {
        return false;
      }
    }
    return true;
View Full Code Here

        }
      }
      return 0;
    }
    catch (NullPointerException e) {
      throw new NullKeyFieldException(this.keyFields[i]);
    }
  }
View Full Code Here

      final Key k1 = this.temp1.getField(this.keyFields[i], this.keyHolders[i]);
      @SuppressWarnings("rawtypes")
      final Key k2 = this.temp2.getField(this.keyFields[i], this.transientKeyHolders[i]);
     
      if (k1 == null || k2 == null) {
        throw new NullKeyFieldException(this.keyFields[i]);
      }
     
      @SuppressWarnings("unchecked")
      final int comp = k1.compareTo(k2);
      if (comp != 0) {
View Full Code Here

        numBytes -= len;
        offset += len;
      }
    }
    catch (NullPointerException npex) {
      throw new NullKeyFieldException(this.keyFields[i]);
    }
  }
View Full Code Here

TOP

Related Classes of org.apache.flink.types.NullKeyFieldException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.