/** * An alternative validation function used by CollectionsType in conjunction with CompositeType. * * This is similar to the compare function above. */ public void validateCollectionMember(ByteBuffer bytes, ByteBuffer collectionName) throws MarshalException { validate(bytes); }
public static boolean isValid(ByteBuffer term, AbstractType<?> validator) { try { validator.validate(term); return true; } catch (MarshalException e) { return false; } }
/** * Validate cell value. Unlike {@linkplain #validate(java.nio.ByteBuffer)}, * cell value is passed to validate its content. * Usually, this is the same as validate except collection. * * @param cellValue ByteBuffer representing cell value * @throws MarshalException */ public void validateCellValue(ByteBuffer cellValue) throws MarshalException { validate(cellValue); }
/** * An alternative validation function used by CollectionsType in conjunction with CompositeType. * * This is similar to the compare function above. */ public void validateCollectionMember(ByteBuffer bytes, ByteBuffer collectionName) throws MarshalException { validate(bytes); }
public static boolean isValid(ByteBuffer term, AbstractType<?> validator) { try { validator.validate(term); return true; } catch (MarshalException e) { return false; } }
/** * Validate cell value. Unlike {@linkplain #validate(java.nio.ByteBuffer)}, * cell value is passed to validate its content. * Usually, this is the same as validate except collection. * * @param cellValue ByteBuffer representing cell value * @throws MarshalException */ public void validateCellValue(ByteBuffer cellValue) throws MarshalException { validate(cellValue); }
/** * Validate cell value. Unlike {@linkplain #validate(java.nio.ByteBuffer)}, * cell value is passed to validate its content. * Usually, this is the same as validate except collection. * * @param cellValue ByteBuffer representing cell value * @throws MarshalException */ public void validateCellValue(ByteBuffer cellValue) throws MarshalException { validate(cellValue); }
/** * Validate cell value. Unlike {@linkplain #validate(java.nio.ByteBuffer)}, * cell value is passed to validate its content. * Usually, this is the same as validate except collection. * * @param cellValue ByteBuffer representing cell value * @throws MarshalException */ public void validateCellValue(ByteBuffer cellValue) throws MarshalException { validate(cellValue); }
/** * Validate cell value. Unlike {@linkplain #validate(java.nio.ByteBuffer)}, * cell value is passed to validate its content. * Usually, this is the same as validate except collection. * * @param cellValue ByteBuffer representing cell value * @throws MarshalException */ public void validateCellValue(ByteBuffer cellValue) throws MarshalException { validate(cellValue); }
public static boolean isValid(ByteBuffer term, AbstractType<?> validator) { try { validator.validate(term); return true; } catch (MarshalException e) { return false; } }
public void validateCollectionMember(ByteBuffer bytes, ByteBuffer collectionName) throws MarshalException { CollectionType t = defined.get(collectionName); if (t == null) throw new MarshalException(ByteBufferUtil.bytesToHex(collectionName) + " is not defined as a collection"); t.nameComparator().validate(bytes); }
public void validateCollectionMember(ByteBuffer bytes, ByteBuffer collectionName) throws MarshalException { CollectionType t = defined.get(collectionName); if (t == null) throw new MarshalException(ByteBufferUtil.bytesToHex(collectionName) + " is not defined as a collection"); t.nameComparator().validate(bytes); }
public void validateCollectionMember(ByteBuffer bytes, ByteBuffer collectionName) throws MarshalException { CollectionType t = defined.get(collectionName); if (t == null) throw new MarshalException(ByteBufferUtil.bytesToHex(collectionName) + " is not defined as a collection"); t.nameComparator().validate(bytes); }
public void validateCollectionMember(ByteBuffer bytes, ByteBuffer collectionName) throws MarshalException { CollectionType t = defined.get(collectionName); if (t == null) throw new MarshalException(ByteBufferUtil.bytesToHex(collectionName) + " is not defined as a collection"); t.nameComparator().validate(bytes); }
public void validateData(CFMetaData metadata) { ClusteringBoundOrBoundary bound = clustering(); for (int i = 0; i < bound.size(); i++) { ByteBuffer value = bound.get(i); if (value != null) metadata.comparator.subtype(i).validate(value); } }
public void validateData(CFMetaData metadata) { ClusteringBoundOrBoundary bound = clustering(); for (int i = 0; i < bound.size(); i++) { ByteBuffer value = bound.get(i); if (value != null) metadata.comparator.subtype(i).validate(value); } }
public void validateData(CFMetaData metadata) { ClusteringBoundOrBoundary bound = clustering(); for (int i = 0; i < bound.size(); i++) { ByteBuffer value = bound.get(i); if (value != null) metadata.comparator.subtype(i).validate(value); } }
private void validateCellPath(CellPath path) { if (!isComplex()) throw new MarshalException("Only complex cells should have a cell path"); assert type.isMultiCell(); if (type.isCollection()) ((CollectionType)type).nameComparator().validate(path.get(0)); else ((UserType)type).nameComparator().validate(path.get(0)); }
private void validateCellPath(CellPath path) { if (!isComplex()) throw new MarshalException("Only complex cells should have a cell path"); assert type.isMultiCell(); if (type.isCollection()) ((CollectionType)type).nameComparator().validate(path.get(0)); else ((UserType)type).nameComparator().validate(path.get(0)); }
private void validateCellPath(CellPath path) { if (!isComplex()) throw new MarshalException("Only complex cells should have a cell path"); assert type.isMultiCell(); if (type.isCollection()) ((CollectionType)type).nameComparator().validate(path.get(0)); else ((UserType)type).nameComparator().validate(path.get(0)); }