Ignore:
Timestamp:
06/24/13 13:38:40 (11 years ago)
Author:
psniegowski
Message:

HIGHLIGHTS:

  • upgrade to Java 7
    • use try-multi-catch clauses
    • use try-with-resources were appropriate
  • configure FindBugs? (use mvn site and then navigate in browser to the report)
    • remove most bugs found
  • parametrize Dispatching environment (Dispatcher, RunAt?) to enforce more control on the place of closures actual call

CHANGELOG:
Rework FavouritesXMLFactory.

FindBugs?. Thread start.

FindBugs?. Minor change.

FindBugs?. Iterate over entrySet.

FindBugs?. Various.

FindBug?.

FindBug?. Encoding.

FindBug?. Final fields.

FindBug?.

Remove synchronization bug in ClientConnection?.

Experiments with findbugs.

Finish parametrization.

Make RunAt? an abstract class.

More changes in parametrization.

More changes in parametrizing dispatching.

Several changes to parametrize tasks.

Rename Runnable to RunAt?.

Add specific framsticks Runnable.

Add JSR305 (annotations).

Add findbugs reporting.

More improvements to ParamBuilder? wording.

Make FramsClass? accept also ParamBuilder?.

Change wording of ParamBuilder?.

Change wording of Request creation.

Use Java 7 exception catch syntax.

Add ScopeEnd? class.

Upgrade to Java 7.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • java/main/src/main/java/com/framsticks/core/Instance.java

    r84 r85  
    1212import com.framsticks.util.lang.Casting;
    1313import org.apache.log4j.Logger;
     14import com.framsticks.util.dispatching.RunAt;
    1415
    1516import java.util.*;
     
    3334        protected void run() {
    3435                super.run();
    35                 root = new Node((CompositeParam)new ParamBuilder().setName("Instance").setId(name).setType("o").build(), null);
     36                root = new Node((CompositeParam)Param.build().name("Instance").id(name).type("o").finish(), null);
    3637                com.framsticks.model.Package.register(registry);
    3738        }
     
    7172        public void storeValue(Path path, Param param, Object value, final StateFunctor stateFunctor) {
    7273                assert isActive();
    73                 invokeLater(new Runnable() {
     74                invokeLater(new RunAt<Instance>() {
    7475                        @Override
    7576                        public void run() {
     
    9394        public void addListener(final InstanceListener listener) {
    9495                assert Dispatching.isThreadSafe();
    95                 Dispatching.invokeLaterOrNow(this, new Runnable() {
     96                Dispatching.invokeLaterOrNow(this, new RunAt<Instance>() {
    9697                        @Override
    9798                        public void run() {
     
    103104        public void removeListener(final InstanceListener listener) {
    104105                assert Dispatching.isThreadSafe();
    105                 Dispatching.invokeLaterOrNow(this, new Runnable() {
     106                Dispatching.invokeLaterOrNow(this, new RunAt<Instance>() {
    106107                        @Override
    107108                        public void run() {
     
    271272                if ("/".equals(file.getPath())) {
    272273                        if (root.getParam().getContainedTypeName() == null) {
    273                                 root = new Node((CompositeParam)new ParamBuilder().setName("Instance").setId(name).setType("o " + framsClass.getId()).build(), root.getObject());
     274                                root = new Node((CompositeParam)Param.build().name("Instance").id(name).type("o " + framsClass.getId()).finish(), root.getObject());
    274275                        }
    275276                }
     
    310311
    311312                                        String id = listAccess.computeIdentifierFor(accessInterface.getSelected());
    312                                         Param param = new ParamBuilder().setType("o " + accessInterface.getId()).setId(id).build();
     313                                        Param param = Param.build().type("o " + accessInterface.getId()).id(id).finish();
    313314                                        Object child = accessInterface.getSelected();
    314315                                        accessInterface.select(null);
Note: See TracChangeset for help on using the changeset viewer.