summaryrefslogtreecommitdiff
path: root/nlpsolver/ThirdParty/EvolutionarySolver
diff options
context:
space:
mode:
authorrbuj <robert.buj@gmail.com>2014-08-07 14:06:11 +0200
committerDavid Tardon <dtardon@redhat.com>2014-08-07 12:48:44 +0000
commit90b4217e20af48e08352bdd6b478e7a8c59ee035 (patch)
tree10af33cddd5b3da72aac2a2d469d641d501ec06b /nlpsolver/ThirdParty/EvolutionarySolver
parentefbc5ac6cc4f8d7b57e4d24a70bae92fa0d22060 (diff)
nlpsolver: Use System.arraycopy
Change-Id: I2550bf0799bd5ebc7f6ff299752fa90b7a31674d Reviewed-on: https://gerrit.libreoffice.org/10806 Reviewed-by: David Tardon <dtardon@redhat.com> Tested-by: David Tardon <dtardon@redhat.com>
Diffstat (limited to 'nlpsolver/ThirdParty/EvolutionarySolver')
-rw-r--r--nlpsolver/ThirdParty/EvolutionarySolver/src/net/adaptivebox/knowledge/SearchPoint.java4
-rw-r--r--nlpsolver/ThirdParty/EvolutionarySolver/src/net/adaptivebox/space/DesignSpace.java4
2 files changed, 2 insertions, 6 deletions
diff --git a/nlpsolver/ThirdParty/EvolutionarySolver/src/net/adaptivebox/knowledge/SearchPoint.java b/nlpsolver/ThirdParty/EvolutionarySolver/src/net/adaptivebox/knowledge/SearchPoint.java
index 0085ff7e481e..c33d6490b4be 100644
--- a/nlpsolver/ThirdParty/EvolutionarySolver/src/net/adaptivebox/knowledge/SearchPoint.java
+++ b/nlpsolver/ThirdParty/EvolutionarySolver/src/net/adaptivebox/knowledge/SearchPoint.java
@@ -42,9 +42,7 @@ public class SearchPoint extends BasicPoint implements IEncodeEngine {
}
private void importEncodeInfo(double[] info) {
- for(int i=0; i<encodeInfo.length; i++) {
- encodeInfo[i] = info[i];
- }
+ System.arraycopy(info, 0, encodeInfo, 0, encodeInfo.length);
}
private void importEncodeInfo(IEncodeEngine point) {
diff --git a/nlpsolver/ThirdParty/EvolutionarySolver/src/net/adaptivebox/space/DesignSpace.java b/nlpsolver/ThirdParty/EvolutionarySolver/src/net/adaptivebox/space/DesignSpace.java
index 48f4df46042a..35e2ac0c7775 100644
--- a/nlpsolver/ThirdParty/EvolutionarySolver/src/net/adaptivebox/space/DesignSpace.java
+++ b/nlpsolver/ThirdParty/EvolutionarySolver/src/net/adaptivebox/space/DesignSpace.java
@@ -131,9 +131,7 @@ public class DesignSpace {
public double[] getRealLoc(double[] imageLoc) {
double[] realLoc = new double[imageLoc.length];
- for (int i=0; i<imageLoc.length; i++) {
- realLoc[i] = imageLoc[i];
- }
+ System.arraycopy(imageLoc, 0, realLoc, 0, imageLoc.length);
annulusAdjust(realLoc);
return realLoc;
}