This commit is contained in:
@@ -459,7 +459,7 @@ public final class DataDefaultSource implements DataSource, Function<Class, Enti
|
|||||||
if (writeListener == null) {
|
if (writeListener == null) {
|
||||||
for (final T value : values) {
|
for (final T value : values) {
|
||||||
int i = 0;
|
int i = 0;
|
||||||
if (info.distributed) info.createPrimaryValue(value);
|
if (info.distributed || info.autouuid) info.createPrimaryValue(value);
|
||||||
for (Attribute<T, Serializable> attr : attrs) {
|
for (Attribute<T, Serializable> attr : attrs) {
|
||||||
prestmt.setObject(++i, attr.get(value));
|
prestmt.setObject(++i, attr.get(value));
|
||||||
}
|
}
|
||||||
@@ -471,7 +471,7 @@ public final class DataDefaultSource implements DataSource, Function<Class, Enti
|
|||||||
int index = 0;
|
int index = 0;
|
||||||
for (final T value : values) {
|
for (final T value : values) {
|
||||||
int i = 0;
|
int i = 0;
|
||||||
if (info.distributed || info.autoUUID) info.createPrimaryValue(value);
|
if (info.distributed || info.autouuid) info.createPrimaryValue(value);
|
||||||
for (Attribute<T, Serializable> attr : attrs) {
|
for (Attribute<T, Serializable> attr : attrs) {
|
||||||
Object a = attr.get(value);
|
Object a = attr.get(value);
|
||||||
ps[i] = FilterNode.formatToString(a);
|
ps[i] = FilterNode.formatToString(a);
|
||||||
|
|||||||
@@ -93,7 +93,7 @@ public final class EntityInfo<T> {
|
|||||||
|
|
||||||
final boolean autoGenerated;
|
final boolean autoGenerated;
|
||||||
|
|
||||||
final boolean autoUUID;
|
final boolean autouuid;
|
||||||
|
|
||||||
final boolean distributed;
|
final boolean distributed;
|
||||||
|
|
||||||
@@ -220,7 +220,6 @@ public final class EntityInfo<T> {
|
|||||||
uuid = true;
|
uuid = true;
|
||||||
auto = false;
|
auto = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!auto) {
|
if (!auto) {
|
||||||
insertcols.add(sqlfield);
|
insertcols.add(sqlfield);
|
||||||
insertattrs.add(attr);
|
insertattrs.add(attr);
|
||||||
@@ -272,7 +271,7 @@ public final class EntityInfo<T> {
|
|||||||
this.querySQL = null;
|
this.querySQL = null;
|
||||||
}
|
}
|
||||||
this.autoGenerated = auto;
|
this.autoGenerated = auto;
|
||||||
this.autoUUID = uuid;
|
this.autouuid = uuid;
|
||||||
this.distributed = sqldistribute;
|
this.distributed = sqldistribute;
|
||||||
this.allocationSize = allocationSize0;
|
this.allocationSize = allocationSize0;
|
||||||
//----------------cache--------------
|
//----------------cache--------------
|
||||||
@@ -291,7 +290,7 @@ public final class EntityInfo<T> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public void createPrimaryValue(T src) {
|
public void createPrimaryValue(T src) {
|
||||||
if (autoUUID) {
|
if (autouuid) {
|
||||||
getPrimary().set(src, Utility.uuid());
|
getPrimary().set(src, Utility.uuid());
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user