source: java/main/src/main/java/com/framsticks/params/ListAccess.java @ 84

Last change on this file since 84 was 84, checked in by psniegowski, 11 years ago

HIGHLIGHTS:

  • simplification of entities management model
  • cleanup around params (improve hierarchy)
  • migrate from JUnit to TestNG
  • introduce FEST to automatically test GUI
  • improve slider control
  • loosen synchronization between gui tree and backend representation
  • and many other bug fixes

NOTICE:

  • a great many of lines is changed only because of substituting spaces with tabs

CHANGELOG (oldest changes at the bottom):

Some cleaning after fix found.

Fix bug with tree.

More changes with TreeNodes?.

Finally fix issue with tree.

Improve gui tree management.

Decouple update of values from fetch request in gui.

Minor changes.

Minor changes.

Minor change.

Change Path construction wording.

More fixes to SliderControl?.

Fix SliderControl?.

Fix SliderControl?.

Minor improvement.

Several changes.

Make NumberParam? a generic class.

Add robot to the gui test.

Setup common testing logging configuration.

Remove Parameters class.

Remove entityOwner from Parameters.

Move name out from Parameters class.

Move configuration to after the construction.

Simplify observers and endpoints.

Remove superfluous configureEntity overrides.

Add dependency on fest-swing-testng.

Use FEST for final print test.

Use FEST for more concise and readable assertions.

Divide test of F0Parser into multiple methods.

Migrate to TestNG

Minor change.

Change convention from LOGGER to log.

Fix reporting of errors during controls filling.

Bound maximal height of SliderControl?.

Minor improvements.

Improve tooltips for controls.

Also use Delimeted in more places.

Move static control utilities to Gui.

Rename package gui.components to controls.

Some cleaning in controls.

Improve Param classes placing.

Move ValueParam?, PrimitiveParam? and CompositeParam? one package up.

Improve ParamBuilder?.

Move getDef to ValueParam? and PrimitiveParam?.

Move getMax and getDef to ValueParam?.

Move getMin to ValueParam?.

Upgrade to laters apache commons versions.

Use filterInstanceof extensively.

Add instanceof filters.

Make ValueParam? in many places of Param.

Place assertions about ValueParam?.

Add ValueParam?

Rename ValueParam? to PrimitiveParam?

Minor changes.

Several improvements to params types.

Add NumberParam?.

Add TextControl? component.

Add .swp files to .gitignore

Greatly improved slider component.

Some improvements.

Make Param.reassign return also a state.

Add IterableIterator?.

Several changes.

  • Move util classes to better packages.
  • Remove warnings from eclim.

Several improvements.

Fix bug with BooleanParam?.

Some experiments with visualization.

Another fix to panel management.

Improve panel management.

Some refactorization around panels.

Add root class for panel.

File size: 1.3 KB
Line 
1package com.framsticks.params;
2
3
4
5import static com.framsticks.util.lang.Containers.filterInstanceof;
6
7/**
8 * @author Piotr Sniegowski
9 */
10public abstract class ListAccess implements AccessInterface {
11
12        final AccessInterface elementAccess;
13
14        public ListAccess(AccessInterface elementAccess) {
15                this.elementAccess = elementAccess;
16        }
17
18        @Override
19        public Param getGroupMember(int gi, int n) {
20                return null;
21        }
22
23        @Override
24        public void setDefault(boolean numericOnly) {
25        }
26
27        @Override
28        public void setDefault(int i, boolean numericOnly) {
29        }
30
31        @Override
32        public void setMin() {
33        }
34
35        @Override
36        public void setMin(int i) {
37        }
38
39        @Override
40        public void setMax() {
41        }
42
43        @Override
44        public void setMax(int i) {
45        }
46
47        @Override
48        public void copyFrom(AccessInterface src) {
49        }
50
51        @Override
52        public void save(SinkInterface sink) {
53                for (CompositeParam p : filterInstanceof(getParams(), CompositeParam.class)) {
54                        Object child = get(p, Object.class);
55                        //this is probably an assertion
56                        assert child != null;
57                        elementAccess.select(child);
58                        elementAccess.save(sink);
59                }
60        }
61
62        @Override
63        public void load(SourceInterface stream) throws Exception {
64        }
65
66        public AccessInterface getElementAccess() {
67                return elementAccess;
68        }
69
70        public abstract String computeIdentifierFor(Object selected);
71
72        @Override
73        public final FramsClass getFramsClass() {
74                return elementAccess.getFramsClass();
75        }
76
77}
Note: See TracBrowser for help on using the repository browser.