Revision 40629
trunk/org.gvsig.desktop/org.gvsig.desktop.compat.cdc/org.gvsig.fmap.dal/org.gvsig.fmap.dal.impl/src/main/java/org/gvsig/fmap/dal/feature/impl/featureset/FastEditedIterator.java | ||
---|---|---|
45 | 45 |
super(featureSet); |
46 | 46 |
this.initializeFeature(); |
47 | 47 |
if (index > 0) { |
48 |
|
|
49 |
this.iterator = featureSet.provider.fastIterator(); |
|
50 |
setNewsFeatures(null); |
|
51 |
skypto(index); |
|
52 |
|
|
53 |
/* |
|
54 |
* This did not work because the provider |
|
55 |
* skips to the index without considering the |
|
56 |
* changes in editing mode. We need the |
|
57 |
* "skypto" method which knows about those |
|
58 |
* changes. |
|
59 |
* |
|
48 | 60 |
if (featureSet.provider.canIterateFromIndex()) { |
49 | 61 |
try { |
50 | 62 |
this.iterator = featureSet.provider.fastIterator(index); |
... | ... | |
62 | 74 |
setNewsFeatures(null); |
63 | 75 |
skypto(index); |
64 | 76 |
} |
77 |
*/ |
|
78 |
|
|
65 | 79 |
} else { |
66 | 80 |
this.iterator = featureSet.provider.fastIterator(); |
67 | 81 |
setNewsFeatures(featureManager.getInserted()); |
trunk/org.gvsig.desktop/org.gvsig.desktop.compat.cdc/org.gvsig.fmap.dal/org.gvsig.fmap.dal.impl/src/main/java/org/gvsig/fmap/dal/feature/impl/featureset/EditedIterator.java | ||
---|---|---|
61 | 61 |
this(featureSet); |
62 | 62 |
this.newsFeatures = null; |
63 | 63 |
if (index > 0) { |
64 |
if (featureSet.provider.canIterateFromIndex()) { |
|
64 |
|
|
65 |
this.iterator = featureSet.provider.iterator(); |
|
66 |
skypto(index); |
|
67 |
|
|
68 |
/* |
|
69 |
* This did not work because the provider |
|
70 |
* skips to the index without considering the |
|
71 |
* changes in editing mode. We need the |
|
72 |
* "skypto" method which knows about those |
|
73 |
* changes. |
|
74 |
* |
|
75 |
if (featureSet.provider.canIterateFromIndex()) { |
|
65 | 76 |
try { |
66 | 77 |
this.iterator = featureSet.provider.iterator(index); |
67 | 78 |
} catch (IllegalArgumentException e) { |
... | ... | |
75 | 86 |
this.iterator = featureSet.provider.iterator(); |
76 | 87 |
skypto(index); |
77 | 88 |
} |
89 |
*/ |
|
90 |
|
|
78 | 91 |
} else { |
79 | 92 |
this.iterator = featureSet.provider.iterator(); |
80 | 93 |
} |
trunk/org.gvsig.desktop/org.gvsig.desktop.compat.cdc/org.gvsig.fmap.dal/org.gvsig.fmap.dal.impl/src/main/java/org/gvsig/fmap/dal/feature/impl/featureset/FilteredIterator.java | ||
---|---|---|
62 | 62 |
|
63 | 63 |
protected void skypto(long index) { |
64 | 64 |
// TODO: Comprobar si esta bien la condicion de n<= |
65 |
for (long n = 0; n <= index && this.hasNext(); n++, this.next()) {
|
|
65 |
for (long n = 0; n < index && this.hasNext(); n++, this.next()) { |
|
66 | 66 |
; |
67 | 67 |
} |
68 | 68 |
} |
Also available in: Unified diff