/** * バージョンチェック用かどうかを処理します。 * * @param propertyMeta プロパティメタデータ * @param field フィールド * @param entityMeta エンティティメタデータ */ protected void doVersion( PropertyMeta propertyMeta, Field field, @SuppressWarnings("unused") EntityMeta entityMeta) { if (field.getAnnotation(Version.class) == null) { return; } Class<?> clazz = ClassUtil.getWrapperClassIfPrimitive(field.getType()); if (clazz != Integer.class && clazz != Long.class && clazz != int.class && clazz != long.class) { throw new VersionPropertyNotNumberRuntimeException( entityMeta.getName(), propertyMeta.getName()); } propertyMeta.setVersion(true); }